aspectcode 0.2.2 → 0.3.1
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/dist/cli.d.ts +15 -47
- package/dist/cli.d.ts.map +1 -1
- package/dist/cli.js +18 -17
- package/dist/cli.js.map +1 -1
- package/dist/config.d.ts +14 -24
- package/dist/config.d.ts.map +1 -1
- package/dist/config.js +5 -60
- package/dist/config.js.map +1 -1
- package/dist/kbBuilder.d.ts +14 -0
- package/dist/kbBuilder.d.ts.map +1 -0
- package/dist/kbBuilder.js +106 -0
- package/dist/kbBuilder.js.map +1 -0
- package/dist/main.d.ts +4 -5
- package/dist/main.d.ts.map +1 -1
- package/dist/main.js +45 -124
- package/dist/main.js.map +1 -1
- package/dist/optimize.d.ts +14 -0
- package/dist/optimize.d.ts.map +1 -0
- package/dist/optimize.js +131 -0
- package/dist/optimize.js.map +1 -0
- package/dist/pipeline.d.ts +15 -0
- package/dist/pipeline.d.ts.map +1 -0
- package/dist/pipeline.js +212 -0
- package/dist/pipeline.js.map +1 -0
- package/dist/toolIngestion.d.ts +15 -0
- package/dist/toolIngestion.d.ts.map +1 -0
- package/dist/toolIngestion.js +47 -0
- package/dist/toolIngestion.js.map +1 -0
- package/dist/writer.d.ts +17 -0
- package/dist/writer.d.ts.map +1 -0
- package/dist/writer.js +26 -0
- package/dist/writer.js.map +1 -0
- package/node_modules/@aspectcode/core/dist/analysis/analyzer.d.ts +34 -0
- package/node_modules/@aspectcode/core/dist/analysis/analyzer.d.ts.map +1 -0
- package/node_modules/@aspectcode/core/dist/analysis/analyzer.js +240 -0
- package/node_modules/@aspectcode/core/dist/analysis/analyzer.js.map +1 -0
- package/node_modules/@aspectcode/core/dist/analysis/dependencyAdapters.d.ts +32 -0
- package/node_modules/@aspectcode/core/dist/analysis/dependencyAdapters.d.ts.map +1 -0
- package/node_modules/@aspectcode/core/dist/analysis/dependencyAdapters.js +133 -0
- package/node_modules/@aspectcode/core/dist/analysis/dependencyAdapters.js.map +1 -0
- package/node_modules/@aspectcode/core/dist/analysis/importParsers.d.ts +30 -0
- package/node_modules/@aspectcode/core/dist/analysis/importParsers.d.ts.map +1 -0
- package/node_modules/@aspectcode/core/dist/analysis/importParsers.js +92 -0
- package/node_modules/@aspectcode/core/dist/analysis/importParsers.js.map +1 -0
- package/node_modules/@aspectcode/core/dist/analysis/index.d.ts +9 -0
- package/node_modules/@aspectcode/core/dist/analysis/index.d.ts.map +1 -0
- package/node_modules/@aspectcode/core/dist/analysis/index.js +9 -0
- package/node_modules/@aspectcode/core/dist/analysis/index.js.map +1 -0
- package/node_modules/@aspectcode/core/dist/analysis/moduleResolver.d.ts +34 -0
- package/node_modules/@aspectcode/core/dist/analysis/moduleResolver.d.ts.map +1 -0
- package/node_modules/@aspectcode/core/dist/analysis/moduleResolver.js +240 -0
- package/node_modules/@aspectcode/core/dist/analysis/moduleResolver.js.map +1 -0
- package/node_modules/@aspectcode/core/dist/analysis/repo.d.ts +33 -0
- package/node_modules/@aspectcode/core/dist/analysis/repo.d.ts.map +1 -0
- package/node_modules/@aspectcode/core/dist/analysis/repo.js +246 -0
- package/node_modules/@aspectcode/core/dist/analysis/repo.js.map +1 -0
- package/node_modules/@aspectcode/core/dist/classifiers.d.ts +24 -0
- package/node_modules/@aspectcode/core/dist/classifiers.d.ts.map +1 -0
- package/node_modules/@aspectcode/core/dist/classifiers.js +119 -0
- package/node_modules/@aspectcode/core/dist/classifiers.js.map +1 -0
- package/node_modules/@aspectcode/core/dist/fs/exclusions.d.ts +26 -0
- package/node_modules/@aspectcode/core/dist/fs/exclusions.d.ts.map +1 -0
- package/node_modules/@aspectcode/core/dist/fs/exclusions.js +130 -0
- package/node_modules/@aspectcode/core/dist/fs/exclusions.js.map +1 -0
- package/node_modules/@aspectcode/core/dist/fs/fingerprint.d.ts +42 -0
- package/node_modules/@aspectcode/core/dist/fs/fingerprint.d.ts.map +1 -0
- package/node_modules/@aspectcode/core/dist/fs/fingerprint.js +125 -0
- package/node_modules/@aspectcode/core/dist/fs/fingerprint.js.map +1 -0
- package/node_modules/@aspectcode/core/dist/fs/index.d.ts +9 -0
- package/node_modules/@aspectcode/core/dist/fs/index.d.ts.map +1 -0
- package/node_modules/@aspectcode/core/dist/fs/index.js +26 -0
- package/node_modules/@aspectcode/core/dist/fs/index.js.map +1 -0
- package/node_modules/@aspectcode/core/dist/fs/walker.d.ts +23 -0
- package/node_modules/@aspectcode/core/dist/fs/walker.d.ts.map +1 -0
- package/node_modules/@aspectcode/core/dist/fs/walker.js +94 -0
- package/node_modules/@aspectcode/core/dist/fs/walker.js.map +1 -0
- package/node_modules/@aspectcode/core/dist/host.d.ts +38 -0
- package/node_modules/@aspectcode/core/dist/host.d.ts.map +1 -0
- package/node_modules/@aspectcode/core/dist/host.js +110 -0
- package/node_modules/@aspectcode/core/dist/host.js.map +1 -0
- package/node_modules/@aspectcode/core/dist/index.d.ts +23 -0
- package/node_modules/@aspectcode/core/dist/index.d.ts.map +1 -0
- package/node_modules/@aspectcode/core/dist/index.js +59 -0
- package/node_modules/@aspectcode/core/dist/index.js.map +1 -0
- package/node_modules/@aspectcode/core/dist/model.d.ts +90 -0
- package/node_modules/@aspectcode/core/dist/model.d.ts.map +1 -0
- package/node_modules/@aspectcode/core/dist/model.js +9 -0
- package/node_modules/@aspectcode/core/dist/model.js.map +1 -0
- package/node_modules/@aspectcode/core/dist/parsers/csharpExtractors.d.ts +17 -0
- package/node_modules/@aspectcode/core/dist/parsers/csharpExtractors.d.ts.map +1 -0
- package/node_modules/@aspectcode/core/dist/parsers/csharpExtractors.js +225 -0
- package/node_modules/@aspectcode/core/dist/parsers/csharpExtractors.js.map +1 -0
- package/node_modules/@aspectcode/core/dist/parsers/grammarLoader.d.ts +30 -0
- package/node_modules/@aspectcode/core/dist/parsers/grammarLoader.d.ts.map +1 -0
- package/node_modules/@aspectcode/core/dist/parsers/grammarLoader.js +71 -0
- package/node_modules/@aspectcode/core/dist/parsers/grammarLoader.js.map +1 -0
- package/node_modules/@aspectcode/core/dist/parsers/index.d.ts +13 -0
- package/node_modules/@aspectcode/core/dist/parsers/index.d.ts.map +1 -0
- package/node_modules/@aspectcode/core/dist/parsers/index.js +32 -0
- package/node_modules/@aspectcode/core/dist/parsers/index.js.map +1 -0
- package/node_modules/@aspectcode/core/dist/parsers/javaExtractors.d.ts +17 -0
- package/node_modules/@aspectcode/core/dist/parsers/javaExtractors.d.ts.map +1 -0
- package/node_modules/@aspectcode/core/dist/parsers/javaExtractors.js +182 -0
- package/node_modules/@aspectcode/core/dist/parsers/javaExtractors.js.map +1 -0
- package/node_modules/@aspectcode/core/dist/parsers/languages.d.ts +44 -0
- package/node_modules/@aspectcode/core/dist/parsers/languages.d.ts.map +1 -0
- package/node_modules/@aspectcode/core/dist/parsers/languages.js +64 -0
- package/node_modules/@aspectcode/core/dist/parsers/languages.js.map +1 -0
- package/node_modules/@aspectcode/core/dist/parsers/pythonExtractors.d.ts +18 -0
- package/node_modules/@aspectcode/core/dist/parsers/pythonExtractors.d.ts.map +1 -0
- package/node_modules/@aspectcode/core/dist/parsers/pythonExtractors.js +139 -0
- package/node_modules/@aspectcode/core/dist/parsers/pythonExtractors.js.map +1 -0
- package/node_modules/@aspectcode/core/dist/parsers/tsJsExtractors.d.ts +22 -0
- package/node_modules/@aspectcode/core/dist/parsers/tsJsExtractors.d.ts.map +1 -0
- package/node_modules/@aspectcode/core/dist/parsers/tsJsExtractors.js +240 -0
- package/node_modules/@aspectcode/core/dist/parsers/tsJsExtractors.js.map +1 -0
- package/node_modules/@aspectcode/core/dist/parsers/utils.d.ts +7 -0
- package/node_modules/@aspectcode/core/dist/parsers/utils.d.ts.map +1 -0
- package/node_modules/@aspectcode/core/dist/parsers/utils.js +11 -0
- package/node_modules/@aspectcode/core/dist/parsers/utils.js.map +1 -0
- package/node_modules/@aspectcode/core/dist/paths.d.ts +27 -0
- package/node_modules/@aspectcode/core/dist/paths.d.ts.map +1 -0
- package/node_modules/@aspectcode/core/dist/paths.js +45 -0
- package/node_modules/@aspectcode/core/dist/paths.js.map +1 -0
- package/node_modules/@aspectcode/core/dist/stats.d.ts +41 -0
- package/node_modules/@aspectcode/core/dist/stats.d.ts.map +1 -0
- package/node_modules/@aspectcode/core/dist/stats.js +88 -0
- package/node_modules/@aspectcode/core/dist/stats.js.map +1 -0
- package/node_modules/@aspectcode/core/package.json +41 -0
- package/node_modules/@aspectcode/core/parsers/c_sharp.wasm +0 -0
- package/node_modules/@aspectcode/core/parsers/java.wasm +0 -0
- package/node_modules/@aspectcode/core/parsers/javascript.wasm +0 -0
- package/node_modules/@aspectcode/core/parsers/python.wasm +0 -0
- package/node_modules/@aspectcode/core/parsers/tree-sitter.wasm +0 -0
- package/node_modules/@aspectcode/core/parsers/tsx.wasm +0 -0
- package/node_modules/@aspectcode/core/parsers/typescript.wasm +0 -0
- package/node_modules/@aspectcode/emitters/dist/emitter.d.ts +72 -0
- package/node_modules/@aspectcode/emitters/dist/emitter.d.ts.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/emitter.js +10 -0
- package/node_modules/@aspectcode/emitters/dist/emitter.js.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/host.d.ts +31 -0
- package/node_modules/@aspectcode/emitters/dist/host.d.ts.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/host.js +86 -0
- package/node_modules/@aspectcode/emitters/dist/host.js.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/index.d.ts +27 -0
- package/node_modules/@aspectcode/emitters/dist/index.d.ts.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/index.js +116 -0
- package/node_modules/@aspectcode/emitters/dist/index.js.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/instructions/content.d.ts +15 -0
- package/node_modules/@aspectcode/emitters/dist/instructions/content.d.ts.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/instructions/content.js +289 -0
- package/node_modules/@aspectcode/emitters/dist/instructions/content.js.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/instructions/detection.d.ts +13 -0
- package/node_modules/@aspectcode/emitters/dist/instructions/detection.d.ts.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/instructions/detection.js +55 -0
- package/node_modules/@aspectcode/emitters/dist/instructions/detection.js.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/instructions/formats.d.ts +17 -0
- package/node_modules/@aspectcode/emitters/dist/instructions/formats.d.ts.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/instructions/formats.js +23 -0
- package/node_modules/@aspectcode/emitters/dist/instructions/formats.js.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/instructions/index.d.ts +5 -0
- package/node_modules/@aspectcode/emitters/dist/instructions/index.d.ts.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/instructions/index.js +12 -0
- package/node_modules/@aspectcode/emitters/dist/instructions/index.js.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/instructions/instructionsEmitter.d.ts +9 -0
- package/node_modules/@aspectcode/emitters/dist/instructions/instructionsEmitter.d.ts.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/instructions/instructionsEmitter.js +30 -0
- package/node_modules/@aspectcode/emitters/dist/instructions/instructionsEmitter.js.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/kb/analyzers.d.ts +64 -0
- package/node_modules/@aspectcode/emitters/dist/kb/analyzers.d.ts.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/kb/analyzers.js +504 -0
- package/node_modules/@aspectcode/emitters/dist/kb/analyzers.js.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/kb/architectureEmitter.d.ts +24 -0
- package/node_modules/@aspectcode/emitters/dist/kb/architectureEmitter.d.ts.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/kb/architectureEmitter.js +238 -0
- package/node_modules/@aspectcode/emitters/dist/kb/architectureEmitter.js.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/kb/classifiers.d.ts +8 -0
- package/node_modules/@aspectcode/emitters/dist/kb/classifiers.d.ts.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/kb/classifiers.js +14 -0
- package/node_modules/@aspectcode/emitters/dist/kb/classifiers.js.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/kb/constants.d.ts +35 -0
- package/node_modules/@aspectcode/emitters/dist/kb/constants.d.ts.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/kb/constants.js +38 -0
- package/node_modules/@aspectcode/emitters/dist/kb/constants.js.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/kb/contextEmitter.d.ts +20 -0
- package/node_modules/@aspectcode/emitters/dist/kb/contextEmitter.d.ts.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/kb/contextEmitter.js +155 -0
- package/node_modules/@aspectcode/emitters/dist/kb/contextEmitter.js.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/kb/conventions.d.ts +52 -0
- package/node_modules/@aspectcode/emitters/dist/kb/conventions.d.ts.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/kb/conventions.js +391 -0
- package/node_modules/@aspectcode/emitters/dist/kb/conventions.js.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/kb/depData.d.ts +18 -0
- package/node_modules/@aspectcode/emitters/dist/kb/depData.d.ts.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/kb/depData.js +31 -0
- package/node_modules/@aspectcode/emitters/dist/kb/depData.js.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/kb/detectors.d.ts +18 -0
- package/node_modules/@aspectcode/emitters/dist/kb/detectors.d.ts.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/kb/detectors.js +317 -0
- package/node_modules/@aspectcode/emitters/dist/kb/detectors.js.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/kb/entryPoints.d.ts +33 -0
- package/node_modules/@aspectcode/emitters/dist/kb/entryPoints.d.ts.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/kb/entryPoints.js +323 -0
- package/node_modules/@aspectcode/emitters/dist/kb/entryPoints.js.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/kb/helpers.d.ts +27 -0
- package/node_modules/@aspectcode/emitters/dist/kb/helpers.d.ts.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/kb/helpers.js +63 -0
- package/node_modules/@aspectcode/emitters/dist/kb/helpers.js.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/kb/index.d.ts +27 -0
- package/node_modules/@aspectcode/emitters/dist/kb/index.d.ts.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/kb/index.js +72 -0
- package/node_modules/@aspectcode/emitters/dist/kb/index.js.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/kb/kbEmitter.d.ts +21 -0
- package/node_modules/@aspectcode/emitters/dist/kb/kbEmitter.d.ts.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/kb/kbEmitter.js +125 -0
- package/node_modules/@aspectcode/emitters/dist/kb/kbEmitter.js.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/kb/mapEmitter.d.ts +26 -0
- package/node_modules/@aspectcode/emitters/dist/kb/mapEmitter.d.ts.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/kb/mapEmitter.js +255 -0
- package/node_modules/@aspectcode/emitters/dist/kb/mapEmitter.js.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/kb/policy.d.ts +12 -0
- package/node_modules/@aspectcode/emitters/dist/kb/policy.d.ts.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/kb/policy.js +29 -0
- package/node_modules/@aspectcode/emitters/dist/kb/policy.js.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/kb/symbols.d.ts +43 -0
- package/node_modules/@aspectcode/emitters/dist/kb/symbols.d.ts.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/kb/symbols.js +343 -0
- package/node_modules/@aspectcode/emitters/dist/kb/symbols.js.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/manifest.d.ts +37 -0
- package/node_modules/@aspectcode/emitters/dist/manifest.d.ts.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/manifest.js +50 -0
- package/node_modules/@aspectcode/emitters/dist/manifest.js.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/report.d.ts +22 -0
- package/node_modules/@aspectcode/emitters/dist/report.d.ts.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/report.js +3 -0
- package/node_modules/@aspectcode/emitters/dist/report.js.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/stableJson.d.ts +14 -0
- package/node_modules/@aspectcode/emitters/dist/stableJson.d.ts.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/stableJson.js +40 -0
- package/node_modules/@aspectcode/emitters/dist/stableJson.js.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/transaction.d.ts +29 -0
- package/node_modules/@aspectcode/emitters/dist/transaction.d.ts.map +1 -0
- package/node_modules/@aspectcode/emitters/dist/transaction.js +104 -0
- package/node_modules/@aspectcode/emitters/dist/transaction.js.map +1 -0
- package/node_modules/@aspectcode/emitters/package.json +39 -0
- package/node_modules/@aspectcode/optimizer/dist/agent.d.ts +18 -0
- package/node_modules/@aspectcode/optimizer/dist/agent.d.ts.map +1 -0
- package/node_modules/@aspectcode/optimizer/dist/agent.js +123 -0
- package/node_modules/@aspectcode/optimizer/dist/agent.js.map +1 -0
- package/node_modules/@aspectcode/optimizer/dist/index.d.ts +15 -0
- package/node_modules/@aspectcode/optimizer/dist/index.d.ts.map +1 -0
- package/node_modules/@aspectcode/optimizer/dist/index.js +31 -0
- package/node_modules/@aspectcode/optimizer/dist/index.js.map +1 -0
- package/node_modules/@aspectcode/optimizer/dist/prompts.d.ts +39 -0
- package/node_modules/@aspectcode/optimizer/dist/prompts.d.ts.map +1 -0
- package/node_modules/@aspectcode/optimizer/dist/prompts.js +156 -0
- package/node_modules/@aspectcode/optimizer/dist/prompts.js.map +1 -0
- package/node_modules/@aspectcode/optimizer/dist/providers/anthropic.d.ts +20 -0
- package/node_modules/@aspectcode/optimizer/dist/providers/anthropic.d.ts.map +1 -0
- package/node_modules/@aspectcode/optimizer/dist/providers/anthropic.js +126 -0
- package/node_modules/@aspectcode/optimizer/dist/providers/anthropic.js.map +1 -0
- package/node_modules/@aspectcode/optimizer/dist/providers/index.d.ts +28 -0
- package/node_modules/@aspectcode/optimizer/dist/providers/index.d.ts.map +1 -0
- package/node_modules/@aspectcode/optimizer/dist/providers/index.js +142 -0
- package/node_modules/@aspectcode/optimizer/dist/providers/index.js.map +1 -0
- package/node_modules/@aspectcode/optimizer/dist/providers/openai.d.ts +19 -0
- package/node_modules/@aspectcode/optimizer/dist/providers/openai.d.ts.map +1 -0
- package/node_modules/@aspectcode/optimizer/dist/providers/openai.js +98 -0
- package/node_modules/@aspectcode/optimizer/dist/providers/openai.js.map +1 -0
- package/node_modules/@aspectcode/optimizer/dist/providers/retry.d.ts +19 -0
- package/node_modules/@aspectcode/optimizer/dist/providers/retry.d.ts.map +1 -0
- package/node_modules/@aspectcode/optimizer/dist/providers/retry.js +87 -0
- package/node_modules/@aspectcode/optimizer/dist/providers/retry.js.map +1 -0
- package/node_modules/@aspectcode/optimizer/dist/types.d.ts +93 -0
- package/node_modules/@aspectcode/optimizer/dist/types.d.ts.map +1 -0
- package/node_modules/@aspectcode/optimizer/dist/types.js +20 -0
- package/node_modules/@aspectcode/optimizer/dist/types.js.map +1 -0
- package/node_modules/@aspectcode/optimizer/package.json +41 -0
- package/node_modules/dotenv/CHANGELOG.md +520 -0
- package/node_modules/dotenv/LICENSE +23 -0
- package/node_modules/dotenv/README-es.md +411 -0
- package/node_modules/dotenv/README.md +645 -0
- package/node_modules/dotenv/SECURITY.md +1 -0
- package/node_modules/dotenv/config.d.ts +1 -0
- package/node_modules/dotenv/config.js +9 -0
- package/node_modules/dotenv/lib/cli-options.js +17 -0
- package/node_modules/dotenv/lib/env-options.js +28 -0
- package/node_modules/dotenv/lib/main.d.ts +162 -0
- package/node_modules/dotenv/lib/main.js +386 -0
- package/node_modules/dotenv/package.json +62 -0
- package/package.json +16 -4
- package/dist/commands/deps.d.ts +0 -11
- package/dist/commands/deps.d.ts.map +0 -1
- package/dist/commands/deps.js +0 -197
- package/dist/commands/deps.js.map +0 -1
- package/dist/commands/generate.d.ts +0 -8
- package/dist/commands/generate.d.ts.map +0 -1
- package/dist/commands/generate.js +0 -162
- package/dist/commands/generate.js.map +0 -1
- package/dist/commands/settings.d.ts +0 -9
- package/dist/commands/settings.d.ts.map +0 -1
- package/dist/commands/settings.js +0 -165
- package/dist/commands/settings.js.map +0 -1
- package/dist/commands/watch.d.ts +0 -6
- package/dist/commands/watch.d.ts.map +0 -1
- package/dist/commands/watch.js +0 -180
- package/dist/commands/watch.js.map +0 -1
- package/dist/connections.d.ts +0 -24
- package/dist/connections.d.ts.map +0 -1
- package/dist/connections.js +0 -89
- package/dist/connections.js.map +0 -1
|
@@ -0,0 +1,343 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Symbol-extraction helpers for the KB emitter.
|
|
4
|
+
*
|
|
5
|
+
* - extractModelSignature – one-line model signature from content
|
|
6
|
+
* - extractFileSymbolsWithSignatures – all exported symbols in a file
|
|
7
|
+
*
|
|
8
|
+
* Regex-based fallback; tree-sitter support is injected via `grammars`
|
|
9
|
+
* parameter following the existing kb.ts contract.
|
|
10
|
+
*
|
|
11
|
+
* All functions are pure (no I/O, no vscode).
|
|
12
|
+
*/
|
|
13
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
14
|
+
exports.extractModelSignature = extractModelSignature;
|
|
15
|
+
exports.extractFileSymbolsWithSignatures = extractFileSymbolsWithSignatures;
|
|
16
|
+
const core_1 = require("@aspectcode/core");
|
|
17
|
+
const analyzers_1 = require("./analyzers");
|
|
18
|
+
// ── extractModelSignature ────────────────────────────────────
|
|
19
|
+
/**
|
|
20
|
+
* Extract a one-line signature for a named model/class/interface
|
|
21
|
+
* from the file content cache.
|
|
22
|
+
*/
|
|
23
|
+
function extractModelSignature(filePath, modelName, fileContentCache) {
|
|
24
|
+
const text = fileContentCache.get(filePath);
|
|
25
|
+
if (!text)
|
|
26
|
+
return null;
|
|
27
|
+
const lines = text.split('\n');
|
|
28
|
+
const ext = getExtension(filePath);
|
|
29
|
+
let cleanName = modelName;
|
|
30
|
+
cleanName = cleanName.replace(/^(Data Class|Pydantic|ORM|Entity|BaseModel|SQLModel|Interface|Type Alias)\s*[:(]\s*/i, '');
|
|
31
|
+
cleanName = cleanName.replace(/\s*\([^)]+\)\s*-\s*\w+\s*$/, '');
|
|
32
|
+
cleanName = cleanName.replace(/\s*-\s*(class|function|type|interface)\s*$/i, '');
|
|
33
|
+
cleanName = cleanName.split(/[\s:,]/)[0].trim();
|
|
34
|
+
if (!cleanName || cleanName.length < 2 || !/^[A-Za-z_]/.test(cleanName))
|
|
35
|
+
return null;
|
|
36
|
+
if (ext === '.py')
|
|
37
|
+
return extractPyModelSig(lines, cleanName);
|
|
38
|
+
if (['.ts', '.tsx'].includes(ext))
|
|
39
|
+
return extractTSModelSig(lines, cleanName);
|
|
40
|
+
if (ext === '.java')
|
|
41
|
+
return extractJavaModelSig(lines, cleanName);
|
|
42
|
+
if (ext === '.cs')
|
|
43
|
+
return extractCSModelSig(lines, cleanName);
|
|
44
|
+
if (ext === '.prisma')
|
|
45
|
+
return extractPrismaModelSig(lines, cleanName);
|
|
46
|
+
return null;
|
|
47
|
+
}
|
|
48
|
+
function extractPyModelSig(lines, name) {
|
|
49
|
+
for (let i = 0; i < lines.length; i++) {
|
|
50
|
+
if (lines[i].match(new RegExp(`^class\\s+${name}\\s*[:(]`))) {
|
|
51
|
+
const classLine = lines[i].trim();
|
|
52
|
+
const fields = [];
|
|
53
|
+
for (let j = i + 1; j < Math.min(i + 8, lines.length); j++) {
|
|
54
|
+
const m = lines[j].match(/^\s+(\w+):\s*([^\s=]+)/);
|
|
55
|
+
if (m && !m[1].startsWith('_')) {
|
|
56
|
+
fields.push(`${m[1]}: ${m[2]}`);
|
|
57
|
+
if (fields.length >= 3)
|
|
58
|
+
break;
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
return fields.length > 0 ? `${classLine} { ${fields.join(', ')}${fields.length >= 3 ? ', ...' : ''} }` : classLine;
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
return null;
|
|
65
|
+
}
|
|
66
|
+
function extractTSModelSig(lines, name) {
|
|
67
|
+
for (let i = 0; i < lines.length; i++) {
|
|
68
|
+
if (lines[i].match(new RegExp(`(interface|type|class)\\s+${name}\\s*[{<]`))) {
|
|
69
|
+
const typeLine = lines[i].trim();
|
|
70
|
+
const fields = [];
|
|
71
|
+
for (let j = i + 1; j < Math.min(i + 8, lines.length); j++) {
|
|
72
|
+
const m = lines[j].match(/^\s+(\w+)(\?)?\s*:\s*([^;]+)/);
|
|
73
|
+
if (m) {
|
|
74
|
+
fields.push(`${m[1]}${m[2] || ''}: ${m[3].trim()}`);
|
|
75
|
+
if (fields.length >= 3)
|
|
76
|
+
break;
|
|
77
|
+
}
|
|
78
|
+
if (lines[j].includes('}'))
|
|
79
|
+
break;
|
|
80
|
+
}
|
|
81
|
+
return fields.length > 0
|
|
82
|
+
? `${typeLine.replace('{', '').trim()} { ${fields.join('; ')}${fields.length >= 3 ? '; ...' : ''} }`
|
|
83
|
+
: typeLine;
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
return null;
|
|
87
|
+
}
|
|
88
|
+
function extractJavaModelSig(lines, name) {
|
|
89
|
+
for (let i = 0; i < lines.length; i++) {
|
|
90
|
+
if (lines[i].match(new RegExp(`(class|record|interface)\\s+${name}\\s*`))) {
|
|
91
|
+
const classLine = lines[i].trim();
|
|
92
|
+
const recordMatch = lines[i].match(/record\s+\w+\s*\(([^)]+)\)/);
|
|
93
|
+
if (recordMatch) {
|
|
94
|
+
const params = recordMatch[1].split(',').slice(0, 3).map((p) => p.trim());
|
|
95
|
+
return `record ${name}(${params.join(', ')}${params.length >= 3 ? ', ...' : ''})`;
|
|
96
|
+
}
|
|
97
|
+
const fields = [];
|
|
98
|
+
for (let j = i + 1; j < Math.min(i + 12, lines.length); j++) {
|
|
99
|
+
const m = lines[j].match(/^\s+(?:private|protected|public)\s+([\w<>\[\]]+)\s+(\w+)\s*[;=]/);
|
|
100
|
+
if (m) {
|
|
101
|
+
fields.push(`${m[2]}: ${m[1]}`);
|
|
102
|
+
if (fields.length >= 3)
|
|
103
|
+
break;
|
|
104
|
+
}
|
|
105
|
+
if (lines[j].match(/^\s*}/) || lines[j].match(/^\s*(?:public|private|protected).*\(/))
|
|
106
|
+
break;
|
|
107
|
+
}
|
|
108
|
+
return fields.length > 0
|
|
109
|
+
? `${classLine.replace('{', '').trim()} { ${fields.join(', ')}${fields.length >= 3 ? ', ...' : ''} }`
|
|
110
|
+
: classLine.replace('{', '').trim();
|
|
111
|
+
}
|
|
112
|
+
}
|
|
113
|
+
return null;
|
|
114
|
+
}
|
|
115
|
+
function extractCSModelSig(lines, name) {
|
|
116
|
+
for (let i = 0; i < lines.length; i++) {
|
|
117
|
+
if (lines[i].match(new RegExp(`(class|record|struct|interface)\\s+${name}\\s*`))) {
|
|
118
|
+
const classLine = lines[i].trim();
|
|
119
|
+
const recordMatch = lines[i].match(/record\s+\w+\s*\(([^)]+)\)/);
|
|
120
|
+
if (recordMatch) {
|
|
121
|
+
const params = recordMatch[1].split(',').slice(0, 3).map((p) => p.trim());
|
|
122
|
+
return `record ${name}(${params.join(', ')}${params.length >= 3 ? ', ...' : ''})`;
|
|
123
|
+
}
|
|
124
|
+
const fields = [];
|
|
125
|
+
for (let j = i + 1; j < Math.min(i + 12, lines.length); j++) {
|
|
126
|
+
const m = lines[j].match(/^\s+(?:public|protected|internal)\s+(?:required\s+)?([\w<>\[\]?]+)\s+(\w+)\s*{/);
|
|
127
|
+
if (m) {
|
|
128
|
+
fields.push(`${m[2]}: ${m[1]}`);
|
|
129
|
+
if (fields.length >= 3)
|
|
130
|
+
break;
|
|
131
|
+
}
|
|
132
|
+
if (lines[j].match(/^\s*}/) || lines[j].match(/^\s*(?:public|private|protected).*\(/))
|
|
133
|
+
break;
|
|
134
|
+
}
|
|
135
|
+
return fields.length > 0
|
|
136
|
+
? `${classLine.replace('{', '').trim()} { ${fields.join('; ')}${fields.length >= 3 ? '; ...' : ''} }`
|
|
137
|
+
: classLine.replace('{', '').trim();
|
|
138
|
+
}
|
|
139
|
+
}
|
|
140
|
+
return null;
|
|
141
|
+
}
|
|
142
|
+
function extractPrismaModelSig(lines, name) {
|
|
143
|
+
for (let i = 0; i < lines.length; i++) {
|
|
144
|
+
if (lines[i].match(new RegExp(`model\\s+${name}\\s*{`))) {
|
|
145
|
+
const fields = [];
|
|
146
|
+
for (let j = i + 1; j < Math.min(i + 15, lines.length); j++) {
|
|
147
|
+
const m = lines[j].match(/^\s+(\w+)\s+(String|Int|Float|Boolean|DateTime|Json|Bytes|BigInt|\w+)(\?)?(\[\])?/);
|
|
148
|
+
if (m) {
|
|
149
|
+
fields.push(`${m[1]}: ${m[2]}${m[3] || ''}${m[4] || ''}`);
|
|
150
|
+
if (fields.length >= 4)
|
|
151
|
+
break;
|
|
152
|
+
}
|
|
153
|
+
if (lines[j].trim() === '}')
|
|
154
|
+
break;
|
|
155
|
+
}
|
|
156
|
+
return fields.length > 0
|
|
157
|
+
? `model ${name} { ${fields.join(', ')}${fields.length >= 4 ? ', ...' : ''} }`
|
|
158
|
+
: `model ${name}`;
|
|
159
|
+
}
|
|
160
|
+
}
|
|
161
|
+
return null;
|
|
162
|
+
}
|
|
163
|
+
// ── extractFileSymbolsWithSignatures ─────────────────────────
|
|
164
|
+
/**
|
|
165
|
+
* Extract all exported symbols from a file with optional tree-sitter support.
|
|
166
|
+
* Falls back to regex-based extraction when grammars are not available.
|
|
167
|
+
*/
|
|
168
|
+
function extractFileSymbolsWithSignatures(filePath, allLinks, workspaceRoot, grammars, fileContentCache, extractors) {
|
|
169
|
+
const symbols = [];
|
|
170
|
+
const text = fileContentCache.get(filePath);
|
|
171
|
+
if (!text)
|
|
172
|
+
return symbols;
|
|
173
|
+
const ext = getExtension(filePath);
|
|
174
|
+
// Try tree-sitter
|
|
175
|
+
let extracted = null;
|
|
176
|
+
if (grammars && extractors) {
|
|
177
|
+
try {
|
|
178
|
+
if (ext === '.py' && grammars.python && extractors.extractPythonSymbols) {
|
|
179
|
+
extracted = extractors.extractPythonSymbols(grammars.python, text);
|
|
180
|
+
}
|
|
181
|
+
else if (ext === '.ts' && grammars.typescript && extractors.extractTSJSSymbols) {
|
|
182
|
+
extracted = extractors.extractTSJSSymbols(grammars.typescript, text);
|
|
183
|
+
}
|
|
184
|
+
else if (ext === '.tsx' && grammars.tsx && extractors.extractTSJSSymbols) {
|
|
185
|
+
extracted = extractors.extractTSJSSymbols(grammars.tsx, text);
|
|
186
|
+
}
|
|
187
|
+
else if ((ext === '.js' || ext === '.jsx') && grammars.javascript && extractors.extractTSJSSymbols) {
|
|
188
|
+
extracted = extractors.extractTSJSSymbols(grammars.javascript, text);
|
|
189
|
+
}
|
|
190
|
+
else if (ext === '.java' && grammars.java && extractors.extractJavaSymbols) {
|
|
191
|
+
extracted = extractors.extractJavaSymbols(grammars.java, text);
|
|
192
|
+
}
|
|
193
|
+
else if (ext === '.cs' && grammars.csharp && extractors.extractCSharpSymbols) {
|
|
194
|
+
extracted = extractors.extractCSharpSymbols(grammars.csharp, text);
|
|
195
|
+
}
|
|
196
|
+
}
|
|
197
|
+
catch {
|
|
198
|
+
extracted = null;
|
|
199
|
+
}
|
|
200
|
+
}
|
|
201
|
+
if (extracted && extracted.length > 0) {
|
|
202
|
+
for (const sym of extracted) {
|
|
203
|
+
if (sym.exported || ext === '.py' || ext === '.java' || ext === '.cs') {
|
|
204
|
+
symbols.push({
|
|
205
|
+
name: sym.name,
|
|
206
|
+
kind: sym.kind,
|
|
207
|
+
signature: sym.signature,
|
|
208
|
+
calledBy: (0, analyzers_1.getSymbolCallers)(sym.name, filePath, allLinks, workspaceRoot),
|
|
209
|
+
});
|
|
210
|
+
}
|
|
211
|
+
}
|
|
212
|
+
return symbols;
|
|
213
|
+
}
|
|
214
|
+
// Regex fallback
|
|
215
|
+
const lines = text.split('\n');
|
|
216
|
+
if (ext === '.py')
|
|
217
|
+
extractPySymbols(lines, filePath, allLinks, workspaceRoot, symbols);
|
|
218
|
+
else if (['.ts', '.tsx', '.js', '.jsx'].includes(ext))
|
|
219
|
+
extractTSJSSymbolsFallback(lines, filePath, allLinks, workspaceRoot, symbols);
|
|
220
|
+
else if (ext === '.java')
|
|
221
|
+
extractJavaSymbolsFallback(lines, filePath, allLinks, workspaceRoot, symbols);
|
|
222
|
+
else if (ext === '.cs')
|
|
223
|
+
extractCSSymbolsFallback(lines, filePath, allLinks, workspaceRoot, symbols);
|
|
224
|
+
return symbols;
|
|
225
|
+
}
|
|
226
|
+
function extractPySymbols(lines, filePath, allLinks, workspaceRoot, symbols) {
|
|
227
|
+
for (const line of lines) {
|
|
228
|
+
const funcMatch = line.match(/^def\s+(\w+)\s*\(([^)]*)\)/);
|
|
229
|
+
if (funcMatch && !funcMatch[1].startsWith('_')) {
|
|
230
|
+
const params = funcMatch[2].split(',').slice(0, 3).map((p) => p.trim().split(':')[0].split('=')[0].trim()).filter((p) => p && p !== 'self');
|
|
231
|
+
symbols.push({
|
|
232
|
+
name: funcMatch[1],
|
|
233
|
+
kind: 'function',
|
|
234
|
+
signature: `def ${funcMatch[1]}(${params.join(', ')})`,
|
|
235
|
+
calledBy: (0, analyzers_1.getSymbolCallers)(funcMatch[1], filePath, allLinks, workspaceRoot),
|
|
236
|
+
});
|
|
237
|
+
}
|
|
238
|
+
const classMatch = line.match(/^class\s+(\w+)(?:\(([^)]*)\))?/);
|
|
239
|
+
if (classMatch) {
|
|
240
|
+
const bases = classMatch[2] ? classMatch[2].split(',')[0].trim() : '';
|
|
241
|
+
symbols.push({
|
|
242
|
+
name: classMatch[1],
|
|
243
|
+
kind: 'class',
|
|
244
|
+
signature: bases ? `class ${classMatch[1]}(${bases})` : `class ${classMatch[1]}`,
|
|
245
|
+
calledBy: (0, analyzers_1.getSymbolCallers)(classMatch[1], filePath, allLinks, workspaceRoot),
|
|
246
|
+
});
|
|
247
|
+
}
|
|
248
|
+
}
|
|
249
|
+
}
|
|
250
|
+
function extractTSJSSymbolsFallback(lines, filePath, allLinks, workspaceRoot, symbols) {
|
|
251
|
+
for (let i = 0; i < lines.length; i++) {
|
|
252
|
+
const line = lines[i];
|
|
253
|
+
const funcMatch = line.match(/export\s+(?:async\s+)?function\s+(\w+)\s*(?:<[^>]*>)?\s*\(([^)]*)\)/);
|
|
254
|
+
if (funcMatch) {
|
|
255
|
+
const params = funcMatch[2].split(',').slice(0, 3).map((p) => p.trim().split(':')[0].split('=')[0].trim()).filter((p) => p);
|
|
256
|
+
symbols.push({ name: funcMatch[1], kind: 'function', signature: `function ${funcMatch[1]}(${params.join(', ')})`, calledBy: (0, analyzers_1.getSymbolCallers)(funcMatch[1], filePath, allLinks, workspaceRoot) });
|
|
257
|
+
continue;
|
|
258
|
+
}
|
|
259
|
+
const classMatch = line.match(/export\s+(?:abstract\s+)?class\s+(\w+)(?:\s+extends\s+(\w+))?/);
|
|
260
|
+
if (classMatch) {
|
|
261
|
+
const ext = classMatch[2] ? ` extends ${classMatch[2]}` : '';
|
|
262
|
+
symbols.push({ name: classMatch[1], kind: 'class', signature: `class ${classMatch[1]}${ext}`, calledBy: (0, analyzers_1.getSymbolCallers)(classMatch[1], filePath, allLinks, workspaceRoot) });
|
|
263
|
+
continue;
|
|
264
|
+
}
|
|
265
|
+
const ifMatch = line.match(/export\s+interface\s+(\w+)/);
|
|
266
|
+
if (ifMatch) {
|
|
267
|
+
symbols.push({ name: ifMatch[1], kind: 'interface', signature: `interface ${ifMatch[1]}`, calledBy: (0, analyzers_1.getSymbolCallers)(ifMatch[1], filePath, allLinks, workspaceRoot) });
|
|
268
|
+
continue;
|
|
269
|
+
}
|
|
270
|
+
const typeMatch = line.match(/export\s+type\s+(\w+)\s*=/);
|
|
271
|
+
if (typeMatch) {
|
|
272
|
+
symbols.push({ name: typeMatch[1], kind: 'type', signature: `type ${typeMatch[1]}`, calledBy: (0, analyzers_1.getSymbolCallers)(typeMatch[1], filePath, allLinks, workspaceRoot) });
|
|
273
|
+
continue;
|
|
274
|
+
}
|
|
275
|
+
const arrowFnMatch = line.match(/export\s+const\s+(\w+)\s*=\s*(?:async\s+)?\(([^)]*)\)\s*(?::\s*\S+)?\s*=>/);
|
|
276
|
+
if (arrowFnMatch) {
|
|
277
|
+
const params = arrowFnMatch[2].split(',').slice(0, 3).map((p) => p.trim().split(':')[0].split('=')[0].trim()).filter((p) => p);
|
|
278
|
+
symbols.push({ name: arrowFnMatch[1], kind: 'const', signature: `const ${arrowFnMatch[1]} = (${params.join(', ')}) =>`, calledBy: (0, analyzers_1.getSymbolCallers)(arrowFnMatch[1], filePath, allLinks, workspaceRoot) });
|
|
279
|
+
continue;
|
|
280
|
+
}
|
|
281
|
+
const arrowSingle = line.match(/export\s+const\s+(\w+)\s*=\s*(?:async\s+)?(\w+)\s*=>/);
|
|
282
|
+
if (arrowSingle) {
|
|
283
|
+
symbols.push({ name: arrowSingle[1], kind: 'const', signature: `const ${arrowSingle[1]} = (${arrowSingle[2]}) =>`, calledBy: (0, analyzers_1.getSymbolCallers)(arrowSingle[1], filePath, allLinks, workspaceRoot) });
|
|
284
|
+
continue;
|
|
285
|
+
}
|
|
286
|
+
const constMatch = line.match(/export\s+const\s+(\w+)\s*[:=]/);
|
|
287
|
+
if (constMatch) {
|
|
288
|
+
let sig = null;
|
|
289
|
+
if (i + 1 < lines.length) {
|
|
290
|
+
const nextArrow = lines[i + 1].match(/^\s*(?:async\s+)?\(([^)]*)\)\s*(?::\s*\S+)?\s*=>/);
|
|
291
|
+
if (nextArrow) {
|
|
292
|
+
const params = nextArrow[1].split(',').slice(0, 3).map((p) => p.trim().split(':')[0].split('=')[0].trim()).filter((p) => p);
|
|
293
|
+
sig = `const ${constMatch[1]} = (${params.join(', ')}) =>`;
|
|
294
|
+
}
|
|
295
|
+
}
|
|
296
|
+
symbols.push({ name: constMatch[1], kind: 'const', signature: sig, calledBy: (0, analyzers_1.getSymbolCallers)(constMatch[1], filePath, allLinks, workspaceRoot) });
|
|
297
|
+
}
|
|
298
|
+
}
|
|
299
|
+
}
|
|
300
|
+
function extractJavaSymbolsFallback(lines, filePath, allLinks, workspaceRoot, symbols) {
|
|
301
|
+
for (const line of lines) {
|
|
302
|
+
const methodMatch = line.match(/^\s*(?:public|protected)\s+(?:static\s+)?(?:async\s+)?([\w<>\[\],\s]+)\s+(\w+)\s*\(([^)]*)\)/);
|
|
303
|
+
if (methodMatch && !methodMatch[2].startsWith('_')) {
|
|
304
|
+
const retType = methodMatch[1].trim();
|
|
305
|
+
const params = methodMatch[3].split(',').slice(0, 3).map((p) => p.trim().split(/\s+/).pop() || '').filter((p) => p);
|
|
306
|
+
symbols.push({ name: methodMatch[2], kind: 'method', signature: `${retType} ${methodMatch[2]}(${params.join(', ')})`, calledBy: (0, analyzers_1.getSymbolCallers)(methodMatch[2], filePath, allLinks, workspaceRoot) });
|
|
307
|
+
}
|
|
308
|
+
const classMatch = line.match(/^\s*(?:public|protected)?\s*(?:abstract\s+)?(?:class|interface|record)\s+(\w+)(?:\s+extends\s+(\w+))?(?:\s+implements\s+([\w,\s]+))?/);
|
|
309
|
+
if (classMatch) {
|
|
310
|
+
const ext = classMatch[2] ? ` extends ${classMatch[2]}` : '';
|
|
311
|
+
const impl = classMatch[3] ? ` implements ${classMatch[3].split(',')[0].trim()}` : '';
|
|
312
|
+
const kind = line.includes('interface') ? 'interface' : line.includes('record') ? 'record' : 'class';
|
|
313
|
+
symbols.push({ name: classMatch[1], kind, signature: `class ${classMatch[1]}${ext}${impl}`, calledBy: (0, analyzers_1.getSymbolCallers)(classMatch[1], filePath, allLinks, workspaceRoot) });
|
|
314
|
+
}
|
|
315
|
+
}
|
|
316
|
+
}
|
|
317
|
+
function extractCSSymbolsFallback(lines, filePath, allLinks, workspaceRoot, symbols) {
|
|
318
|
+
for (const line of lines) {
|
|
319
|
+
const methodMatch = line.match(/^\s*(?:public|protected|internal)\s+(?:static\s+)?(?:async\s+)?(?:virtual\s+)?(?:override\s+)?([\w<>\[\],\s?]+)\s+(\w+)\s*\(([^)]*)\)/);
|
|
320
|
+
if (methodMatch && !methodMatch[2].startsWith('_')) {
|
|
321
|
+
const retType = methodMatch[1].trim();
|
|
322
|
+
const params = methodMatch[3].split(',').slice(0, 3).map((p) => p.trim().split(/\s+/).pop() || '').filter((p) => p);
|
|
323
|
+
symbols.push({ name: methodMatch[2], kind: 'method', signature: `${retType} ${methodMatch[2]}(${params.join(', ')})`, calledBy: (0, analyzers_1.getSymbolCallers)(methodMatch[2], filePath, allLinks, workspaceRoot) });
|
|
324
|
+
}
|
|
325
|
+
const classMatch = line.match(/^\s*(?:public|protected|internal)?\s*(?:abstract\s+)?(?:partial\s+)?(?:class|interface|record|struct)\s+(\w+)(?:\s*:\s*([\w,\s]+))?/);
|
|
326
|
+
if (classMatch) {
|
|
327
|
+
const baseClause = classMatch[2] ? ` : ${classMatch[2].split(',')[0].trim()}` : '';
|
|
328
|
+
const kind = line.includes('interface') ? 'interface' : line.includes('record') ? 'record' : line.includes('struct') ? 'struct' : 'class';
|
|
329
|
+
symbols.push({ name: classMatch[1], kind, signature: `${kind} ${classMatch[1]}${baseClause}`, calledBy: (0, analyzers_1.getSymbolCallers)(classMatch[1], filePath, allLinks, workspaceRoot) });
|
|
330
|
+
}
|
|
331
|
+
const propMatch = line.match(/^\s*(?:public|protected|internal)\s+(?:static\s+)?(?:virtual\s+)?(?:override\s+)?([\w<>\[\],\s?]+)\s+(\w+)\s*{\s*get/);
|
|
332
|
+
if (propMatch) {
|
|
333
|
+
symbols.push({ name: propMatch[2], kind: 'property', signature: `${propMatch[1].trim()} ${propMatch[2]}`, calledBy: (0, analyzers_1.getSymbolCallers)(propMatch[2], filePath, allLinks, workspaceRoot) });
|
|
334
|
+
}
|
|
335
|
+
}
|
|
336
|
+
}
|
|
337
|
+
// ── Internal ─────────────────────────────────────────────────
|
|
338
|
+
function getExtension(filePath) {
|
|
339
|
+
const p = (0, core_1.toPosix)(filePath);
|
|
340
|
+
const lastDot = p.lastIndexOf('.');
|
|
341
|
+
return lastDot >= 0 ? p.substring(lastDot).toLowerCase() : '';
|
|
342
|
+
}
|
|
343
|
+
//# sourceMappingURL=symbols.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"symbols.js","sourceRoot":"","sources":["../../src/kb/symbols.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;GAUG;;AAgCH,sDA4BC;AA2GD,4EA4DC;AAjOD,2CAA4E;AAC5E,2CAA+C;AAuB/C,gEAAgE;AAEhE;;;GAGG;AACH,SAAgB,qBAAqB,CACnC,QAAgB,EAChB,SAAiB,EACjB,gBAAqC;IAErC,MAAM,IAAI,GAAG,gBAAgB,CAAC,GAAG,CAAC,QAAQ,CAAC,CAAC;IAC5C,IAAI,CAAC,IAAI;QAAE,OAAO,IAAI,CAAC;IACvB,MAAM,KAAK,GAAG,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC;IAC/B,MAAM,GAAG,GAAG,YAAY,CAAC,QAAQ,CAAC,CAAC;IAEnC,IAAI,SAAS,GAAG,SAAS,CAAC;IAC1B,SAAS,GAAG,SAAS,CAAC,OAAO,CAC3B,sFAAsF,EACtF,EAAE,CACH,CAAC;IACF,SAAS,GAAG,SAAS,CAAC,OAAO,CAAC,4BAA4B,EAAE,EAAE,CAAC,CAAC;IAChE,SAAS,GAAG,SAAS,CAAC,OAAO,CAAC,6CAA6C,EAAE,EAAE,CAAC,CAAC;IACjF,SAAS,GAAG,SAAS,CAAC,KAAK,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,IAAI,EAAE,CAAC;IAEhD,IAAI,CAAC,SAAS,IAAI,SAAS,CAAC,MAAM,GAAG,CAAC,IAAI,CAAC,YAAY,CAAC,IAAI,CAAC,SAAS,CAAC;QAAE,OAAO,IAAI,CAAC;IAErF,IAAI,GAAG,KAAK,KAAK;QAAE,OAAO,iBAAiB,CAAC,KAAK,E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AW,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;AAChE,CAAC"}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Manifest builder — builds manifest metadata for embedding in kb.md.
|
|
3
|
+
*
|
|
4
|
+
* The manifest provides a machine-readable summary alongside the
|
|
5
|
+
* human-readable KB content. The KB emitter embeds the manifest as
|
|
6
|
+
* an HTML comment at the bottom of kb.md.
|
|
7
|
+
*
|
|
8
|
+
* Determinism: keys are sorted explicitly; `generatedAt` is the only
|
|
9
|
+
* volatile field and is injected via options.
|
|
10
|
+
*/
|
|
11
|
+
import type { AnalysisModel } from '@aspectcode/core';
|
|
12
|
+
export interface Manifest {
|
|
13
|
+
schemaVersion: string;
|
|
14
|
+
generatorVersion: string;
|
|
15
|
+
generatedAt: string;
|
|
16
|
+
stats: ManifestStats;
|
|
17
|
+
}
|
|
18
|
+
export interface ManifestStats {
|
|
19
|
+
fileCount: number;
|
|
20
|
+
totalLines: number;
|
|
21
|
+
languageCounts: Record<string, number>;
|
|
22
|
+
edgeCount: number;
|
|
23
|
+
circularCount: number;
|
|
24
|
+
topHubs: Array<{
|
|
25
|
+
file: string;
|
|
26
|
+
inDegree: number;
|
|
27
|
+
outDegree: number;
|
|
28
|
+
}>;
|
|
29
|
+
}
|
|
30
|
+
/**
|
|
31
|
+
* Build a Manifest object from an AnalysisModel.
|
|
32
|
+
*
|
|
33
|
+
* Pure function — no I/O. Used by the KB emitter to embed
|
|
34
|
+
* manifest data as an HTML comment in kb.md.
|
|
35
|
+
*/
|
|
36
|
+
export declare function buildManifest(model: AnalysisModel, generatedAt: string, topN?: number): Manifest;
|
|
37
|
+
//# sourceMappingURL=manifest.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"manifest.d.ts","sourceRoot":"","sources":["../src/manifest.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAEH,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AAKtD,MAAM,WAAW,QAAQ;IACvB,aAAa,EAAE,MAAM,CAAC;IACtB,gBAAgB,EAAE,MAAM,CAAC;IACzB,WAAW,EAAE,MAAM,CAAC;IACpB,KAAK,EAAE,aAAa,CAAC;CACtB;AAED,MAAM,WAAW,aAAa;IAC5B,SAAS,EAAE,MAAM,CAAC;IAClB,UAAU,EAAE,MAAM,CAAC;IACnB,cAAc,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IACvC,SAAS,EAAE,MAAM,CAAC;IAClB,aAAa,EAAE,MAAM,CAAC;IACtB,OAAO,EAAE,KAAK,CAAC;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,QAAQ,EAAE,MAAM,CAAC;QAAC,SAAS,EAAE,MAAM,CAAA;KAAE,CAAC,CAAC;CACvE;AASD;;;;;GAKG;AACH,wBAAgB,aAAa,CAC3B,KAAK,EAAE,aAAa,EACpB,WAAW,EAAE,MAAM,EACnB,IAAI,SAAK,GACR,QAAQ,CA0BV"}
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Manifest builder — builds manifest metadata for embedding in kb.md.
|
|
4
|
+
*
|
|
5
|
+
* The manifest provides a machine-readable summary alongside the
|
|
6
|
+
* human-readable KB content. The KB emitter embeds the manifest as
|
|
7
|
+
* an HTML comment at the bottom of kb.md.
|
|
8
|
+
*
|
|
9
|
+
* Determinism: keys are sorted explicitly; `generatedAt` is the only
|
|
10
|
+
* volatile field and is injected via options.
|
|
11
|
+
*/
|
|
12
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
+
exports.buildManifest = buildManifest;
|
|
14
|
+
const core_1 = require("@aspectcode/core");
|
|
15
|
+
// ── Constants ────────────────────────────────────────────────
|
|
16
|
+
/** Package version — updated at release time. */
|
|
17
|
+
const GENERATOR_VERSION = '0.0.1';
|
|
18
|
+
// ── Public API ───────────────────────────────────────────────
|
|
19
|
+
/**
|
|
20
|
+
* Build a Manifest object from an AnalysisModel.
|
|
21
|
+
*
|
|
22
|
+
* Pure function — no I/O. Used by the KB emitter to embed
|
|
23
|
+
* manifest data as an HTML comment in kb.md.
|
|
24
|
+
*/
|
|
25
|
+
function buildManifest(model, generatedAt, topN = 10) {
|
|
26
|
+
const stats = (0, core_1.computeModelStats)(model, topN);
|
|
27
|
+
// Sort language keys for determinism
|
|
28
|
+
const sortedLanguageCounts = {};
|
|
29
|
+
for (const key of Object.keys(stats.languageCounts).sort()) {
|
|
30
|
+
sortedLanguageCounts[key] = stats.languageCounts[key];
|
|
31
|
+
}
|
|
32
|
+
return {
|
|
33
|
+
schemaVersion: model.schemaVersion,
|
|
34
|
+
generatorVersion: GENERATOR_VERSION,
|
|
35
|
+
generatedAt,
|
|
36
|
+
stats: {
|
|
37
|
+
fileCount: stats.fileCount,
|
|
38
|
+
totalLines: stats.totalLines,
|
|
39
|
+
languageCounts: sortedLanguageCounts,
|
|
40
|
+
edgeCount: stats.edgeCount,
|
|
41
|
+
circularCount: stats.circularCount,
|
|
42
|
+
topHubs: stats.topHubs.map((h) => ({
|
|
43
|
+
file: h.file,
|
|
44
|
+
inDegree: h.inDegree,
|
|
45
|
+
outDegree: h.outDegree,
|
|
46
|
+
})),
|
|
47
|
+
},
|
|
48
|
+
};
|
|
49
|
+
}
|
|
50
|
+
//# sourceMappingURL=manifest.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"manifest.js","sourceRoot":"","sources":["../src/manifest.ts"],"names":[],"mappings":";AAAA;;;;;;;;;GASG;;AAoCH,sCA8BC;AA/DD,2CAAqD;AAoBrD,gEAAgE;AAEhE,iDAAiD;AACjD,MAAM,iBAAiB,GAAG,OAAO,CAAC;AAElC,gEAAgE;AAEhE;;;;;GAKG;AACH,SAAgB,aAAa,CAC3B,KAAoB,EACpB,WAAmB,EACnB,IAAI,GAAG,EAAE;IAET,MAAM,KAAK,GAAG,IAAA,wBAAiB,EAAC,KAAK,EAAE,IAAI,CAAC,CAAC;IAE7C,qCAAqC;IACrC,MAAM,oBAAoB,GAA2B,EAAE,CAAC;IACxD,KAAK,MAAM,GAAG,IAAI,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC,cAAc,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC;QAC3D,oBAAoB,CAAC,GAAG,CAAC,GAAG,KAAK,CAAC,cAAc,CAAC,GAAG,CAAC,CAAC;IACxD,CAAC;IAED,OAAO;QACL,aAAa,EAAE,KAAK,CAAC,aAAa;QAClC,gBAAgB,EAAE,iBAAiB;QACnC,WAAW;QACX,KAAK,EAAE;YACL,SAAS,EAAE,KAAK,CAAC,SAAS;YAC1B,UAAU,EAAE,KAAK,CAAC,UAAU;YAC5B,cAAc,EAAE,oBAAoB;YACpC,SAAS,EAAE,KAAK,CAAC,SAAS;YAC1B,aAAa,EAAE,KAAK,CAAC,aAAa;YAClC,OAAO,EAAE,KAAK,CAAC,OAAO,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC;gBACjC,IAAI,EAAE,CAAC,CAAC,IAAI;gBACZ,QAAQ,EAAE,CAAC,CAAC,QAAQ;gBACpB,SAAS,EAAE,CAAC,CAAC,SAAS;aACvB,CAAC,CAAC;SACJ;KACF,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import type { ModelStats } from '@aspectcode/core';
|
|
2
|
+
/**
|
|
3
|
+
* Minimal structured report returned by `runEmitters()`.
|
|
4
|
+
* Intended to be serializable for a future `--json` CLI.
|
|
5
|
+
*/
|
|
6
|
+
export type EmitReport = {
|
|
7
|
+
schemaVersion: string;
|
|
8
|
+
wrote: Array<{
|
|
9
|
+
path: string;
|
|
10
|
+
bytes: number;
|
|
11
|
+
}>;
|
|
12
|
+
skipped?: Array<{
|
|
13
|
+
id: string;
|
|
14
|
+
reason: string;
|
|
15
|
+
}>;
|
|
16
|
+
stats: {
|
|
17
|
+
files: number;
|
|
18
|
+
edges: number;
|
|
19
|
+
hubsTop: ModelStats['topHubs'];
|
|
20
|
+
};
|
|
21
|
+
};
|
|
22
|
+
//# sourceMappingURL=report.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"report.d.ts","sourceRoot":"","sources":["../src/report.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAEnD;;;GAGG;AACH,MAAM,MAAM,UAAU,GAAG;IACvB,aAAa,EAAE,MAAM,CAAC;IACtB,KAAK,EAAE,KAAK,CAAC;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,MAAM,CAAA;KAAE,CAAC,CAAC;IAC9C,OAAO,CAAC,EAAE,KAAK,CAAC;QAAE,EAAE,EAAE,MAAM,CAAC;QAAC,MAAM,EAAE,MAAM,CAAA;KAAE,CAAC,CAAC;IAChD,KAAK,EAAE;QACL,KAAK,EAAE,MAAM,CAAC;QACd,KAAK,EAAE,MAAM,CAAC;QACd,OAAO,EAAE,UAAU,CAAC,SAAS,CAAC,CAAC;KAChC,CAAC;CACH,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"report.js","sourceRoot":"","sources":["../src/report.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Stable JSON stringification.
|
|
3
|
+
*
|
|
4
|
+
* Ensures deterministic key ordering for objects (recursively) without
|
|
5
|
+
* adding any external dependency.
|
|
6
|
+
*/
|
|
7
|
+
/**
|
|
8
|
+
* Stable JSON stringify with sorted keys.
|
|
9
|
+
*
|
|
10
|
+
* @param value Any JSON-serializable value
|
|
11
|
+
* @param space Indentation (defaults to 2, matching existing outputs)
|
|
12
|
+
*/
|
|
13
|
+
export declare function stableStringify(value: unknown, space?: number): string;
|
|
14
|
+
//# sourceMappingURL=stableJson.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"stableJson.d.ts","sourceRoot":"","sources":["../src/stableJson.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAyBH;;;;;GAKG;AACH,wBAAgB,eAAe,CAAC,KAAK,EAAE,OAAO,EAAE,KAAK,GAAE,MAAU,GAAG,MAAM,CAEzE"}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Stable JSON stringification.
|
|
4
|
+
*
|
|
5
|
+
* Ensures deterministic key ordering for objects (recursively) without
|
|
6
|
+
* adding any external dependency.
|
|
7
|
+
*/
|
|
8
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
9
|
+
exports.stableStringify = stableStringify;
|
|
10
|
+
function isPlainObject(value) {
|
|
11
|
+
if (value === null)
|
|
12
|
+
return false;
|
|
13
|
+
if (typeof value !== 'object')
|
|
14
|
+
return false;
|
|
15
|
+
const proto = Object.getPrototypeOf(value);
|
|
16
|
+
return proto === Object.prototype || proto === null;
|
|
17
|
+
}
|
|
18
|
+
function sortKeysDeep(value) {
|
|
19
|
+
if (Array.isArray(value)) {
|
|
20
|
+
return value.map(sortKeysDeep);
|
|
21
|
+
}
|
|
22
|
+
if (isPlainObject(value)) {
|
|
23
|
+
const out = {};
|
|
24
|
+
for (const key of Object.keys(value).sort()) {
|
|
25
|
+
out[key] = sortKeysDeep(value[key]);
|
|
26
|
+
}
|
|
27
|
+
return out;
|
|
28
|
+
}
|
|
29
|
+
return value;
|
|
30
|
+
}
|
|
31
|
+
/**
|
|
32
|
+
* Stable JSON stringify with sorted keys.
|
|
33
|
+
*
|
|
34
|
+
* @param value Any JSON-serializable value
|
|
35
|
+
* @param space Indentation (defaults to 2, matching existing outputs)
|
|
36
|
+
*/
|
|
37
|
+
function stableStringify(value, space = 2) {
|
|
38
|
+
return JSON.stringify(sortKeysDeep(value), null, space);
|
|
39
|
+
}
|
|
40
|
+
//# sourceMappingURL=stableJson.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"stableJson.js","sourceRoot":"","sources":["../src/stableJson.ts"],"names":[],"mappings":";AAAA;;;;;GAKG;;AA+BH,0CAEC;AA/BD,SAAS,aAAa,CAAC,KAAc;IACnC,IAAI,KAAK,KAAK,IAAI;QAAE,OAAO,KAAK,CAAC;IACjC,IAAI,OAAO,KAAK,KAAK,QAAQ;QAAE,OAAO,KAAK,CAAC;IAC5C,MAAM,KAAK,GAAG,MAAM,CAAC,cAAc,CAAC,KAAK,CAAC,CAAC;IAC3C,OAAO,KAAK,KAAK,MAAM,CAAC,SAAS,IAAI,KAAK,KAAK,IAAI,CAAC;AACtD,CAAC;AAED,SAAS,YAAY,CAAC,KAAc;IAClC,IAAI,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,EAAE,CAAC;QACzB,OAAO,KAAK,CAAC,GAAG,CAAC,YAAY,CAAC,CAAC;IACjC,CAAC;IAED,IAAI,aAAa,CAAC,KAAK,CAAC,EAAE,CAAC;QACzB,MAAM,GAAG,GAA4B,EAAE,CAAC;QACxC,KAAK,MAAM,GAAG,IAAI,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC;YAC5C,GAAG,CAAC,GAAG,CAAC,GAAG,YAAY,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC;QACtC,CAAC;QACD,OAAO,GAAG,CAAC;IACb,CAAC;IAED,OAAO,KAAK,CAAC;AACf,CAAC;AAED;;;;;GAKG;AACH,SAAgB,eAAe,CAAC,KAAc,EAAE,QAAgB,CAAC;IAC/D,OAAO,IAAI,CAAC,SAAS,CAAC,YAAY,CAAC,KAAK,CAAC,EAAE,IAAI,EAAE,KAAK,CAAC,CAAC;AAC1D,CAAC"}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import type { EmitterHost } from './host';
|
|
2
|
+
export type TransactionWrite = {
|
|
3
|
+
finalPath: string;
|
|
4
|
+
tempPath: string;
|
|
5
|
+
bytes: number;
|
|
6
|
+
};
|
|
7
|
+
/**
|
|
8
|
+
* Transaction wrapper around an EmitterHost.
|
|
9
|
+
*
|
|
10
|
+
* It stages writes to temp files and only replaces target files on commit.
|
|
11
|
+
* This reduces the chance of partially-written outputs on crashes.
|
|
12
|
+
*/
|
|
13
|
+
export declare class GenerationTransaction {
|
|
14
|
+
private readonly baseHost;
|
|
15
|
+
private readonly id;
|
|
16
|
+
private readonly staged;
|
|
17
|
+
constructor(baseHost: EmitterHost);
|
|
18
|
+
/** Host view used by emitters to stage writes. */
|
|
19
|
+
get host(): EmitterHost;
|
|
20
|
+
/** All staged writes (final paths + bytes). */
|
|
21
|
+
getWrites(): TransactionWrite[];
|
|
22
|
+
/**
|
|
23
|
+
* Commit staged files into place.
|
|
24
|
+
*
|
|
25
|
+
* Writes are committed in deterministic (sorted) order.
|
|
26
|
+
*/
|
|
27
|
+
commit(): Promise<void>;
|
|
28
|
+
}
|
|
29
|
+
//# sourceMappingURL=transaction.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"transaction.d.ts","sourceRoot":"","sources":["../src/transaction.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,QAAQ,CAAC;AAE1C,MAAM,MAAM,gBAAgB,GAAG;IAC7B,SAAS,EAAE,MAAM,CAAC;IAClB,QAAQ,EAAE,MAAM,CAAC;IACjB,KAAK,EAAE,MAAM,CAAC;CACf,CAAC;AAEF;;;;;GAKG;AACH,qBAAa,qBAAqB;IAIpB,OAAO,CAAC,QAAQ,CAAC,QAAQ;IAHrC,OAAO,CAAC,QAAQ,CAAC,EAAE,CAAS;IAC5B,OAAO,CAAC,QAAQ,CAAC,MAAM,CAAuC;gBAEjC,QAAQ,EAAE,WAAW;IAIlD,kDAAkD;IAClD,IAAI,IAAI,IAAI,WAAW,CAuBtB;IAED,+CAA+C;IAC/C,SAAS,IAAI,gBAAgB,EAAE;IAI/B;;;;OAIG;IACG,MAAM,IAAI,OAAO,CAAC,IAAI,CAAC;CAwD9B"}
|