@blamechris/repo-memory 0.12.0 → 0.14.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -2
- package/dist/cache/generation.d.ts +50 -0
- package/dist/cache/generation.d.ts.map +1 -0
- package/dist/cache/generation.js +62 -0
- package/dist/cache/generation.js.map +1 -0
- package/dist/cache/invalidation.d.ts +3 -1
- package/dist/cache/invalidation.d.ts.map +1 -1
- package/dist/cache/invalidation.js +4 -5
- package/dist/cache/invalidation.js.map +1 -1
- package/dist/cache/ranking.d.ts +51 -6
- package/dist/cache/ranking.d.ts.map +1 -1
- package/dist/cache/ranking.js +92 -18
- package/dist/cache/ranking.js.map +1 -1
- package/dist/cache/store.d.ts +32 -0
- package/dist/cache/store.d.ts.map +1 -1
- package/dist/cache/store.js +110 -19
- package/dist/cache/store.js.map +1 -1
- package/dist/graph/dependency-graph.d.ts +14 -0
- package/dist/graph/dependency-graph.d.ts.map +1 -1
- package/dist/graph/dependency-graph.js +70 -5
- package/dist/graph/dependency-graph.js.map +1 -1
- package/dist/graph/refresh.d.ts +21 -0
- package/dist/graph/refresh.d.ts.map +1 -0
- package/dist/graph/refresh.js +101 -0
- package/dist/graph/refresh.js.map +1 -0
- package/dist/indexer/imports.d.ts.map +1 -1
- package/dist/indexer/imports.js +152 -86
- package/dist/indexer/imports.js.map +1 -1
- package/dist/indexer/project-map.d.ts +0 -2
- package/dist/indexer/project-map.d.ts.map +1 -1
- package/dist/indexer/project-map.js +0 -3
- package/dist/indexer/project-map.js.map +1 -1
- package/dist/indexer/source-extensions.d.ts +10 -0
- package/dist/indexer/source-extensions.d.ts.map +1 -0
- package/dist/indexer/source-extensions.js +28 -0
- package/dist/indexer/source-extensions.js.map +1 -0
- package/dist/indexer/summarize.d.ts +16 -1
- package/dist/indexer/summarize.d.ts.map +1 -1
- package/dist/indexer/summarize.js +38 -23
- package/dist/indexer/summarize.js.map +1 -1
- package/dist/persistence/db.d.ts.map +1 -1
- package/dist/persistence/db.js +78 -13
- package/dist/persistence/db.js.map +1 -1
- package/dist/server.js +18 -11
- package/dist/server.js.map +1 -1
- package/dist/tools/batch-file-summaries.d.ts +0 -1
- package/dist/tools/batch-file-summaries.d.ts.map +1 -1
- package/dist/tools/batch-file-summaries.js +1 -1
- package/dist/tools/batch-file-summaries.js.map +1 -1
- package/dist/tools/force-reread.d.ts.map +1 -1
- package/dist/tools/force-reread.js +7 -0
- package/dist/tools/force-reread.js.map +1 -1
- package/dist/tools/get-changed-files.d.ts.map +1 -1
- package/dist/tools/get-changed-files.js +23 -5
- package/dist/tools/get-changed-files.js.map +1 -1
- package/dist/tools/get-dependency-graph.d.ts +9 -7
- package/dist/tools/get-dependency-graph.d.ts.map +1 -1
- package/dist/tools/get-dependency-graph.js +51 -74
- package/dist/tools/get-dependency-graph.js.map +1 -1
- package/dist/tools/get-file-summary.d.ts +2 -3
- package/dist/tools/get-file-summary.d.ts.map +1 -1
- package/dist/tools/get-file-summary.js +11 -19
- package/dist/tools/get-file-summary.js.map +1 -1
- package/dist/tools/get-project-map.d.ts.map +1 -1
- package/dist/tools/get-project-map.js +9 -1
- package/dist/tools/get-project-map.js.map +1 -1
- package/dist/tools/get-related-files.d.ts.map +1 -1
- package/dist/tools/get-related-files.js +19 -71
- package/dist/tools/get-related-files.js.map +1 -1
- package/dist/tools/search-by-purpose.d.ts +2 -3
- package/dist/tools/search-by-purpose.d.ts.map +1 -1
- package/dist/tools/search-by-purpose.js +162 -44
- package/dist/tools/search-by-purpose.js.map +1 -1
- package/dist/types.d.ts +6 -0
- package/dist/types.d.ts.map +1 -1
- package/package.json +1 -1
|
@@ -1,7 +1,124 @@
|
|
|
1
|
+
import { readFile } from 'node:fs/promises';
|
|
2
|
+
import { join } from 'node:path';
|
|
3
|
+
import { hashContents } from '../cache/hash.js';
|
|
1
4
|
import { CacheStore } from '../cache/store.js';
|
|
5
|
+
import { ensureSummaryGeneration, summarizeForProject } from '../indexer/summarize.js';
|
|
2
6
|
import { TelemetryTracker } from '../telemetry/tracker.js';
|
|
3
7
|
import { toPosix } from '../utils/posix-path.js';
|
|
4
|
-
|
|
8
|
+
/** Max exports listed per result; the rest collapse into `exportsTruncated`. */
|
|
9
|
+
const MAX_EXPORTS_PER_RESULT = 5;
|
|
10
|
+
/**
|
|
11
|
+
* Lowercase word tokens of an identifier or free-text field: splits camelCase
|
|
12
|
+
* and PascalCase boundaries, snake_case, kebab-case, dots, and path
|
|
13
|
+
* separators. "CacheStore" -> ["cache","store"]; "get_file_summary" ->
|
|
14
|
+
* ["get","file","summary"].
|
|
15
|
+
*/
|
|
16
|
+
function tokenize(text) {
|
|
17
|
+
return text
|
|
18
|
+
.replace(/([a-z0-9])([A-Z])/g, '$1 $2')
|
|
19
|
+
.replace(/([A-Z]+)([A-Z][a-z])/g, '$1 $2')
|
|
20
|
+
.toLowerCase()
|
|
21
|
+
.split(/[^a-z0-9]+/)
|
|
22
|
+
.filter(Boolean);
|
|
23
|
+
}
|
|
24
|
+
/** Terms shorter than this only count on a whole-token match. */
|
|
25
|
+
const MIN_SUBSTRING_TERM = 3;
|
|
26
|
+
/**
|
|
27
|
+
* Match quality of one query term against one field, tiered by specificity:
|
|
28
|
+
* whole token (1.0) > token prefix (0.75) > bare substring (0.5). Short terms
|
|
29
|
+
* must match a whole token — "id" landing inside "validation" is noise, but
|
|
30
|
+
* "id" as an identifier word (findUserById) is a real hit.
|
|
31
|
+
*/
|
|
32
|
+
function termQuality(term, tokens, raw) {
|
|
33
|
+
if (tokens.includes(term))
|
|
34
|
+
return 1;
|
|
35
|
+
if (term.length < MIN_SUBSTRING_TERM)
|
|
36
|
+
return 0;
|
|
37
|
+
if (tokens.some((t) => t.startsWith(term)))
|
|
38
|
+
return 0.75;
|
|
39
|
+
if (raw.includes(term))
|
|
40
|
+
return 0.5;
|
|
41
|
+
return 0;
|
|
42
|
+
}
|
|
43
|
+
/**
|
|
44
|
+
* Score a cached entry against the query terms; null when nothing matched.
|
|
45
|
+
* Field weights: purpose 3 > exports 2 > declarations 1 = path 1. Each term
|
|
46
|
+
* contributes its match quality x the field weight, so a whole-word purpose
|
|
47
|
+
* hit outranks any pile of incidental substrings. Path segments count as a
|
|
48
|
+
* field of their own (sans extension) so directory and file names carry the
|
|
49
|
+
* concept signal they naturally encode — src/telemetry/tracker.ts should
|
|
50
|
+
* match "telemetry" even when its summary text doesn't say the word.
|
|
51
|
+
*/
|
|
52
|
+
function scoreEntry(path, summary, queryTerms) {
|
|
53
|
+
const fields = [
|
|
54
|
+
{
|
|
55
|
+
name: 'purpose',
|
|
56
|
+
weight: 3,
|
|
57
|
+
tokens: tokenize(summary.purpose),
|
|
58
|
+
raw: summary.purpose.toLowerCase(),
|
|
59
|
+
},
|
|
60
|
+
{
|
|
61
|
+
name: 'exports',
|
|
62
|
+
weight: 2,
|
|
63
|
+
tokens: summary.exports.flatMap(tokenize),
|
|
64
|
+
raw: summary.exports.join(' ').toLowerCase(),
|
|
65
|
+
},
|
|
66
|
+
{
|
|
67
|
+
name: 'declarations',
|
|
68
|
+
weight: 1,
|
|
69
|
+
tokens: summary.topLevelDeclarations.flatMap(tokenize),
|
|
70
|
+
raw: summary.topLevelDeclarations.join(' ').toLowerCase(),
|
|
71
|
+
},
|
|
72
|
+
{
|
|
73
|
+
name: 'path',
|
|
74
|
+
weight: 1,
|
|
75
|
+
tokens: tokenize(path.replace(/\.[a-z0-9]+$/i, '')),
|
|
76
|
+
raw: path.toLowerCase(),
|
|
77
|
+
},
|
|
78
|
+
];
|
|
79
|
+
const matchedOn = [];
|
|
80
|
+
let score = 0;
|
|
81
|
+
for (const field of fields) {
|
|
82
|
+
let fieldScore = 0;
|
|
83
|
+
for (const term of queryTerms) {
|
|
84
|
+
fieldScore += termQuality(term, field.tokens, field.raw) * field.weight;
|
|
85
|
+
}
|
|
86
|
+
if (fieldScore > 0) {
|
|
87
|
+
matchedOn.push(field.name);
|
|
88
|
+
score += fieldScore;
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
return matchedOn.length > 0 ? { matchedOn, score } : null;
|
|
92
|
+
}
|
|
93
|
+
/**
|
|
94
|
+
* Re-hash a matched candidate before serving it (never return stale data).
|
|
95
|
+
* - Missing/unreadable file: evict the dead cache entry and drop the result.
|
|
96
|
+
* - Hash mismatch: regenerate the summary through the standard path (same
|
|
97
|
+
* semantics as get_file_summary's cache-miss branch), re-score it against
|
|
98
|
+
* the query, and keep it only if it still matches.
|
|
99
|
+
*/
|
|
100
|
+
async function validateCandidate(projectRoot, store, candidate, queryTerms) {
|
|
101
|
+
let contents;
|
|
102
|
+
try {
|
|
103
|
+
contents = await readFile(join(projectRoot, candidate.entry.path), 'utf-8');
|
|
104
|
+
}
|
|
105
|
+
catch {
|
|
106
|
+
store.deleteEntry(candidate.entry.path);
|
|
107
|
+
return null;
|
|
108
|
+
}
|
|
109
|
+
const currentHash = hashContents(contents);
|
|
110
|
+
if (currentHash === candidate.entry.hash)
|
|
111
|
+
return candidate;
|
|
112
|
+
const summary = await summarizeForProject(projectRoot, candidate.entry.path, contents);
|
|
113
|
+
store.setEntry(candidate.entry.path, currentHash, summary);
|
|
114
|
+
const match = scoreEntry(candidate.entry.path, summary, queryTerms);
|
|
115
|
+
if (!match)
|
|
116
|
+
return null;
|
|
117
|
+
return { entry: candidate.entry, summary, matchedOn: match.matchedOn, score: match.score };
|
|
118
|
+
}
|
|
119
|
+
export async function searchByPurpose(projectRoot, query, limit, pathPrefix) {
|
|
120
|
+
// Never serve summaries from an invalidated generation (audit invariant I5).
|
|
121
|
+
ensureSummaryGeneration(projectRoot);
|
|
5
122
|
const store = new CacheStore(projectRoot);
|
|
6
123
|
const effectiveLimit = limit ?? 20;
|
|
7
124
|
// Optional scope: restrict the search to files at or under a directory/prefix.
|
|
@@ -23,57 +140,58 @@ export function searchByPurpose(projectRoot, query, limit, pathPrefix) {
|
|
|
23
140
|
})
|
|
24
141
|
: allEntries;
|
|
25
142
|
const queryTerms = query.toLowerCase().split(/\s+/).filter(Boolean);
|
|
26
|
-
const
|
|
143
|
+
const candidates = [];
|
|
27
144
|
for (const entry of entries) {
|
|
28
145
|
if (!entry.summary)
|
|
29
146
|
continue;
|
|
30
|
-
const
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
const purposeMatches = queryTerms.filter(term => purpose.includes(term));
|
|
34
|
-
if (purposeMatches.length > 0) {
|
|
35
|
-
matchedOn.push('purpose');
|
|
36
|
-
score += purposeMatches.length * 3; // purpose matches weighted highest
|
|
37
|
-
}
|
|
38
|
-
const exportsLower = entry.summary.exports.map(e => e.toLowerCase());
|
|
39
|
-
const exportMatches = queryTerms.filter(term => exportsLower.some(exp => exp.includes(term)));
|
|
40
|
-
if (exportMatches.length > 0) {
|
|
41
|
-
matchedOn.push('exports');
|
|
42
|
-
score += exportMatches.length * 2;
|
|
43
|
-
}
|
|
44
|
-
const declsLower = entry.summary.topLevelDeclarations.map(d => d.toLowerCase());
|
|
45
|
-
const declMatches = queryTerms.filter(term => declsLower.some(decl => decl.includes(term)));
|
|
46
|
-
if (declMatches.length > 0) {
|
|
47
|
-
matchedOn.push('declarations');
|
|
48
|
-
score += declMatches.length;
|
|
49
|
-
}
|
|
50
|
-
if (matchedOn.length > 0) {
|
|
51
|
-
results.push({
|
|
52
|
-
path: entry.path,
|
|
53
|
-
purpose: entry.summary.purpose,
|
|
54
|
-
matchedOn,
|
|
55
|
-
exports: entry.summary.exports,
|
|
56
|
-
confidence: entry.summary.confidence,
|
|
57
|
-
score,
|
|
58
|
-
});
|
|
147
|
+
const match = scoreEntry(entry.path, entry.summary, queryTerms);
|
|
148
|
+
if (match) {
|
|
149
|
+
candidates.push({ entry, summary: entry.summary, ...match });
|
|
59
150
|
}
|
|
60
151
|
}
|
|
61
152
|
// Sort by score descending
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
//
|
|
65
|
-
//
|
|
66
|
-
const
|
|
67
|
-
for (const
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
const
|
|
71
|
-
|
|
153
|
+
candidates.sort((a, b) => b.score - a.score);
|
|
154
|
+
// Validate before serving: walk the sorted candidates in score order until
|
|
155
|
+
// `limit` survive, so slots freed by dropped (deleted or no-longer-matching)
|
|
156
|
+
// files are backfilled from the remaining candidates in one pass.
|
|
157
|
+
const served = [];
|
|
158
|
+
for (const candidate of candidates) {
|
|
159
|
+
if (served.length >= effectiveLimit)
|
|
160
|
+
break;
|
|
161
|
+
const validated = await validateCandidate(projectRoot, store, candidate, queryTerms);
|
|
162
|
+
if (validated)
|
|
163
|
+
served.push(validated);
|
|
164
|
+
}
|
|
165
|
+
// Telemetry: ONE summary_served event per query, not per hit. Per-hit
|
|
166
|
+
// tracking booked every matched file as a full read avoided, inflating
|
|
167
|
+
// "tokens saved" by up to `limit`x. The realistic counterfactual for one
|
|
168
|
+
// search is the agent grepping and then reading roughly ONE candidate file
|
|
169
|
+
// in full, so we book the estimated raw-content tokens of one average
|
|
170
|
+
// served file (lineCount x ~40 chars/line / ~4 chars/token = lineCount x 10).
|
|
171
|
+
// Best-effort: a telemetry write failure (e.g. locked DB) must never fail
|
|
172
|
+
// the read path.
|
|
173
|
+
if (served.length > 0) {
|
|
174
|
+
try {
|
|
175
|
+
const avgLineCount = served.reduce((sum, c) => sum + c.summary.lineCount, 0) / served.length;
|
|
176
|
+
new TelemetryTracker(projectRoot).trackEvent('summary_served', served[0].entry.path, Math.round(avgLineCount * 10), { query, resultCount: served.length });
|
|
177
|
+
}
|
|
178
|
+
catch {
|
|
179
|
+
// Telemetry is best-effort on read paths (audit invariant I8).
|
|
180
|
+
}
|
|
72
181
|
}
|
|
73
182
|
return {
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
183
|
+
results: served.map((c) => {
|
|
184
|
+
const exports = c.summary.exports;
|
|
185
|
+
const capped = exports.length > MAX_EXPORTS_PER_RESULT;
|
|
186
|
+
return {
|
|
187
|
+
path: c.entry.path,
|
|
188
|
+
purpose: c.summary.purpose,
|
|
189
|
+
exports: capped ? exports.slice(0, MAX_EXPORTS_PER_RESULT) : exports,
|
|
190
|
+
...(capped ? { exportsTruncated: exports.length } : {}),
|
|
191
|
+
confidence: c.summary.confidence,
|
|
192
|
+
};
|
|
193
|
+
}),
|
|
194
|
+
totalCached: entries.filter((e) => e.summary).length,
|
|
77
195
|
...(normalizedPrefix ? { scope: normalizedPrefix } : {}),
|
|
78
196
|
};
|
|
79
197
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"search-by-purpose.js","sourceRoot":"","sources":["../../src/tools/search-by-purpose.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAC/C,OAAO,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;
|
|
1
|
+
{"version":3,"file":"search-by-purpose.js","sourceRoot":"","sources":["../../src/tools/search-by-purpose.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAC5C,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AACjC,OAAO,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC;AAChD,OAAO,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAC/C,OAAO,EAAE,uBAAuB,EAAE,mBAAmB,EAAE,MAAM,yBAAyB,CAAC;AACvF,OAAO,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAE3D,OAAO,EAAE,OAAO,EAAE,MAAM,wBAAwB,CAAC;AAEjD,gFAAgF;AAChF,MAAM,sBAAsB,GAAG,CAAC,CAAC;AAqBjC;;;;;GAKG;AACH,SAAS,QAAQ,CAAC,IAAY;IAC5B,OAAO,IAAI;SACR,OAAO,CAAC,oBAAoB,EAAE,OAAO,CAAC;SACtC,OAAO,CAAC,uBAAuB,EAAE,OAAO,CAAC;SACzC,WAAW,EAAE;SACb,KAAK,CAAC,YAAY,CAAC;SACnB,MAAM,CAAC,OAAO,CAAC,CAAC;AACrB,CAA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,GAAG,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,gBAAgB,EAAE,OAAO,CAAC,MAAM,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;gBACvD,UAAU,EAAE,CAAC,CAAC,OAAO,CAAC,UAAU;aACjC,CAAC;QACJ,CAAC,CAAC;QACF,WAAW,EAAE,OAAO,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,MAAM;QACpD,GAAG,CAAC,gBAAgB,CAAC,CAAC,CAAC,EAAE,KAAK,EAAE,gBAAgB,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;KACzD,CAAC;AACJ,CAAC"}
|
package/dist/types.d.ts
CHANGED
|
@@ -17,5 +17,11 @@ export interface ImportRef {
|
|
|
17
17
|
target: string;
|
|
18
18
|
specifiers: string[];
|
|
19
19
|
type: 'static' | 'dynamic' | 're-export';
|
|
20
|
+
/**
|
|
21
|
+
* True when the target does not resolve to a file inside the project
|
|
22
|
+
* (bare module specifiers, builtins, unresolvable relative paths).
|
|
23
|
+
* External refs are excluded from the dependency graph.
|
|
24
|
+
*/
|
|
25
|
+
external?: boolean;
|
|
20
26
|
}
|
|
21
27
|
//# sourceMappingURL=types.d.ts.map
|
package/dist/types.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,UAAU;IACzB,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,EAAE,MAAM,CAAC;IACpB,OAAO,EAAE,WAAW,GAAG,IAAI,CAAC;CAC7B;AAED,MAAM,WAAW,WAAW;IAC1B,OAAO,EAAE,MAAM,CAAC;IAChB,OAAO,EAAE,MAAM,EAAE,CAAC;IAClB,OAAO,EAAE,MAAM,EAAE,CAAC;IAClB,SAAS,EAAE,MAAM,CAAC;IAClB,oBAAoB,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