@ttsc/graph 0.16.5 → 0.16.6

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.
Files changed (61) hide show
  1. package/lib/TtscGraphApplication.js +36 -23
  2. package/lib/TtscGraphApplication.js.map +1 -1
  3. package/lib/model/loadGraph.js +17 -17
  4. package/lib/server/accessAliases.js +53 -0
  5. package/lib/server/accessAliases.js.map +1 -0
  6. package/lib/server/createServer.js +1133 -634
  7. package/lib/server/createServer.js.map +1 -1
  8. package/lib/server/instructions.js +69 -21
  9. package/lib/server/instructions.js.map +1 -1
  10. package/lib/server/runDetails.js +413 -0
  11. package/lib/server/runDetails.js.map +1 -0
  12. package/lib/server/{runIndex.js → runEntrypoints.js} +91 -26
  13. package/lib/server/runEntrypoints.js.map +1 -0
  14. package/lib/server/{runQuery.js → runLookup.js} +102 -15
  15. package/lib/server/runLookup.js.map +1 -0
  16. package/lib/server/runOverview.js +31 -21
  17. package/lib/server/runOverview.js.map +1 -1
  18. package/lib/server/runTrace.js +133 -38
  19. package/lib/server/runTrace.js.map +1 -1
  20. package/lib/structures/{ITtscGraphQuery.js → ITtscGraphDetails.js} +1 -1
  21. package/lib/structures/ITtscGraphDetails.js.map +1 -0
  22. package/lib/structures/ITtscGraphEntrypoints.js +3 -0
  23. package/lib/structures/ITtscGraphEntrypoints.js.map +1 -0
  24. package/lib/structures/{ITtscGraphExpand.js → ITtscGraphEscape.js} +1 -1
  25. package/lib/structures/ITtscGraphEscape.js.map +1 -0
  26. package/lib/structures/{ITtscGraphIndex.js → ITtscGraphLookup.js} +1 -1
  27. package/lib/structures/ITtscGraphLookup.js.map +1 -0
  28. package/lib/structures/index.js +4 -3
  29. package/lib/structures/index.js.map +1 -1
  30. package/package.json +2 -2
  31. package/src/TtscGraphApplication.ts +39 -32
  32. package/src/server/accessAliases.ts +55 -0
  33. package/src/server/createServer.ts +4 -7
  34. package/src/server/instructions.ts +69 -21
  35. package/src/server/runDetails.ts +469 -0
  36. package/src/server/{runIndex.ts → runEntrypoints.ts} +109 -34
  37. package/src/server/{runQuery.ts → runLookup.ts} +123 -16
  38. package/src/server/runOverview.ts +35 -23
  39. package/src/server/runTrace.ts +164 -38
  40. package/src/structures/ITtscGraphApplication.ts +100 -52
  41. package/src/structures/ITtscGraphDecorator.ts +12 -14
  42. package/src/structures/ITtscGraphDetails.ts +134 -0
  43. package/src/structures/{ITtscGraphIndex.ts → ITtscGraphEntrypoints.ts} +34 -16
  44. package/src/structures/ITtscGraphEscape.ts +39 -0
  45. package/src/structures/ITtscGraphEvidence.ts +5 -8
  46. package/src/structures/ITtscGraphLookup.ts +61 -0
  47. package/src/structures/ITtscGraphNode.ts +10 -4
  48. package/src/structures/ITtscGraphOverview.ts +24 -16
  49. package/src/structures/ITtscGraphTrace.ts +54 -11
  50. package/src/structures/TtscGraphNodeKind.ts +2 -2
  51. package/src/structures/index.ts +4 -3
  52. package/lib/server/runExpand.js +0 -177
  53. package/lib/server/runExpand.js.map +0 -1
  54. package/lib/server/runIndex.js.map +0 -1
  55. package/lib/server/runQuery.js.map +0 -1
  56. package/lib/structures/ITtscGraphExpand.js.map +0 -1
  57. package/lib/structures/ITtscGraphIndex.js.map +0 -1
  58. package/lib/structures/ITtscGraphQuery.js.map +0 -1
  59. package/src/server/runExpand.ts +0 -186
  60. package/src/structures/ITtscGraphExpand.ts +0 -85
  61. package/src/structures/ITtscGraphQuery.ts +0 -49
@@ -1 +1 @@
1
- {"version":3,"file":"createServer.js","sourceRoot":"","sources":["../../src/server/createServer.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,oEAAoE;AACpE,iEAG4C;AAC5C,kDAA0B;AAE1B,kEAAgF;AAGhF,iDAA8C;AAE9C;;;;;;;;;;;;;GAaG;AACH,sBACE,KAAsB,EACtB,OAAe;IAEf,MAAM,UAAU;;gBACd,OAAO;mBACP,IAAI,2CAAoB,CAAC,KAAK,CAAC;;;;;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CAAC,OAAO,CAAC,MAAM,CAAC,SAAS,IAAI,EAAE,CAAC,CAAC;QACjE,IAAI,CAAC,UAAU,CAAC,OAAO,EAAE,CAAC;YACxB,yEAAyE;YACzE,OAAO,KAAK,CAAC,IAAI,CAAC,SAAS,CAAC,UAAU,CAAC,MAAM,EAAE,IAAI,EAAE,CAAC,CAAC,CAAC,CAAC;QAC3D,CAAC;QACD,IAAI,CAAC;YACH,MAAM,MAAM,GAAG,MAAM,MAAM,CAAC,IAAI,CAAC,OAAO,EAAE,UAAU,CAAC,IAAI,CAAC,CAAC;YAC3D,OAAO;gBACL,OAAO,EAAE;oBACP;wBACE,IAAI,EAAE,MAAe;wBACrB,IAAI,EAAE,MAAM,KAAK,SAAS,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,IAAI,CAAC,SAAS,CAAC,MAAM,CAAC;qBAChE;iBACF;aACF,CAAC;QACJ,CAAC;QAAC,OAAO,SAAS,EAAE,CAAC;YACnB,OAAO,KAAK,CACV,SAAS,YAAY,KAAK;gBACxB,CAAC,CAAC,GAAG,SAAS,CAAC,IAAI,KAAK,SAAS,CAAC,OAAO,EAAE;gBAC3C,CAAC,CAAC,MAAM,CAAC,SAAS,CAAC,CACtB,CAAC;QACJ,CAAC;IACH,CAAC,CAAC,CAAC;IAEH,OAAO,MAAM,CAAC;AAChB,CAAC;AAED,SAAS,KAAK,CAAC,IAAY;IAIzB,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,CAAC,EAAE,CAAC;AAC9D,CAAC"}
@@ -7,26 +7,74 @@ exports.instructions = void 0;
7
7
  * files. Keep it short; the per-tool descriptions carry the detail.
8
8
  */
9
9
  exports.instructions = `
10
- This TypeScript project is indexed by the compiler. Use the graph as the first
11
- source of codebase coordinates: it has already resolved symbols and the
12
- relationships between them.
13
-
14
- - graph_index: first call for source questions. It returns ranked symbols,
15
- declaration signatures, directly mentioned code handles, and nearby dependency
16
- context without source bodies.
17
- - graph_overview: the architecture, layers, hotspots, and public API.
18
- - graph_query: find any symbol by name or description; each hit carries its
19
- signature, usually enough to answer without expanding. Use next.expand when
20
- you need bodies.
21
- - graph_trace: follow a flow forward, reverse, or to its impact; or give dotted
22
- from/to names for the path between two symbols, how A reaches B, in one call.
23
- - graph_expand: a symbol's declared shape, its signature, and a container's
24
- members; source:true to read a specific TypeScript body after graph_index,
25
- graph_query, or graph_trace has located it.
26
-
27
- Answer in as few calls as you can. For TypeScript declarations, read source with
28
- graph_expand(source:true) on the resolved handles. Use shell or file reads only
29
- for a non-TypeScript file, generated output, or an exact literal text search that
30
- is not represented as symbols or edges.
10
+ Before answering a TypeScript codebase question, call query. It is the
11
+ code-evidence path:
12
+ symbols, dependency paths, edge evidence ranges, and sourceSpan line anchors
13
+ from the resident project graph. Do not answer from assumptions, ls, rg, cat,
14
+ or Get-Content when graph evidence can answer the code question.
15
+
16
+ The graph is a resident TypeScript fact map, not an answer writer. Fill
17
+ arguments in order: question, graphNeed, draft, review, request. Write
18
+ draft.reason before draft.type, review it for overfetch and non-graph fallback,
19
+ then choose one final request.type:
20
+ entrypoints, lookup, trace, details, overview, or escape. If the review shows the
21
+ question is about scripts, config, generated output, prose docs, or evidence
22
+ already in hand, choose escape instead of spending a graph
23
+ operation. If more TypeScript evidence is needed, make another graph request
24
+ instead of switching to shell search.
25
+
26
+ Budget graph calls before the first request. Most answers need 1-3 calls, and
27
+ four calls is the hard stop for one answer. A fifth graph call means the tool is
28
+ being used as a source reader; answer from returned handles/ranges or choose
29
+ escape and report the missing span.
30
+
31
+ For behavior, lifecycle, request-flow, rendering-flow, or validation-flow
32
+ questions, start with one default entrypoints call, then one trace from the best
33
+ handle, then answer. Use overview only for broad architecture or public API
34
+ orientation.
35
+
36
+ The graph already knows resolved symbols, dependency edges, evidence spans,
37
+ decorators, stable handles, and sourceSpan line anchors. Use returned ranges and
38
+ handles as the evidence. If implementation text is required to decide a detail,
39
+ report the gap and the smallest sourceSpan instead of opening files during the
40
+ graph answer.
41
+
42
+ For caller or call-site questions, do not use rg. Use trace with direction:
43
+ "reverse" or details with neighbors: true; both return edge evidence and line
44
+ anchors for the call expression.
45
+
46
+ Request types:
47
+
48
+ - entrypoints: compact shortlist for behavior-specific code questions. It returns
49
+ ranked symbols, direct mentions, and small dependency orientation without
50
+ implementation text. Do not use it as the first broad public API map.
51
+ - lookup: targeted symbol search for a class, method, function, property, or
52
+ type when you do not already have its handle.
53
+ - trace: call/type/dependency flow for "how A reaches B", lifecycle,
54
+ request-flow, rendering-flow, validation-flow, and impact questions.
55
+ - details: signatures, members, direct calls, direct types, dependency
56
+ neighbors, and sourceSpan anchors for selected handles.
57
+ - overview: source-free architecture map for layers, hotspots, counts, and
58
+ public API. Use it to choose a central exported TypeScript API or entry point
59
+ without reading package scripts.
60
+ - escape: no-op route when the review decides this tool was the wrong evidence
61
+ source or the previous graph result is enough.
62
+
63
+ For a flow question, use entrypoints once, then trace before details. Keep
64
+ dependency maps compact: default limits first, one to three handles in details,
65
+ and no larger limits unless the previous result was truncated and the missing
66
+ piece is named. Do not spend graph calls only to find tests; mention tests only
67
+ when the returned graph slice already exposes them. Stop once file/symbol/range
68
+ evidence is enough to answer.
69
+
70
+ Copy exact names from returned nodes, references, aliases, evidence ranges,
71
+ sourceSpan anchors, and trace steps. Do not use shell to recover TypeScript line
72
+ numbers, call targets, or branch details not already returned by graph evidence;
73
+ name the missing detail and give the returned range.
74
+
75
+ Package scripts, config files, generated output, prose documentation, and exact
76
+ text searches are separate evidence sources. Use them only when the user asks
77
+ about those sources directly; do not use them to answer a TypeScript API or
78
+ call-path question.
31
79
  `.trim();
32
80
  //# sourceMappingURL=instructions.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"instructions.js","sourceRoot":"","sources":["../../src/server/instructions.ts"],"names":[],"mappings":";;;AAAA;;;;GAIG;AACU,QAAA,YAAY,GAAG;;;;;;;;;;;;;;;;;;;;;;CAsB3B,CAAC,IAAI,EAAE,CAAC"}
1
+ {"version":3,"file":"instructions.js","sourceRoot":"","sources":["../../src/server/instructions.ts"],"names":[],"mappings":";;;AAAA;;;;GAIG;AACU,QAAA,YAAY,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAsE3B,CAAC,IAAI,EAAE,CAAC"}
@@ -0,0 +1,413 @@
1
+ "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ exports.runDetails = runDetails;
7
+ exports.decoratorsOf = decoratorsOf;
8
+ exports.edgeEvidenceOf = edgeEvidenceOf;
9
+ exports.edgeEvidenceTextOf = edgeEvidenceTextOf;
10
+ exports.signatureOf = signatureOf;
11
+ const node_fs_1 = __importDefault(require("node:fs"));
12
+ const node_path_1 = __importDefault(require("node:path"));
13
+ const accessAliases_1 = require("./accessAliases");
14
+ const resolveHandle_1 = require("./resolveHandle");
15
+ // A signature is the declaration head up to the body brace: a handful of lines.
16
+ const MAX_SIGNATURE_LINES = 4;
17
+ // Neighbor lists are a map, not a dump; keep them scannable.
18
+ const DEFAULT_NEIGHBORS = 2;
19
+ const MAX_NEIGHBORS = 3;
20
+ // A container outline can be long; default to a scannable first page.
21
+ const DEFAULT_MEMBERS = 6;
22
+ const MAX_MEMBERS = 8;
23
+ // Direct dependency groups are orientation slices, not full fan-out dumps.
24
+ const DEFAULT_DEPENDENCIES = 1;
25
+ const MAX_DEPENDENCIES = 2;
26
+ // Object literal outlines are navigation aids, not source excerpts.
27
+ const MAX_OBJECT_MEMBER_LINES = 300;
28
+ // Structural relationships are navigation, not the dependency picture details is for.
29
+ const STRUCTURAL_KINDS = new Set(["contains", "exports", "imports"]);
30
+ // Kinds whose value is their member outline, not implementation text.
31
+ const CONTAINER_KINDS = new Set([
32
+ "class",
33
+ "interface",
34
+ "namespace",
35
+ "module",
36
+ "enum",
37
+ "file",
38
+ ]);
39
+ /**
40
+ * Resolve each handle to its declared shape: sourceSpan anchors, signature,
41
+ * direct dependencies, and for containers, member outlines. It answers from the
42
+ * graph's resolved structure instead of inlining implementation bodies.
43
+ */
44
+ function runDetails(graph, props) {
45
+ const neighborLimit = bound(props.neighborLimit, DEFAULT_NEIGHBORS, 1, MAX_NEIGHBORS);
46
+ const memberLimit = bound(props.memberLimit, DEFAULT_MEMBERS, 1, MAX_MEMBERS);
47
+ const dependencyLimit = bound(props.dependencyLimit, DEFAULT_DEPENDENCIES, 1, MAX_DEPENDENCIES);
48
+ const wantNeighbors = props.neighbors === true;
49
+ const nodes = [];
50
+ const unknown = [];
51
+ for (const handle of props.handles) {
52
+ const resolved = (0, resolveHandle_1.resolveGraphHandle)(graph, handle);
53
+ if (resolved.node === undefined) {
54
+ unknown.push(handle);
55
+ continue;
56
+ }
57
+ const node = resolved.node;
58
+ const detail = {
59
+ id: node.id,
60
+ name: node.qualifiedName ?? node.name,
61
+ kind: node.kind,
62
+ file: node.file,
63
+ };
64
+ if (node.evidence?.startLine)
65
+ detail.line = node.evidence.startLine;
66
+ const sig = signatureOf(graph.project, node);
67
+ if (sig !== undefined)
68
+ detail.signature = sig;
69
+ const signatureLiterals = literalSummaries(sig);
70
+ const decorators = decoratorsOf(node);
71
+ if (decorators !== undefined)
72
+ detail.decorators = decorators;
73
+ const implementation = evidenceCoordinatesOf(node.implementation);
74
+ if (implementation !== undefined)
75
+ detail.implementation = implementation;
76
+ const span = implementation ?? evidenceCoordinatesOf(node.evidence);
77
+ if (span !== undefined) {
78
+ detail.sourceSpan = {
79
+ file: span.file,
80
+ startLine: span.startLine,
81
+ endLine: span.endLine,
82
+ };
83
+ }
84
+ const calls = dependencyRefs(graph, node, executionKinds, dependencyLimit);
85
+ if (calls.length > 0)
86
+ detail.calls = calls;
87
+ const types = dependencyRefs(graph, node, typeKinds, dependencyLimit);
88
+ if (types.length > 0)
89
+ detail.types = types;
90
+ if (CONTAINER_KINDS.has(node.kind)) {
91
+ const list = members(graph, node, memberLimit);
92
+ if (list.length > 0)
93
+ detail.members = list;
94
+ }
95
+ if (node.kind === "variable" && detail.sourceSpan !== undefined) {
96
+ const list = objectLiteralMembers(graph.project, detail.sourceSpan, memberLimit);
97
+ if (list.length > 0)
98
+ detail.members = list;
99
+ }
100
+ if (signatureLiterals.length > 0)
101
+ detail.literals = signatureLiterals.slice(0, 6);
102
+ if (wantNeighbors) {
103
+ detail.dependsOn = refs(graph, graph.outgoing(node.id), "to", neighborLimit);
104
+ detail.dependedOnBy = refs(graph, graph.incoming(node.id), "from", neighborLimit);
105
+ }
106
+ nodes.push(detail);
107
+ }
108
+ return { type: "details", nodes, unknown };
109
+ }
110
+ /** The members a container owns (via `contains`), each with its own signature. */
111
+ function members(graph, node, limit) {
112
+ const out = [];
113
+ for (const edge of graph.outgoing(node.id)) {
114
+ if (edge.kind !== "contains")
115
+ continue;
116
+ const member = graph.node(edge.to);
117
+ if (member === undefined)
118
+ continue;
119
+ const m = {
120
+ name: member.qualifiedName ?? member.name,
121
+ kind: member.kind,
122
+ };
123
+ if (member.evidence?.startLine)
124
+ m.line = member.evidence.startLine;
125
+ const sig = signatureOf(graph.project, member);
126
+ if (sig !== undefined)
127
+ m.signature = sig;
128
+ const decorators = decoratorsOf(member);
129
+ if (decorators !== undefined)
130
+ m.decorators = decorators;
131
+ out.push(m);
132
+ if (out.length >= limit)
133
+ break;
134
+ }
135
+ return out;
136
+ }
137
+ function objectLiteralMembers(project, span, limit) {
138
+ if (span.endLine === undefined)
139
+ return [];
140
+ if (span.endLine - span.startLine > MAX_OBJECT_MEMBER_LINES)
141
+ return [];
142
+ const lines = fileLines(project, span.file);
143
+ if (lines === undefined)
144
+ return [];
145
+ const start = Math.max(0, span.startLine - 1);
146
+ const end = Math.min(lines.length - 1, span.endLine - 1);
147
+ const members = [];
148
+ let depth = 0;
149
+ let entered = false;
150
+ for (let i = start; i <= end; i++) {
151
+ const raw = lines[i] ?? "";
152
+ const text = stripStrings(raw);
153
+ const before = depth;
154
+ if (entered && before === 1) {
155
+ const member = objectMemberOf(raw, i + 1);
156
+ if (member !== undefined) {
157
+ members.push(member);
158
+ if (members.length >= limit)
159
+ break;
160
+ }
161
+ }
162
+ for (const char of text) {
163
+ if (char === "{") {
164
+ depth++;
165
+ entered = true;
166
+ }
167
+ else if (char === "}") {
168
+ depth = Math.max(0, depth - 1);
169
+ }
170
+ }
171
+ }
172
+ return members;
173
+ }
174
+ function objectMemberOf(line, lineNumber) {
175
+ const text = line.trim();
176
+ if (text === "" ||
177
+ text.startsWith("//") ||
178
+ text.startsWith("/*") ||
179
+ text.startsWith("*")) {
180
+ return undefined;
181
+ }
182
+ const property = /^(['"]?)([A-Za-z_$][\w$-]*)\1\s*\??\s*:/.exec(text);
183
+ if (property !== null) {
184
+ return {
185
+ name: property[2],
186
+ kind: "property",
187
+ line: lineNumber,
188
+ signature: signatureLine(text),
189
+ };
190
+ }
191
+ const method = /^(?:async\s+)?(?:get\s+|set\s+)?([A-Za-z_$][\w$-]*)\s*\(/.exec(text);
192
+ if (method !== null) {
193
+ return {
194
+ name: method[1],
195
+ kind: "method",
196
+ line: lineNumber,
197
+ signature: signatureLine(text),
198
+ };
199
+ }
200
+ return undefined;
201
+ }
202
+ function signatureLine(text) {
203
+ return text.replace(/\s+/g, " ").replace(/,$/, "");
204
+ }
205
+ function stripStrings(line) {
206
+ return line.replace(/\/\/.*$/, "").replace(/(['"`])(?:\\.|(?!\1).)*\1/g, "");
207
+ }
208
+ /** Map dependency edges to references on their far endpoint, dropping structure. */
209
+ function refs(graph, edges, end, limit) {
210
+ const ranked = [];
211
+ for (const edge of edges) {
212
+ if (STRUCTURAL_KINDS.has(edge.kind))
213
+ continue;
214
+ const other = graph.node(end === "to" ? edge.to : edge.from);
215
+ if (other === undefined)
216
+ continue;
217
+ const ref = {
218
+ id: other.id,
219
+ name: other.qualifiedName ?? other.name,
220
+ kind: other.kind,
221
+ file: other.file,
222
+ relation: edge.kind,
223
+ };
224
+ if (other.evidence?.startLine)
225
+ ref.line = other.evidence.startLine;
226
+ const evidence = edgeEvidenceOf(edge);
227
+ if (evidence !== undefined)
228
+ ref.evidence = evidence;
229
+ const aliases = (0, accessAliases_1.accessAliasesFor)(other, edgeEvidenceTextOf(edge));
230
+ if (aliases !== undefined)
231
+ ref.aliases = aliases;
232
+ ranked.push({ ref, rank: refRank(ref, edge) });
233
+ }
234
+ ranked.sort((a, b) => a.rank - b.rank);
235
+ const out = [];
236
+ for (const item of ranked) {
237
+ out.push(item.ref);
238
+ if (out.length >= limit)
239
+ break;
240
+ }
241
+ return out;
242
+ }
243
+ const executionKinds = new Set([
244
+ "calls",
245
+ "instantiates",
246
+ "accesses",
247
+ "renders",
248
+ ]);
249
+ const typeKinds = new Set(["type_ref", "extends", "implements", "overrides"]);
250
+ function dependencyRefs(graph, node, kinds, limit) {
251
+ const ranked = [];
252
+ for (const edge of graph.outgoing(node.id)) {
253
+ if (!kinds.has(edge.kind))
254
+ continue;
255
+ const other = graph.node(edge.to);
256
+ if (other === undefined || other.kind === "file")
257
+ continue;
258
+ const name = other.qualifiedName ?? other.name;
259
+ const ref = {
260
+ id: other.id,
261
+ name,
262
+ kind: other.kind,
263
+ file: other.file,
264
+ relation: edge.kind,
265
+ };
266
+ if (other.evidence?.startLine)
267
+ ref.line = other.evidence.startLine;
268
+ const evidence = edgeEvidenceOf(edge);
269
+ if (evidence !== undefined)
270
+ ref.evidence = evidence;
271
+ const aliases = (0, accessAliases_1.accessAliasesFor)(other, edgeEvidenceTextOf(edge));
272
+ if (aliases !== undefined)
273
+ ref.aliases = aliases;
274
+ ranked.push({
275
+ ref,
276
+ rank: refRank(ref, edge),
277
+ });
278
+ }
279
+ ranked.sort((a, b) => a.rank - b.rank);
280
+ const out = [];
281
+ const seen = new Set();
282
+ for (const item of ranked) {
283
+ const key = `${item.ref.relation}:${item.ref.id}`;
284
+ if (seen.has(key))
285
+ continue;
286
+ seen.add(key);
287
+ out.push(item.ref);
288
+ if (out.length >= limit)
289
+ break;
290
+ }
291
+ return out;
292
+ }
293
+ function literalSummaries(text) {
294
+ if (text === undefined)
295
+ return [];
296
+ const out = [];
297
+ for (const match of text.matchAll(/(["'`])((?:\\.|(?!\1).){1,80})\1/g)) {
298
+ const value = cleanLiteral(match[2]);
299
+ if (value !== undefined && !out.includes(value))
300
+ out.push(value);
301
+ if (out.length >= 20)
302
+ break;
303
+ }
304
+ return out;
305
+ }
306
+ function cleanLiteral(value) {
307
+ const text = value?.replace(/\s+/g, " ").trim();
308
+ if (text === undefined ||
309
+ text === "" ||
310
+ text.length > 40 ||
311
+ /^[{}()[\],.:;]+$/.test(text)) {
312
+ return undefined;
313
+ }
314
+ return text;
315
+ }
316
+ function bound(value, fallback, min, max) {
317
+ const n = value === undefined || !Number.isFinite(value) ? fallback : value;
318
+ return Math.max(min, Math.min(max, Math.floor(n)));
319
+ }
320
+ function refRank(ref, edge) {
321
+ return (edgeKindRank(edge.kind) * 100000 +
322
+ evidenceRank(edge) +
323
+ (ref.file.startsWith("bundled://") ? 20000 : 0));
324
+ }
325
+ function evidenceRank(edge) {
326
+ const line = edge.evidence?.startLine ?? 9999;
327
+ const col = edge.evidence?.startCol ?? 999;
328
+ return line * 100 + col;
329
+ }
330
+ function edgeKindRank(kind) {
331
+ switch (kind) {
332
+ case "calls":
333
+ return 0;
334
+ case "instantiates":
335
+ return 1;
336
+ case "accesses":
337
+ case "renders":
338
+ return 2;
339
+ case "tests":
340
+ return 3;
341
+ case "overrides":
342
+ case "decorates":
343
+ return 4;
344
+ case "extends":
345
+ case "implements":
346
+ return 5;
347
+ case "type_ref":
348
+ return 6;
349
+ default:
350
+ return 10;
351
+ }
352
+ }
353
+ /** Decorator facts already captured on a node, omitted when absent. */
354
+ function decoratorsOf(node) {
355
+ return node.decorators !== undefined && node.decorators.length > 0
356
+ ? node.decorators
357
+ : undefined;
358
+ }
359
+ /** Relationship evidence as public coordinates, omitted when absent. */
360
+ function edgeEvidenceOf(edge) {
361
+ return evidenceCoordinatesOf(edge.evidence);
362
+ }
363
+ function evidenceCoordinatesOf(evidence) {
364
+ if (evidence === undefined)
365
+ return undefined;
366
+ return {
367
+ file: evidence.file,
368
+ startLine: evidence.startLine,
369
+ ...(evidence.startCol !== undefined ? { startCol: evidence.startCol } : {}),
370
+ ...(evidence.endLine !== undefined ? { endLine: evidence.endLine } : {}),
371
+ ...(evidence.endCol !== undefined ? { endCol: evidence.endCol } : {}),
372
+ };
373
+ }
374
+ /** Source text is an internal alias hint, not part of the MCP evidence object. */
375
+ function edgeEvidenceTextOf(edge) {
376
+ const text = edge.evidence?.text;
377
+ return typeof text === "string" && text.length > 0 ? text : undefined;
378
+ }
379
+ /** Read a file's lines once, or undefined when it cannot be read. */
380
+ function fileLines(project, file) {
381
+ if (file === "")
382
+ return undefined;
383
+ try {
384
+ return node_fs_1.default.readFileSync(node_path_1.default.join(project, file), "utf8").split(/\r?\n/);
385
+ }
386
+ catch {
387
+ return undefined;
388
+ }
389
+ }
390
+ /**
391
+ * The declaration signature: the head of the declaration up to and including
392
+ * the line that opens its body (`{`), or the single declaration line when there
393
+ * is no brace, capped so a wrapped signature cannot run away.
394
+ */
395
+ function signatureOf(project, node) {
396
+ const evidence = node.evidence;
397
+ const lines = evidence === undefined ? undefined : fileLines(project, evidence.file);
398
+ if (lines === undefined || evidence === undefined)
399
+ return undefined;
400
+ const start = Math.max(0, evidence.startLine - 1);
401
+ const out = [];
402
+ for (let i = start; i < lines.length && out.length < MAX_SIGNATURE_LINES; i++) {
403
+ const line = lines[i];
404
+ if (line === undefined)
405
+ break;
406
+ out.push(line);
407
+ if (line.includes("{"))
408
+ break;
409
+ }
410
+ const text = out.join("\n").trim();
411
+ return text === "" ? undefined : text;
412
+ }
413
+ //# sourceMappingURL=runDetails.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"runDetails.js","sourceRoot":"","sources":["../../src/server/runDetails.ts"],"names":[],"mappings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