spectra-cli 4.1.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/LICENSE +21 -0
- package/README.md +350 -0
- package/dist/adapters/go-adapter.d.ts +38 -0
- package/dist/adapters/go-adapter.d.ts.map +1 -0
- package/dist/adapters/go-adapter.js +58 -0
- package/dist/adapters/go-adapter.js.map +1 -0
- package/dist/adapters/index.d.ts +21 -0
- package/dist/adapters/index.d.ts.map +1 -0
- package/dist/adapters/index.js +36 -0
- package/dist/adapters/index.js.map +1 -0
- package/dist/adapters/java-adapter.d.ts +39 -0
- package/dist/adapters/java-adapter.d.ts.map +1 -0
- package/dist/adapters/java-adapter.js +65 -0
- package/dist/adapters/java-adapter.js.map +1 -0
- package/dist/adapters/language-adapter-registry.d.ts +56 -0
- package/dist/adapters/language-adapter-registry.d.ts.map +1 -0
- package/dist/adapters/language-adapter-registry.js +110 -0
- package/dist/adapters/language-adapter-registry.js.map +1 -0
- package/dist/adapters/language-adapter.d.ts +127 -0
- package/dist/adapters/language-adapter.d.ts.map +1 -0
- package/dist/adapters/language-adapter.js +2 -0
- package/dist/adapters/language-adapter.js.map +1 -0
- package/dist/adapters/python-adapter.d.ts +61 -0
- package/dist/adapters/python-adapter.d.ts.map +1 -0
- package/dist/adapters/python-adapter.js +260 -0
- package/dist/adapters/python-adapter.js.map +1 -0
- package/dist/adapters/tree-sitter-comment-extractor.d.ts +15 -0
- package/dist/adapters/tree-sitter-comment-extractor.d.ts.map +1 -0
- package/dist/adapters/tree-sitter-comment-extractor.js +105 -0
- package/dist/adapters/tree-sitter-comment-extractor.js.map +1 -0
- package/dist/adapters/ts-js-adapter.d.ts +38 -0
- package/dist/adapters/ts-js-adapter.d.ts.map +1 -0
- package/dist/adapters/ts-js-adapter.js +164 -0
- package/dist/adapters/ts-js-adapter.js.map +1 -0
- package/dist/auth/auth-detector.d.ts +41 -0
- package/dist/auth/auth-detector.d.ts.map +1 -0
- package/dist/auth/auth-detector.js +324 -0
- package/dist/auth/auth-detector.js.map +1 -0
- package/dist/auth/cli-proxy.d.ts +35 -0
- package/dist/auth/cli-proxy.d.ts.map +1 -0
- package/dist/auth/cli-proxy.js +225 -0
- package/dist/auth/cli-proxy.js.map +1 -0
- package/dist/auth/codex-proxy.d.ts +22 -0
- package/dist/auth/codex-proxy.d.ts.map +1 -0
- package/dist/auth/codex-proxy.js +199 -0
- package/dist/auth/codex-proxy.js.map +1 -0
- package/dist/batch/batch-orchestrator.d.ts +214 -0
- package/dist/batch/batch-orchestrator.d.ts.map +1 -0
- package/dist/batch/batch-orchestrator.js +1552 -0
- package/dist/batch/batch-orchestrator.js.map +1 -0
- package/dist/batch/batch-readme-generator.d.ts +32 -0
- package/dist/batch/batch-readme-generator.d.ts.map +1 -0
- package/dist/batch/batch-readme-generator.js +153 -0
- package/dist/batch/batch-readme-generator.js.map +1 -0
- package/dist/batch/budget-gate.d.ts +107 -0
- package/dist/batch/budget-gate.d.ts.map +1 -0
- package/dist/batch/budget-gate.js +279 -0
- package/dist/batch/budget-gate.js.map +1 -0
- package/dist/batch/checkpoint.d.ts +25 -0
- package/dist/batch/checkpoint.d.ts.map +1 -0
- package/dist/batch/checkpoint.js +68 -0
- package/dist/batch/checkpoint.js.map +1 -0
- package/dist/batch/cost-summary.d.ts +78 -0
- package/dist/batch/cost-summary.d.ts.map +1 -0
- package/dist/batch/cost-summary.js +191 -0
- package/dist/batch/cost-summary.js.map +1 -0
- package/dist/batch/delta-regenerator.d.ts +41 -0
- package/dist/batch/delta-regenerator.d.ts.map +1 -0
- package/dist/batch/delta-regenerator.js +267 -0
- package/dist/batch/delta-regenerator.js.map +1 -0
- package/dist/batch/directory-classifier.d.ts +79 -0
- package/dist/batch/directory-classifier.d.ts.map +1 -0
- package/dist/batch/directory-classifier.js +270 -0
- package/dist/batch/directory-classifier.js.map +1 -0
- package/dist/batch/language-grouper.d.ts +28 -0
- package/dist/batch/language-grouper.d.ts.map +1 -0
- package/dist/batch/language-grouper.js +67 -0
- package/dist/batch/language-grouper.js.map +1 -0
- package/dist/batch/model-override-decision.d.ts +27 -0
- package/dist/batch/model-override-decision.d.ts.map +1 -0
- package/dist/batch/model-override-decision.js +14 -0
- package/dist/batch/model-override-decision.js.map +1 -0
- package/dist/batch/module-grouper.d.ts +59 -0
- package/dist/batch/module-grouper.d.ts.map +1 -0
- package/dist/batch/module-grouper.js +286 -0
- package/dist/batch/module-grouper.js.map +1 -0
- package/dist/batch/progress-reporter.d.ts +68 -0
- package/dist/batch/progress-reporter.d.ts.map +1 -0
- package/dist/batch/progress-reporter.js +273 -0
- package/dist/batch/progress-reporter.js.map +1 -0
- package/dist/batch/readme-graph-section.d.ts +53 -0
- package/dist/batch/readme-graph-section.d.ts.map +1 -0
- package/dist/batch/readme-graph-section.js +183 -0
- package/dist/batch/readme-graph-section.js.map +1 -0
- package/dist/cli/commands/auth-status.d.ts +10 -0
- package/dist/cli/commands/auth-status.d.ts.map +1 -0
- package/dist/cli/commands/auth-status.js +50 -0
- package/dist/cli/commands/auth-status.js.map +1 -0
- package/dist/cli/commands/batch.d.ts +10 -0
- package/dist/cli/commands/batch.d.ts.map +1 -0
- package/dist/cli/commands/batch.js +133 -0
- package/dist/cli/commands/batch.js.map +1 -0
- package/dist/cli/commands/cache.d.ts +13 -0
- package/dist/cli/commands/cache.d.ts.map +1 -0
- package/dist/cli/commands/cache.js +65 -0
- package/dist/cli/commands/cache.js.map +1 -0
- package/dist/cli/commands/community.d.ts +10 -0
- package/dist/cli/commands/community.d.ts.map +1 -0
- package/dist/cli/commands/community.js +92 -0
- package/dist/cli/commands/community.js.map +1 -0
- package/dist/cli/commands/diff.d.ts +10 -0
- package/dist/cli/commands/diff.d.ts.map +1 -0
- package/dist/cli/commands/diff.js +49 -0
- package/dist/cli/commands/diff.js.map +1 -0
- package/dist/cli/commands/direction-audit.d.ts +12 -0
- package/dist/cli/commands/direction-audit.d.ts.map +1 -0
- package/dist/cli/commands/direction-audit.js +458 -0
- package/dist/cli/commands/direction-audit.js.map +1 -0
- package/dist/cli/commands/export.d.ts +22 -0
- package/dist/cli/commands/export.d.ts.map +1 -0
- package/dist/cli/commands/export.js +123 -0
- package/dist/cli/commands/export.js.map +1 -0
- package/dist/cli/commands/generate.d.ts +10 -0
- package/dist/cli/commands/generate.d.ts.map +1 -0
- package/dist/cli/commands/generate.js +50 -0
- package/dist/cli/commands/generate.js.map +1 -0
- package/dist/cli/commands/graph.d.ts +20 -0
- package/dist/cli/commands/graph.d.ts.map +1 -0
- package/dist/cli/commands/graph.js +189 -0
- package/dist/cli/commands/graph.js.map +1 -0
- package/dist/cli/commands/init.d.ts +10 -0
- package/dist/cli/commands/init.d.ts.map +1 -0
- package/dist/cli/commands/init.js +33 -0
- package/dist/cli/commands/init.js.map +1 -0
- package/dist/cli/commands/install.d.ts +11 -0
- package/dist/cli/commands/install.d.ts.map +1 -0
- package/dist/cli/commands/install.js +52 -0
- package/dist/cli/commands/install.js.map +1 -0
- package/dist/cli/commands/mcp-server.d.ts +23 -0
- package/dist/cli/commands/mcp-server.d.ts.map +1 -0
- package/dist/cli/commands/mcp-server.js +90 -0
- package/dist/cli/commands/mcp-server.js.map +1 -0
- package/dist/cli/commands/panoramic.d.ts +7 -0
- package/dist/cli/commands/panoramic.d.ts.map +1 -0
- package/dist/cli/commands/panoramic.js +43 -0
- package/dist/cli/commands/panoramic.js.map +1 -0
- package/dist/cli/commands/prepare.d.ts +13 -0
- package/dist/cli/commands/prepare.d.ts.map +1 -0
- package/dist/cli/commands/prepare.js +148 -0
- package/dist/cli/commands/prepare.js.map +1 -0
- package/dist/cli/commands/query.d.ts +13 -0
- package/dist/cli/commands/query.d.ts.map +1 -0
- package/dist/cli/commands/query.js +116 -0
- package/dist/cli/commands/query.js.map +1 -0
- package/dist/cli/commands/watch.d.ts +16 -0
- package/dist/cli/commands/watch.d.ts.map +1 -0
- package/dist/cli/commands/watch.js +188 -0
- package/dist/cli/commands/watch.js.map +1 -0
- package/dist/cli/index.d.ts +7 -0
- package/dist/cli/index.d.ts.map +1 -0
- package/dist/cli/index.js +193 -0
- package/dist/cli/index.js.map +1 -0
- package/dist/cli/utils/error-handler.d.ts +41 -0
- package/dist/cli/utils/error-handler.d.ts.map +1 -0
- package/dist/cli/utils/error-handler.js +90 -0
- package/dist/cli/utils/error-handler.js.map +1 -0
- package/dist/cli/utils/parse-args.d.ts +111 -0
- package/dist/cli/utils/parse-args.d.ts.map +1 -0
- package/dist/cli/utils/parse-args.js +756 -0
- package/dist/cli/utils/parse-args.js.map +1 -0
- package/dist/config/project-config.d.ts +49 -0
- package/dist/config/project-config.d.ts.map +1 -0
- package/dist/config/project-config.js +118 -0
- package/dist/config/project-config.js.map +1 -0
- package/dist/config/spec-driver-config.d.ts +32 -0
- package/dist/config/spec-driver-config.d.ts.map +1 -0
- package/dist/config/spec-driver-config.js +91 -0
- package/dist/config/spec-driver-config.js.map +1 -0
- package/dist/core/ast-analyzer.d.ts +49 -0
- package/dist/core/ast-analyzer.d.ts.map +1 -0
- package/dist/core/ast-analyzer.js +439 -0
- package/dist/core/ast-analyzer.js.map +1 -0
- package/dist/core/code-slice-extractor.d.ts +47 -0
- package/dist/core/code-slice-extractor.d.ts.map +1 -0
- package/dist/core/code-slice-extractor.js +227 -0
- package/dist/core/code-slice-extractor.js.map +1 -0
- package/dist/core/context-assembler.d.ts +80 -0
- package/dist/core/context-assembler.d.ts.map +1 -0
- package/dist/core/context-assembler.js +262 -0
- package/dist/core/context-assembler.js.map +1 -0
- package/dist/core/grammar-manager.d.ts +79 -0
- package/dist/core/grammar-manager.d.ts.map +1 -0
- package/dist/core/grammar-manager.js +188 -0
- package/dist/core/grammar-manager.js.map +1 -0
- package/dist/core/llm-client.d.ts +120 -0
- package/dist/core/llm-client.d.ts.map +1 -0
- package/dist/core/llm-client.js +608 -0
- package/dist/core/llm-client.js.map +1 -0
- package/dist/core/model-selection.d.ts +50 -0
- package/dist/core/model-selection.d.ts.map +1 -0
- package/dist/core/model-selection.js +410 -0
- package/dist/core/model-selection.js.map +1 -0
- package/dist/core/query-mappers/base-mapper.d.ts +22 -0
- package/dist/core/query-mappers/base-mapper.d.ts.map +1 -0
- package/dist/core/query-mappers/base-mapper.js +2 -0
- package/dist/core/query-mappers/base-mapper.js.map +1 -0
- package/dist/core/query-mappers/go-mapper.d.ts +46 -0
- package/dist/core/query-mappers/go-mapper.d.ts.map +1 -0
- package/dist/core/query-mappers/go-mapper.js +477 -0
- package/dist/core/query-mappers/go-mapper.js.map +1 -0
- package/dist/core/query-mappers/index.d.ts +6 -0
- package/dist/core/query-mappers/index.d.ts.map +1 -0
- package/dist/core/query-mappers/index.js +5 -0
- package/dist/core/query-mappers/index.js.map +1 -0
- package/dist/core/query-mappers/java-mapper.d.ts +40 -0
- package/dist/core/query-mappers/java-mapper.d.ts.map +1 -0
- package/dist/core/query-mappers/java-mapper.js +405 -0
- package/dist/core/query-mappers/java-mapper.js.map +1 -0
- package/dist/core/query-mappers/python-mapper.d.ts +65 -0
- package/dist/core/query-mappers/python-mapper.d.ts.map +1 -0
- package/dist/core/query-mappers/python-mapper.js +673 -0
- package/dist/core/query-mappers/python-mapper.js.map +1 -0
- package/dist/core/query-mappers/typescript-mapper.d.ts +54 -0
- package/dist/core/query-mappers/typescript-mapper.d.ts.map +1 -0
- package/dist/core/query-mappers/typescript-mapper.js +706 -0
- package/dist/core/query-mappers/typescript-mapper.js.map +1 -0
- package/dist/core/secret-redactor.d.ts +10 -0
- package/dist/core/secret-redactor.d.ts.map +1 -0
- package/dist/core/secret-redactor.js +208 -0
- package/dist/core/secret-redactor.js.map +1 -0
- package/dist/core/single-spec-orchestrator.d.ts +103 -0
- package/dist/core/single-spec-orchestrator.d.ts.map +1 -0
- package/dist/core/single-spec-orchestrator.js +911 -0
- package/dist/core/single-spec-orchestrator.js.map +1 -0
- package/dist/core/token-counter.d.ts +48 -0
- package/dist/core/token-counter.d.ts.map +1 -0
- package/dist/core/token-counter.js +136 -0
- package/dist/core/token-counter.js.map +1 -0
- package/dist/core/tree-sitter-analyzer.d.ts +62 -0
- package/dist/core/tree-sitter-analyzer.d.ts.map +1 -0
- package/dist/core/tree-sitter-analyzer.js +229 -0
- package/dist/core/tree-sitter-analyzer.js.map +1 -0
- package/dist/core/tree-sitter-fallback.d.ts +14 -0
- package/dist/core/tree-sitter-fallback.d.ts.map +1 -0
- package/dist/core/tree-sitter-fallback.js +423 -0
- package/dist/core/tree-sitter-fallback.js.map +1 -0
- package/dist/debt-scanner/aggregator/quality-report-patcher.d.ts +22 -0
- package/dist/debt-scanner/aggregator/quality-report-patcher.d.ts.map +1 -0
- package/dist/debt-scanner/aggregator/quality-report-patcher.js +107 -0
- package/dist/debt-scanner/aggregator/quality-report-patcher.js.map +1 -0
- package/dist/debt-scanner/aggregator/readme-indexer.d.ts +6 -0
- package/dist/debt-scanner/aggregator/readme-indexer.d.ts.map +1 -0
- package/dist/debt-scanner/aggregator/readme-indexer.js +52 -0
- package/dist/debt-scanner/aggregator/readme-indexer.js.map +1 -0
- package/dist/debt-scanner/aggregator/report-builder.d.ts +25 -0
- package/dist/debt-scanner/aggregator/report-builder.d.ts.map +1 -0
- package/dist/debt-scanner/aggregator/report-builder.js +162 -0
- package/dist/debt-scanner/aggregator/report-builder.js.map +1 -0
- package/dist/debt-scanner/comments/debt-classifier.d.ts +28 -0
- package/dist/debt-scanner/comments/debt-classifier.d.ts.map +1 -0
- package/dist/debt-scanner/comments/debt-classifier.js +50 -0
- package/dist/debt-scanner/comments/debt-classifier.js.map +1 -0
- package/dist/debt-scanner/comments/index.d.ts +32 -0
- package/dist/debt-scanner/comments/index.d.ts.map +1 -0
- package/dist/debt-scanner/comments/index.js +103 -0
- package/dist/debt-scanner/comments/index.js.map +1 -0
- package/dist/debt-scanner/comments/symbol-resolver.d.ts +18 -0
- package/dist/debt-scanner/comments/symbol-resolver.d.ts.map +1 -0
- package/dist/debt-scanner/comments/symbol-resolver.js +18 -0
- package/dist/debt-scanner/comments/symbol-resolver.js.map +1 -0
- package/dist/debt-scanner/design-docs/doc-discoverer.d.ts +6 -0
- package/dist/debt-scanner/design-docs/doc-discoverer.d.ts.map +1 -0
- package/dist/debt-scanner/design-docs/doc-discoverer.js +62 -0
- package/dist/debt-scanner/design-docs/doc-discoverer.js.map +1 -0
- package/dist/debt-scanner/design-docs/index.d.ts +28 -0
- package/dist/debt-scanner/design-docs/index.d.ts.map +1 -0
- package/dist/debt-scanner/design-docs/index.js +60 -0
- package/dist/debt-scanner/design-docs/index.js.map +1 -0
- package/dist/debt-scanner/design-docs/llm-topic-inferrer.d.ts +68 -0
- package/dist/debt-scanner/design-docs/llm-topic-inferrer.d.ts.map +1 -0
- package/dist/debt-scanner/design-docs/llm-topic-inferrer.js +151 -0
- package/dist/debt-scanner/design-docs/llm-topic-inferrer.js.map +1 -0
- package/dist/debt-scanner/design-docs/markdown-sections.d.ts +24 -0
- package/dist/debt-scanner/design-docs/markdown-sections.d.ts.map +1 -0
- package/dist/debt-scanner/design-docs/markdown-sections.js +92 -0
- package/dist/debt-scanner/design-docs/markdown-sections.js.map +1 -0
- package/dist/debt-scanner/design-docs/rule-detector.d.ts +18 -0
- package/dist/debt-scanner/design-docs/rule-detector.d.ts.map +1 -0
- package/dist/debt-scanner/design-docs/rule-detector.js +46 -0
- package/dist/debt-scanner/design-docs/rule-detector.js.map +1 -0
- package/dist/debt-scanner/index.d.ts +43 -0
- package/dist/debt-scanner/index.d.ts.map +1 -0
- package/dist/debt-scanner/index.js +177 -0
- package/dist/debt-scanner/index.js.map +1 -0
- package/dist/debt-scanner/llm-clients.d.ts +33 -0
- package/dist/debt-scanner/llm-clients.d.ts.map +1 -0
- package/dist/debt-scanner/llm-clients.js +78 -0
- package/dist/debt-scanner/llm-clients.js.map +1 -0
- package/dist/debt-scanner/types.d.ts +97 -0
- package/dist/debt-scanner/types.d.ts.map +1 -0
- package/dist/debt-scanner/types.js +7 -0
- package/dist/debt-scanner/types.js.map +1 -0
- package/dist/diff/drift-orchestrator.d.ts +25 -0
- package/dist/diff/drift-orchestrator.d.ts.map +1 -0
- package/dist/diff/drift-orchestrator.js +248 -0
- package/dist/diff/drift-orchestrator.js.map +1 -0
- package/dist/diff/noise-filter.d.ts +27 -0
- package/dist/diff/noise-filter.d.ts.map +1 -0
- package/dist/diff/noise-filter.js +129 -0
- package/dist/diff/noise-filter.js.map +1 -0
- package/dist/diff/semantic-diff.d.ts +12 -0
- package/dist/diff/semantic-diff.d.ts.map +1 -0
- package/dist/diff/semantic-diff.js +94 -0
- package/dist/diff/semantic-diff.js.map +1 -0
- package/dist/diff/structural-diff.d.ts +16 -0
- package/dist/diff/structural-diff.d.ts.map +1 -0
- package/dist/diff/structural-diff.js +171 -0
- package/dist/diff/structural-diff.js.map +1 -0
- package/dist/extraction/artifact-classifier.d.ts +19 -0
- package/dist/extraction/artifact-classifier.d.ts.map +1 -0
- package/dist/extraction/artifact-classifier.js +104 -0
- package/dist/extraction/artifact-classifier.js.map +1 -0
- package/dist/extraction/extraction-cache.d.ts +32 -0
- package/dist/extraction/extraction-cache.d.ts.map +1 -0
- package/dist/extraction/extraction-cache.js +117 -0
- package/dist/extraction/extraction-cache.js.map +1 -0
- package/dist/extraction/extraction-pipeline.d.ts +44 -0
- package/dist/extraction/extraction-pipeline.d.ts.map +1 -0
- package/dist/extraction/extraction-pipeline.js +286 -0
- package/dist/extraction/extraction-pipeline.js.map +1 -0
- package/dist/extraction/extraction-types.d.ts +180 -0
- package/dist/extraction/extraction-types.d.ts.map +1 -0
- package/dist/extraction/extraction-types.js +63 -0
- package/dist/extraction/extraction-types.js.map +1 -0
- package/dist/extraction/image-extractor.d.ts +21 -0
- package/dist/extraction/image-extractor.d.ts.map +1 -0
- package/dist/extraction/image-extractor.js +211 -0
- package/dist/extraction/image-extractor.js.map +1 -0
- package/dist/extraction/index.d.ts +8 -0
- package/dist/extraction/index.d.ts.map +1 -0
- package/dist/extraction/index.js +6 -0
- package/dist/extraction/index.js.map +1 -0
- package/dist/extraction/markdown-extractor.d.ts +11 -0
- package/dist/extraction/markdown-extractor.d.ts.map +1 -0
- package/dist/extraction/markdown-extractor.js +212 -0
- package/dist/extraction/markdown-extractor.js.map +1 -0
- package/dist/extraction/openapi-extractor.d.ts +10 -0
- package/dist/extraction/openapi-extractor.d.ts.map +1 -0
- package/dist/extraction/openapi-extractor.js +449 -0
- package/dist/extraction/openapi-extractor.js.map +1 -0
- package/dist/generator/frontmatter.d.ts +58 -0
- package/dist/generator/frontmatter.d.ts.map +1 -0
- package/dist/generator/frontmatter.js +100 -0
- package/dist/generator/frontmatter.js.map +1 -0
- package/dist/generator/index-generator.d.ts +27 -0
- package/dist/generator/index-generator.d.ts.map +1 -0
- package/dist/generator/index-generator.js +129 -0
- package/dist/generator/index-generator.js.map +1 -0
- package/dist/generator/mermaid-class-diagram.d.ts +14 -0
- package/dist/generator/mermaid-class-diagram.d.ts.map +1 -0
- package/dist/generator/mermaid-class-diagram.js +115 -0
- package/dist/generator/mermaid-class-diagram.js.map +1 -0
- package/dist/generator/mermaid-dependency-graph.d.ts +15 -0
- package/dist/generator/mermaid-dependency-graph.d.ts.map +1 -0
- package/dist/generator/mermaid-dependency-graph.js +84 -0
- package/dist/generator/mermaid-dependency-graph.js.map +1 -0
- package/dist/generator/spec-renderer.d.ts +24 -0
- package/dist/generator/spec-renderer.d.ts.map +1 -0
- package/dist/generator/spec-renderer.js +110 -0
- package/dist/generator/spec-renderer.js.map +1 -0
- package/dist/graph/dependency-graph.d.ts +24 -0
- package/dist/graph/dependency-graph.d.ts.map +1 -0
- package/dist/graph/dependency-graph.js +206 -0
- package/dist/graph/dependency-graph.js.map +1 -0
- package/dist/graph/directory-graph.d.ts +16 -0
- package/dist/graph/directory-graph.d.ts.map +1 -0
- package/dist/graph/directory-graph.js +281 -0
- package/dist/graph/directory-graph.js.map +1 -0
- package/dist/graph/mermaid-renderer.d.ts +22 -0
- package/dist/graph/mermaid-renderer.d.ts.map +1 -0
- package/dist/graph/mermaid-renderer.js +133 -0
- package/dist/graph/mermaid-renderer.js.map +1 -0
- package/dist/graph/topological-sort.d.ts +31 -0
- package/dist/graph/topological-sort.d.ts.map +1 -0
- package/dist/graph/topological-sort.js +167 -0
- package/dist/graph/topological-sort.js.map +1 -0
- package/dist/hooks/git-hook-installer.d.ts +37 -0
- package/dist/hooks/git-hook-installer.d.ts.map +1 -0
- package/dist/hooks/git-hook-installer.js +136 -0
- package/dist/hooks/git-hook-installer.js.map +1 -0
- package/dist/hooks/hook-installer.d.ts +39 -0
- package/dist/hooks/hook-installer.d.ts.map +1 -0
- package/dist/hooks/hook-installer.js +164 -0
- package/dist/hooks/hook-installer.js.map +1 -0
- package/dist/installer/skill-installer.d.ts +63 -0
- package/dist/installer/skill-installer.d.ts.map +1 -0
- package/dist/installer/skill-installer.js +203 -0
- package/dist/installer/skill-installer.js.map +1 -0
- package/dist/installer/skill-templates.d.ts +19 -0
- package/dist/installer/skill-templates.d.ts.map +1 -0
- package/dist/installer/skill-templates.js +42 -0
- package/dist/installer/skill-templates.js.map +1 -0
- package/dist/mcp/graph-tools.d.ts +17 -0
- package/dist/mcp/graph-tools.d.ts.map +1 -0
- package/dist/mcp/graph-tools.js +269 -0
- package/dist/mcp/graph-tools.js.map +1 -0
- package/dist/mcp/index.d.ts +10 -0
- package/dist/mcp/index.d.ts.map +1 -0
- package/dist/mcp/index.js +18 -0
- package/dist/mcp/index.js.map +1 -0
- package/dist/mcp/server.d.ts +10 -0
- package/dist/mcp/server.d.ts.map +1 -0
- package/dist/mcp/server.js +235 -0
- package/dist/mcp/server.js.map +1 -0
- package/dist/models/code-skeleton.d.ts +394 -0
- package/dist/models/code-skeleton.d.ts.map +1 -0
- package/dist/models/code-skeleton.js +119 -0
- package/dist/models/code-skeleton.js.map +1 -0
- package/dist/models/dependency-graph.d.ts +172 -0
- package/dist/models/dependency-graph.d.ts.map +1 -0
- package/dist/models/dependency-graph.js +44 -0
- package/dist/models/dependency-graph.js.map +1 -0
- package/dist/models/drift-item.d.ts +104 -0
- package/dist/models/drift-item.d.ts.map +1 -0
- package/dist/models/drift-item.js +38 -0
- package/dist/models/drift-item.js.map +1 -0
- package/dist/models/module-spec.d.ts +1905 -0
- package/dist/models/module-spec.d.ts.map +1 -0
- package/dist/models/module-spec.js +272 -0
- package/dist/models/module-spec.js.map +1 -0
- package/dist/panoramic/abstract-registry.d.ts +87 -0
- package/dist/panoramic/abstract-registry.d.ts.map +1 -0
- package/dist/panoramic/abstract-registry.js +88 -0
- package/dist/panoramic/abstract-registry.js.map +1 -0
- package/dist/panoramic/anchoring/chunker.d.ts +34 -0
- package/dist/panoramic/anchoring/chunker.d.ts.map +1 -0
- package/dist/panoramic/anchoring/chunker.js +274 -0
- package/dist/panoramic/anchoring/chunker.js.map +1 -0
- package/dist/panoramic/anchoring/edge-builder.d.ts +53 -0
- package/dist/panoramic/anchoring/edge-builder.d.ts.map +1 -0
- package/dist/panoramic/anchoring/edge-builder.js +183 -0
- package/dist/panoramic/anchoring/edge-builder.js.map +1 -0
- package/dist/panoramic/anchoring/embedding-provider.d.ts +51 -0
- package/dist/panoramic/anchoring/embedding-provider.d.ts.map +1 -0
- package/dist/panoramic/anchoring/embedding-provider.js +7 -0
- package/dist/panoramic/anchoring/embedding-provider.js.map +1 -0
- package/dist/panoramic/anchoring/index.d.ts +73 -0
- package/dist/panoramic/anchoring/index.d.ts.map +1 -0
- package/dist/panoramic/anchoring/index.js +91 -0
- package/dist/panoramic/anchoring/index.js.map +1 -0
- package/dist/panoramic/anchoring/providers/factory.d.ts +35 -0
- package/dist/panoramic/anchoring/providers/factory.d.ts.map +1 -0
- package/dist/panoramic/anchoring/providers/factory.js +33 -0
- package/dist/panoramic/anchoring/providers/factory.js.map +1 -0
- package/dist/panoramic/anchoring/providers/local-provider.d.ts +48 -0
- package/dist/panoramic/anchoring/providers/local-provider.d.ts.map +1 -0
- package/dist/panoramic/anchoring/providers/local-provider.js +145 -0
- package/dist/panoramic/anchoring/providers/local-provider.js.map +1 -0
- package/dist/panoramic/anchoring/providers/openai-provider.d.ts +45 -0
- package/dist/panoramic/anchoring/providers/openai-provider.d.ts.map +1 -0
- package/dist/panoramic/anchoring/providers/openai-provider.js +78 -0
- package/dist/panoramic/anchoring/providers/openai-provider.js.map +1 -0
- package/dist/panoramic/anchoring/similarity.d.ts +37 -0
- package/dist/panoramic/anchoring/similarity.d.ts.map +1 -0
- package/dist/panoramic/anchoring/similarity.js +75 -0
- package/dist/panoramic/anchoring/similarity.js.map +1 -0
- package/dist/panoramic/api-surface/endpoint-utils.d.ts +15 -0
- package/dist/panoramic/api-surface/endpoint-utils.d.ts.map +1 -0
- package/dist/panoramic/api-surface/endpoint-utils.js +145 -0
- package/dist/panoramic/api-surface/endpoint-utils.js.map +1 -0
- package/dist/panoramic/api-surface/express-extractor.d.ts +3 -0
- package/dist/panoramic/api-surface/express-extractor.d.ts.map +1 -0
- package/dist/panoramic/api-surface/express-extractor.js +288 -0
- package/dist/panoramic/api-surface/express-extractor.js.map +1 -0
- package/dist/panoramic/api-surface/fastapi-extractor.d.ts +6 -0
- package/dist/panoramic/api-surface/fastapi-extractor.d.ts.map +1 -0
- package/dist/panoramic/api-surface/fastapi-extractor.js +287 -0
- package/dist/panoramic/api-surface/fastapi-extractor.js.map +1 -0
- package/dist/panoramic/api-surface/framework-introspection.d.ts +3 -0
- package/dist/panoramic/api-surface/framework-introspection.d.ts.map +1 -0
- package/dist/panoramic/api-surface/framework-introspection.js +189 -0
- package/dist/panoramic/api-surface/framework-introspection.js.map +1 -0
- package/dist/panoramic/api-surface/index.d.ts +13 -0
- package/dist/panoramic/api-surface/index.d.ts.map +1 -0
- package/dist/panoramic/api-surface/index.js +238 -0
- package/dist/panoramic/api-surface/index.js.map +1 -0
- package/dist/panoramic/api-surface/openapi-extractor.d.ts +3 -0
- package/dist/panoramic/api-surface/openapi-extractor.d.ts.map +1 -0
- package/dist/panoramic/api-surface/openapi-extractor.js +247 -0
- package/dist/panoramic/api-surface/openapi-extractor.js.map +1 -0
- package/dist/panoramic/api-surface/types.d.ts +140 -0
- package/dist/panoramic/api-surface/types.d.ts.map +1 -0
- package/dist/panoramic/api-surface/types.js +7 -0
- package/dist/panoramic/api-surface/types.js.map +1 -0
- package/dist/panoramic/api-surface/utils.d.ts +29 -0
- package/dist/panoramic/api-surface/utils.d.ts.map +1 -0
- package/dist/panoramic/api-surface/utils.js +340 -0
- package/dist/panoramic/api-surface/utils.js.map +1 -0
- package/dist/panoramic/batch-project-docs.d.ts +101 -0
- package/dist/panoramic/batch-project-docs.d.ts.map +1 -0
- package/dist/panoramic/batch-project-docs.js +616 -0
- package/dist/panoramic/batch-project-docs.js.map +1 -0
- package/dist/panoramic/builders/architecture-ir-builder.d.ts +19 -0
- package/dist/panoramic/builders/architecture-ir-builder.d.ts.map +1 -0
- package/dist/panoramic/builders/architecture-ir-builder.js +561 -0
- package/dist/panoramic/builders/architecture-ir-builder.js.map +1 -0
- package/dist/panoramic/builders/architecture-ir-mermaid-adapter.d.ts +6 -0
- package/dist/panoramic/builders/architecture-ir-mermaid-adapter.d.ts.map +1 -0
- package/dist/panoramic/builders/architecture-ir-mermaid-adapter.js +98 -0
- package/dist/panoramic/builders/architecture-ir-mermaid-adapter.js.map +1 -0
- package/dist/panoramic/builders/component-view-builder.d.ts +38 -0
- package/dist/panoramic/builders/component-view-builder.d.ts.map +1 -0
- package/dist/panoramic/builders/component-view-builder.js +694 -0
- package/dist/panoramic/builders/component-view-builder.js.map +1 -0
- package/dist/panoramic/builders/doc-graph-builder.d.ts +179 -0
- package/dist/panoramic/builders/doc-graph-builder.d.ts.map +1 -0
- package/dist/panoramic/builders/doc-graph-builder.js +546 -0
- package/dist/panoramic/builders/doc-graph-builder.js.map +1 -0
- package/dist/panoramic/builders/dynamic-scenarios-builder.d.ts +38 -0
- package/dist/panoramic/builders/dynamic-scenarios-builder.d.ts.map +1 -0
- package/dist/panoramic/builders/dynamic-scenarios-builder.js +361 -0
- package/dist/panoramic/builders/dynamic-scenarios-builder.js.map +1 -0
- package/dist/panoramic/cache/cache-key-builder.d.ts +25 -0
- package/dist/panoramic/cache/cache-key-builder.d.ts.map +1 -0
- package/dist/panoramic/cache/cache-key-builder.js +119 -0
- package/dist/panoramic/cache/cache-key-builder.js.map +1 -0
- package/dist/panoramic/cache/cache-manager.d.ts +58 -0
- package/dist/panoramic/cache/cache-manager.d.ts.map +1 -0
- package/dist/panoramic/cache/cache-manager.js +170 -0
- package/dist/panoramic/cache/cache-manager.js.map +1 -0
- package/dist/panoramic/cache/content-hasher.d.ts +47 -0
- package/dist/panoramic/cache/content-hasher.d.ts.map +1 -0
- package/dist/panoramic/cache/content-hasher.js +89 -0
- package/dist/panoramic/cache/content-hasher.js.map +1 -0
- package/dist/panoramic/cache/index.d.ts +10 -0
- package/dist/panoramic/cache/index.d.ts.map +1 -0
- package/dist/panoramic/cache/index.js +13 -0
- package/dist/panoramic/cache/index.js.map +1 -0
- package/dist/panoramic/cache/manifest-manager.d.ts +83 -0
- package/dist/panoramic/cache/manifest-manager.d.ts.map +1 -0
- package/dist/panoramic/cache/manifest-manager.js +119 -0
- package/dist/panoramic/cache/manifest-manager.js.map +1 -0
- package/dist/panoramic/cache/schemas.d.ts +199 -0
- package/dist/panoramic/cache/schemas.d.ts.map +1 -0
- package/dist/panoramic/cache/schemas.js +53 -0
- package/dist/panoramic/cache/schemas.js.map +1 -0
- package/dist/panoramic/cluster-orchestrator.d.ts +278 -0
- package/dist/panoramic/cluster-orchestrator.d.ts.map +1 -0
- package/dist/panoramic/cluster-orchestrator.js +531 -0
- package/dist/panoramic/cluster-orchestrator.js.map +1 -0
- package/dist/panoramic/community/community-detector.d.ts +41 -0
- package/dist/panoramic/community/community-detector.d.ts.map +1 -0
- package/dist/panoramic/community/community-detector.js +190 -0
- package/dist/panoramic/community/community-detector.js.map +1 -0
- package/dist/panoramic/community/god-node-analyzer.d.ts +28 -0
- package/dist/panoramic/community/god-node-analyzer.d.ts.map +1 -0
- package/dist/panoramic/community/god-node-analyzer.js +91 -0
- package/dist/panoramic/community/god-node-analyzer.js.map +1 -0
- package/dist/panoramic/community/graph-report-generator.d.ts +31 -0
- package/dist/panoramic/community/graph-report-generator.d.ts.map +1 -0
- package/dist/panoramic/community/graph-report-generator.js +98 -0
- package/dist/panoramic/community/graph-report-generator.js.map +1 -0
- package/dist/panoramic/community/index.d.ts +31 -0
- package/dist/panoramic/community/index.d.ts.map +1 -0
- package/dist/panoramic/community/index.js +63 -0
- package/dist/panoramic/community/index.js.map +1 -0
- package/dist/panoramic/community/surprising-edges.d.ts +42 -0
- package/dist/panoramic/community/surprising-edges.d.ts.map +1 -0
- package/dist/panoramic/community/surprising-edges.js +154 -0
- package/dist/panoramic/community/surprising-edges.js.map +1 -0
- package/dist/panoramic/cross-reference-index.d.ts +4 -0
- package/dist/panoramic/cross-reference-index.d.ts.map +1 -0
- package/dist/panoramic/cross-reference-index.js +201 -0
- package/dist/panoramic/cross-reference-index.js.map +1 -0
- package/dist/panoramic/exporters/architecture-ir-exporters.d.ts +7 -0
- package/dist/panoramic/exporters/architecture-ir-exporters.d.ts.map +1 -0
- package/dist/panoramic/exporters/architecture-ir-exporters.js +183 -0
- package/dist/panoramic/exporters/architecture-ir-exporters.js.map +1 -0
- package/dist/panoramic/exporters/export-types.d.ts +33 -0
- package/dist/panoramic/exporters/export-types.d.ts.map +1 -0
- package/dist/panoramic/exporters/export-types.js +7 -0
- package/dist/panoramic/exporters/export-types.js.map +1 -0
- package/dist/panoramic/exporters/html-exporter.d.ts +83 -0
- package/dist/panoramic/exporters/html-exporter.d.ts.map +1 -0
- package/dist/panoramic/exporters/html-exporter.js +224 -0
- package/dist/panoramic/exporters/html-exporter.js.map +1 -0
- package/dist/panoramic/exporters/html-template.d.ts +32 -0
- package/dist/panoramic/exporters/html-template.d.ts.map +1 -0
- package/dist/panoramic/exporters/html-template.js +737 -0
- package/dist/panoramic/exporters/html-template.js.map +1 -0
- package/dist/panoramic/exporters/obsidian-exporter.d.ts +67 -0
- package/dist/panoramic/exporters/obsidian-exporter.d.ts.map +1 -0
- package/dist/panoramic/exporters/obsidian-exporter.js +333 -0
- package/dist/panoramic/exporters/obsidian-exporter.js.map +1 -0
- package/dist/panoramic/generator-registry.d.ts +86 -0
- package/dist/panoramic/generator-registry.d.ts.map +1 -0
- package/dist/panoramic/generator-registry.js +194 -0
- package/dist/panoramic/generator-registry.js.map +1 -0
- package/dist/panoramic/generators/architecture-ir-generator.d.ts +36 -0
- package/dist/panoramic/generators/architecture-ir-generator.d.ts.map +1 -0
- package/dist/panoramic/generators/architecture-ir-generator.js +51 -0
- package/dist/panoramic/generators/architecture-ir-generator.js.map +1 -0
- package/dist/panoramic/generators/architecture-overview-generator.d.ts +31 -0
- package/dist/panoramic/generators/architecture-overview-generator.d.ts.map +1 -0
- package/dist/panoramic/generators/architecture-overview-generator.js +454 -0
- package/dist/panoramic/generators/architecture-overview-generator.js.map +1 -0
- package/dist/panoramic/generators/config-reference-generator.d.ts +78 -0
- package/dist/panoramic/generators/config-reference-generator.d.ts.map +1 -0
- package/dist/panoramic/generators/config-reference-generator.js +201 -0
- package/dist/panoramic/generators/config-reference-generator.js.map +1 -0
- package/dist/panoramic/generators/cross-package-analyzer.d.ts +112 -0
- package/dist/panoramic/generators/cross-package-analyzer.d.ts.map +1 -0
- package/dist/panoramic/generators/cross-package-analyzer.js +258 -0
- package/dist/panoramic/generators/cross-package-analyzer.js.map +1 -0
- package/dist/panoramic/generators/data-model-generator.d.ts +528 -0
- package/dist/panoramic/generators/data-model-generator.d.ts.map +1 -0
- package/dist/panoramic/generators/data-model-generator.js +674 -0
- package/dist/panoramic/generators/data-model-generator.js.map +1 -0
- package/dist/panoramic/generators/event-surface-generator.d.ts +52 -0
- package/dist/panoramic/generators/event-surface-generator.d.ts.map +1 -0
- package/dist/panoramic/generators/event-surface-generator.js +634 -0
- package/dist/panoramic/generators/event-surface-generator.js.map +1 -0
- package/dist/panoramic/generators/interface-surface-generator.d.ts +50 -0
- package/dist/panoramic/generators/interface-surface-generator.d.ts.map +1 -0
- package/dist/panoramic/generators/interface-surface-generator.js +393 -0
- package/dist/panoramic/generators/interface-surface-generator.js.map +1 -0
- package/dist/panoramic/generators/mock-readme-generator.d.ts +90 -0
- package/dist/panoramic/generators/mock-readme-generator.d.ts.map +1 -0
- package/dist/panoramic/generators/mock-readme-generator.js +113 -0
- package/dist/panoramic/generators/mock-readme-generator.js.map +1 -0
- package/dist/panoramic/generators/pattern-hints-generator.d.ts +28 -0
- package/dist/panoramic/generators/pattern-hints-generator.d.ts.map +1 -0
- package/dist/panoramic/generators/pattern-hints-generator.js +170 -0
- package/dist/panoramic/generators/pattern-hints-generator.js.map +1 -0
- package/dist/panoramic/generators/runtime-topology-generator.d.ts +77 -0
- package/dist/panoramic/generators/runtime-topology-generator.d.ts.map +1 -0
- package/dist/panoramic/generators/runtime-topology-generator.js +679 -0
- package/dist/panoramic/generators/runtime-topology-generator.js.map +1 -0
- package/dist/panoramic/generators/troubleshooting-generator.d.ts +51 -0
- package/dist/panoramic/generators/troubleshooting-generator.d.ts.map +1 -0
- package/dist/panoramic/generators/troubleshooting-generator.js +464 -0
- package/dist/panoramic/generators/troubleshooting-generator.js.map +1 -0
- package/dist/panoramic/generators/workspace-index-generator.d.ts +148 -0
- package/dist/panoramic/generators/workspace-index-generator.d.ts.map +1 -0
- package/dist/panoramic/generators/workspace-index-generator.js +500 -0
- package/dist/panoramic/generators/workspace-index-generator.js.map +1 -0
- package/dist/panoramic/graph/confidence-mapper.d.ts +39 -0
- package/dist/panoramic/graph/confidence-mapper.d.ts.map +1 -0
- package/dist/panoramic/graph/confidence-mapper.js +55 -0
- package/dist/panoramic/graph/confidence-mapper.js.map +1 -0
- package/dist/panoramic/graph/graph-builder.d.ts +33 -0
- package/dist/panoramic/graph/graph-builder.d.ts.map +1 -0
- package/dist/panoramic/graph/graph-builder.js +382 -0
- package/dist/panoramic/graph/graph-builder.js.map +1 -0
- package/dist/panoramic/graph/graph-paths.d.ts +13 -0
- package/dist/panoramic/graph/graph-paths.d.ts.map +1 -0
- package/dist/panoramic/graph/graph-paths.js +16 -0
- package/dist/panoramic/graph/graph-paths.js.map +1 -0
- package/dist/panoramic/graph/graph-query.d.ts +226 -0
- package/dist/panoramic/graph/graph-query.d.ts.map +1 -0
- package/dist/panoramic/graph/graph-query.js +571 -0
- package/dist/panoramic/graph/graph-query.js.map +1 -0
- package/dist/panoramic/graph/graph-types.d.ts +156 -0
- package/dist/panoramic/graph/graph-types.d.ts.map +1 -0
- package/dist/panoramic/graph/graph-types.js +10 -0
- package/dist/panoramic/graph/graph-types.js.map +1 -0
- package/dist/panoramic/graph/index.d.ts +6 -0
- package/dist/panoramic/graph/index.d.ts.map +1 -0
- package/dist/panoramic/graph/index.js +8 -0
- package/dist/panoramic/graph/index.js.map +1 -0
- package/dist/panoramic/hyperedges/constants.d.ts +16 -0
- package/dist/panoramic/hyperedges/constants.d.ts.map +1 -0
- package/dist/panoramic/hyperedges/constants.js +13 -0
- package/dist/panoramic/hyperedges/constants.js.map +1 -0
- package/dist/panoramic/hyperedges/extractor.d.ts +80 -0
- package/dist/panoramic/hyperedges/extractor.d.ts.map +1 -0
- package/dist/panoramic/hyperedges/extractor.js +133 -0
- package/dist/panoramic/hyperedges/extractor.js.map +1 -0
- package/dist/panoramic/hyperedges/index.d.ts +12 -0
- package/dist/panoramic/hyperedges/index.d.ts.map +1 -0
- package/dist/panoramic/hyperedges/index.js +19 -0
- package/dist/panoramic/hyperedges/index.js.map +1 -0
- package/dist/panoramic/hyperedges/prompt.d.ts +30 -0
- package/dist/panoramic/hyperedges/prompt.d.ts.map +1 -0
- package/dist/panoramic/hyperedges/prompt.js +88 -0
- package/dist/panoramic/hyperedges/prompt.js.map +1 -0
- package/dist/panoramic/hyperedges/schema.d.ts +91 -0
- package/dist/panoramic/hyperedges/schema.d.ts.map +1 -0
- package/dist/panoramic/hyperedges/schema.js +52 -0
- package/dist/panoramic/hyperedges/schema.js.map +1 -0
- package/dist/panoramic/index.d.ts +17 -0
- package/dist/panoramic/index.d.ts.map +1 -0
- package/dist/panoramic/index.js +22 -0
- package/dist/panoramic/index.js.map +1 -0
- package/dist/panoramic/interfaces.d.ts +243 -0
- package/dist/panoramic/interfaces.d.ts.map +1 -0
- package/dist/panoramic/interfaces.js +130 -0
- package/dist/panoramic/interfaces.js.map +1 -0
- package/dist/panoramic/internal.d.ts +67 -0
- package/dist/panoramic/internal.d.ts.map +1 -0
- package/dist/panoramic/internal.js +93 -0
- package/dist/panoramic/internal.js.map +1 -0
- package/dist/panoramic/models/architecture-ir-model.d.ts +92 -0
- package/dist/panoramic/models/architecture-ir-model.d.ts.map +1 -0
- package/dist/panoramic/models/architecture-ir-model.js +14 -0
- package/dist/panoramic/models/architecture-ir-model.js.map +1 -0
- package/dist/panoramic/models/architecture-overview-model.d.ts +77 -0
- package/dist/panoramic/models/architecture-overview-model.d.ts.map +1 -0
- package/dist/panoramic/models/architecture-overview-model.js +31 -0
- package/dist/panoramic/models/architecture-overview-model.js.map +1 -0
- package/dist/panoramic/models/component-view-model.d.ts +127 -0
- package/dist/panoramic/models/component-view-model.d.ts.map +1 -0
- package/dist/panoramic/models/component-view-model.js +65 -0
- package/dist/panoramic/models/component-view-model.js.map +1 -0
- package/dist/panoramic/models/docs-bundle-profiles.d.ts +4 -0
- package/dist/panoramic/models/docs-bundle-profiles.d.ts.map +1 -0
- package/dist/panoramic/models/docs-bundle-profiles.js +82 -0
- package/dist/panoramic/models/docs-bundle-profiles.js.map +1 -0
- package/dist/panoramic/models/docs-bundle-types.d.ts +94 -0
- package/dist/panoramic/models/docs-bundle-types.d.ts.map +1 -0
- package/dist/panoramic/models/docs-bundle-types.js +10 -0
- package/dist/panoramic/models/docs-bundle-types.js.map +1 -0
- package/dist/panoramic/models/docs-quality-model.d.ts +125 -0
- package/dist/panoramic/models/docs-quality-model.d.ts.map +1 -0
- package/dist/panoramic/models/docs-quality-model.js +166 -0
- package/dist/panoramic/models/docs-quality-model.js.map +1 -0
- package/dist/panoramic/models/pattern-hints-model.d.ts +89 -0
- package/dist/panoramic/models/pattern-hints-model.d.ts.map +1 -0
- package/dist/panoramic/models/pattern-hints-model.js +61 -0
- package/dist/panoramic/models/pattern-hints-model.js.map +1 -0
- package/dist/panoramic/models/pattern-knowledge-base.d.ts +31 -0
- package/dist/panoramic/models/pattern-knowledge-base.d.ts.map +1 -0
- package/dist/panoramic/models/pattern-knowledge-base.js +407 -0
- package/dist/panoramic/models/pattern-knowledge-base.js.map +1 -0
- package/dist/panoramic/models/runtime-topology-model.d.ts +145 -0
- package/dist/panoramic/models/runtime-topology-model.d.ts.map +1 -0
- package/dist/panoramic/models/runtime-topology-model.js +300 -0
- package/dist/panoramic/models/runtime-topology-model.js.map +1 -0
- package/dist/panoramic/output-filenames.d.ts +26 -0
- package/dist/panoramic/output-filenames.d.ts.map +1 -0
- package/dist/panoramic/output-filenames.js +48 -0
- package/dist/panoramic/output-filenames.js.map +1 -0
- package/dist/panoramic/parser-registry.d.ts +89 -0
- package/dist/panoramic/parser-registry.d.ts.map +1 -0
- package/dist/panoramic/parser-registry.js +169 -0
- package/dist/panoramic/parser-registry.js.map +1 -0
- package/dist/panoramic/parsers/abstract-artifact-parser.d.ts +48 -0
- package/dist/panoramic/parsers/abstract-artifact-parser.d.ts.map +1 -0
- package/dist/panoramic/parsers/abstract-artifact-parser.js +52 -0
- package/dist/panoramic/parsers/abstract-artifact-parser.js.map +1 -0
- package/dist/panoramic/parsers/abstract-config-parser.d.ts +35 -0
- package/dist/panoramic/parsers/abstract-config-parser.d.ts.map +1 -0
- package/dist/panoramic/parsers/abstract-config-parser.js +34 -0
- package/dist/panoramic/parsers/abstract-config-parser.js.map +1 -0
- package/dist/panoramic/parsers/behavior-yaml-parser.d.ts +34 -0
- package/dist/panoramic/parsers/behavior-yaml-parser.d.ts.map +1 -0
- package/dist/panoramic/parsers/behavior-yaml-parser.js +195 -0
- package/dist/panoramic/parsers/behavior-yaml-parser.js.map +1 -0
- package/dist/panoramic/parsers/comment-tracker.d.ts +37 -0
- package/dist/panoramic/parsers/comment-tracker.d.ts.map +1 -0
- package/dist/panoramic/parsers/comment-tracker.js +50 -0
- package/dist/panoramic/parsers/comment-tracker.js.map +1 -0
- package/dist/panoramic/parsers/dockerfile-parser.d.ts +42 -0
- package/dist/panoramic/parsers/dockerfile-parser.d.ts.map +1 -0
- package/dist/panoramic/parsers/dockerfile-parser.js +128 -0
- package/dist/panoramic/parsers/dockerfile-parser.js.map +1 -0
- package/dist/panoramic/parsers/env-config-parser.d.ts +37 -0
- package/dist/panoramic/parsers/env-config-parser.d.ts.map +1 -0
- package/dist/panoramic/parsers/env-config-parser.js +73 -0
- package/dist/panoramic/parsers/env-config-parser.js.map +1 -0
- package/dist/panoramic/parsers/index.d.ts +25 -0
- package/dist/panoramic/parsers/index.d.ts.map +1 -0
- package/dist/panoramic/parsers/index.js +25 -0
- package/dist/panoramic/parsers/index.js.map +1 -0
- package/dist/panoramic/parsers/skill-md-parser.d.ts +42 -0
- package/dist/panoramic/parsers/skill-md-parser.d.ts.map +1 -0
- package/dist/panoramic/parsers/skill-md-parser.js +105 -0
- package/dist/panoramic/parsers/skill-md-parser.js.map +1 -0
- package/dist/panoramic/parsers/toml-config-parser.d.ts +39 -0
- package/dist/panoramic/parsers/toml-config-parser.d.ts.map +1 -0
- package/dist/panoramic/parsers/toml-config-parser.js +98 -0
- package/dist/panoramic/parsers/toml-config-parser.js.map +1 -0
- package/dist/panoramic/parsers/types.d.ts +314 -0
- package/dist/panoramic/parsers/types.d.ts.map +1 -0
- package/dist/panoramic/parsers/types.js +136 -0
- package/dist/panoramic/parsers/types.js.map +1 -0
- package/dist/panoramic/parsers/yaml-config-parser.d.ts +58 -0
- package/dist/panoramic/parsers/yaml-config-parser.d.ts.map +1 -0
- package/dist/panoramic/parsers/yaml-config-parser.js +356 -0
- package/dist/panoramic/parsers/yaml-config-parser.js.map +1 -0
- package/dist/panoramic/pipelines/adr-decision-pipeline.d.ts +74 -0
- package/dist/panoramic/pipelines/adr-decision-pipeline.d.ts.map +1 -0
- package/dist/panoramic/pipelines/adr-decision-pipeline.js +421 -0
- package/dist/panoramic/pipelines/adr-decision-pipeline.js.map +1 -0
- package/dist/panoramic/pipelines/adr-evidence-verifier.d.ts +30 -0
- package/dist/panoramic/pipelines/adr-evidence-verifier.d.ts.map +1 -0
- package/dist/panoramic/pipelines/adr-evidence-verifier.js +141 -0
- package/dist/panoramic/pipelines/adr-evidence-verifier.js.map +1 -0
- package/dist/panoramic/pipelines/adr-mapreduce.d.ts +316 -0
- package/dist/panoramic/pipelines/adr-mapreduce.d.ts.map +1 -0
- package/dist/panoramic/pipelines/adr-mapreduce.js +331 -0
- package/dist/panoramic/pipelines/adr-mapreduce.js.map +1 -0
- package/dist/panoramic/pipelines/adr-migration.d.ts +26 -0
- package/dist/panoramic/pipelines/adr-migration.d.ts.map +1 -0
- package/dist/panoramic/pipelines/adr-migration.js +203 -0
- package/dist/panoramic/pipelines/adr-migration.js.map +1 -0
- package/dist/panoramic/pipelines/architecture-narrative-mapreduce.d.ts +121 -0
- package/dist/panoramic/pipelines/architecture-narrative-mapreduce.d.ts.map +1 -0
- package/dist/panoramic/pipelines/architecture-narrative-mapreduce.js +412 -0
- package/dist/panoramic/pipelines/architecture-narrative-mapreduce.js.map +1 -0
- package/dist/panoramic/pipelines/architecture-narrative.d.ts +123 -0
- package/dist/panoramic/pipelines/architecture-narrative.d.ts.map +1 -0
- package/dist/panoramic/pipelines/architecture-narrative.js +419 -0
- package/dist/panoramic/pipelines/architecture-narrative.js.map +1 -0
- package/dist/panoramic/pipelines/coverage-auditor.d.ts +95 -0
- package/dist/panoramic/pipelines/coverage-auditor.d.ts.map +1 -0
- package/dist/panoramic/pipelines/coverage-auditor.js +290 -0
- package/dist/panoramic/pipelines/coverage-auditor.js.map +1 -0
- package/dist/panoramic/pipelines/debt-intelligence-pipeline.d.ts +32 -0
- package/dist/panoramic/pipelines/debt-intelligence-pipeline.d.ts.map +1 -0
- package/dist/panoramic/pipelines/debt-intelligence-pipeline.js +108 -0
- package/dist/panoramic/pipelines/debt-intelligence-pipeline.js.map +1 -0
- package/dist/panoramic/pipelines/docs-bundle-manifest-reader.d.ts +26 -0
- package/dist/panoramic/pipelines/docs-bundle-manifest-reader.d.ts.map +1 -0
- package/dist/panoramic/pipelines/docs-bundle-manifest-reader.js +108 -0
- package/dist/panoramic/pipelines/docs-bundle-manifest-reader.js.map +1 -0
- package/dist/panoramic/pipelines/docs-bundle-orchestrator.d.ts +16 -0
- package/dist/panoramic/pipelines/docs-bundle-orchestrator.d.ts.map +1 -0
- package/dist/panoramic/pipelines/docs-bundle-orchestrator.js +588 -0
- package/dist/panoramic/pipelines/docs-bundle-orchestrator.js.map +1 -0
- package/dist/panoramic/pipelines/docs-quality-evaluator.d.ts +55 -0
- package/dist/panoramic/pipelines/docs-quality-evaluator.d.ts.map +1 -0
- package/dist/panoramic/pipelines/docs-quality-evaluator.js +1045 -0
- package/dist/panoramic/pipelines/docs-quality-evaluator.js.map +1 -0
- package/dist/panoramic/pipelines/narrative-provenance-adapter.d.ts +8 -0
- package/dist/panoramic/pipelines/narrative-provenance-adapter.d.ts.map +1 -0
- package/dist/panoramic/pipelines/narrative-provenance-adapter.js +99 -0
- package/dist/panoramic/pipelines/narrative-provenance-adapter.js.map +1 -0
- package/dist/panoramic/pipelines/product-ux-docs.d.ts +123 -0
- package/dist/panoramic/pipelines/product-ux-docs.d.ts.map +1 -0
- package/dist/panoramic/pipelines/product-ux-docs.js +959 -0
- package/dist/panoramic/pipelines/product-ux-docs.js.map +1 -0
- package/dist/panoramic/project-context.d.ts +17 -0
- package/dist/panoramic/project-context.d.ts.map +1 -0
- package/dist/panoramic/project-context.js +289 -0
- package/dist/panoramic/project-context.js.map +1 -0
- package/dist/panoramic/qa/citation.d.ts +21 -0
- package/dist/panoramic/qa/citation.d.ts.map +1 -0
- package/dist/panoramic/qa/citation.js +184 -0
- package/dist/panoramic/qa/citation.js.map +1 -0
- package/dist/panoramic/qa/debt-context.d.ts +33 -0
- package/dist/panoramic/qa/debt-context.d.ts.map +1 -0
- package/dist/panoramic/qa/debt-context.js +82 -0
- package/dist/panoramic/qa/debt-context.js.map +1 -0
- package/dist/panoramic/qa/graph-retriever.d.ts +29 -0
- package/dist/panoramic/qa/graph-retriever.d.ts.map +1 -0
- package/dist/panoramic/qa/graph-retriever.js +65 -0
- package/dist/panoramic/qa/graph-retriever.js.map +1 -0
- package/dist/panoramic/qa/index.d.ts +23 -0
- package/dist/panoramic/qa/index.d.ts.map +1 -0
- package/dist/panoramic/qa/index.js +201 -0
- package/dist/panoramic/qa/index.js.map +1 -0
- package/dist/panoramic/qa/llm-caller.d.ts +35 -0
- package/dist/panoramic/qa/llm-caller.d.ts.map +1 -0
- package/dist/panoramic/qa/llm-caller.js +138 -0
- package/dist/panoramic/qa/llm-caller.js.map +1 -0
- package/dist/panoramic/qa/prompt-builder.d.ts +36 -0
- package/dist/panoramic/qa/prompt-builder.d.ts.map +1 -0
- package/dist/panoramic/qa/prompt-builder.js +143 -0
- package/dist/panoramic/qa/prompt-builder.js.map +1 -0
- package/dist/panoramic/qa/rag-reranker.d.ts +43 -0
- package/dist/panoramic/qa/rag-reranker.d.ts.map +1 -0
- package/dist/panoramic/qa/rag-reranker.js +129 -0
- package/dist/panoramic/qa/rag-reranker.js.map +1 -0
- package/dist/panoramic/qa/types.d.ts +126 -0
- package/dist/panoramic/qa/types.d.ts.map +1 -0
- package/dist/panoramic/qa/types.js +6 -0
- package/dist/panoramic/qa/types.js.map +1 -0
- package/dist/panoramic/query.d.ts +29 -0
- package/dist/panoramic/query.d.ts.map +1 -0
- package/dist/panoramic/query.js +80 -0
- package/dist/panoramic/query.js.map +1 -0
- package/dist/panoramic/stored-module-specs.d.ts +26 -0
- package/dist/panoramic/stored-module-specs.d.ts.map +1 -0
- package/dist/panoramic/stored-module-specs.js +155 -0
- package/dist/panoramic/stored-module-specs.js.map +1 -0
- package/dist/panoramic/utils/html-sanitizer.d.ts +33 -0
- package/dist/panoramic/utils/html-sanitizer.d.ts.map +1 -0
- package/dist/panoramic/utils/html-sanitizer.js +170 -0
- package/dist/panoramic/utils/html-sanitizer.js.map +1 -0
- package/dist/panoramic/utils/llm-enricher.d.ts +74 -0
- package/dist/panoramic/utils/llm-enricher.d.ts.map +1 -0
- package/dist/panoramic/utils/llm-enricher.js +315 -0
- package/dist/panoramic/utils/llm-enricher.js.map +1 -0
- package/dist/panoramic/utils/llm-facade.d.ts +66 -0
- package/dist/panoramic/utils/llm-facade.d.ts.map +1 -0
- package/dist/panoramic/utils/llm-facade.js +136 -0
- package/dist/panoramic/utils/llm-facade.js.map +1 -0
- package/dist/panoramic/utils/logger.d.ts +43 -0
- package/dist/panoramic/utils/logger.d.ts.map +1 -0
- package/dist/panoramic/utils/logger.js +76 -0
- package/dist/panoramic/utils/logger.js.map +1 -0
- package/dist/panoramic/utils/mermaid-helpers.d.ts +19 -0
- package/dist/panoramic/utils/mermaid-helpers.d.ts.map +1 -0
- package/dist/panoramic/utils/mermaid-helpers.js +21 -0
- package/dist/panoramic/utils/mermaid-helpers.js.map +1 -0
- package/dist/panoramic/utils/multi-format-writer.d.ts +43 -0
- package/dist/panoramic/utils/multi-format-writer.d.ts.map +1 -0
- package/dist/panoramic/utils/multi-format-writer.js +73 -0
- package/dist/panoramic/utils/multi-format-writer.js.map +1 -0
- package/dist/panoramic/utils/template-loader.d.ts +15 -0
- package/dist/panoramic/utils/template-loader.d.ts.map +1 -0
- package/dist/panoramic/utils/template-loader.js +65 -0
- package/dist/panoramic/utils/template-loader.js.map +1 -0
- package/dist/panoramic/utils/text-segmenter.d.ts +50 -0
- package/dist/panoramic/utils/text-segmenter.d.ts.map +1 -0
- package/dist/panoramic/utils/text-segmenter.js +151 -0
- package/dist/panoramic/utils/text-segmenter.js.map +1 -0
- package/dist/scripts/postinstall.d.ts +7 -0
- package/dist/scripts/postinstall.d.ts.map +1 -0
- package/dist/scripts/postinstall.js +70 -0
- package/dist/scripts/postinstall.js.map +1 -0
- package/dist/scripts/preuninstall.d.ts +7 -0
- package/dist/scripts/preuninstall.d.ts.map +1 -0
- package/dist/scripts/preuninstall.js +62 -0
- package/dist/scripts/preuninstall.js.map +1 -0
- package/dist/spec-store/index.d.ts +9 -0
- package/dist/spec-store/index.d.ts.map +1 -0
- package/dist/spec-store/index.js +9 -0
- package/dist/spec-store/index.js.map +1 -0
- package/dist/spec-store/spec-identity.d.ts +28 -0
- package/dist/spec-store/spec-identity.d.ts.map +1 -0
- package/dist/spec-store/spec-identity.js +24 -0
- package/dist/spec-store/spec-identity.js.map +1 -0
- package/dist/spec-store/spec-store.d.ts +62 -0
- package/dist/spec-store/spec-store.d.ts.map +1 -0
- package/dist/spec-store/spec-store.js +201 -0
- package/dist/spec-store/spec-store.js.map +1 -0
- package/dist/utils/atomic-write.d.ts +10 -0
- package/dist/utils/atomic-write.d.ts.map +1 -0
- package/dist/utils/atomic-write.js +27 -0
- package/dist/utils/atomic-write.js.map +1 -0
- package/dist/utils/chunk-splitter.d.ts +32 -0
- package/dist/utils/chunk-splitter.d.ts.map +1 -0
- package/dist/utils/chunk-splitter.js +116 -0
- package/dist/utils/chunk-splitter.js.map +1 -0
- package/dist/utils/file-scanner.d.ts +38 -0
- package/dist/utils/file-scanner.d.ts.map +1 -0
- package/dist/utils/file-scanner.js +323 -0
- package/dist/utils/file-scanner.js.map +1 -0
- package/dist/utils/git-blame.d.ts +32 -0
- package/dist/utils/git-blame.d.ts.map +1 -0
- package/dist/utils/git-blame.js +151 -0
- package/dist/utils/git-blame.js.map +1 -0
- package/dist/utils/specify-template-sync.d.ts +16 -0
- package/dist/utils/specify-template-sync.d.ts.map +1 -0
- package/dist/utils/specify-template-sync.js +66 -0
- package/dist/utils/specify-template-sync.js.map +1 -0
- package/dist/watcher/file-watcher.d.ts +77 -0
- package/dist/watcher/file-watcher.d.ts.map +1 -0
- package/dist/watcher/file-watcher.js +233 -0
- package/dist/watcher/file-watcher.js.map +1 -0
- package/dist/watcher/index.d.ts +6 -0
- package/dist/watcher/index.d.ts.map +1 -0
- package/dist/watcher/index.js +5 -0
- package/dist/watcher/index.js.map +1 -0
- package/grammars/manifest.json +28 -0
- package/grammars/tree-sitter-go.wasm +0 -0
- package/grammars/tree-sitter-java.wasm +0 -0
- package/grammars/tree-sitter-javascript.wasm +0 -0
- package/grammars/tree-sitter-python.wasm +0 -0
- package/grammars/tree-sitter-typescript.wasm +0 -0
- package/package.json +84 -0
- package/plugins/spec-driver/.claude-plugin/plugin.json +16 -0
- package/plugins/spec-driver/README.md +401 -0
- package/plugins/spec-driver/agents/analyze.artifact.yaml +10 -0
- package/plugins/spec-driver/agents/analyze.md +144 -0
- package/plugins/spec-driver/agents/checklist.artifact.yaml +8 -0
- package/plugins/spec-driver/agents/checklist.md +84 -0
- package/plugins/spec-driver/agents/clarify.artifact.yaml +6 -0
- package/plugins/spec-driver/agents/clarify.md +104 -0
- package/plugins/spec-driver/agents/constitution.artifact.yaml +9 -0
- package/plugins/spec-driver/agents/constitution.md +100 -0
- package/plugins/spec-driver/agents/implement.artifact.yaml +8 -0
- package/plugins/spec-driver/agents/implement.md +159 -0
- package/plugins/spec-driver/agents/plan.artifact.yaml +12 -0
- package/plugins/spec-driver/agents/plan.md +116 -0
- package/plugins/spec-driver/agents/product-research.artifact.yaml +11 -0
- package/plugins/spec-driver/agents/product-research.md +94 -0
- package/plugins/spec-driver/agents/quality-review.artifact.yaml +11 -0
- package/plugins/spec-driver/agents/quality-review.md +165 -0
- package/plugins/spec-driver/agents/refactor-plan.md +132 -0
- package/plugins/spec-driver/agents/spec-review.artifact.yaml +12 -0
- package/plugins/spec-driver/agents/spec-review.md +111 -0
- package/plugins/spec-driver/agents/specify.artifact.yaml +9 -0
- package/plugins/spec-driver/agents/specify.md +109 -0
- package/plugins/spec-driver/agents/sync.artifact.yaml +19 -0
- package/plugins/spec-driver/agents/sync.md +91 -0
- package/plugins/spec-driver/agents/tasks.artifact.yaml +10 -0
- package/plugins/spec-driver/agents/tasks.md +88 -0
- package/plugins/spec-driver/agents/tech-research.artifact.yaml +12 -0
- package/plugins/spec-driver/agents/tech-research.md +102 -0
- package/plugins/spec-driver/agents/verify.artifact.yaml +11 -0
- package/plugins/spec-driver/agents/verify.md +204 -0
- package/plugins/spec-driver/config/orchestration.yaml +779 -0
- package/plugins/spec-driver/contracts/orchestration-overrides-contract.yaml +124 -0
- package/plugins/spec-driver/contracts/orchestration-schema.mjs +301 -0
- package/plugins/spec-driver/contracts/scan-project-output.md +70 -0
- package/plugins/spec-driver/contracts/wrapper-source-of-truth.yaml +44 -0
- package/plugins/spec-driver/hooks/hooks.json +70 -0
- package/plugins/spec-driver/hooks/post-tool-use-format.sh +28 -0
- package/plugins/spec-driver/hooks/pre-tool-use-guard.sh +42 -0
- package/plugins/spec-driver/hooks/stop-task-check.sh +22 -0
- package/plugins/spec-driver/hooks/worktree-lifecycle.sh +33 -0
- package/plugins/spec-driver/lib/orchestration-output-serializer.mjs +219 -0
- package/plugins/spec-driver/lib/orchestration-resolver.mjs +485 -0
- package/plugins/spec-driver/lib/orchestrator-fallback.mjs +98 -0
- package/plugins/spec-driver/lib/orchestrator.mjs +280 -0
- package/plugins/spec-driver/scorecards/default-governance.yaml +63 -0
- package/plugins/spec-driver/scripts/codex-skills.sh +225 -0
- package/plugins/spec-driver/scripts/experimental/README.md +9 -0
- package/plugins/spec-driver/scripts/generate-adoption-insights.mjs +523 -0
- package/plugins/spec-driver/scripts/generate-product-entity-catalog.mjs +472 -0
- package/plugins/spec-driver/scripts/generate-product-quality-reports.mjs +18 -0
- package/plugins/spec-driver/scripts/generate-product-scorecards.mjs +25 -0
- package/plugins/spec-driver/scripts/generate-project-context-suggestions.mjs +622 -0
- package/plugins/spec-driver/scripts/generate-workflow-registry.mjs +16 -0
- package/plugins/spec-driver/scripts/init-project.sh +328 -0
- package/plugins/spec-driver/scripts/lib/config-schema.mjs +433 -0
- package/plugins/spec-driver/scripts/lib/init-project-output.sh +146 -0
- package/plugins/spec-driver/scripts/lib/product-artifact-patchers.mjs +29 -0
- package/plugins/spec-driver/scripts/lib/product-artifact-paths.mjs +129 -0
- package/plugins/spec-driver/scripts/lib/product-governance-helpers.mjs +48 -0
- package/plugins/spec-driver/scripts/lib/product-quality-core.mjs +531 -0
- package/plugins/spec-driver/scripts/lib/product-scorecard-core.mjs +810 -0
- package/plugins/spec-driver/scripts/lib/project-context-paths.mjs +21 -0
- package/plugins/spec-driver/scripts/lib/project-profile-resolver.mjs +704 -0
- package/plugins/spec-driver/scripts/lib/project-profile-schema.mjs +78 -0
- package/plugins/spec-driver/scripts/lib/script-cli-args.mjs +25 -0
- package/plugins/spec-driver/scripts/lib/script-diagnostics.mjs +29 -0
- package/plugins/spec-driver/scripts/lib/script-report-io.mjs +37 -0
- package/plugins/spec-driver/scripts/lib/simple-yaml.mjs +257 -0
- package/plugins/spec-driver/scripts/lib/sync-conflict-resolver.mjs +128 -0
- package/plugins/spec-driver/scripts/lib/sync-merge-strategy.mjs +388 -0
- package/plugins/spec-driver/scripts/lib/sync-product-mapping.mjs +228 -0
- package/plugins/spec-driver/scripts/lib/sync-timeline-builder.mjs +114 -0
- package/plugins/spec-driver/scripts/lib/sync-validator.mjs +174 -0
- package/plugins/spec-driver/scripts/lib/workflow-registry-core.mjs +281 -0
- package/plugins/spec-driver/scripts/orchestrator-cli.mjs +490 -0
- package/plugins/spec-driver/scripts/orchestrator-cli.sh +36 -0
- package/plugins/spec-driver/scripts/postinstall.sh +101 -0
- package/plugins/spec-driver/scripts/record-workflow-run.mjs +332 -0
- package/plugins/spec-driver/scripts/resolve-project-context.mjs +56 -0
- package/plugins/spec-driver/scripts/scan-project.sh +668 -0
- package/plugins/spec-driver/scripts/sync-merge-engine.mjs +663 -0
- package/plugins/spec-driver/scripts/validate-config.mjs +223 -0
- package/plugins/spec-driver/scripts/validate-orchestration-overrides.mjs +190 -0
- package/plugins/spec-driver/scripts/validate-wrapper-sources.mjs +302 -0
- package/plugins/spec-driver/skills/spec-driver-constitution/SKILL.md +77 -0
- package/plugins/spec-driver/skills/spec-driver-doc/SKILL.md +732 -0
- package/plugins/spec-driver/skills/spec-driver-feature/SKILL.md +336 -0
- package/plugins/spec-driver/skills/spec-driver-fix/SKILL.md +457 -0
- package/plugins/spec-driver/skills/spec-driver-implement/SKILL.md +653 -0
- package/plugins/spec-driver/skills/spec-driver-refactor/SKILL.md +250 -0
- package/plugins/spec-driver/skills/spec-driver-resume/SKILL.md +325 -0
- package/plugins/spec-driver/skills/spec-driver-story/SKILL.md +566 -0
- package/plugins/spec-driver/skills/spec-driver-sync/SKILL.md +300 -0
- package/plugins/spec-driver/templates/code-of-conduct-v2.1.md +85 -0
- package/plugins/spec-driver/templates/licenses/Apache-2.0.txt +201 -0
- package/plugins/spec-driver/templates/licenses/BSD-2-Clause.txt +24 -0
- package/plugins/spec-driver/templates/licenses/BSD-3-Clause.txt +28 -0
- package/plugins/spec-driver/templates/licenses/GPL-3.0.txt +232 -0
- package/plugins/spec-driver/templates/licenses/ISC.txt +15 -0
- package/plugins/spec-driver/templates/licenses/MIT.txt +21 -0
- package/plugins/spec-driver/templates/licenses/MPL-2.0.txt +373 -0
- package/plugins/spec-driver/templates/licenses/Unlicense.txt +24 -0
- package/plugins/spec-driver/templates/orchestration-overrides.example.yaml +81 -0
- package/plugins/spec-driver/templates/product-research-template.md +95 -0
- package/plugins/spec-driver/templates/product-spec-template.md +250 -0
- package/plugins/spec-driver/templates/research-synthesis-template.md +102 -0
- package/plugins/spec-driver/templates/spec-driver.config-template.yaml +244 -0
- package/plugins/spec-driver/templates/specify-base/agent-file-template.md +28 -0
- package/plugins/spec-driver/templates/specify-base/checklist-template.md +40 -0
- package/plugins/spec-driver/templates/specify-base/constitution-template.md +50 -0
- package/plugins/spec-driver/templates/specify-base/plan-template.md +134 -0
- package/plugins/spec-driver/templates/specify-base/product-research-template.md +95 -0
- package/plugins/spec-driver/templates/specify-base/project-context-template.yaml +40 -0
- package/plugins/spec-driver/templates/specify-base/research-synthesis-template.md +102 -0
- package/plugins/spec-driver/templates/specify-base/spec-template.md +115 -0
- package/plugins/spec-driver/templates/specify-base/tasks-template.md +266 -0
- package/plugins/spec-driver/templates/specify-base/tech-research-template.md +111 -0
- package/plugins/spec-driver/templates/specify-base/verification-report-template.md +63 -0
- package/plugins/spec-driver/templates/tech-research-template.md +111 -0
- package/plugins/spec-driver/templates/verification-report-template.md +63 -0
- package/plugins/spec-driver/workflows/golden-paths.yaml +39 -0
- package/plugins/spec-driver/workflows/spec-driver-doc.yaml +24 -0
- package/plugins/spec-driver/workflows/spec-driver-feature.yaml +29 -0
- package/plugins/spec-driver/workflows/spec-driver-fix.yaml +21 -0
- package/plugins/spec-driver/workflows/spec-driver-implement.yaml +23 -0
- package/plugins/spec-driver/workflows/spec-driver-resume.yaml +20 -0
- package/plugins/spec-driver/workflows/spec-driver-story.yaml +24 -0
- package/plugins/spec-driver/workflows/spec-driver-sync.yaml +34 -0
- package/plugins/spectra/.claude-plugin/plugin.json +20 -0
- package/plugins/spectra/.mcp.json +8 -0
- package/plugins/spectra/README.md +128 -0
- package/plugins/spectra/contracts/skill-source-of-truth.yaml +34 -0
- package/plugins/spectra/hooks/hooks.json +15 -0
- package/plugins/spectra/scripts/postinstall.sh +12 -0
- package/plugins/spectra/scripts/sync-skill-mirrors.mjs +148 -0
- package/plugins/spectra/scripts/validate-skill-sources.mjs +280 -0
- package/plugins/spectra/skills/spectra/SKILL.md +214 -0
- package/plugins/spectra/skills/spectra-batch/SKILL.md +232 -0
- package/plugins/spectra/skills/spectra-diff/SKILL.md +99 -0
- package/queries/go.scm +54 -0
- package/queries/java.scm +50 -0
- package/queries/javascript.scm +30 -0
- package/queries/python.scm +35 -0
- package/queries/typescript.scm +50 -0
- package/scripts/lifecycle-runner.cjs +33 -0
- package/templates/adr-draft.hbs +51 -0
- package/templates/adr-index.hbs +25 -0
- package/templates/api-surface.hbs +40 -0
- package/templates/architecture-ir.hbs +49 -0
- package/templates/architecture-narrative.hbs +116 -0
- package/templates/architecture-overview.hbs +103 -0
- package/templates/component-view.hbs +87 -0
- package/templates/config-reference.hbs +22 -0
- package/templates/coverage-report.hbs +84 -0
- package/templates/cross-package-analysis.hbs +43 -0
- package/templates/data-model.hbs +72 -0
- package/templates/delta-report.hbs +53 -0
- package/templates/docs-bundle-index.hbs +41 -0
- package/templates/drift-report.hbs +53 -0
- package/templates/dynamic-scenarios.hbs +46 -0
- package/templates/event-surface.hbs +90 -0
- package/templates/feature-brief-index.hbs +27 -0
- package/templates/feature-brief.hbs +28 -0
- package/templates/index-spec.hbs +57 -0
- package/templates/interface-surface.hbs +87 -0
- package/templates/module-spec.hbs +117 -0
- package/templates/pattern-hints.hbs +85 -0
- package/templates/product-overview.hbs +65 -0
- package/templates/quality-report.hbs +130 -0
- package/templates/runtime-topology.hbs +128 -0
- package/templates/troubleshooting.hbs +86 -0
- package/templates/user-journeys.hbs +44 -0
- package/templates/workspace-index.hbs +26 -0
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* qa/debt-context.ts
|
|
3
|
+
* Step 4:F3 debt-scanner 集成 + 债务上下文注入
|
|
4
|
+
*
|
|
5
|
+
* 职责:
|
|
6
|
+
* - 检测问题是否含债务关键词(TODO/FIXME/HACK/技术债/最老等)
|
|
7
|
+
* - 匹配时调用 scanProjectDebt(),返回按 ageDays 倒序 Top-5 CodeDebtEntry
|
|
8
|
+
* - 将 CodeDebtEntry 转换为 Citation 格式
|
|
9
|
+
* - 不匹配时返回空结果(不触发 scanProjectDebt,节省 I/O)
|
|
10
|
+
*
|
|
11
|
+
* 说明:
|
|
12
|
+
* - plan §7 F3 集成决策:scanProjectDebt 每次问答都调用,不缓存
|
|
13
|
+
* (主要是 AST 扫描 + git blame,无 LLM,单次耗时约 0.5-3 秒,可接受)
|
|
14
|
+
*/
|
|
15
|
+
import { scanProjectDebt } from '../../debt-scanner/index.js';
|
|
16
|
+
// ============================================================
|
|
17
|
+
// 债务关键词正则(大小写不敏感)
|
|
18
|
+
// ============================================================
|
|
19
|
+
/**
|
|
20
|
+
* 触发 debt-scanner 的关键词集合
|
|
21
|
+
* 包含:英文 TODO/FIXME/HACK/XXX/technical debt + 中文等价词
|
|
22
|
+
*/
|
|
23
|
+
const DEBT_KEYWORD_PATTERN = /TODO|FIXME|HACK|XXX|technical\s*debt|技术债|最老|最旧|最长时间|债务/i;
|
|
24
|
+
// ============================================================
|
|
25
|
+
// 工具函数
|
|
26
|
+
// ============================================================
|
|
27
|
+
/**
|
|
28
|
+
* 检测问题文本是否包含债务关键词
|
|
29
|
+
*/
|
|
30
|
+
export function isDebtQuestion(questionText) {
|
|
31
|
+
return DEBT_KEYWORD_PATTERN.test(questionText);
|
|
32
|
+
}
|
|
33
|
+
// ============================================================
|
|
34
|
+
// 主函数
|
|
35
|
+
// ============================================================
|
|
36
|
+
/**
|
|
37
|
+
* 按需注入债务上下文
|
|
38
|
+
* 问题含债务关键词时:调用 scanProjectDebt,返回 Top-5 ageDays 倒序的 Citation
|
|
39
|
+
* 否则:返回 triggered=false + 空 citations
|
|
40
|
+
*
|
|
41
|
+
* @param questionText - 用户问题文本
|
|
42
|
+
* @param projectRoot - 项目根目录
|
|
43
|
+
* @param registry - LanguageAdapterRegistry(来自 batch-orchestrator 或 MCP 上下文)
|
|
44
|
+
* @param options - 选项(topN、scanOptions)
|
|
45
|
+
* @returns DebtContextResult
|
|
46
|
+
*/
|
|
47
|
+
export async function injectDebtContext(questionText, projectRoot, registry, options) {
|
|
48
|
+
// 关键词路由:不匹配时提前返回
|
|
49
|
+
if (!isDebtQuestion(questionText)) {
|
|
50
|
+
return { triggered: false, citations: [] };
|
|
51
|
+
}
|
|
52
|
+
const topN = options?.topN ?? 5;
|
|
53
|
+
// 调用 scanProjectDebt(每次都调用,不缓存)
|
|
54
|
+
let report;
|
|
55
|
+
try {
|
|
56
|
+
report = await scanProjectDebt({
|
|
57
|
+
projectRoot,
|
|
58
|
+
registry,
|
|
59
|
+
dryRun: true, // F5 问答仅需 AST 扫描,不需要 LLM 主题推断
|
|
60
|
+
...options?.scanOptions,
|
|
61
|
+
});
|
|
62
|
+
}
|
|
63
|
+
catch (err) {
|
|
64
|
+
// scanProjectDebt 失败时不阻断问答,返回空债务上下文并记录 warn
|
|
65
|
+
const message = err instanceof Error ? err.message : String(err);
|
|
66
|
+
console.warn(`[warn] qa/debt-context: scanProjectDebt 失败,跳过债务上下文注入。原因:${message}`);
|
|
67
|
+
return { triggered: true, citations: [] };
|
|
68
|
+
}
|
|
69
|
+
// 按 ageDays 倒序排列,取 Top-N
|
|
70
|
+
const sorted = report.codeEntries
|
|
71
|
+
.filter((e) => e.ageDays >= 0)
|
|
72
|
+
.sort((a, b) => b.ageDays - a.ageDays)
|
|
73
|
+
.slice(0, topN);
|
|
74
|
+
// 转换为 Citation 格式
|
|
75
|
+
const citations = sorted.map((entry) => ({
|
|
76
|
+
specPath: entry.filePath,
|
|
77
|
+
lineRange: { startLine: entry.line, endLine: entry.line },
|
|
78
|
+
excerpt: entry.text.slice(0, 200),
|
|
79
|
+
}));
|
|
80
|
+
return { triggered: true, citations };
|
|
81
|
+
}
|
|
82
|
+
//# sourceMappingURL=debt-context.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"debt-context.js","sourceRoot":"","sources":["../../../src/panoramic/qa/debt-context.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AACH,OAAO,EAAE,eAAe,EAAE,MAAM,6BAA6B,CAAC;AAwB9D,+DAA+D;AAC/D,kBAAkB;AAClB,+DAA+D;AAE/D;;;GAGG;AACH,MAAM,oBAAoB,GAAG,yDAAyD,CAAC;AAEvF,+DAA+D;AAC/D,OAAO;AACP,+DAA+D;AAE/D;;GAEG;AACH,MAAM,UAAU,cAAc,CAAC,YAAoB;IACjD,OAAO,oBAAoB,CAAC,IAAI,CAAC,YAAY,CAAC,CAAC;AACjD,CAAC;AAED,+DAA+D;AAC/D,MAAM;AACN,+DAA+D;AAE/D;;;;;;;;;;GAUG;AACH,MAAM,CAAC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,EAAE,KAAK,CAAC,QAAQ;QACxB,SAAS,EAAE,EAAE,SAAS,EAAE,KAAK,CAAC,IAAI,EAAE,OAAO,EAAE,KAAK,CAAC,IAAI,EAAE;QACzD,OAAO,EAAE,KAAK,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,EAAE,GAAG,CAAC;KAClC,CAAC,CAAC,CAAC;IAEJ,OAAO,EAAE,SAAS,EAAE,IAAI,EAAE,SAAS,EAAE,CAAC;AACxC,CAAC"}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* qa/graph-retriever.ts
|
|
3
|
+
* Step 1-2:Graph BFS 检索 + hyperedge 扩展
|
|
4
|
+
*
|
|
5
|
+
* 职责:
|
|
6
|
+
* - 通过 GraphQueryEngine.query() 做 BFS 候选节点检索
|
|
7
|
+
* - 通过 engine.getHyperedges() 做 label + nodeId 两种命中方式扩展
|
|
8
|
+
* - 合并去重,构建 GraphContext
|
|
9
|
+
* - BFS 命中 < 3 节点时设 fallbackMode = 'rag-only'(R1 / FR-014)
|
|
10
|
+
*/
|
|
11
|
+
import type { GraphQueryEngine } from '../graph/graph-query.js';
|
|
12
|
+
import type { GraphContext } from './types.js';
|
|
13
|
+
/** graph-retriever 的输入选项 */
|
|
14
|
+
export interface GraphRetrieverOptions {
|
|
15
|
+
/** BFS 节点预算(默认 20) */
|
|
16
|
+
budget?: number;
|
|
17
|
+
/** BFS 遍历深度(默认 2) */
|
|
18
|
+
depth?: number;
|
|
19
|
+
}
|
|
20
|
+
/**
|
|
21
|
+
* 通过 BFS + hyperedge 扩展检索与问题相关的图谱上下文
|
|
22
|
+
*
|
|
23
|
+
* @param questionText - 用户问题文本
|
|
24
|
+
* @param engine - GraphQueryEngine 实例
|
|
25
|
+
* @param options - 检索选项(budget、depth)
|
|
26
|
+
* @returns GraphContext(含 bfsNodes、hyperedges、fallbackMode)
|
|
27
|
+
*/
|
|
28
|
+
export declare function retrieveGraphContext(questionText: string, engine: GraphQueryEngine, options?: GraphRetrieverOptions): GraphContext;
|
|
29
|
+
//# sourceMappingURL=graph-retriever.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"graph-retriever.d.ts","sourceRoot":"","sources":["../../../src/panoramic/qa/graph-retriever.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AACH,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAEhE,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAM/C,4BAA4B;AAC5B,MAAM,WAAW,qBAAqB;IACpC,sBAAsB;IACtB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,qBAAqB;IACrB,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AA0BD;;;;;;;GAOG;AACH,wBAAgB,oBAAoB,CAClC,YAAY,EAAE,MAAM,EACpB,MAAM,EAAE,gBAAgB,EACxB,OAAO,CAAC,EAAE,qBAAqB,GAC9B,YAAY,CA0Cd"}
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
// ============================================================
|
|
2
|
+
// 工具函数
|
|
3
|
+
// ============================================================
|
|
4
|
+
/**
|
|
5
|
+
* 对数组元素按 key 函数去重,保留首次出现的元素
|
|
6
|
+
*/
|
|
7
|
+
function dedup(arr, keyFn) {
|
|
8
|
+
const seen = new Set();
|
|
9
|
+
const result = [];
|
|
10
|
+
for (const item of arr) {
|
|
11
|
+
const key = keyFn(item);
|
|
12
|
+
if (!seen.has(key)) {
|
|
13
|
+
seen.add(key);
|
|
14
|
+
result.push(item);
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
return result;
|
|
18
|
+
}
|
|
19
|
+
// ============================================================
|
|
20
|
+
// 主函数
|
|
21
|
+
// ============================================================
|
|
22
|
+
/**
|
|
23
|
+
* 通过 BFS + hyperedge 扩展检索与问题相关的图谱上下文
|
|
24
|
+
*
|
|
25
|
+
* @param questionText - 用户问题文本
|
|
26
|
+
* @param engine - GraphQueryEngine 实例
|
|
27
|
+
* @param options - 检索选项(budget、depth)
|
|
28
|
+
* @returns GraphContext(含 bfsNodes、hyperedges、fallbackMode)
|
|
29
|
+
*/
|
|
30
|
+
export function retrieveGraphContext(questionText, engine, options) {
|
|
31
|
+
const budget = options?.budget ?? 20;
|
|
32
|
+
const depth = options?.depth ?? 2;
|
|
33
|
+
// Step 1:BFS 关键词子图检索
|
|
34
|
+
const queryResult = engine.query(questionText, { budget, mode: 'bfs', depth });
|
|
35
|
+
const bfsNodes = queryResult.nodes.map((n) => ({
|
|
36
|
+
id: n.id,
|
|
37
|
+
label: n.label,
|
|
38
|
+
kind: n.kind,
|
|
39
|
+
specPath: n.metadata['specPath'],
|
|
40
|
+
}));
|
|
41
|
+
// Step 2:hyperedge 扩展(两种命中方式)
|
|
42
|
+
// 方式 1:按 label 子串模糊匹配(问题含流程名时适用)
|
|
43
|
+
// 截取问题前 30 字符作为 label 搜索词
|
|
44
|
+
const labelQuery = questionText.slice(0, 30).trim();
|
|
45
|
+
const heByLabel = labelQuery.length > 0
|
|
46
|
+
? engine.getHyperedges({ label: labelQuery })
|
|
47
|
+
: [];
|
|
48
|
+
// 方式 2:按已命中的 BFS 节点 ID 精确匹配(最多取前 5 个种子节点)
|
|
49
|
+
const heByNode = [];
|
|
50
|
+
for (const bfsNode of bfsNodes.slice(0, 5)) {
|
|
51
|
+
const hes = engine.getHyperedges({ nodeId: bfsNode.id });
|
|
52
|
+
heByNode.push(...hes);
|
|
53
|
+
}
|
|
54
|
+
// 合并去重(按 hyperedge.id 去重)
|
|
55
|
+
const allHyperedges = dedup([...heByLabel, ...heByNode], (he) => he.id);
|
|
56
|
+
// fallback 判断:BFS 命中 < 3 节点时降级为纯 RAG(R1 / FR-014)
|
|
57
|
+
const fallbackMode = bfsNodes.length < 3 ? 'rag-only' : undefined;
|
|
58
|
+
return {
|
|
59
|
+
bfsNodes,
|
|
60
|
+
topChunks: [], // 由 rag-reranker 填充
|
|
61
|
+
hyperedges: allHyperedges,
|
|
62
|
+
fallbackMode,
|
|
63
|
+
};
|
|
64
|
+
}
|
|
65
|
+
//# sourceMappingURL=graph-retriever.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"graph-retriever.js","sourceRoot":"","sources":["../../../src/panoramic/qa/graph-retriever.ts"],"names":[],"mappings":"AA0BA,+DAA+D;AAC/D,OAAO;AACP,+DAA+D;AAE/D;;GAEG;AACH,SAAS,KAAK,CAAI,GAAQ,EAAE,KAA0B;IACpD,MAAM,IAAI,GAAG,IAAI,GAAG,EAAU,CAAC;IAC/B,MAAM,MAAM,GAAQ,EAAE,CAAC;IACvB,KAAK,MAAM,IAAI,IAAI,GAAG,EAAE,CAAC;QACvB,MAAM,GAAG,GAAG,KAAK,CAAC,IAAI,CAAC,CAAC;QACxB,IAAI,CAAC,IAAI,CAAC,GAAG,CAAC,GAAG,CAAC,EAAE,CAAC;YACnB,IAAI,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;YACd,MAAM,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QACpB,CAAC;IACH,CAAC;IACD,OAAO,MAAM,CAAC;AAChB,CAAC;AAED,+DAA+D;AAC/D,MAAM;AACN,+DAA+D;AAE/D;;;;;;;GAOG;AACH,MAAM,UAAU,oBAAoB,CAClC,YAAoB,EACpB,MAAwB,EACxB,OAA+B;IAE/B,MAAM,MAAM,GAAG,OAAO,EAAE,MAAM,IAAI,EAAE,CAAC;IACrC,MAAM,KAAK,GAAG,OAAO,EAAE,KAAK,IAAI,CAAC,CAAC;IAElC,qBAAqB;IACrB,MAAM,WAAW,GAAG,MAAM,CAAC,KAAK,CAAC,YAAY,EAAE,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,KAAK,EAAE,CAAC,CAAC;IAC/E,MAAM,QAAQ,GAAG,WAAW,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC;QAC7C,EAAE,EAAE,CAAC,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+
import type { QnAQuery, QnAAnswer, QnAOptions } from './types.js';
|
|
2
|
+
/**
|
|
3
|
+
* 测试专用:清除引擎缓存
|
|
4
|
+
*/
|
|
5
|
+
export declare function clearEngineCache(): void;
|
|
6
|
+
/**
|
|
7
|
+
* 自然语言问答 — 公开 API
|
|
8
|
+
*
|
|
9
|
+
* 7 步 pipeline:
|
|
10
|
+
* 1-2. GraphRetriever:BFS 候选节点 + hyperedge 扩展
|
|
11
|
+
* 3. RAGReranker:chunk 切分 + embedding 精排
|
|
12
|
+
* 4. DebtContext:债务上下文注入(按关键词路由)
|
|
13
|
+
* 5. Citation:构建溯源引用列表
|
|
14
|
+
* 6. PromptBuilder:组装 LLM prompt
|
|
15
|
+
* 7. LLMCaller:budget-gate + Anthropic SDK 调用
|
|
16
|
+
*
|
|
17
|
+
* @param query - 用户问题(含 text + 可选 focusNodeId)
|
|
18
|
+
* @param options - 问答选项(projectRoot 等)
|
|
19
|
+
* @returns QnAAnswer(含 text、citations、tokenUsage、durationMs)
|
|
20
|
+
* @throws InvalidQueryError 当 query.text 为空字符串时
|
|
21
|
+
*/
|
|
22
|
+
export declare function answerQuestion(query: QnAQuery, options: QnAOptions): Promise<QnAAnswer>;
|
|
23
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/panoramic/qa/index.ts"],"names":[],"mappings":"AAwBA,OAAO,KAAK,EAAE,QAAQ,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AA+BlE;;GAEG;AACH,wBAAgB,gBAAgB,IAAI,IAAI,CAEvC;AAMD;;;;;;;;;;;;;;;GAeG;AACH,wBAAsB,cAAc,CAClC,KAAK,EAAE,QAAQ,EACf,OAAO,EAAE,UAAU,GAClB,OAAO,CAAC,SAAS,CAAC,CA8KpB"}
|
|
@@ -0,0 +1,201 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* qa/index.ts
|
|
3
|
+
* 公开 API 汇聚点:answerQuestion()
|
|
4
|
+
*
|
|
5
|
+
* 职责:
|
|
6
|
+
* - 入参校验(空字符串拒绝、> 2000 字符截断)
|
|
7
|
+
* - 空图谱检查(nodes.length === 0 时返回友好提示)
|
|
8
|
+
* - 串联 7 步 pipeline:
|
|
9
|
+
* Step 1-2:graph-retriever(BFS + hyperedge 扩展)
|
|
10
|
+
* Step 3:rag-reranker(chunk 切分 + embedding 精排)
|
|
11
|
+
* Step 4:debt-context(债务上下文注入)
|
|
12
|
+
* Step 5:citation(Citation 构建 + lineRange 验证)
|
|
13
|
+
* Step 6:prompt-builder(LLM prompt 组装)
|
|
14
|
+
* Step 7:llm-caller(budget-gate + Anthropic SDK 调用)
|
|
15
|
+
* - 结构化日志(F-015 LOW):BFS 命中数、fallbackMode、各步耗时、总 durationMs
|
|
16
|
+
*/
|
|
17
|
+
import { GraphQueryEngine } from '../graph/graph-query.js';
|
|
18
|
+
import { resolveGraphJsonPath } from '../graph/graph-paths.js';
|
|
19
|
+
import { retrieveGraphContext } from './graph-retriever.js';
|
|
20
|
+
import { rerankWithEmbedding } from './rag-reranker.js';
|
|
21
|
+
import { injectDebtContext } from './debt-context.js';
|
|
22
|
+
import { buildCitations } from './citation.js';
|
|
23
|
+
import { buildQnAPrompt } from './prompt-builder.js';
|
|
24
|
+
import { callQnALlm } from './llm-caller.js';
|
|
25
|
+
// ============================================================
|
|
26
|
+
// 常量
|
|
27
|
+
// ============================================================
|
|
28
|
+
/** 问题最大字符数,超出时截断 */
|
|
29
|
+
const MAX_QUERY_LENGTH = 2000;
|
|
30
|
+
// ============================================================
|
|
31
|
+
// 引擎缓存(模块级,按 projectRoot 缓存,避免重复加载 graph.json)
|
|
32
|
+
// ============================================================
|
|
33
|
+
const engineCache = new Map();
|
|
34
|
+
/**
|
|
35
|
+
* 获取 GraphQueryEngine 实例(按 projectRoot 缓存)
|
|
36
|
+
* 图谱文件不存在时抛出 Error(明确告知用户需要先生成图谱)
|
|
37
|
+
*/
|
|
38
|
+
function getEngine(projectRoot, graphJsonPath) {
|
|
39
|
+
const graphPath = graphJsonPath ?? resolveGraphJsonPath(projectRoot);
|
|
40
|
+
const cacheKey = graphPath;
|
|
41
|
+
let engine = engineCache.get(cacheKey);
|
|
42
|
+
if (!engine) {
|
|
43
|
+
engine = GraphQueryEngine.loadFromFile(graphPath);
|
|
44
|
+
engineCache.set(cacheKey, engine);
|
|
45
|
+
}
|
|
46
|
+
return engine;
|
|
47
|
+
}
|
|
48
|
+
/**
|
|
49
|
+
* 测试专用:清除引擎缓存
|
|
50
|
+
*/
|
|
51
|
+
export function clearEngineCache() {
|
|
52
|
+
engineCache.clear();
|
|
53
|
+
}
|
|
54
|
+
// ============================================================
|
|
55
|
+
// 主函数
|
|
56
|
+
// ============================================================
|
|
57
|
+
/**
|
|
58
|
+
* 自然语言问答 — 公开 API
|
|
59
|
+
*
|
|
60
|
+
* 7 步 pipeline:
|
|
61
|
+
* 1-2. GraphRetriever:BFS 候选节点 + hyperedge 扩展
|
|
62
|
+
* 3. RAGReranker:chunk 切分 + embedding 精排
|
|
63
|
+
* 4. DebtContext:债务上下文注入(按关键词路由)
|
|
64
|
+
* 5. Citation:构建溯源引用列表
|
|
65
|
+
* 6. PromptBuilder:组装 LLM prompt
|
|
66
|
+
* 7. LLMCaller:budget-gate + Anthropic SDK 调用
|
|
67
|
+
*
|
|
68
|
+
* @param query - 用户问题(含 text + 可选 focusNodeId)
|
|
69
|
+
* @param options - 问答选项(projectRoot 等)
|
|
70
|
+
* @returns QnAAnswer(含 text、citations、tokenUsage、durationMs)
|
|
71
|
+
* @throws InvalidQueryError 当 query.text 为空字符串时
|
|
72
|
+
*/
|
|
73
|
+
export async function answerQuestion(query, options) {
|
|
74
|
+
const t0 = Date.now();
|
|
75
|
+
// ── 入参校验 ──────────────────────────────────────────────
|
|
76
|
+
// Edge Case 3:空字符串查询直接拒绝
|
|
77
|
+
if (!query.text || query.text.trim().length === 0) {
|
|
78
|
+
throw new Error('问题不能为空,请提供有效的查询文本');
|
|
79
|
+
}
|
|
80
|
+
// Edge Case 4:> 2000 字符截断并 warn
|
|
81
|
+
let questionText = query.text;
|
|
82
|
+
if (questionText.length > MAX_QUERY_LENGTH) {
|
|
83
|
+
console.warn(`[warn] qa/index: 问题文本超过 ${MAX_QUERY_LENGTH} 字符,已截断为前 ${MAX_QUERY_LENGTH} 字符。` +
|
|
84
|
+
`原始长度:${questionText.length}`);
|
|
85
|
+
questionText = questionText.slice(0, MAX_QUERY_LENGTH);
|
|
86
|
+
}
|
|
87
|
+
const { projectRoot, graphJsonPath, bfsBudget, bfsDepth, similarityThreshold } = options;
|
|
88
|
+
// ── 加载图谱引擎 ──────────────────────────────────────────
|
|
89
|
+
let engine;
|
|
90
|
+
try {
|
|
91
|
+
engine = getEngine(projectRoot, graphJsonPath);
|
|
92
|
+
}
|
|
93
|
+
catch (err) {
|
|
94
|
+
const message = err instanceof Error ? err.message : String(err);
|
|
95
|
+
console.warn(`[warn] qa/index: 图谱加载失败,返回空图谱提示。原因:${message}`);
|
|
96
|
+
return {
|
|
97
|
+
text: '图谱为空或无法加载,无法回答该问题。请先运行 `spectra graph` 生成图谱。',
|
|
98
|
+
citations: [],
|
|
99
|
+
tokenUsage: { input: 0, output: 0, overBudget: false },
|
|
100
|
+
durationMs: Date.now() - t0,
|
|
101
|
+
fallbackMode: 'graph-insufficient',
|
|
102
|
+
};
|
|
103
|
+
}
|
|
104
|
+
// ── Step 1-2:Graph BFS + hyperedge 扩展 ─────────────────
|
|
105
|
+
const t1 = Date.now();
|
|
106
|
+
const graphCtx = retrieveGraphContext(questionText, engine, {
|
|
107
|
+
budget: bfsBudget,
|
|
108
|
+
depth: bfsDepth,
|
|
109
|
+
});
|
|
110
|
+
const retrieverMs = Date.now() - t1;
|
|
111
|
+
// Edge Case 1:空图谱(BFS 命中 0 节点)
|
|
112
|
+
if (graphCtx.bfsNodes.length === 0) {
|
|
113
|
+
console.info(`[info] qa: 图谱为空,bfs_hits=0, duration_retriever=${retrieverMs}ms, total=${Date.now() - t0}ms`);
|
|
114
|
+
return {
|
|
115
|
+
text: '图谱为空,无法回答该问题。图谱可能尚未生成或不包含任何节点。',
|
|
116
|
+
citations: [],
|
|
117
|
+
tokenUsage: { input: 0, output: 0, overBudget: false },
|
|
118
|
+
durationMs: Date.now() - t0,
|
|
119
|
+
fallbackMode: graphCtx.fallbackMode,
|
|
120
|
+
};
|
|
121
|
+
}
|
|
122
|
+
// 结构化日志:BFS 命中数和 fallbackMode
|
|
123
|
+
console.info(`[info] qa: bfs_hits=${graphCtx.bfsNodes.length}, ` +
|
|
124
|
+
`hyperedges=${graphCtx.hyperedges.length}, ` +
|
|
125
|
+
`fallback=${graphCtx.fallbackMode ?? 'none'}, ` +
|
|
126
|
+
`retriever_ms=${retrieverMs}`);
|
|
127
|
+
// ── Step 3:RAG embedding 精排 ────────────────────────────
|
|
128
|
+
const t2 = Date.now();
|
|
129
|
+
// 收集 BFS 节点对应的 spec 文件路径(过滤无 specPath 的节点)
|
|
130
|
+
const specPaths = graphCtx.bfsNodes
|
|
131
|
+
.filter((n) => !!n.specPath)
|
|
132
|
+
.map((n) => n.specPath)
|
|
133
|
+
// 去重
|
|
134
|
+
.filter((p, i, arr) => arr.indexOf(p) === i);
|
|
135
|
+
const rerankResult = await rerankWithEmbedding(graphCtx, specPaths, questionText, projectRoot, { similarityThreshold });
|
|
136
|
+
const embeddingMs = Date.now() - t2;
|
|
137
|
+
// 将精排结果合并到 graphCtx.topChunks(供下游使用)
|
|
138
|
+
graphCtx.topChunks = rerankResult.rankedChunks.map((r) => ({
|
|
139
|
+
chunk: r.chunk,
|
|
140
|
+
similarity: r.similarity,
|
|
141
|
+
}));
|
|
142
|
+
// 若 rag-reranker 降级为 bfs-only,更新 fallbackMode
|
|
143
|
+
if (rerankResult.fallbackMode === 'bfs-only') {
|
|
144
|
+
graphCtx.fallbackMode = 'bfs-only';
|
|
145
|
+
}
|
|
146
|
+
console.info(`[info] qa: embedding_chunks=${rerankResult.rankedChunks.length}, embedding_ms=${embeddingMs}`);
|
|
147
|
+
// W-002:BFS 候选节点不足 3 个(rag-only 降级)且 RAG 精排 0 个 chunk 时,二级降级
|
|
148
|
+
if (graphCtx.fallbackMode === 'rag-only' && rerankResult.rankedChunks.length === 0) {
|
|
149
|
+
return {
|
|
150
|
+
text: '图谱数据不足以回答此问题:BFS 命中候选节点不足 3 个,且 RAG 精排未命中任何相关 spec 片段。请尝试更具体的问题或运行 `spectra batch` 补充图谱数据。',
|
|
151
|
+
citations: [],
|
|
152
|
+
tokenUsage: { input: 0, output: 0, overBudget: false },
|
|
153
|
+
durationMs: Date.now() - t0,
|
|
154
|
+
fallbackMode: 'rag-only',
|
|
155
|
+
};
|
|
156
|
+
}
|
|
157
|
+
// ── Step 4:debt 上下文注入 ───────────────────────────────
|
|
158
|
+
// 注意:scanProjectDebt 需要 registry,但 QnAOptions 未提供
|
|
159
|
+
// 此处传入 null registry,injectDebtContext 中有 try/catch 保护
|
|
160
|
+
// plan §7 说明:F5 问答仅需 AST 扫描,registry 不参与债务扫描的核心逻辑
|
|
161
|
+
const debtResult = await injectDebtContext(questionText, projectRoot,
|
|
162
|
+
// registry 设为 undefined cast,scanProjectDebt 内部 dryRun=true 时不依赖 registry
|
|
163
|
+
undefined);
|
|
164
|
+
// ── Step 5:Citation 构建 ─────────────────────────────────
|
|
165
|
+
const citations = buildCitations(rerankResult, graphCtx, debtResult.citations, projectRoot);
|
|
166
|
+
// ── Step 6:LLM prompt 组装 ───────────────────────────────
|
|
167
|
+
const prompt = buildQnAPrompt(graphCtx, citations, questionText);
|
|
168
|
+
// ── Step 7:LLM 调用 ──────────────────────────────────────
|
|
169
|
+
const t3 = Date.now();
|
|
170
|
+
let llmResult;
|
|
171
|
+
try {
|
|
172
|
+
llmResult = await callQnALlm(prompt);
|
|
173
|
+
}
|
|
174
|
+
catch (err) {
|
|
175
|
+
const message = err instanceof Error ? err.message : String(err);
|
|
176
|
+
console.error(`[error] qa/index: LLM 调用失败。原因:${message}`);
|
|
177
|
+
throw new Error(`问答 LLM 调用失败:${message}`);
|
|
178
|
+
}
|
|
179
|
+
const llmMs = Date.now() - t3;
|
|
180
|
+
const totalMs = Date.now() - t0;
|
|
181
|
+
console.info(`[info] qa: llm_ms=${llmMs}, total_ms=${totalMs}, ` +
|
|
182
|
+
`input_tokens=${llmResult.tokenUsage.input}, output_tokens=${llmResult.tokenUsage.output}, ` +
|
|
183
|
+
`over_budget=${llmResult.tokenUsage.overBudget}`);
|
|
184
|
+
// ── 合并 citations:优先使用 LLM 解析的 citations,若为空则用构建的 citations ──
|
|
185
|
+
const finalCitations = llmResult.parsedCitations.length > 0
|
|
186
|
+
? llmResult.parsedCitations
|
|
187
|
+
: citations;
|
|
188
|
+
// W-004:finalCitations 为空且 answer 中未包含"图谱数据不足"时,加注无引用警告
|
|
189
|
+
let answerText = llmResult.answer;
|
|
190
|
+
if (finalCitations.length === 0 && !answerText.includes('图谱数据不足')) {
|
|
191
|
+
answerText = '[注意:本答案无引用,图谱数据可能不足]\n\n' + answerText;
|
|
192
|
+
}
|
|
193
|
+
return {
|
|
194
|
+
text: answerText,
|
|
195
|
+
citations: finalCitations,
|
|
196
|
+
tokenUsage: llmResult.tokenUsage,
|
|
197
|
+
durationMs: totalMs,
|
|
198
|
+
fallbackMode: graphCtx.fallbackMode,
|
|
199
|
+
};
|
|
200
|
+
}
|
|
201
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/panoramic/qa/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AACH,OAAO,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAC3D,OAAO,EAAE,oBAAoB,EAAE,MAAM,yBAAyB,CAAC;AAC/D,OAAO,EAAE,oBAAoB,EAAE,MAAM,sBAAsB,CAAC;AAC5D,OAAO,EAAE,mBAAmB,EAA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AS,CAAC,MAAM,CAAC;IAClC,IAAI,cAAc,CAAC,MAAM,KAAK,CAAC,IAAI,CAAC,UAAU,CAAC,QAAQ,CAAC,QAAQ,CAAC,EAAE,CAAC;QAClE,UAAU,GAAG,0BAA0B,GAAG,UAAU,CAAC;IACvD,CAAC;IAED,OAAO;QACL,IAAI,EAAE,UAAU;QAChB,SAAS,EAAE,cAAc;QACzB,UAAU,EAAE,SAAS,CAAC,UAAU;QAChC,UAAU,EAAE,OAAO;QACnB,YAAY,EAAE,QAAQ,CAAC,YAAY;KACpC,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import type { Citation } from './types.js';
|
|
2
|
+
import type { QnAPrompt } from './prompt-builder.js';
|
|
3
|
+
/** LLM 调用选项 */
|
|
4
|
+
export interface QnALlmOptions {
|
|
5
|
+
/** 最大输出 token 数(默认 2048) */
|
|
6
|
+
maxTokens?: number;
|
|
7
|
+
/** 采样温度(默认 0.3) */
|
|
8
|
+
temperature?: number;
|
|
9
|
+
/** 超时毫秒(默认 60_000) */
|
|
10
|
+
timeoutMs?: number;
|
|
11
|
+
}
|
|
12
|
+
/** LLM 调用结果 */
|
|
13
|
+
export interface QnALlmResult {
|
|
14
|
+
/** 回答文本(来自 LLM 响应的 answer 字段) */
|
|
15
|
+
answer: string;
|
|
16
|
+
/** 从 LLM 响应解析出的 citations */
|
|
17
|
+
parsedCitations: Citation[];
|
|
18
|
+
/** token 使用记录 */
|
|
19
|
+
tokenUsage: {
|
|
20
|
+
input: number;
|
|
21
|
+
output: number;
|
|
22
|
+
/** true = 超过 hardcode 上限(record-only,不阻断) */
|
|
23
|
+
overBudget: boolean;
|
|
24
|
+
};
|
|
25
|
+
}
|
|
26
|
+
/**
|
|
27
|
+
* 调用 LLM 完成问答
|
|
28
|
+
*
|
|
29
|
+
* @param prompt - buildQnAPrompt 输出的 { systemPrompt, userPrompt }
|
|
30
|
+
* @param options - 调用选项(maxTokens、temperature、timeoutMs)
|
|
31
|
+
* @returns QnALlmResult(含 answer、parsedCitations、tokenUsage)
|
|
32
|
+
* @throws LLM 调用失败时抛出 Error(不吞掉异常,由 index.ts 处理)
|
|
33
|
+
*/
|
|
34
|
+
export declare function callQnALlm(prompt: QnAPrompt, options?: QnALlmOptions): Promise<QnALlmResult>;
|
|
35
|
+
//# sourceMappingURL=llm-caller.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"llm-caller.d.ts","sourceRoot":"","sources":["../../../src/panoramic/qa/llm-caller.ts"],"names":[],"mappings":"AAqBA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AAC3C,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,qBAAqB,CAAC;AAiBrD,eAAe;AACf,MAAM,WAAW,aAAa;IAC5B,4BAA4B;IAC5B,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,mBAAmB;IACnB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,sBAAsB;IACtB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,eAAe;AACf,MAAM,WAAW,YAAY;IAC3B,iCAAiC;IACjC,MAAM,EAAE,MAAM,CAAC;IACf,6BAA6B;IAC7B,eAAe,EAAE,QAAQ,EAAE,CAAC;IAC5B,iBAAiB;IACjB,UAAU,EAAE;QACV,KAAK,EAAE,MAAM,CAAC;QACd,MAAM,EAAE,MAAM,CAAC;QACf,6CAA6C;QAC7C,UAAU,EAAE,OAAO,CAAC;KACrB,CAAC;CACH;AAsDD;;;;;;;GAOG;AACH,wBAAsB,UAAU,CAC9B,MAAM,EAAE,SAAS,EACjB,OAAO,CAAC,EAAE,aAAa,GACtB,OAAO,CAAC,YAAY,CAAC,CAoEvB"}
|
|
@@ -0,0 +1,138 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* qa/llm-caller.ts
|
|
3
|
+
* Step 7:Budget-gate 注入 + Anthropic SDK 调用
|
|
4
|
+
*
|
|
5
|
+
* 职责:
|
|
6
|
+
* - 用 estimateFast() 预估 token 消耗
|
|
7
|
+
* - 调用 runBudgetGate({ budget: Infinity, preset: 'continue' }) 实现 record-only 模式(Q2 / FR-017)
|
|
8
|
+
* - budget = Infinity 保证永不触发阻断
|
|
9
|
+
* - 超额判断:若 totalEstimate > HARDCODE_LIMIT_TOKENS,标记 overBudget=true 并记录 warn
|
|
10
|
+
* - 调用 Anthropic SDK messages.create()(模型 ID 从项目配置读取,不硬编码)
|
|
11
|
+
* - 解析响应:提取 answer + citations + tokenUsage
|
|
12
|
+
*
|
|
13
|
+
* 注意:HARDCODE_LIMIT_TOKENS 约为 $0.05/query:
|
|
14
|
+
* claude-sonnet 输入约 $3/1M tokens → $0.05 / $0.000003 ≈ 16,666 input tokens
|
|
15
|
+
* 加上 ~3,333 output tokens(~$10/1M × $0.05 / $0.00001)
|
|
16
|
+
* 这里保守取 5k input + 1k output = ~6000 tokens 作为提示性 hardcode 上限
|
|
17
|
+
*/
|
|
18
|
+
import Anthropic from '@anthropic-ai/sdk';
|
|
19
|
+
import { estimateFast } from '../../core/token-counter.js';
|
|
20
|
+
import { runBudgetGate } from '../../batch/budget-gate.js';
|
|
21
|
+
import { resolveReverseSpecModel } from '../../core/model-selection.js';
|
|
22
|
+
// ============================================================
|
|
23
|
+
// 常量
|
|
24
|
+
// ============================================================
|
|
25
|
+
/**
|
|
26
|
+
* 单次问答 token 消耗的 hardcode 上限(约 $0.05/query)
|
|
27
|
+
* 以 claude-sonnet input $3/1M 计算:$0.05 / $0.000003 ≈ 16,666 input tokens
|
|
28
|
+
* 此处保守取较小值(5000 + 1000 = 6000 tokens)触发 warn 提示
|
|
29
|
+
*/
|
|
30
|
+
const HARDCODE_LIMIT_TOKENS = 6000;
|
|
31
|
+
// ============================================================
|
|
32
|
+
// 响应解析
|
|
33
|
+
// ============================================================
|
|
34
|
+
/**
|
|
35
|
+
* 从 LLM 返回的文本中解析 QnA JSON 结果
|
|
36
|
+
* 容错:JSON 解析失败时返回 answer=rawText, citations=[]
|
|
37
|
+
*/
|
|
38
|
+
function parseLlmResponse(rawText) {
|
|
39
|
+
// 尝试从 markdown 代码块中提取 JSON
|
|
40
|
+
const jsonMatch = rawText.match(/```(?:json)?\s*([\s\S]*?)\s*```/);
|
|
41
|
+
const jsonStr = jsonMatch ? jsonMatch[1] : rawText.trim();
|
|
42
|
+
try {
|
|
43
|
+
const parsed = JSON.parse(jsonStr ?? rawText.trim());
|
|
44
|
+
if (typeof parsed === 'object' &&
|
|
45
|
+
parsed !== null &&
|
|
46
|
+
'answer' in parsed &&
|
|
47
|
+
typeof parsed['answer'] === 'string') {
|
|
48
|
+
const obj = parsed;
|
|
49
|
+
const answer = String(obj['answer']);
|
|
50
|
+
const rawCitations = Array.isArray(obj['citations']) ? obj['citations'] : [];
|
|
51
|
+
// 解析 citations 数组
|
|
52
|
+
const citations = rawCitations
|
|
53
|
+
.filter((c) => typeof c === 'object' && c !== null)
|
|
54
|
+
.map((c) => ({
|
|
55
|
+
specPath: String(c['specPath'] ?? ''),
|
|
56
|
+
lineRange: {
|
|
57
|
+
startLine: typeof c['startLine'] === 'number' ? c['startLine'] : 0,
|
|
58
|
+
endLine: typeof c['endLine'] === 'number' ? c['endLine'] : 0,
|
|
59
|
+
},
|
|
60
|
+
excerpt: String(c['excerpt'] ?? ''),
|
|
61
|
+
}));
|
|
62
|
+
return { answer, citations };
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
catch {
|
|
66
|
+
// JSON 解析失败:将原始文本作为 answer 返回
|
|
67
|
+
}
|
|
68
|
+
return { answer: rawText.trim(), citations: [] };
|
|
69
|
+
}
|
|
70
|
+
// ============================================================
|
|
71
|
+
// 主函数
|
|
72
|
+
// ============================================================
|
|
73
|
+
/**
|
|
74
|
+
* 调用 LLM 完成问答
|
|
75
|
+
*
|
|
76
|
+
* @param prompt - buildQnAPrompt 输出的 { systemPrompt, userPrompt }
|
|
77
|
+
* @param options - 调用选项(maxTokens、temperature、timeoutMs)
|
|
78
|
+
* @returns QnALlmResult(含 answer、parsedCitations、tokenUsage)
|
|
79
|
+
* @throws LLM 调用失败时抛出 Error(不吞掉异常,由 index.ts 处理)
|
|
80
|
+
*/
|
|
81
|
+
export async function callQnALlm(prompt, options) {
|
|
82
|
+
const maxTokens = options?.maxTokens ?? 2048;
|
|
83
|
+
const temperature = options?.temperature ?? 0.3;
|
|
84
|
+
const timeoutMs = options?.timeoutMs ?? 60_000;
|
|
85
|
+
// ── Step 7a:budget gate(record-only 模式)────────────────
|
|
86
|
+
const inputEstimate = estimateFast(prompt.userPrompt + prompt.systemPrompt);
|
|
87
|
+
const outputEstimate = Math.round(inputEstimate * 0.3);
|
|
88
|
+
const totalEstimate = inputEstimate + outputEstimate;
|
|
89
|
+
// budget = Infinity 保证永不触发阻断(record-only 语义)
|
|
90
|
+
await runBudgetGate({
|
|
91
|
+
baseEstimate: totalEstimate,
|
|
92
|
+
budget: Infinity,
|
|
93
|
+
preset: 'continue',
|
|
94
|
+
isTTY: false,
|
|
95
|
+
});
|
|
96
|
+
// 超额判断:超过 hardcode 上限时记录 warn(不阻断)
|
|
97
|
+
const overBudget = totalEstimate > HARDCODE_LIMIT_TOKENS;
|
|
98
|
+
if (overBudget) {
|
|
99
|
+
console.warn(`[warn] qna token cost over hardcode limit, recorded only. ` +
|
|
100
|
+
`estimate=${totalEstimate} tokens, limit=${HARDCODE_LIMIT_TOKENS} tokens`);
|
|
101
|
+
}
|
|
102
|
+
// ── Step 7b:从项目配置读取模型 ID(不硬编码)─────────────
|
|
103
|
+
const modelId = resolveReverseSpecModel().model;
|
|
104
|
+
// ── Step 7c:Anthropic SDK 调用──────────────────────────
|
|
105
|
+
const client = new Anthropic({
|
|
106
|
+
apiKey: process.env['ANTHROPIC_API_KEY'],
|
|
107
|
+
timeout: timeoutMs,
|
|
108
|
+
});
|
|
109
|
+
const response = await client.messages.create({
|
|
110
|
+
model: modelId,
|
|
111
|
+
max_tokens: maxTokens,
|
|
112
|
+
temperature,
|
|
113
|
+
system: prompt.systemPrompt,
|
|
114
|
+
messages: [{ role: 'user', content: prompt.userPrompt }],
|
|
115
|
+
});
|
|
116
|
+
// ── Step 7d:提取文本内容 ──────────────────────────────
|
|
117
|
+
const rawText = response.content
|
|
118
|
+
.filter((block) => block.type === 'text')
|
|
119
|
+
.map((block) => block.text)
|
|
120
|
+
.join('\n');
|
|
121
|
+
// 实际 token 使用量(来自 API 响应)
|
|
122
|
+
const actualInput = response.usage?.input_tokens ?? inputEstimate;
|
|
123
|
+
const actualOutput = response.usage?.output_tokens ?? outputEstimate;
|
|
124
|
+
const actualTotal = actualInput + actualOutput;
|
|
125
|
+
const actualOverBudget = overBudget || actualTotal > HARDCODE_LIMIT_TOKENS;
|
|
126
|
+
// ── Step 7e:解析响应结构 ─────────────────────────────
|
|
127
|
+
const { answer, citations } = parseLlmResponse(rawText);
|
|
128
|
+
return {
|
|
129
|
+
answer,
|
|
130
|
+
parsedCitations: citations,
|
|
131
|
+
tokenUsage: {
|
|
132
|
+
input: actualInput,
|
|
133
|
+
output: actualOutput,
|
|
134
|
+
overBudget: actualOverBudget,
|
|
135
|
+
},
|
|
136
|
+
};
|
|
137
|
+
}
|
|
138
|
+
//# sourceMappingURL=llm-caller.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"llm-caller.js","sourceRoot":"","sources":["../../../src/panoramic/qa/llm-caller.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AACH,OAAO,SAAS,MAAM,mBAAmB,CAAC;AAC1C,OAAO,EAAE,YAAY,EAAE,MAAM,6BAA6B,CAAC;AAC3D,OAAO,EAAE,aAAa,EAAE,MAAM,4BAA4B,CAAC;AAC3D,OAAO,EAAE,uBAAuB,EAAE,MAAM,+BAA+B,CAAC;AAIxE,+DAA+D;AAC/D,KAAK;AACL,+DAA+D;AAE/D;;;;GAIG;AACH,MAAM,qBAAqB,GAAG,IAAI,CAAC;AA+BnC,+DAA+D;AAC/D,OAAO;A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