@folterung/project-memory 0.1.21 → 0.1.22
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/package.json +1 -1
- package/packages/cli/coverage/lcov-report/chunking/chunker.ts.html +1 -1
- package/packages/cli/coverage/lcov-report/chunking/hash.ts.html +1 -1
- package/packages/cli/coverage/lcov-report/chunking/index.html +1 -1
- package/packages/cli/coverage/lcov-report/chunking/types.ts.html +1 -1
- package/packages/cli/coverage/lcov-report/config/index.html +7 -7
- package/packages/cli/coverage/lcov-report/config/load.ts.html +16 -4
- package/packages/cli/coverage/lcov-report/config/types.ts.html +35 -5
- package/packages/cli/coverage/lcov-report/embedding/index.html +1 -1
- package/packages/cli/coverage/lcov-report/embedding/stub.ts.html +1 -1
- package/packages/cli/coverage/lcov-report/index.html +21 -21
- package/packages/cli/coverage/lcov-report/qdrant/index.html +1 -1
- package/packages/cli/coverage/lcov-report/qdrant/upsert.ts.html +1 -1
- package/packages/cli/coverage/lcov-report/scope/allowlist.ts.html +1 -1
- package/packages/cli/coverage/lcov-report/scope/architecture-anchors.ts.html +529 -0
- package/packages/cli/coverage/lcov-report/scope/ignore.ts.html +1 -1
- package/packages/cli/coverage/lcov-report/scope/index.html +24 -9
- package/packages/cli/coverage/lcov.info +255 -19
- package/packages/cli/coverage/tmp/{coverage-24604-1770174821315-0.json → coverage-43283-1770177058833-0.json} +1 -1
- package/packages/cli/coverage/tmp/{coverage-24605-1770174821362-0.json → coverage-43284-1770177058881-0.json} +1 -1
- package/packages/cli/coverage/tmp/{coverage-24606-1770174821361-0.json → coverage-43285-1770177058878-0.json} +1 -1
- package/packages/cli/coverage/tmp/{coverage-24607-1770174821359-0.json → coverage-43286-1770177058876-0.json} +1 -1
- package/packages/cli/coverage/tmp/{coverage-24608-1770174821367-0.json → coverage-43287-1770177058882-0.json} +1 -1
- package/packages/cli/coverage/tmp/{coverage-24609-1770174821359-0.json → coverage-43288-1770177058880-0.json} +1 -1
- package/packages/cli/coverage/tmp/{coverage-24610-1770174821360-0.json → coverage-43289-1770177058879-0.json} +1 -1
- package/packages/cli/coverage/tmp/{coverage-24611-1770174821416-0.json → coverage-43290-1770177058933-0.json} +1 -1
- package/packages/cli/coverage/tmp/{coverage-24612-1770174821392-0.json → coverage-43291-1770177058905-0.json} +1 -1
- package/packages/cli/coverage/tmp/coverage-43292-1770177058903-0.json +1 -0
- package/packages/cli/coverage/tmp/{coverage-24613-1770174821380-0.json → coverage-43293-1770177058897-0.json} +1 -1
- package/packages/cli/dist/config/load.js +4 -0
- package/packages/cli/dist/config/load.js.map +1 -1
- package/packages/cli/dist/config/types.d.ts +8 -0
- package/packages/cli/dist/config/types.js +2 -0
- package/packages/cli/dist/config/types.js.map +1 -1
- package/packages/cli/dist/phase2/deep-index.js +39 -5
- package/packages/cli/dist/phase2/deep-index.js.map +1 -1
- package/packages/cli/dist/scope/architecture-anchors.d.ts +37 -0
- package/packages/cli/dist/scope/architecture-anchors.js +125 -0
- package/packages/cli/dist/scope/architecture-anchors.js.map +1 -0
- package/packages/cli/dist/scope/architecture-anchors.test.d.ts +1 -0
- package/packages/cli/dist/scope/architecture-anchors.test.js +58 -0
- package/packages/cli/dist/scope/architecture-anchors.test.js.map +1 -0
- package/packages/cli/src/config/load.ts +4 -0
- package/packages/cli/src/config/types.ts +11 -1
- package/packages/cli/src/phase2/deep-index.ts +43 -5
- package/packages/cli/src/scope/architecture-anchors.test.ts +83 -0
- package/packages/cli/src/scope/architecture-anchors.ts +148 -0
- package/packages/mcp-server/dist/system-instructions.md +7 -0
- package/packages/mcp-server/system-instructions.md +7 -0
- package/packages/server/coverage/lcov-report/api/index.html +5 -5
- package/packages/server/coverage/lcov-report/api/points.ts.html +1 -1
- package/packages/server/coverage/lcov-report/api/search.ts.html +14 -5
- package/packages/server/coverage/lcov-report/api/store.ts.html +1 -1
- package/packages/server/coverage/lcov-report/embedding/index.html +1 -1
- package/packages/server/coverage/lcov-report/embedding/stub.ts.html +1 -1
- package/packages/server/coverage/lcov-report/index.html +7 -7
- package/packages/server/coverage/lcov-report/qdrant/client.ts.html +1 -1
- package/packages/server/coverage/lcov-report/qdrant/index.html +1 -1
- package/packages/server/coverage/lcov.info +20 -17
- package/packages/server/coverage/tmp/{coverage-24692-1770174822211-0.json → coverage-43380-1770177059752-0.json} +1 -1
- package/packages/server/coverage/tmp/{coverage-24693-1770174822463-0.json → coverage-43381-1770177059983-0.json} +1 -1
- package/packages/server/coverage/tmp/{coverage-24694-1770174822454-0.json → coverage-43382-1770177059974-0.json} +1 -1
- package/packages/server/coverage/tmp/{coverage-24695-1770174822463-0.json → coverage-43383-1770177059981-0.json} +1 -1
- package/packages/server/coverage/tmp/{coverage-24696-1770174822253-0.json → coverage-43384-1770177059795-0.json} +1 -1
- package/packages/server/dist/api/search.js +3 -1
- package/packages/server/dist/api/search.js.map +1 -1
- package/packages/server/src/api/search.ts +4 -1
|
@@ -0,0 +1,148 @@
|
|
|
1
|
+
import fg from "fast-glob";
|
|
2
|
+
import { join } from "node:path";
|
|
3
|
+
import { statSync } from "node:fs";
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* Architecture anchors: deterministic path rules for tagging entrypoints, routing,
|
|
7
|
+
* DI, bootstrap, and config so they can be retrieved for system-overview queries.
|
|
8
|
+
* Two tiers: hard anchors (explicit paths, always tag) and soft anchors (broader
|
|
9
|
+
* globs restricted to allowed roots and optional file size).
|
|
10
|
+
* Binaries (pdf, images, archives, fonts, etc.) are never considered anchors.
|
|
11
|
+
*/
|
|
12
|
+
|
|
13
|
+
export type ArchitectureAnchorKind = "entrypoint" | "routing" | "bootstrap" | "di" | "config";
|
|
14
|
+
|
|
15
|
+
/** Extensions that are never considered architecture anchors (binaries / non-code). */
|
|
16
|
+
export const BINARY_EXTENSIONS = new Set([
|
|
17
|
+
"pdf", "png", "jpg", "jpeg", "gif", "ico", "webp", "svg",
|
|
18
|
+
"woff", "woff2", "ttf", "eot", "otf",
|
|
19
|
+
"zip", "tar", "gz", "rar", "7z",
|
|
20
|
+
"exe", "dll", "so", "dylib", "bin",
|
|
21
|
+
]);
|
|
22
|
+
|
|
23
|
+
/** Default roots under which soft anchors are allowed (reduces false positives). */
|
|
24
|
+
export const DEFAULT_SOFT_ANCHOR_ROOTS = ["app/", "src/", "public/", "server/", "api/"];
|
|
25
|
+
|
|
26
|
+
/** Default max file size (bytes) for soft anchors; larger files are not tagged. */
|
|
27
|
+
export const DEFAULT_MAX_SOFT_ANCHOR_FILE_BYTES = 200 * 1024;
|
|
28
|
+
|
|
29
|
+
export interface GetArchitectureAnchorKindOptions {
|
|
30
|
+
fileSizeBytes?: number;
|
|
31
|
+
allowedRoots?: string[];
|
|
32
|
+
maxSoftAnchorFileBytes?: number;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
/**
|
|
36
|
+
* Returns the architecture anchor kind for a relative path, or undefined if not an anchor.
|
|
37
|
+
* Hard anchors (explicit entrypoint/wiring paths) are always tagged when matched.
|
|
38
|
+
* Soft anchors (broader patterns) are only tagged when path is under allowedRoots
|
|
39
|
+
* and (when fileSizeBytes is provided) under maxSoftAnchorFileBytes.
|
|
40
|
+
* Paths with binary extensions are never anchors.
|
|
41
|
+
*/
|
|
42
|
+
export function getArchitectureAnchorKind(
|
|
43
|
+
relativePath: string,
|
|
44
|
+
options?: GetArchitectureAnchorKindOptions
|
|
45
|
+
): ArchitectureAnchorKind | undefined {
|
|
46
|
+
const normalized = relativePath.replace(/\\/g, "/");
|
|
47
|
+
const ext = extFromPath(normalized);
|
|
48
|
+
if (ext && BINARY_EXTENSIONS.has(ext.toLowerCase())) {
|
|
49
|
+
return undefined;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
const kind = matchHardAnchor(normalized) ?? matchSoftAnchor(normalized, options);
|
|
53
|
+
return kind;
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
function extFromPath(path: string): string {
|
|
57
|
+
const i = path.lastIndexOf(".");
|
|
58
|
+
if (i === -1) return "";
|
|
59
|
+
return path.slice(i + 1);
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
/** Hard anchors: explicit, narrow paths. No size/root constraints. */
|
|
63
|
+
function matchHardAnchor(normalized: string): ArchitectureAnchorKind | undefined {
|
|
64
|
+
const entrypointExts = ["ts", "tsx", "js", "jsx", "html", "php"];
|
|
65
|
+
if (pathMatches(normalized, "public/index", entrypointExts)) return "entrypoint";
|
|
66
|
+
if (pathMatches(normalized, "src/index", ["ts", "tsx", "js", "jsx"])) return "entrypoint";
|
|
67
|
+
if (pathMatches(normalized, "server/index", ["ts", "js"])) return "entrypoint";
|
|
68
|
+
if (pathMatches(normalized, "api/index", ["ts", "js"])) return "entrypoint";
|
|
69
|
+
if (pathMatches(normalized, "app/index", ["ts", "tsx", "js", "jsx", "php"])) return "entrypoint";
|
|
70
|
+
|
|
71
|
+
if (pathMatches(normalized, "app/routes", ["ts", "js"])) return "routing";
|
|
72
|
+
if (pathMatches(normalized, "app/dependencies", ["ts", "js"])) return "di";
|
|
73
|
+
if (pathMatches(normalized, "app/settings", ["ts", "js"])) return "config";
|
|
74
|
+
return undefined;
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
function pathMatches(normalized: string, prefix: string, exts: string[]): boolean {
|
|
78
|
+
for (const ext of exts) {
|
|
79
|
+
if (normalized === `${prefix}.${ext}`) return true;
|
|
80
|
+
}
|
|
81
|
+
return false;
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
/** Soft anchors: broader patterns, only under allowed roots and optional size cap. */
|
|
85
|
+
function matchSoftAnchor(
|
|
86
|
+
normalized: string,
|
|
87
|
+
options?: GetArchitectureAnchorKindOptions
|
|
88
|
+
): ArchitectureAnchorKind | undefined {
|
|
89
|
+
const roots = options?.allowedRoots ?? DEFAULT_SOFT_ANCHOR_ROOTS;
|
|
90
|
+
const underRoot = roots.some((r) => normalized === r.slice(0, -1) || normalized.startsWith(r));
|
|
91
|
+
if (!underRoot) return undefined;
|
|
92
|
+
|
|
93
|
+
const maxBytes = options?.maxSoftAnchorFileBytes ?? DEFAULT_MAX_SOFT_ANCHOR_FILE_BYTES;
|
|
94
|
+
if (options?.fileSizeBytes != null && options.fileSizeBytes > maxBytes) {
|
|
95
|
+
return undefined;
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
if (normalized.includes("/routes/") || /\/routes\.(ts|js)$/.test(normalized)) return "routing";
|
|
99
|
+
if (/\/container[\w.-]*\.(ts|js)$/.test(normalized)) return "di";
|
|
100
|
+
if (/\/di[\w.-]*\.(ts|js)$/.test(normalized)) return "di";
|
|
101
|
+
if (/\/middleware[\w.-]*\.(ts|js)$/.test(normalized)) return "bootstrap";
|
|
102
|
+
if (/\/bootstrap[\w.-]*\.(ts|js)$/.test(normalized)) return "bootstrap";
|
|
103
|
+
if (/\/config[\w.-]*\.(ts|js|yml|yaml)$/.test(normalized)) return "config";
|
|
104
|
+
if (/\/settings[\w.-]*\.(ts|js)$/.test(normalized)) return "config";
|
|
105
|
+
return undefined;
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
export interface ListArchitectureAnchorPathsOptions {
|
|
109
|
+
allowedRoots?: string[];
|
|
110
|
+
maxSoftAnchorFileBytes?: number;
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
/**
|
|
114
|
+
* Returns absolute paths of files in the repo that match architecture anchor rules.
|
|
115
|
+
* Used when allowOutsideInclude is true to merge anchor paths into eligible paths.
|
|
116
|
+
* Binary extensions are excluded; soft anchors are restricted to allowedRoots and file size.
|
|
117
|
+
*/
|
|
118
|
+
export function listArchitectureAnchorPaths(
|
|
119
|
+
cwd: string,
|
|
120
|
+
options?: ListArchitectureAnchorPathsOptions
|
|
121
|
+
): string[] {
|
|
122
|
+
const allowedRoots = options?.allowedRoots ?? DEFAULT_SOFT_ANCHOR_ROOTS;
|
|
123
|
+
const maxBytes = options?.maxSoftAnchorFileBytes ?? DEFAULT_MAX_SOFT_ANCHOR_FILE_BYTES;
|
|
124
|
+
const files = fg.sync("**/*", {
|
|
125
|
+
cwd,
|
|
126
|
+
dot: true,
|
|
127
|
+
onlyFiles: true,
|
|
128
|
+
absolute: true,
|
|
129
|
+
suppressErrors: true,
|
|
130
|
+
});
|
|
131
|
+
const result: string[] = [];
|
|
132
|
+
for (const abs of files) {
|
|
133
|
+
const rel = abs.slice(cwd.length).replace(/^[/\\]+/, "").replace(/\\/g, "/");
|
|
134
|
+
let fileSizeBytes: number | undefined;
|
|
135
|
+
try {
|
|
136
|
+
fileSizeBytes = statSync(abs).size;
|
|
137
|
+
} catch {
|
|
138
|
+
continue;
|
|
139
|
+
}
|
|
140
|
+
const kind = getArchitectureAnchorKind(rel, {
|
|
141
|
+
fileSizeBytes,
|
|
142
|
+
allowedRoots,
|
|
143
|
+
maxSoftAnchorFileBytes: maxBytes,
|
|
144
|
+
});
|
|
145
|
+
if (kind != null) result.push(abs);
|
|
146
|
+
}
|
|
147
|
+
return result;
|
|
148
|
+
}
|
|
@@ -22,3 +22,10 @@ You are using Project Memory as a **verification and consistency layer** and a *
|
|
|
22
22
|
- **Pre-store memory hygiene checklist** (for session summaries): Before storing, (a) search for existing summary in same scope/topic, (b) if found prefer superseding via `supersedesId`, (c) ensure template compliance, (d) include scope if applicable.
|
|
23
23
|
- **Justifications:** Every stored or updated memory entry must include a **short justification** (why it improves future correctness). Justifications are trust signals for future agents.
|
|
24
24
|
- **Temporal decay:** Older or low-confidence memory is more likely to require re-verification over time (e.g. after refactors, migrations, or architectural changes). Treat such entries as candidates for re-check against the repository, not as settled fact.
|
|
25
|
+
|
|
26
|
+
## Architecture and system-overview queries
|
|
27
|
+
|
|
28
|
+
When answering **application architecture**, **system overview**, or **how the app is wired**:
|
|
29
|
+
|
|
30
|
+
- **Retrieval:** Use `search_project_memory` with `refsOnly: true` and `intent: "navigation"`. Prefer architecture anchor kinds when available (default includes entrypoint, routing, bootstrap, di, config). De-prioritize DTOs, models, PDFs/binaries, `.git`, `vendor`, and submodule metadata. Select 5–12 high-signal refs, then call `get_project_memory_items(ids)` to expand; do not answer from refs alone.
|
|
31
|
+
- **Query wording:** Favor concrete wiring terms ("entry point", "routes", "dependencies", "container", "settings", "middleware", "bootstrap", "config") instead of generic "architecture" or "system overview" to reduce irrelevant chunks.
|
|
@@ -22,3 +22,10 @@ You are using Project Memory as a **verification and consistency layer** and a *
|
|
|
22
22
|
- **Pre-store memory hygiene checklist** (for session summaries): Before storing, (a) search for existing summary in same scope/topic, (b) if found prefer superseding via `supersedesId`, (c) ensure template compliance, (d) include scope if applicable.
|
|
23
23
|
- **Justifications:** Every stored or updated memory entry must include a **short justification** (why it improves future correctness). Justifications are trust signals for future agents.
|
|
24
24
|
- **Temporal decay:** Older or low-confidence memory is more likely to require re-verification over time (e.g. after refactors, migrations, or architectural changes). Treat such entries as candidates for re-check against the repository, not as settled fact.
|
|
25
|
+
|
|
26
|
+
## Architecture and system-overview queries
|
|
27
|
+
|
|
28
|
+
When answering **application architecture**, **system overview**, or **how the app is wired**:
|
|
29
|
+
|
|
30
|
+
- **Retrieval:** Use `search_project_memory` with `refsOnly: true` and `intent: "navigation"`. Prefer architecture anchor kinds when available (default includes entrypoint, routing, bootstrap, di, config). De-prioritize DTOs, models, PDFs/binaries, `.git`, `vendor`, and submodule metadata. Select 5–12 high-signal refs, then call `get_project_memory_items(ids)` to expand; do not answer from refs alone.
|
|
31
|
+
- **Query wording:** Favor concrete wiring terms ("entry point", "routes", "dependencies", "container", "settings", "middleware", "bootstrap", "config") instead of generic "architecture" or "system overview" to reduce irrelevant chunks.
|
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
<div class='fl pad1y space-right2'>
|
|
26
26
|
<span class="strong">100% </span>
|
|
27
27
|
<span class="quiet">Statements</span>
|
|
28
|
-
<span class='fraction'>
|
|
28
|
+
<span class='fraction'>346/346</span>
|
|
29
29
|
</div>
|
|
30
30
|
|
|
31
31
|
|
|
@@ -46,7 +46,7 @@
|
|
|
46
46
|
<div class='fl pad1y space-right2'>
|
|
47
47
|
<span class="strong">100% </span>
|
|
48
48
|
<span class="quiet">Lines</span>
|
|
49
|
-
<span class='fraction'>
|
|
49
|
+
<span class='fraction'>346/346</span>
|
|
50
50
|
</div>
|
|
51
51
|
|
|
52
52
|
|
|
@@ -99,13 +99,13 @@
|
|
|
99
99
|
<div class="chart"><div class="cover-fill cover-full" style="width: 100%"></div><div class="cover-empty" style="width: 0%"></div></div>
|
|
100
100
|
</td>
|
|
101
101
|
<td data-value="100" class="pct high">100%</td>
|
|
102
|
-
<td data-value="
|
|
102
|
+
<td data-value="120" class="abs high">120/120</td>
|
|
103
103
|
<td data-value="70.58" class="pct medium">70.58%</td>
|
|
104
104
|
<td data-value="17" class="abs medium">12/17</td>
|
|
105
105
|
<td data-value="100" class="pct high">100%</td>
|
|
106
106
|
<td data-value="2" class="abs high">2/2</td>
|
|
107
107
|
<td data-value="100" class="pct high">100%</td>
|
|
108
|
-
<td data-value="
|
|
108
|
+
<td data-value="120" class="abs high">120/120</td>
|
|
109
109
|
</tr>
|
|
110
110
|
|
|
111
111
|
<tr>
|
|
@@ -131,7 +131,7 @@
|
|
|
131
131
|
<div class='footer quiet pad2 space-top1 center small'>
|
|
132
132
|
Code coverage generated by
|
|
133
133
|
<a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
|
|
134
|
-
at 2026-02-04T03:
|
|
134
|
+
at 2026-02-04T03:51:00.028Z
|
|
135
135
|
</div>
|
|
136
136
|
<script src="../prettify.js"></script>
|
|
137
137
|
<script>
|
|
@@ -346,7 +346,7 @@ export function registerPointsRoutes(
|
|
|
346
346
|
<div class='footer quiet pad2 space-top1 center small'>
|
|
347
347
|
Code coverage generated by
|
|
348
348
|
<a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
|
|
349
|
-
at 2026-02-04T03:
|
|
349
|
+
at 2026-02-04T03:51:00.028Z
|
|
350
350
|
</div>
|
|
351
351
|
<script src="../prettify.js"></script>
|
|
352
352
|
<script>
|
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
<div class='fl pad1y space-right2'>
|
|
26
26
|
<span class="strong">100% </span>
|
|
27
27
|
<span class="quiet">Statements</span>
|
|
28
|
-
<span class='fraction'>
|
|
28
|
+
<span class='fraction'>120/120</span>
|
|
29
29
|
</div>
|
|
30
30
|
|
|
31
31
|
|
|
@@ -46,7 +46,7 @@
|
|
|
46
46
|
<div class='fl pad1y space-right2'>
|
|
47
47
|
<span class="strong">100% </span>
|
|
48
48
|
<span class="quiet">Lines</span>
|
|
49
|
-
<span class='fraction'>
|
|
49
|
+
<span class='fraction'>120/120</span>
|
|
50
50
|
</div>
|
|
51
51
|
|
|
52
52
|
|
|
@@ -180,7 +180,10 @@
|
|
|
180
180
|
<a name='L115'></a><a href='#L115'>115</a>
|
|
181
181
|
<a name='L116'></a><a href='#L116'>116</a>
|
|
182
182
|
<a name='L117'></a><a href='#L117'>117</a>
|
|
183
|
-
<a name='L118'></a><a href='#L118'>118</a
|
|
183
|
+
<a name='L118'></a><a href='#L118'>118</a>
|
|
184
|
+
<a name='L119'></a><a href='#L119'>119</a>
|
|
185
|
+
<a name='L120'></a><a href='#L120'>120</a>
|
|
186
|
+
<a name='L121'></a><a href='#L121'>121</a></td><td class="line-coverage quiet"><span class="cline-any cline-yes">1x</span>
|
|
184
187
|
<span class="cline-any cline-yes">1x</span>
|
|
185
188
|
<span class="cline-any cline-yes">1x</span>
|
|
186
189
|
<span class="cline-any cline-yes">1x</span>
|
|
@@ -297,6 +300,9 @@
|
|
|
297
300
|
<span class="cline-any cline-yes">4x</span>
|
|
298
301
|
<span class="cline-any cline-yes">4x</span>
|
|
299
302
|
<span class="cline-any cline-yes">4x</span>
|
|
303
|
+
<span class="cline-any cline-yes">4x</span>
|
|
304
|
+
<span class="cline-any cline-yes">4x</span>
|
|
305
|
+
<span class="cline-any cline-yes">4x</span>
|
|
300
306
|
<span class="cline-any cline-neutral"> </span></td><td class="text"><pre class="prettyprint lang-js">import type { FastifyInstance } from "fastify";
|
|
301
307
|
import type { QdrantClient } from "@qdrant/js-client-rest";
|
|
302
308
|
import { createQdrantClient } from "../qdrant/client.js";
|
|
@@ -373,7 +379,10 @@ export function registerSearchRoutes(
|
|
|
373
379
|
limitChunks,
|
|
374
380
|
} = request.body;
|
|
375
381
|
const vector = embedText(query<span class="branch-0 cbranch-no" title="branch not covered" > ?? "")</span>;
|
|
376
|
-
const chunkKinds =
|
|
382
|
+
const chunkKinds =
|
|
383
|
+
kinds && kinds.length > 0
|
|
384
|
+
? kinds
|
|
385
|
+
: ["chunk", "entrypoint", "routing", "bootstrap", "di", "config", "agent_note"];
|
|
377
386
|
const chunkLimit = limitChunks ?? limit;
|
|
378
387
|
|
|
379
388
|
const [systemMaps, moduleSummaries, chunks] = await Promise.all([
|
|
@@ -421,7 +430,7 @@ export function registerSearchRoutes(
|
|
|
421
430
|
<div class='footer quiet pad2 space-top1 center small'>
|
|
422
431
|
Code coverage generated by
|
|
423
432
|
<a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
|
|
424
|
-
at 2026-02-04T03:
|
|
433
|
+
at 2026-02-04T03:51:00.028Z
|
|
425
434
|
</div>
|
|
426
435
|
<script src="../prettify.js"></script>
|
|
427
436
|
<script>
|
|
@@ -472,7 +472,7 @@ export function registerStoreRoutes(
|
|
|
472
472
|
<div class='footer quiet pad2 space-top1 center small'>
|
|
473
473
|
Code coverage generated by
|
|
474
474
|
<a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
|
|
475
|
-
at 2026-02-04T03:
|
|
475
|
+
at 2026-02-04T03:51:00.028Z
|
|
476
476
|
</div>
|
|
477
477
|
<script src="../prettify.js"></script>
|
|
478
478
|
<script>
|
|
@@ -101,7 +101,7 @@
|
|
|
101
101
|
<div class='footer quiet pad2 space-top1 center small'>
|
|
102
102
|
Code coverage generated by
|
|
103
103
|
<a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
|
|
104
|
-
at 2026-02-04T03:
|
|
104
|
+
at 2026-02-04T03:51:00.028Z
|
|
105
105
|
</div>
|
|
106
106
|
<script src="../prettify.js"></script>
|
|
107
107
|
<script>
|
|
@@ -169,7 +169,7 @@ export function getVectorSize(): number {
|
|
|
169
169
|
<div class='footer quiet pad2 space-top1 center small'>
|
|
170
170
|
Code coverage generated by
|
|
171
171
|
<a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
|
|
172
|
-
at 2026-02-04T03:
|
|
172
|
+
at 2026-02-04T03:51:00.028Z
|
|
173
173
|
</div>
|
|
174
174
|
<script src="../prettify.js"></script>
|
|
175
175
|
<script>
|
|
@@ -23,9 +23,9 @@
|
|
|
23
23
|
<div class='clearfix'>
|
|
24
24
|
|
|
25
25
|
<div class='fl pad1y space-right2'>
|
|
26
|
-
<span class="strong">97.
|
|
26
|
+
<span class="strong">97.89% </span>
|
|
27
27
|
<span class="quiet">Statements</span>
|
|
28
|
-
<span class='fraction'>
|
|
28
|
+
<span class='fraction'>512/523</span>
|
|
29
29
|
</div>
|
|
30
30
|
|
|
31
31
|
|
|
@@ -44,9 +44,9 @@
|
|
|
44
44
|
|
|
45
45
|
|
|
46
46
|
<div class='fl pad1y space-right2'>
|
|
47
|
-
<span class="strong">97.
|
|
47
|
+
<span class="strong">97.89% </span>
|
|
48
48
|
<span class="quiet">Lines</span>
|
|
49
|
-
<span class='fraction'>
|
|
49
|
+
<span class='fraction'>512/523</span>
|
|
50
50
|
</div>
|
|
51
51
|
|
|
52
52
|
|
|
@@ -84,13 +84,13 @@
|
|
|
84
84
|
<div class="chart"><div class="cover-fill cover-full" style="width: 100%"></div><div class="cover-empty" style="width: 0%"></div></div>
|
|
85
85
|
</td>
|
|
86
86
|
<td data-value="100" class="pct high">100%</td>
|
|
87
|
-
<td data-value="
|
|
87
|
+
<td data-value="346" class="abs high">346/346</td>
|
|
88
88
|
<td data-value="83.87" class="pct high">83.87%</td>
|
|
89
89
|
<td data-value="62" class="abs high">52/62</td>
|
|
90
90
|
<td data-value="100" class="pct high">100%</td>
|
|
91
91
|
<td data-value="6" class="abs high">6/6</td>
|
|
92
92
|
<td data-value="100" class="pct high">100%</td>
|
|
93
|
-
<td data-value="
|
|
93
|
+
<td data-value="346" class="abs high">346/346</td>
|
|
94
94
|
</tr>
|
|
95
95
|
|
|
96
96
|
<tr>
|
|
@@ -131,7 +131,7 @@
|
|
|
131
131
|
<div class='footer quiet pad2 space-top1 center small'>
|
|
132
132
|
Code coverage generated by
|
|
133
133
|
<a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
|
|
134
|
-
at 2026-02-04T03:
|
|
134
|
+
at 2026-02-04T03:51:00.028Z
|
|
135
135
|
</div>
|
|
136
136
|
<script src="prettify.js"></script>
|
|
137
137
|
<script>
|
|
@@ -502,7 +502,7 @@ export async function retrievePointsById(
|
|
|
502
502
|
<div class='footer quiet pad2 space-top1 center small'>
|
|
503
503
|
Code coverage generated by
|
|
504
504
|
<a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
|
|
505
|
-
at 2026-02-04T03:
|
|
505
|
+
at 2026-02-04T03:51:00.028Z
|
|
506
506
|
</div>
|
|
507
507
|
<script src="../prettify.js"></script>
|
|
508
508
|
<script>
|
|
@@ -101,7 +101,7 @@
|
|
|
101
101
|
<div class='footer quiet pad2 space-top1 center small'>
|
|
102
102
|
Code coverage generated by
|
|
103
103
|
<a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
|
|
104
|
-
at 2026-02-04T03:
|
|
104
|
+
at 2026-02-04T03:51:00.028Z
|
|
105
105
|
</div>
|
|
106
106
|
<script src="../prettify.js"></script>
|
|
107
107
|
<script>
|
|
@@ -117,7 +117,7 @@ end_of_record
|
|
|
117
117
|
TN:
|
|
118
118
|
SF:src/api/search.ts
|
|
119
119
|
FN:37,registerSearchRoutes
|
|
120
|
-
FN:
|
|
120
|
+
FN:89,textForChunk
|
|
121
121
|
FNF:2
|
|
122
122
|
FNH:2
|
|
123
123
|
FNDA:4,registerSearchRoutes
|
|
@@ -239,25 +239,28 @@ DA:114,4
|
|
|
239
239
|
DA:115,4
|
|
240
240
|
DA:116,4
|
|
241
241
|
DA:117,4
|
|
242
|
-
|
|
243
|
-
|
|
242
|
+
DA:118,4
|
|
243
|
+
DA:119,4
|
|
244
|
+
DA:120,4
|
|
245
|
+
LF:120
|
|
246
|
+
LH:120
|
|
244
247
|
BRDA:37,0,0,4
|
|
245
248
|
BRDA:42,1,0,0
|
|
246
249
|
BRDA:66,2,0,4
|
|
247
250
|
BRDA:76,3,0,0
|
|
248
|
-
BRDA:
|
|
249
|
-
BRDA:
|
|
250
|
-
BRDA:
|
|
251
|
-
BRDA:
|
|
252
|
-
BRDA:
|
|
253
|
-
BRDA:
|
|
254
|
-
BRDA:
|
|
255
|
-
BRDA:
|
|
256
|
-
BRDA:
|
|
257
|
-
BRDA:
|
|
258
|
-
BRDA:
|
|
259
|
-
BRDA:
|
|
260
|
-
BRDA:
|
|
251
|
+
BRDA:78,4,0,1
|
|
252
|
+
BRDA:79,5,0,1
|
|
253
|
+
BRDA:80,6,0,3
|
|
254
|
+
BRDA:89,7,0,12
|
|
255
|
+
BRDA:90,8,0,3
|
|
256
|
+
BRDA:90,9,0,3
|
|
257
|
+
BRDA:90,10,0,9
|
|
258
|
+
BRDA:93,11,0,4
|
|
259
|
+
BRDA:95,12,0,0
|
|
260
|
+
BRDA:98,13,0,4
|
|
261
|
+
BRDA:100,14,0,0
|
|
262
|
+
BRDA:103,15,0,4
|
|
263
|
+
BRDA:105,16,0,0
|
|
261
264
|
BRF:17
|
|
262
265
|
BRH:12
|
|
263
266
|
end_of_record
|
|
@@ -676,7 +679,7 @@ BRDA:50,5,0,8
|
|
|
676
679
|
BRDA:59,6,0,0
|
|
677
680
|
BRDA:63,7,0,4
|
|
678
681
|
BRDA:73,8,0,0
|
|
679
|
-
BRDA:72,9,0,
|
|
682
|
+
BRDA:72,9,0,22
|
|
680
683
|
BRDA:77,10,0,3
|
|
681
684
|
BRDA:78,11,0,0
|
|
682
685
|
BRDA:85,12,0,0
|