Repository navigation
fix(summary): key files are files, ranked by how often memory cites them - #35
Merged
Merged
Conversation
infer_file_mentions takes any dotted token, so Key files listed version numbers and identifiers (7.x, 23.1.2, ts.readConfigFile) as files, kept file:line spellings apart from the file, and ordered entries by first mention, which on an aged project is the setup week. Every candidate, now including event locations, goes through location_to_file, as precheck does. Paths under .projectmem/ are left out, and the list is ranked by the number of events citing each file.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
## Key filesinsummary.mdis built byinfer_file_mentions, which accepts any dotted token. On one of my projects (~3k events) 7 of the 20 entries were not files:The list also kept
src/auth.py:42apart fromsrc/auth.py, and it was ordered by first mention, which on an aged project means the files from the setup week.Change
location_to_file, the helper precheck already uses: line suffixes are stripped, and a bare name counts only with a known source suffix. Eventlocationvalues are now candidates too..projectmem/are left out.On the same project the list now holds 20 real files and no version numbers. Nothing in
events.jsonlchanges.Trade-off: a bare file name without a known suffix, such as
.gitignoreorMakefile, is no longer picked up from free text; with a directory (docker/Makefile) or as an event location it still is. That followslocation_to_file's rule rather than adding a second one.Tests
pyproject.tomlmentioned in text is keptbcryptandAuthService.loginas locations produce no entry,src/auth.pydoessrc/auth.py:42andsrc/auth.py:7merge intosrc/auth.py.projectmem/summary.mdleft outtest_summary_and_issue_file_are_regeneratednow expects`auth/redirect.py`instead of`auth/redirect.py:88`. The full suite passes (383).