ai-code-map 0.0.0-stage → 0.1.0-alpha.2

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.
@@ -0,0 +1,1178 @@
1
+ import ts from 'typescript';
2
+ import { z } from 'zod';
3
+
4
+ declare const SCHEMA_VERSION: 4;
5
+ declare const CONFIG_VERSION: 1;
6
+ declare const ANALYZER_VERSION = "0.4.0";
7
+
8
+ declare class CodeMapError extends Error {
9
+ readonly code: string;
10
+ constructor(code: string, message: string, options?: ErrorOptions);
11
+ }
12
+
13
+ declare const JsonValueSchema: z.ZodJSONSchema;
14
+ type JsonValue = z.infer<typeof JsonValueSchema>;
15
+ type JsonPrimitive = Extract<JsonValue, string | number | boolean | null>;
16
+ declare const LanguageSchema: z.ZodEnum<{
17
+ ts: "ts";
18
+ tsx: "tsx";
19
+ js: "js";
20
+ jsx: "jsx";
21
+ mts: "mts";
22
+ cts: "cts";
23
+ mjs: "mjs";
24
+ cjs: "cjs";
25
+ }>;
26
+ type Language = z.infer<typeof LanguageSchema>;
27
+ declare const FrameworkSchema: z.ZodEnum<{
28
+ typescript: "typescript";
29
+ react: "react";
30
+ nextjs: "nextjs";
31
+ nestjs: "nestjs";
32
+ node: "node";
33
+ }>;
34
+ type Framework = z.infer<typeof FrameworkSchema>;
35
+ declare const FrameworkSelectionSchema: z.ZodUnion<readonly [z.ZodEnum<{
36
+ typescript: "typescript";
37
+ react: "react";
38
+ nextjs: "nextjs";
39
+ nestjs: "nestjs";
40
+ node: "node";
41
+ }>, z.ZodLiteral<"auto">]>;
42
+ type FrameworkSelection = z.infer<typeof FrameworkSelectionSchema>;
43
+ declare const ConfigSchema: z.ZodObject<{
44
+ version: z.ZodDefault<z.ZodLiteral<1>>;
45
+ root: z.ZodDefault<z.ZodString>;
46
+ include: z.ZodDefault<z.ZodArray<z.ZodString>>;
47
+ exclude: z.ZodDefault<z.ZodArray<z.ZodString>>;
48
+ tsconfig: z.ZodOptional<z.ZodString>;
49
+ frameworks: z.ZodDefault<z.ZodArray<z.ZodUnion<readonly [z.ZodEnum<{
50
+ typescript: "typescript";
51
+ react: "react";
52
+ nextjs: "nextjs";
53
+ nestjs: "nestjs";
54
+ node: "node";
55
+ }>, z.ZodLiteral<"auto">]>>>;
56
+ output: z.ZodDefault<z.ZodString>;
57
+ includePrivateSymbols: z.ZodDefault<z.ZodBoolean>;
58
+ concurrency: z.ZodOptional<z.ZodNumber>;
59
+ }, z.core.$strict>;
60
+ type CodeMapConfig = z.infer<typeof ConfigSchema>;
61
+ declare const SourceRangeSchema: z.ZodObject<{
62
+ startLine: z.ZodNumber;
63
+ startColumn: z.ZodNumber;
64
+ endLine: z.ZodNumber;
65
+ endColumn: z.ZodNumber;
66
+ }, z.core.$strict>;
67
+ type SourceRange = z.infer<typeof SourceRangeSchema>;
68
+ declare const ImportSpecifierRecordSchema: z.ZodObject<{
69
+ imported: z.ZodString;
70
+ local: z.ZodString;
71
+ typeOnly: z.ZodOptional<z.ZodBoolean>;
72
+ }, z.core.$strict>;
73
+ type ImportSpecifierRecord = z.infer<typeof ImportSpecifierRecordSchema>;
74
+ declare const ImportRecordSchema: z.ZodObject<{
75
+ source: z.ZodString;
76
+ specifiers: z.ZodArray<z.ZodObject<{
77
+ imported: z.ZodString;
78
+ local: z.ZodString;
79
+ typeOnly: z.ZodOptional<z.ZodBoolean>;
80
+ }, z.core.$strict>>;
81
+ resolved: z.ZodOptional<z.ZodString>;
82
+ external: z.ZodBoolean;
83
+ kind: z.ZodEnum<{
84
+ esm: "esm";
85
+ commonjs: "commonjs";
86
+ }>;
87
+ line: z.ZodNumber;
88
+ }, z.core.$strict>;
89
+ type ImportRecord = z.infer<typeof ImportRecordSchema>;
90
+ declare const ExportRecordSchema: z.ZodObject<{
91
+ name: z.ZodString;
92
+ local: z.ZodOptional<z.ZodString>;
93
+ source: z.ZodOptional<z.ZodString>;
94
+ default: z.ZodBoolean;
95
+ typeOnly: z.ZodOptional<z.ZodBoolean>;
96
+ line: z.ZodNumber;
97
+ }, z.core.$strict>;
98
+ type ExportRecord = z.infer<typeof ExportRecordSchema>;
99
+ declare const ExternalOperationKindSchema: z.ZodEnum<{
100
+ filesystem: "filesystem";
101
+ http: "http";
102
+ database: "database";
103
+ queue: "queue";
104
+ }>;
105
+ type ExternalOperationKind = z.infer<typeof ExternalOperationKindSchema>;
106
+ declare const ExternalOperationSchema: z.ZodObject<{
107
+ kind: z.ZodEnum<{
108
+ filesystem: "filesystem";
109
+ http: "http";
110
+ database: "database";
111
+ queue: "queue";
112
+ }>;
113
+ api: z.ZodString;
114
+ line: z.ZodNumber;
115
+ }, z.core.$strict>;
116
+ type ExternalOperation = z.infer<typeof ExternalOperationSchema>;
117
+ declare const SyntaxSummarySchema: z.ZodObject<{
118
+ parser: z.ZodString;
119
+ factCount: z.ZodNumber;
120
+ hadErrors: z.ZodBoolean;
121
+ fallbackFrom: z.ZodOptional<z.ZodString>;
122
+ }, z.core.$strict>;
123
+ type SyntaxSummary = z.infer<typeof SyntaxSummarySchema>;
124
+ declare const FileRecordSchema: z.ZodObject<{
125
+ schemaVersion: z.ZodLiteral<4>;
126
+ id: z.ZodString;
127
+ compilerUnit: z.ZodString;
128
+ path: z.ZodString;
129
+ language: z.ZodEnum<{
130
+ ts: "ts";
131
+ tsx: "tsx";
132
+ js: "js";
133
+ jsx: "jsx";
134
+ mts: "mts";
135
+ cts: "cts";
136
+ mjs: "mjs";
137
+ cjs: "cjs";
138
+ }>;
139
+ frameworks: z.ZodArray<z.ZodEnum<{
140
+ typescript: "typescript";
141
+ react: "react";
142
+ nextjs: "nextjs";
143
+ nestjs: "nestjs";
144
+ node: "node";
145
+ }>>;
146
+ hash: z.ZodString;
147
+ lines: z.ZodNumber;
148
+ imports: z.ZodArray<z.ZodObject<{
149
+ source: z.ZodString;
150
+ specifiers: z.ZodArray<z.ZodObject<{
151
+ imported: z.ZodString;
152
+ local: z.ZodString;
153
+ typeOnly: z.ZodOptional<z.ZodBoolean>;
154
+ }, z.core.$strict>>;
155
+ resolved: z.ZodOptional<z.ZodString>;
156
+ external: z.ZodBoolean;
157
+ kind: z.ZodEnum<{
158
+ esm: "esm";
159
+ commonjs: "commonjs";
160
+ }>;
161
+ line: z.ZodNumber;
162
+ }, z.core.$strict>>;
163
+ exports: z.ZodArray<z.ZodObject<{
164
+ name: z.ZodString;
165
+ local: z.ZodOptional<z.ZodString>;
166
+ source: z.ZodOptional<z.ZodString>;
167
+ default: z.ZodBoolean;
168
+ typeOnly: z.ZodOptional<z.ZodBoolean>;
169
+ line: z.ZodNumber;
170
+ }, z.core.$strict>>;
171
+ symbolIds: z.ZodArray<z.ZodString>;
172
+ env: z.ZodArray<z.ZodString>;
173
+ operations: z.ZodArray<z.ZodObject<{
174
+ kind: z.ZodEnum<{
175
+ filesystem: "filesystem";
176
+ http: "http";
177
+ database: "database";
178
+ queue: "queue";
179
+ }>;
180
+ api: z.ZodString;
181
+ line: z.ZodNumber;
182
+ }, z.core.$strict>>;
183
+ syntax: z.ZodObject<{
184
+ parser: z.ZodString;
185
+ factCount: z.ZodNumber;
186
+ hadErrors: z.ZodBoolean;
187
+ fallbackFrom: z.ZodOptional<z.ZodString>;
188
+ }, z.core.$strict>;
189
+ }, z.core.$strict>;
190
+ type FileRecord = z.infer<typeof FileRecordSchema>;
191
+ declare const CompilerUnitRecordSchema: z.ZodObject<{
192
+ id: z.ZodString;
193
+ kind: z.ZodEnum<{
194
+ configured: "configured";
195
+ fallback: "fallback";
196
+ }>;
197
+ root: z.ZodString;
198
+ config: z.ZodOptional<z.ZodString>;
199
+ references: z.ZodArray<z.ZodString>;
200
+ extends: z.ZodArray<z.ZodString>;
201
+ pathAliases: z.ZodRecord<z.ZodString, z.ZodArray<z.ZodString>>;
202
+ }, z.core.$strict>;
203
+ type CompilerUnitRecord = z.infer<typeof CompilerUnitRecordSchema>;
204
+ declare const SymbolKindSchema: z.ZodEnum<{
205
+ function: "function";
206
+ class: "class";
207
+ method: "method";
208
+ interface: "interface";
209
+ "type-alias": "type-alias";
210
+ variable: "variable";
211
+ "react-component": "react-component";
212
+ "react-hook": "react-hook";
213
+ "react-context": "react-context";
214
+ "next-page": "next-page";
215
+ "next-layout": "next-layout";
216
+ "next-route-handler": "next-route-handler";
217
+ "next-special-file": "next-special-file";
218
+ "nest-module": "nest-module";
219
+ "nest-controller": "nest-controller";
220
+ "nest-provider": "nest-provider";
221
+ "nest-guard": "nest-guard";
222
+ "nest-interceptor": "nest-interceptor";
223
+ "nest-pipe": "nest-pipe";
224
+ "nest-filter": "nest-filter";
225
+ "nest-gateway": "nest-gateway";
226
+ dto: "dto";
227
+ route: "route";
228
+ }>;
229
+ type SymbolKind = z.infer<typeof SymbolKindSchema>;
230
+ declare const SymbolRecordSchema: z.ZodObject<{
231
+ schemaVersion: z.ZodLiteral<4>;
232
+ id: z.ZodString;
233
+ name: z.ZodString;
234
+ kind: z.ZodEnum<{
235
+ function: "function";
236
+ class: "class";
237
+ method: "method";
238
+ interface: "interface";
239
+ "type-alias": "type-alias";
240
+ variable: "variable";
241
+ "react-component": "react-component";
242
+ "react-hook": "react-hook";
243
+ "react-context": "react-context";
244
+ "next-page": "next-page";
245
+ "next-layout": "next-layout";
246
+ "next-route-handler": "next-route-handler";
247
+ "next-special-file": "next-special-file";
248
+ "nest-module": "nest-module";
249
+ "nest-controller": "nest-controller";
250
+ "nest-provider": "nest-provider";
251
+ "nest-guard": "nest-guard";
252
+ "nest-interceptor": "nest-interceptor";
253
+ "nest-pipe": "nest-pipe";
254
+ "nest-filter": "nest-filter";
255
+ "nest-gateway": "nest-gateway";
256
+ dto: "dto";
257
+ route: "route";
258
+ }>;
259
+ file: z.ZodString;
260
+ range: z.ZodObject<{
261
+ startLine: z.ZodNumber;
262
+ startColumn: z.ZodNumber;
263
+ endLine: z.ZodNumber;
264
+ endColumn: z.ZodNumber;
265
+ }, z.core.$strict>;
266
+ exported: z.ZodBoolean;
267
+ defaultExport: z.ZodOptional<z.ZodBoolean>;
268
+ signature: z.ZodOptional<z.ZodString>;
269
+ documentation: z.ZodOptional<z.ZodString>;
270
+ facts: z.ZodRecord<z.ZodString, z.ZodJSONSchema>;
271
+ sourceHash: z.ZodString;
272
+ }, z.core.$strict>;
273
+ type SymbolRecord = z.infer<typeof SymbolRecordSchema>;
274
+ declare const RelationTypeSchema: z.ZodEnum<{
275
+ references: "references";
276
+ imports: "imports";
277
+ exports: "exports";
278
+ reexports: "reexports";
279
+ calls: "calls";
280
+ instantiates: "instantiates";
281
+ renders: "renders";
282
+ "uses-hook": "uses-hook";
283
+ "reads-state": "reads-state";
284
+ "depends-on": "depends-on";
285
+ "used-by": "used-by";
286
+ contains: "contains";
287
+ injects: "injects";
288
+ "handles-route": "handles-route";
289
+ "consumes-dto": "consumes-dto";
290
+ "belongs-to-module": "belongs-to-module";
291
+ "uses-layout": "uses-layout";
292
+ }>;
293
+ type RelationType = z.infer<typeof RelationTypeSchema>;
294
+ declare const RelationEvidenceClassificationSchema: z.ZodEnum<{
295
+ exact: "exact";
296
+ "framework-derived": "framework-derived";
297
+ heuristic: "heuristic";
298
+ derived: "derived";
299
+ }>;
300
+ type RelationEvidenceClassification = z.infer<typeof RelationEvidenceClassificationSchema>;
301
+ declare const RelationOriginSchema: z.ZodObject<{
302
+ file: z.ZodString;
303
+ line: z.ZodNumber;
304
+ range: z.ZodObject<{
305
+ startLine: z.ZodNumber;
306
+ startColumn: z.ZodNumber;
307
+ endLine: z.ZodNumber;
308
+ endColumn: z.ZodNumber;
309
+ }, z.core.$strict>;
310
+ explanation: z.ZodString;
311
+ classification: z.ZodEnum<{
312
+ exact: "exact";
313
+ "framework-derived": "framework-derived";
314
+ heuristic: "heuristic";
315
+ derived: "derived";
316
+ }>;
317
+ analyzer: z.ZodString;
318
+ }, z.core.$strict>;
319
+ type RelationOrigin = z.infer<typeof RelationOriginSchema>;
320
+ declare const RelationRecordSchema: z.ZodObject<{
321
+ schemaVersion: z.ZodLiteral<4>;
322
+ from: z.ZodString;
323
+ type: z.ZodEnum<{
324
+ references: "references";
325
+ imports: "imports";
326
+ exports: "exports";
327
+ reexports: "reexports";
328
+ calls: "calls";
329
+ instantiates: "instantiates";
330
+ renders: "renders";
331
+ "uses-hook": "uses-hook";
332
+ "reads-state": "reads-state";
333
+ "depends-on": "depends-on";
334
+ "used-by": "used-by";
335
+ contains: "contains";
336
+ injects: "injects";
337
+ "handles-route": "handles-route";
338
+ "consumes-dto": "consumes-dto";
339
+ "belongs-to-module": "belongs-to-module";
340
+ "uses-layout": "uses-layout";
341
+ }>;
342
+ to: z.ZodString;
343
+ confidence: z.ZodNumber;
344
+ origin: z.ZodObject<{
345
+ file: z.ZodString;
346
+ line: z.ZodNumber;
347
+ range: z.ZodObject<{
348
+ startLine: z.ZodNumber;
349
+ startColumn: z.ZodNumber;
350
+ endLine: z.ZodNumber;
351
+ endColumn: z.ZodNumber;
352
+ }, z.core.$strict>;
353
+ explanation: z.ZodString;
354
+ classification: z.ZodEnum<{
355
+ exact: "exact";
356
+ "framework-derived": "framework-derived";
357
+ heuristic: "heuristic";
358
+ derived: "derived";
359
+ }>;
360
+ analyzer: z.ZodString;
361
+ }, z.core.$strict>;
362
+ }, z.core.$strict>;
363
+ type RelationRecord = z.infer<typeof RelationRecordSchema>;
364
+ declare const DiagnosticSeveritySchema: z.ZodEnum<{
365
+ error: "error";
366
+ info: "info";
367
+ warning: "warning";
368
+ }>;
369
+ type DiagnosticSeverity = z.infer<typeof DiagnosticSeveritySchema>;
370
+ declare const DiagnosticCodeSchema: z.ZodEnum<{
371
+ "parse-error": "parse-error";
372
+ "unresolved-import": "unresolved-import";
373
+ "invalid-config": "invalid-config";
374
+ "unsupported-file": "unsupported-file";
375
+ "analysis-error": "analysis-error";
376
+ "parser-fallback": "parser-fallback";
377
+ "compiler-config": "compiler-config";
378
+ }>;
379
+ type DiagnosticCode = z.infer<typeof DiagnosticCodeSchema>;
380
+ declare const DiagnosticRecordSchema: z.ZodObject<{
381
+ schemaVersion: z.ZodLiteral<4>;
382
+ code: z.ZodEnum<{
383
+ "parse-error": "parse-error";
384
+ "unresolved-import": "unresolved-import";
385
+ "invalid-config": "invalid-config";
386
+ "unsupported-file": "unsupported-file";
387
+ "analysis-error": "analysis-error";
388
+ "parser-fallback": "parser-fallback";
389
+ "compiler-config": "compiler-config";
390
+ }>;
391
+ severity: z.ZodEnum<{
392
+ error: "error";
393
+ info: "info";
394
+ warning: "warning";
395
+ }>;
396
+ message: z.ZodString;
397
+ file: z.ZodOptional<z.ZodString>;
398
+ line: z.ZodOptional<z.ZodNumber>;
399
+ column: z.ZodOptional<z.ZodNumber>;
400
+ }, z.core.$strict>;
401
+ type DiagnosticRecord = z.infer<typeof DiagnosticRecordSchema>;
402
+ declare const WorkspacePackageSchema: z.ZodObject<{
403
+ name: z.ZodString;
404
+ path: z.ZodString;
405
+ entryPoints: z.ZodArray<z.ZodString>;
406
+ }, z.core.$strict>;
407
+ type WorkspacePackage = z.infer<typeof WorkspacePackageSchema>;
408
+ declare const MapCountsSchema: z.ZodObject<{
409
+ files: z.ZodNumber;
410
+ symbols: z.ZodNumber;
411
+ relations: z.ZodNumber;
412
+ diagnostics: z.ZodNumber;
413
+ }, z.core.$strict>;
414
+ type MapCounts = z.infer<typeof MapCountsSchema>;
415
+ declare const ProjectRecordSchema: z.ZodObject<{
416
+ schemaVersion: z.ZodLiteral<4>;
417
+ name: z.ZodString;
418
+ packageManager: z.ZodOptional<z.ZodString>;
419
+ frameworks: z.ZodArray<z.ZodEnum<{
420
+ typescript: "typescript";
421
+ react: "react";
422
+ nextjs: "nextjs";
423
+ nestjs: "nestjs";
424
+ node: "node";
425
+ }>>;
426
+ compilerUnits: z.ZodArray<z.ZodObject<{
427
+ id: z.ZodString;
428
+ kind: z.ZodEnum<{
429
+ configured: "configured";
430
+ fallback: "fallback";
431
+ }>;
432
+ root: z.ZodString;
433
+ config: z.ZodOptional<z.ZodString>;
434
+ references: z.ZodArray<z.ZodString>;
435
+ extends: z.ZodArray<z.ZodString>;
436
+ pathAliases: z.ZodRecord<z.ZodString, z.ZodArray<z.ZodString>>;
437
+ }, z.core.$strict>>;
438
+ tsconfig: z.ZodOptional<z.ZodString>;
439
+ pathAliases: z.ZodRecord<z.ZodString, z.ZodArray<z.ZodString>>;
440
+ entryPoints: z.ZodArray<z.ZodString>;
441
+ workspaces: z.ZodArray<z.ZodObject<{
442
+ name: z.ZodString;
443
+ path: z.ZodString;
444
+ entryPoints: z.ZodArray<z.ZodString>;
445
+ }, z.core.$strict>>;
446
+ counts: z.ZodObject<{
447
+ files: z.ZodNumber;
448
+ symbols: z.ZodNumber;
449
+ relations: z.ZodNumber;
450
+ diagnostics: z.ZodNumber;
451
+ }, z.core.$strict>;
452
+ }, z.core.$strict>;
453
+ type ProjectRecord = z.infer<typeof ProjectRecordSchema>;
454
+ declare const SemanticInputRecordSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
455
+ path: z.ZodString;
456
+ kind: z.ZodLiteral<"file">;
457
+ hash: z.ZodString;
458
+ }, z.core.$strict>, z.ZodObject<{
459
+ path: z.ZodString;
460
+ kind: z.ZodLiteral<"resolution-probe">;
461
+ scope: z.ZodEnum<{
462
+ project: "project";
463
+ toolchain: "toolchain";
464
+ }>;
465
+ targetKind: z.ZodEnum<{
466
+ file: "file";
467
+ directory: "directory";
468
+ "readable-file": "readable-file";
469
+ }>;
470
+ exists: z.ZodBoolean;
471
+ }, z.core.$strict>, z.ZodObject<{
472
+ path: z.ZodString;
473
+ kind: z.ZodLiteral<"directory-listing">;
474
+ scope: z.ZodEnum<{
475
+ project: "project";
476
+ toolchain: "toolchain";
477
+ }>;
478
+ hash: z.ZodString;
479
+ }, z.core.$strict>, z.ZodObject<{
480
+ path: z.ZodString;
481
+ kind: z.ZodLiteral<"symlink">;
482
+ scope: z.ZodEnum<{
483
+ project: "project";
484
+ toolchain: "toolchain";
485
+ }>;
486
+ target: z.ZodString;
487
+ }, z.core.$strict>, z.ZodObject<{
488
+ path: z.ZodString;
489
+ kind: z.ZodLiteral<"toolchain-file">;
490
+ hash: z.ZodString;
491
+ }, z.core.$strict>], "kind">;
492
+ type SemanticInputRecord = z.infer<typeof SemanticInputRecordSchema>;
493
+ declare const ArtifactIntegrityRecordSchema: z.ZodObject<{
494
+ path: z.ZodEnum<{
495
+ "overview.md": "overview.md";
496
+ "project.json": "project.json";
497
+ "files.jsonl": "files.jsonl";
498
+ "symbols.jsonl": "symbols.jsonl";
499
+ "relations.jsonl": "relations.jsonl";
500
+ "diagnostics.json": "diagnostics.json";
501
+ }>;
502
+ hash: z.ZodString;
503
+ }, z.core.$strict>;
504
+ type ArtifactIntegrityRecord = z.infer<typeof ArtifactIntegrityRecordSchema>;
505
+ declare const ProducerRecordSchema: z.ZodObject<{
506
+ id: z.ZodString;
507
+ kind: z.ZodEnum<{
508
+ "built-in": "built-in";
509
+ custom: "custom";
510
+ }>;
511
+ fingerprint: z.ZodString;
512
+ }, z.core.$strict>;
513
+ type ProducerRecord = z.infer<typeof ProducerRecordSchema>;
514
+ declare const ManifestRecordSchema: z.ZodObject<{
515
+ schemaVersion: z.ZodLiteral<4>;
516
+ analyzerVersion: z.ZodString;
517
+ producer: z.ZodObject<{
518
+ id: z.ZodString;
519
+ kind: z.ZodEnum<{
520
+ "built-in": "built-in";
521
+ custom: "custom";
522
+ }>;
523
+ fingerprint: z.ZodString;
524
+ }, z.core.$strict>;
525
+ semanticResolver: z.ZodObject<{
526
+ name: z.ZodString;
527
+ version: z.ZodString;
528
+ }, z.core.$strict>;
529
+ syntaxParser: z.ZodObject<{
530
+ name: z.ZodString;
531
+ version: z.ZodString;
532
+ }, z.core.$strict>;
533
+ analyzers: z.ZodArray<z.ZodObject<{
534
+ name: z.ZodString;
535
+ version: z.ZodString;
536
+ }, z.core.$strict>>;
537
+ configHash: z.ZodString;
538
+ sourceFiles: z.ZodArray<z.ZodObject<{
539
+ path: z.ZodString;
540
+ hash: z.ZodString;
541
+ compilerUnit: z.ZodString;
542
+ lines: z.ZodNumber;
543
+ }, z.core.$strict>>;
544
+ semanticInputs: z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
545
+ path: z.ZodString;
546
+ kind: z.ZodLiteral<"file">;
547
+ hash: z.ZodString;
548
+ }, z.core.$strict>, z.ZodObject<{
549
+ path: z.ZodString;
550
+ kind: z.ZodLiteral<"resolution-probe">;
551
+ scope: z.ZodEnum<{
552
+ project: "project";
553
+ toolchain: "toolchain";
554
+ }>;
555
+ targetKind: z.ZodEnum<{
556
+ file: "file";
557
+ directory: "directory";
558
+ "readable-file": "readable-file";
559
+ }>;
560
+ exists: z.ZodBoolean;
561
+ }, z.core.$strict>, z.ZodObject<{
562
+ path: z.ZodString;
563
+ kind: z.ZodLiteral<"directory-listing">;
564
+ scope: z.ZodEnum<{
565
+ project: "project";
566
+ toolchain: "toolchain";
567
+ }>;
568
+ hash: z.ZodString;
569
+ }, z.core.$strict>, z.ZodObject<{
570
+ path: z.ZodString;
571
+ kind: z.ZodLiteral<"symlink">;
572
+ scope: z.ZodEnum<{
573
+ project: "project";
574
+ toolchain: "toolchain";
575
+ }>;
576
+ target: z.ZodString;
577
+ }, z.core.$strict>, z.ZodObject<{
578
+ path: z.ZodString;
579
+ kind: z.ZodLiteral<"toolchain-file">;
580
+ hash: z.ZodString;
581
+ }, z.core.$strict>], "kind">>;
582
+ artifacts: z.ZodArray<z.ZodObject<{
583
+ path: z.ZodEnum<{
584
+ "overview.md": "overview.md";
585
+ "project.json": "project.json";
586
+ "files.jsonl": "files.jsonl";
587
+ "symbols.jsonl": "symbols.jsonl";
588
+ "relations.jsonl": "relations.jsonl";
589
+ "diagnostics.json": "diagnostics.json";
590
+ }>;
591
+ hash: z.ZodString;
592
+ }, z.core.$strict>>;
593
+ integrityHash: z.ZodString;
594
+ }, z.core.$strict>;
595
+ type ManifestRecord = z.infer<typeof ManifestRecordSchema>;
596
+ declare const CodeMapSchema: z.ZodObject<{
597
+ manifest: z.ZodObject<{
598
+ schemaVersion: z.ZodLiteral<4>;
599
+ analyzerVersion: z.ZodString;
600
+ producer: z.ZodObject<{
601
+ id: z.ZodString;
602
+ kind: z.ZodEnum<{
603
+ "built-in": "built-in";
604
+ custom: "custom";
605
+ }>;
606
+ fingerprint: z.ZodString;
607
+ }, z.core.$strict>;
608
+ semanticResolver: z.ZodObject<{
609
+ name: z.ZodString;
610
+ version: z.ZodString;
611
+ }, z.core.$strict>;
612
+ syntaxParser: z.ZodObject<{
613
+ name: z.ZodString;
614
+ version: z.ZodString;
615
+ }, z.core.$strict>;
616
+ analyzers: z.ZodArray<z.ZodObject<{
617
+ name: z.ZodString;
618
+ version: z.ZodString;
619
+ }, z.core.$strict>>;
620
+ configHash: z.ZodString;
621
+ sourceFiles: z.ZodArray<z.ZodObject<{
622
+ path: z.ZodString;
623
+ hash: z.ZodString;
624
+ compilerUnit: z.ZodString;
625
+ lines: z.ZodNumber;
626
+ }, z.core.$strict>>;
627
+ semanticInputs: z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
628
+ path: z.ZodString;
629
+ kind: z.ZodLiteral<"file">;
630
+ hash: z.ZodString;
631
+ }, z.core.$strict>, z.ZodObject<{
632
+ path: z.ZodString;
633
+ kind: z.ZodLiteral<"resolution-probe">;
634
+ scope: z.ZodEnum<{
635
+ project: "project";
636
+ toolchain: "toolchain";
637
+ }>;
638
+ targetKind: z.ZodEnum<{
639
+ file: "file";
640
+ directory: "directory";
641
+ "readable-file": "readable-file";
642
+ }>;
643
+ exists: z.ZodBoolean;
644
+ }, z.core.$strict>, z.ZodObject<{
645
+ path: z.ZodString;
646
+ kind: z.ZodLiteral<"directory-listing">;
647
+ scope: z.ZodEnum<{
648
+ project: "project";
649
+ toolchain: "toolchain";
650
+ }>;
651
+ hash: z.ZodString;
652
+ }, z.core.$strict>, z.ZodObject<{
653
+ path: z.ZodString;
654
+ kind: z.ZodLiteral<"symlink">;
655
+ scope: z.ZodEnum<{
656
+ project: "project";
657
+ toolchain: "toolchain";
658
+ }>;
659
+ target: z.ZodString;
660
+ }, z.core.$strict>, z.ZodObject<{
661
+ path: z.ZodString;
662
+ kind: z.ZodLiteral<"toolchain-file">;
663
+ hash: z.ZodString;
664
+ }, z.core.$strict>], "kind">>;
665
+ artifacts: z.ZodArray<z.ZodObject<{
666
+ path: z.ZodEnum<{
667
+ "overview.md": "overview.md";
668
+ "project.json": "project.json";
669
+ "files.jsonl": "files.jsonl";
670
+ "symbols.jsonl": "symbols.jsonl";
671
+ "relations.jsonl": "relations.jsonl";
672
+ "diagnostics.json": "diagnostics.json";
673
+ }>;
674
+ hash: z.ZodString;
675
+ }, z.core.$strict>>;
676
+ integrityHash: z.ZodString;
677
+ }, z.core.$strict>;
678
+ project: z.ZodObject<{
679
+ schemaVersion: z.ZodLiteral<4>;
680
+ name: z.ZodString;
681
+ packageManager: z.ZodOptional<z.ZodString>;
682
+ frameworks: z.ZodArray<z.ZodEnum<{
683
+ typescript: "typescript";
684
+ react: "react";
685
+ nextjs: "nextjs";
686
+ nestjs: "nestjs";
687
+ node: "node";
688
+ }>>;
689
+ compilerUnits: z.ZodArray<z.ZodObject<{
690
+ id: z.ZodString;
691
+ kind: z.ZodEnum<{
692
+ configured: "configured";
693
+ fallback: "fallback";
694
+ }>;
695
+ root: z.ZodString;
696
+ config: z.ZodOptional<z.ZodString>;
697
+ references: z.ZodArray<z.ZodString>;
698
+ extends: z.ZodArray<z.ZodString>;
699
+ pathAliases: z.ZodRecord<z.ZodString, z.ZodArray<z.ZodString>>;
700
+ }, z.core.$strict>>;
701
+ tsconfig: z.ZodOptional<z.ZodString>;
702
+ pathAliases: z.ZodRecord<z.ZodString, z.ZodArray<z.ZodString>>;
703
+ entryPoints: z.ZodArray<z.ZodString>;
704
+ workspaces: z.ZodArray<z.ZodObject<{
705
+ name: z.ZodString;
706
+ path: z.ZodString;
707
+ entryPoints: z.ZodArray<z.ZodString>;
708
+ }, z.core.$strict>>;
709
+ counts: z.ZodObject<{
710
+ files: z.ZodNumber;
711
+ symbols: z.ZodNumber;
712
+ relations: z.ZodNumber;
713
+ diagnostics: z.ZodNumber;
714
+ }, z.core.$strict>;
715
+ }, z.core.$strict>;
716
+ files: z.ZodArray<z.ZodObject<{
717
+ schemaVersion: z.ZodLiteral<4>;
718
+ id: z.ZodString;
719
+ compilerUnit: z.ZodString;
720
+ path: z.ZodString;
721
+ language: z.ZodEnum<{
722
+ ts: "ts";
723
+ tsx: "tsx";
724
+ js: "js";
725
+ jsx: "jsx";
726
+ mts: "mts";
727
+ cts: "cts";
728
+ mjs: "mjs";
729
+ cjs: "cjs";
730
+ }>;
731
+ frameworks: z.ZodArray<z.ZodEnum<{
732
+ typescript: "typescript";
733
+ react: "react";
734
+ nextjs: "nextjs";
735
+ nestjs: "nestjs";
736
+ node: "node";
737
+ }>>;
738
+ hash: z.ZodString;
739
+ lines: z.ZodNumber;
740
+ imports: z.ZodArray<z.ZodObject<{
741
+ source: z.ZodString;
742
+ specifiers: z.ZodArray<z.ZodObject<{
743
+ imported: z.ZodString;
744
+ local: z.ZodString;
745
+ typeOnly: z.ZodOptional<z.ZodBoolean>;
746
+ }, z.core.$strict>>;
747
+ resolved: z.ZodOptional<z.ZodString>;
748
+ external: z.ZodBoolean;
749
+ kind: z.ZodEnum<{
750
+ esm: "esm";
751
+ commonjs: "commonjs";
752
+ }>;
753
+ line: z.ZodNumber;
754
+ }, z.core.$strict>>;
755
+ exports: z.ZodArray<z.ZodObject<{
756
+ name: z.ZodString;
757
+ local: z.ZodOptional<z.ZodString>;
758
+ source: z.ZodOptional<z.ZodString>;
759
+ default: z.ZodBoolean;
760
+ typeOnly: z.ZodOptional<z.ZodBoolean>;
761
+ line: z.ZodNumber;
762
+ }, z.core.$strict>>;
763
+ symbolIds: z.ZodArray<z.ZodString>;
764
+ env: z.ZodArray<z.ZodString>;
765
+ operations: z.ZodArray<z.ZodObject<{
766
+ kind: z.ZodEnum<{
767
+ filesystem: "filesystem";
768
+ http: "http";
769
+ database: "database";
770
+ queue: "queue";
771
+ }>;
772
+ api: z.ZodString;
773
+ line: z.ZodNumber;
774
+ }, z.core.$strict>>;
775
+ syntax: z.ZodObject<{
776
+ parser: z.ZodString;
777
+ factCount: z.ZodNumber;
778
+ hadErrors: z.ZodBoolean;
779
+ fallbackFrom: z.ZodOptional<z.ZodString>;
780
+ }, z.core.$strict>;
781
+ }, z.core.$strict>>;
782
+ symbols: z.ZodArray<z.ZodObject<{
783
+ schemaVersion: z.ZodLiteral<4>;
784
+ id: z.ZodString;
785
+ name: z.ZodString;
786
+ kind: z.ZodEnum<{
787
+ function: "function";
788
+ class: "class";
789
+ method: "method";
790
+ interface: "interface";
791
+ "type-alias": "type-alias";
792
+ variable: "variable";
793
+ "react-component": "react-component";
794
+ "react-hook": "react-hook";
795
+ "react-context": "react-context";
796
+ "next-page": "next-page";
797
+ "next-layout": "next-layout";
798
+ "next-route-handler": "next-route-handler";
799
+ "next-special-file": "next-special-file";
800
+ "nest-module": "nest-module";
801
+ "nest-controller": "nest-controller";
802
+ "nest-provider": "nest-provider";
803
+ "nest-guard": "nest-guard";
804
+ "nest-interceptor": "nest-interceptor";
805
+ "nest-pipe": "nest-pipe";
806
+ "nest-filter": "nest-filter";
807
+ "nest-gateway": "nest-gateway";
808
+ dto: "dto";
809
+ route: "route";
810
+ }>;
811
+ file: z.ZodString;
812
+ range: z.ZodObject<{
813
+ startLine: z.ZodNumber;
814
+ startColumn: z.ZodNumber;
815
+ endLine: z.ZodNumber;
816
+ endColumn: z.ZodNumber;
817
+ }, z.core.$strict>;
818
+ exported: z.ZodBoolean;
819
+ defaultExport: z.ZodOptional<z.ZodBoolean>;
820
+ signature: z.ZodOptional<z.ZodString>;
821
+ documentation: z.ZodOptional<z.ZodString>;
822
+ facts: z.ZodRecord<z.ZodString, z.ZodJSONSchema>;
823
+ sourceHash: z.ZodString;
824
+ }, z.core.$strict>>;
825
+ relations: z.ZodArray<z.ZodObject<{
826
+ schemaVersion: z.ZodLiteral<4>;
827
+ from: z.ZodString;
828
+ type: z.ZodEnum<{
829
+ references: "references";
830
+ imports: "imports";
831
+ exports: "exports";
832
+ reexports: "reexports";
833
+ calls: "calls";
834
+ instantiates: "instantiates";
835
+ renders: "renders";
836
+ "uses-hook": "uses-hook";
837
+ "reads-state": "reads-state";
838
+ "depends-on": "depends-on";
839
+ "used-by": "used-by";
840
+ contains: "contains";
841
+ injects: "injects";
842
+ "handles-route": "handles-route";
843
+ "consumes-dto": "consumes-dto";
844
+ "belongs-to-module": "belongs-to-module";
845
+ "uses-layout": "uses-layout";
846
+ }>;
847
+ to: z.ZodString;
848
+ confidence: z.ZodNumber;
849
+ origin: z.ZodObject<{
850
+ file: z.ZodString;
851
+ line: z.ZodNumber;
852
+ range: z.ZodObject<{
853
+ startLine: z.ZodNumber;
854
+ startColumn: z.ZodNumber;
855
+ endLine: z.ZodNumber;
856
+ endColumn: z.ZodNumber;
857
+ }, z.core.$strict>;
858
+ explanation: z.ZodString;
859
+ classification: z.ZodEnum<{
860
+ exact: "exact";
861
+ "framework-derived": "framework-derived";
862
+ heuristic: "heuristic";
863
+ derived: "derived";
864
+ }>;
865
+ analyzer: z.ZodString;
866
+ }, z.core.$strict>;
867
+ }, z.core.$strict>>;
868
+ diagnostics: z.ZodArray<z.ZodObject<{
869
+ schemaVersion: z.ZodLiteral<4>;
870
+ code: z.ZodEnum<{
871
+ "parse-error": "parse-error";
872
+ "unresolved-import": "unresolved-import";
873
+ "invalid-config": "invalid-config";
874
+ "unsupported-file": "unsupported-file";
875
+ "analysis-error": "analysis-error";
876
+ "parser-fallback": "parser-fallback";
877
+ "compiler-config": "compiler-config";
878
+ }>;
879
+ severity: z.ZodEnum<{
880
+ error: "error";
881
+ info: "info";
882
+ warning: "warning";
883
+ }>;
884
+ message: z.ZodString;
885
+ file: z.ZodOptional<z.ZodString>;
886
+ line: z.ZodOptional<z.ZodNumber>;
887
+ column: z.ZodOptional<z.ZodNumber>;
888
+ }, z.core.$strict>>;
889
+ }, z.core.$strict>;
890
+ type CodeMap = z.infer<typeof CodeMapSchema>;
891
+
892
+ type SyntaxFactKind = "import" | "export" | "declaration" | "call" | "jsx-element" | "parse-error";
893
+ interface SyntaxFact {
894
+ kind: SyntaxFactKind;
895
+ name?: string;
896
+ nodeType: string;
897
+ range: SourceRange;
898
+ evidence: {
899
+ parser: string;
900
+ exact: boolean;
901
+ };
902
+ }
903
+ interface SyntaxIssue {
904
+ message: string;
905
+ range?: SourceRange;
906
+ fatal?: boolean;
907
+ }
908
+ interface SyntaxParseInput {
909
+ path: string;
910
+ language: Language;
911
+ source: string;
912
+ }
913
+ interface SyntaxParseResult {
914
+ parser: string;
915
+ facts: SyntaxFact[];
916
+ issues: SyntaxIssue[];
917
+ hadErrors: boolean;
918
+ fallbackFrom?: string;
919
+ }
920
+ interface SyntaxParserAdapter {
921
+ readonly name: string;
922
+ readonly version?: string;
923
+ supports(language: Language): boolean | Promise<boolean>;
924
+ parse(input: SyntaxParseInput): SyntaxParseResult | Promise<SyntaxParseResult>;
925
+ }
926
+ interface WorkspaceDiscoveryResult {
927
+ tool: string;
928
+ packages: WorkspacePackage[];
929
+ }
930
+ interface WorkspaceDiscovery {
931
+ readonly name: string;
932
+ discover(root: string): Promise<WorkspaceDiscoveryResult>;
933
+ }
934
+ interface IgnoreAdapter {
935
+ readonly name: string;
936
+ filter(root: string, paths: readonly string[]): Promise<string[]>;
937
+ }
938
+ interface SemanticResolveInput {
939
+ root: string;
940
+ sourceFiles: string[];
941
+ tsconfig?: string;
942
+ /** Stable owning compiler-unit ID. Additive in schema v2; legacy resolvers may ignore it. */
943
+ compilerUnit?: string;
944
+ }
945
+ interface SemanticModuleResolution {
946
+ resolvedFileName: string;
947
+ isExternalLibraryImport: boolean;
948
+ }
949
+ interface SemanticResolution {
950
+ program: ts.Program;
951
+ checker: ts.TypeChecker;
952
+ pathAliases: Record<string, string[]>;
953
+ diagnostics: DiagnosticRecord[];
954
+ /** Unit-anchored resolution used by analyzers instead of the process-global ts.sys host. */
955
+ resolveModule?: (moduleName: string, containingFile: string) => SemanticModuleResolution | undefined;
956
+ /** Bounded compiler-consumed files, typed probes, directories, symlinks, and toolchain inputs. */
957
+ semanticInputs?: () => SemanticInputObservation[];
958
+ }
959
+ type SemanticInputObservation = {
960
+ path: string;
961
+ kind: "file";
962
+ hash: string;
963
+ } | {
964
+ path: string;
965
+ kind: "resolution-probe";
966
+ /** Defaults to the selected project for third-party resolver compatibility. */
967
+ scope?: "project" | "toolchain";
968
+ targetKind: "file" | "directory" | "readable-file";
969
+ exists: boolean;
970
+ } | {
971
+ path: string;
972
+ kind: "directory-listing";
973
+ /** Defaults to the selected project for third-party resolver compatibility. */
974
+ scope?: "project" | "toolchain";
975
+ hash: string;
976
+ } | {
977
+ path: string;
978
+ kind: "symlink";
979
+ /** Defaults to the selected project for third-party resolver compatibility. */
980
+ scope?: "project" | "toolchain";
981
+ target: string;
982
+ } | {
983
+ path: string;
984
+ kind: "toolchain-file";
985
+ hash: string;
986
+ };
987
+ interface SemanticResolver {
988
+ readonly name: string;
989
+ readonly version?: string;
990
+ resolve(input: SemanticResolveInput): SemanticResolution | Promise<SemanticResolution>;
991
+ }
992
+ interface ScanOptions {
993
+ root?: string;
994
+ config?: string;
995
+ output?: string;
996
+ strict?: boolean;
997
+ analyzers?: FrameworkAnalyzer[];
998
+ parser?: SyntaxParserAdapter;
999
+ semanticResolver?: SemanticResolver;
1000
+ }
1001
+ interface ScanChanges {
1002
+ added: string[];
1003
+ modified: string[];
1004
+ deleted: string[];
1005
+ moved: Array<{
1006
+ from: string;
1007
+ to: string;
1008
+ }>;
1009
+ }
1010
+ interface ScanResult {
1011
+ map: CodeMap;
1012
+ root: string;
1013
+ outputDir: string;
1014
+ wrote: boolean;
1015
+ changes: ScanChanges;
1016
+ elapsedMs: number;
1017
+ counts: MapCounts;
1018
+ criticalParseErrors: boolean;
1019
+ }
1020
+ interface LoadCodeMapOptions {
1021
+ root?: string;
1022
+ config?: string;
1023
+ output?: string;
1024
+ }
1025
+ type FreshnessStatus = "current" | "stale" | "missing";
1026
+ interface FreshnessResult {
1027
+ status: FreshnessStatus;
1028
+ current: boolean;
1029
+ root: string;
1030
+ outputDir: string;
1031
+ reasons: string[];
1032
+ changes: ScanChanges;
1033
+ }
1034
+ interface ShowResult {
1035
+ selector: string;
1036
+ matches: Array<{
1037
+ symbol: SymbolRecord;
1038
+ file: FileRecord;
1039
+ inbound: RelationRecord[];
1040
+ outbound: RelationRecord[];
1041
+ }>;
1042
+ }
1043
+ interface AnalysisContext {
1044
+ root: string;
1045
+ relativePath: string;
1046
+ sourceFile: ts.SourceFile;
1047
+ program: ts.Program;
1048
+ checker: ts.TypeChecker;
1049
+ sourceHash: string;
1050
+ file: FileRecord;
1051
+ packageDependencies: Set<string>;
1052
+ syntax: SyntaxParseResult;
1053
+ includePrivateSymbols: boolean;
1054
+ compilerUnit?: CompilerUnitRecord;
1055
+ indexedSourcePaths?: ReadonlySet<string>;
1056
+ resolveModule?: SemanticResolution["resolveModule"];
1057
+ }
1058
+ interface AnalysisContribution {
1059
+ symbols?: SymbolRecord[];
1060
+ relations?: RelationRecord[];
1061
+ diagnostics?: DiagnosticRecord[];
1062
+ frameworks?: Framework[];
1063
+ }
1064
+ interface FrameworkAnalyzer {
1065
+ readonly name: string;
1066
+ readonly version?: string;
1067
+ supports(context: AnalysisContext): boolean;
1068
+ analyze(context: AnalysisContext): AnalysisContribution | Promise<AnalysisContribution>;
1069
+ }
1070
+ interface Analyzer {
1071
+ readonly analyzers: readonly FrameworkAnalyzer[];
1072
+ readonly parser: SyntaxParserAdapter;
1073
+ scan(options?: ScanOptions): Promise<ScanResult>;
1074
+ }
1075
+
1076
+ interface InitOptions extends LoadCodeMapOptions {
1077
+ force?: boolean;
1078
+ }
1079
+ interface InitResult {
1080
+ root: string;
1081
+ configPath: string;
1082
+ created: boolean;
1083
+ }
1084
+ declare function createDefaultConfig(root: string, configPath: string, output?: string): CodeMapConfig;
1085
+ declare function findProjectRoot(start?: string): Promise<string>;
1086
+ declare function initProject(options?: InitOptions): Promise<InitResult>;
1087
+
1088
+ declare class TypeScriptParserAdapter implements SyntaxParserAdapter {
1089
+ readonly name = "typescript-compiler-syntax";
1090
+ readonly version: string;
1091
+ constructor();
1092
+ supports(language: Language): boolean;
1093
+ parse(input: SyntaxParseInput): SyntaxParseResult;
1094
+ }
1095
+ declare class FallbackParserAdapter implements SyntaxParserAdapter {
1096
+ readonly primary: SyntaxParserAdapter;
1097
+ readonly fallback: SyntaxParserAdapter;
1098
+ readonly name: string;
1099
+ constructor(primary: SyntaxParserAdapter, fallback?: SyntaxParserAdapter);
1100
+ supports(language: Language): Promise<boolean>;
1101
+ parse(input: SyntaxParseInput): Promise<SyntaxParseResult>;
1102
+ private parseFallback;
1103
+ }
1104
+ declare function createTypeScriptParserAdapter(): SyntaxParserAdapter;
1105
+
1106
+ declare function scanProject(options?: ScanOptions): Promise<ScanResult>;
1107
+ declare function createAnalyzer(options?: {
1108
+ analyzers?: FrameworkAnalyzer[];
1109
+ parser?: SyntaxParserAdapter;
1110
+ semanticResolver?: SemanticResolver;
1111
+ }): {
1112
+ analyzers: FrameworkAnalyzer[];
1113
+ parser: TypeScriptParserAdapter | FallbackParserAdapter;
1114
+ scan: (scanOptions?: ScanOptions) => Promise<ScanResult>;
1115
+ };
1116
+
1117
+ declare function buildOverview(map: CodeMap): string;
1118
+ declare function loadCodeMap(options?: LoadCodeMapOptions): Promise<CodeMap>;
1119
+ declare function computeManifestIntegrityHash(manifest: ManifestRecord): string;
1120
+
1121
+ declare function checkFreshness(options?: LoadCodeMapOptions): Promise<FreshnessResult>;
1122
+
1123
+ declare function showSymbol(map: CodeMap, selector: string): ShowResult;
1124
+ declare function formatShowResult(result: ShowResult): string;
1125
+
1126
+ declare class CoreAnalyzer implements FrameworkAnalyzer {
1127
+ readonly name = "typescript-node";
1128
+ readonly version = "0.4.0";
1129
+ supports(): boolean;
1130
+ analyze(context: AnalysisContext): AnalysisContribution;
1131
+ }
1132
+
1133
+ declare class ReactAnalyzer implements FrameworkAnalyzer {
1134
+ readonly name = "react";
1135
+ readonly version = "0.4.0";
1136
+ supports(context: AnalysisContext): boolean;
1137
+ analyze(context: AnalysisContext): AnalysisContribution;
1138
+ }
1139
+
1140
+ declare class NextJsAnalyzer implements FrameworkAnalyzer {
1141
+ readonly name = "nextjs";
1142
+ readonly version = "0.1.0-experimental";
1143
+ constructor();
1144
+ supports(context: AnalysisContext): boolean;
1145
+ analyze(context: AnalysisContext): AnalysisContribution;
1146
+ }
1147
+
1148
+ declare class NestJsAnalyzer implements FrameworkAnalyzer {
1149
+ readonly name = "nestjs";
1150
+ readonly version = "0.1.0-experimental";
1151
+ constructor();
1152
+ supports(context: AnalysisContext): boolean;
1153
+ analyze(context: AnalysisContext): AnalysisContribution;
1154
+ }
1155
+
1156
+ declare class ManypkgWorkspaceDiscovery implements WorkspaceDiscovery {
1157
+ readonly name = "manypkg";
1158
+ discover(root: string): Promise<WorkspaceDiscoveryResult>;
1159
+ }
1160
+ declare function createWorkspaceDiscovery(): WorkspaceDiscovery;
1161
+
1162
+ declare class GitIgnoreAdapter implements IgnoreAdapter {
1163
+ readonly name = "ignore";
1164
+ filter(root: string, paths: readonly string[]): Promise<string[]>;
1165
+ }
1166
+ declare function createGitIgnoreAdapter(): IgnoreAdapter;
1167
+
1168
+ /** TypeScript remains authoritative for all TypeScript/JavaScript semantic facts. */
1169
+ declare class TypeScriptSemanticResolver implements SemanticResolver {
1170
+ private readonly jsDocParsingMode;
1171
+ readonly name = "typescript-program";
1172
+ readonly version: string;
1173
+ constructor(jsDocParsingMode?: ts.JSDocParsingMode);
1174
+ resolve(input: SemanticResolveInput): SemanticResolution;
1175
+ }
1176
+ declare function createTypeScriptSemanticResolver(): SemanticResolver;
1177
+
1178
+ export { ANALYZER_VERSION, type AnalysisContext, type AnalysisContribution, type Analyzer, type ArtifactIntegrityRecord, ArtifactIntegrityRecordSchema, CONFIG_VERSION, type CodeMap, type CodeMapConfig, CodeMapError, CodeMapSchema, type CompilerUnitRecord, CompilerUnitRecordSchema, ConfigSchema, CoreAnalyzer, type DiagnosticCode, type DiagnosticRecord, DiagnosticRecordSchema, type DiagnosticSeverity, type ExportRecord, type ExternalOperation, type ExternalOperationKind, FallbackParserAdapter, type FileRecord, FileRecordSchema, type Framework, type FrameworkAnalyzer, type FrameworkSelection, type FreshnessResult, type FreshnessStatus, GitIgnoreAdapter, type IgnoreAdapter, type ImportRecord, type ImportSpecifierRecord, type InitOptions, type InitResult, type JsonPrimitive, type JsonValue, type Language, type LoadCodeMapOptions, type ManifestRecord, ManifestRecordSchema, ManypkgWorkspaceDiscovery, type MapCounts, NestJsAnalyzer, NextJsAnalyzer, type ProducerRecord, ProducerRecordSchema, type ProjectRecord, ProjectRecordSchema, ReactAnalyzer, type RelationEvidenceClassification, type RelationOrigin, type RelationRecord, RelationRecordSchema, type RelationType, SCHEMA_VERSION, type ScanChanges, type ScanOptions, type ScanResult, type SemanticInputObservation, type SemanticInputRecord, SemanticInputRecordSchema, type SemanticModuleResolution, type SemanticResolution, type SemanticResolveInput, type SemanticResolver, type ShowResult, type SourceRange, type SymbolKind, type SymbolRecord, SymbolRecordSchema, type SyntaxFact, type SyntaxFactKind, type SyntaxIssue, type SyntaxParseInput, type SyntaxParseResult, type SyntaxParserAdapter, type SyntaxSummary, TypeScriptParserAdapter, TypeScriptSemanticResolver, type WorkspaceDiscovery, type WorkspaceDiscoveryResult, type WorkspacePackage, buildOverview, checkFreshness, computeManifestIntegrityHash, createAnalyzer, createDefaultConfig, createGitIgnoreAdapter, createTypeScriptParserAdapter, createTypeScriptSemanticResolver, createWorkspaceDiscovery, findProjectRoot, formatShowResult, initProject, loadCodeMap, scanProject, showSymbol };