circle-ir-ai 1.1.0
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/CHANGELOG.md +105 -0
- package/LICENSE +15 -0
- package/README.md +336 -0
- package/dist/action-queue/aggregator.d.ts +40 -0
- package/dist/action-queue/aggregator.d.ts.map +1 -0
- package/dist/action-queue/aggregator.js +375 -0
- package/dist/action-queue/aggregator.js.map +1 -0
- package/dist/action-queue/index.d.ts +14 -0
- package/dist/action-queue/index.d.ts.map +1 -0
- package/dist/action-queue/index.js +17 -0
- package/dist/action-queue/index.js.map +1 -0
- package/dist/action-queue/queue.d.ts +74 -0
- package/dist/action-queue/queue.d.ts.map +1 -0
- package/dist/action-queue/queue.js +433 -0
- package/dist/action-queue/queue.js.map +1 -0
- package/dist/action-queue/types.d.ts +162 -0
- package/dist/action-queue/types.d.ts.map +1 -0
- package/dist/action-queue/types.js +44 -0
- package/dist/action-queue/types.js.map +1 -0
- package/dist/agents/enrichment-agent.d.ts +16 -0
- package/dist/agents/enrichment-agent.d.ts.map +1 -0
- package/dist/agents/enrichment-agent.js +102 -0
- package/dist/agents/enrichment-agent.js.map +1 -0
- package/dist/agents/index.d.ts +12 -0
- package/dist/agents/index.d.ts.map +1 -0
- package/dist/agents/index.js +15 -0
- package/dist/agents/index.js.map +1 -0
- package/dist/agents/mastra/agents.d.ts +373 -0
- package/dist/agents/mastra/agents.d.ts.map +1 -0
- package/dist/agents/mastra/agents.js +347 -0
- package/dist/agents/mastra/agents.js.map +1 -0
- package/dist/agents/mastra/index.d.ts +12 -0
- package/dist/agents/mastra/index.d.ts.map +1 -0
- package/dist/agents/mastra/index.js +17 -0
- package/dist/agents/mastra/index.js.map +1 -0
- package/dist/agents/mastra/instance.d.ts +383 -0
- package/dist/agents/mastra/instance.d.ts.map +1 -0
- package/dist/agents/mastra/instance.js +37 -0
- package/dist/agents/mastra/instance.js.map +1 -0
- package/dist/agents/mastra/steps.d.ts +300 -0
- package/dist/agents/mastra/steps.d.ts.map +1 -0
- package/dist/agents/mastra/steps.js +468 -0
- package/dist/agents/mastra/steps.js.map +1 -0
- package/dist/agents/mastra/swarm.d.ts +106 -0
- package/dist/agents/mastra/swarm.d.ts.map +1 -0
- package/dist/agents/mastra/swarm.js +501 -0
- package/dist/agents/mastra/swarm.js.map +1 -0
- package/dist/agents/mastra/workflow.d.ts +81 -0
- package/dist/agents/mastra/workflow.d.ts.map +1 -0
- package/dist/agents/mastra/workflow.js +460 -0
- package/dist/agents/mastra/workflow.js.map +1 -0
- package/dist/agents/multi/agents/security.d.ts +29 -0
- package/dist/agents/multi/agents/security.d.ts.map +1 -0
- package/dist/agents/multi/agents/security.js +830 -0
- package/dist/agents/multi/agents/security.js.map +1 -0
- package/dist/agents/multi/extractor.d.ts +21 -0
- package/dist/agents/multi/extractor.d.ts.map +1 -0
- package/dist/agents/multi/extractor.js +483 -0
- package/dist/agents/multi/extractor.js.map +1 -0
- package/dist/agents/multi/index.d.ts +32 -0
- package/dist/agents/multi/index.d.ts.map +1 -0
- package/dist/agents/multi/index.js +34 -0
- package/dist/agents/multi/index.js.map +1 -0
- package/dist/agents/multi/runner.d.ts +79 -0
- package/dist/agents/multi/runner.d.ts.map +1 -0
- package/dist/agents/multi/runner.js +323 -0
- package/dist/agents/multi/runner.js.map +1 -0
- package/dist/agents/security-agent.d.ts +16 -0
- package/dist/agents/security-agent.d.ts.map +1 -0
- package/dist/agents/security-agent.js +299 -0
- package/dist/agents/security-agent.js.map +1 -0
- package/dist/agents/types.d.ts +373 -0
- package/dist/agents/types.d.ts.map +1 -0
- package/dist/agents/types.js +14 -0
- package/dist/agents/types.js.map +1 -0
- package/dist/agents/verification-agent.d.ts +23 -0
- package/dist/agents/verification-agent.d.ts.map +1 -0
- package/dist/agents/verification-agent.js +217 -0
- package/dist/agents/verification-agent.js.map +1 -0
- package/dist/agents/workflow.d.ts +30 -0
- package/dist/agents/workflow.d.ts.map +1 -0
- package/dist/agents/workflow.js +79 -0
- package/dist/agents/workflow.js.map +1 -0
- package/dist/analysis/enriched.d.ts +16 -0
- package/dist/analysis/enriched.d.ts.map +1 -0
- package/dist/analysis/enriched.js +297 -0
- package/dist/analysis/enriched.js.map +1 -0
- package/dist/analysis/llm-correlated-predicates.d.ts +80 -0
- package/dist/analysis/llm-correlated-predicates.d.ts.map +1 -0
- package/dist/analysis/llm-correlated-predicates.js +255 -0
- package/dist/analysis/llm-correlated-predicates.js.map +1 -0
- package/dist/analysis/llm-cross-file-taint.d.ts +86 -0
- package/dist/analysis/llm-cross-file-taint.d.ts.map +1 -0
- package/dist/analysis/llm-cross-file-taint.js +264 -0
- package/dist/analysis/llm-cross-file-taint.js.map +1 -0
- package/dist/analysis/pattern-discovery.d.ts +79 -0
- package/dist/analysis/pattern-discovery.d.ts.map +1 -0
- package/dist/analysis/pattern-discovery.js +447 -0
- package/dist/analysis/pattern-discovery.js.map +1 -0
- package/dist/cache/file-cache.d.ts +89 -0
- package/dist/cache/file-cache.d.ts.map +1 -0
- package/dist/cache/file-cache.js +208 -0
- package/dist/cache/file-cache.js.map +1 -0
- package/dist/cache/index.d.ts +6 -0
- package/dist/cache/index.d.ts.map +1 -0
- package/dist/cache/index.js +5 -0
- package/dist/cache/index.js.map +1 -0
- package/dist/cli/args.d.ts +52 -0
- package/dist/cli/args.d.ts.map +1 -0
- package/dist/cli/args.js +422 -0
- package/dist/cli/args.js.map +1 -0
- package/dist/cli/colors.d.ts +31 -0
- package/dist/cli/colors.d.ts.map +1 -0
- package/dist/cli/colors.js +80 -0
- package/dist/cli/colors.js.map +1 -0
- package/dist/cli/commands/analyze-skill.d.ts +33 -0
- package/dist/cli/commands/analyze-skill.d.ts.map +1 -0
- package/dist/cli/commands/analyze-skill.js +217 -0
- package/dist/cli/commands/analyze-skill.js.map +1 -0
- package/dist/cli/commands/analyze.d.ts +18 -0
- package/dist/cli/commands/analyze.d.ts.map +1 -0
- package/dist/cli/commands/analyze.js +30 -0
- package/dist/cli/commands/analyze.js.map +1 -0
- package/dist/cli/commands/benchmark-runner.d.ts +42 -0
- package/dist/cli/commands/benchmark-runner.d.ts.map +1 -0
- package/dist/cli/commands/benchmark-runner.js +18 -0
- package/dist/cli/commands/benchmark-runner.js.map +1 -0
- package/dist/cli/commands/benchmark.d.ts +11 -0
- package/dist/cli/commands/benchmark.d.ts.map +1 -0
- package/dist/cli/commands/benchmark.js +90 -0
- package/dist/cli/commands/benchmark.js.map +1 -0
- package/dist/cli/commands/dead-code.d.ts +11 -0
- package/dist/cli/commands/dead-code.d.ts.map +1 -0
- package/dist/cli/commands/dead-code.js +65 -0
- package/dist/cli/commands/dead-code.js.map +1 -0
- package/dist/cli/commands/generate-spec.d.ts +11 -0
- package/dist/cli/commands/generate-spec.d.ts.map +1 -0
- package/dist/cli/commands/generate-spec.js +67 -0
- package/dist/cli/commands/generate-spec.js.map +1 -0
- package/dist/cli/commands/health.d.ts +11 -0
- package/dist/cli/commands/health.d.ts.map +1 -0
- package/dist/cli/commands/health.js +67 -0
- package/dist/cli/commands/health.js.map +1 -0
- package/dist/cli/commands/project.d.ts +21 -0
- package/dist/cli/commands/project.d.ts.map +1 -0
- package/dist/cli/commands/project.js +92 -0
- package/dist/cli/commands/project.js.map +1 -0
- package/dist/cli/commands/scan.d.ts +11 -0
- package/dist/cli/commands/scan.d.ts.map +1 -0
- package/dist/cli/commands/scan.js +68 -0
- package/dist/cli/commands/scan.js.map +1 -0
- package/dist/cli/commands/secrets.d.ts +11 -0
- package/dist/cli/commands/secrets.d.ts.map +1 -0
- package/dist/cli/commands/secrets.js +71 -0
- package/dist/cli/commands/secrets.js.map +1 -0
- package/dist/cli/commands/swarm.d.ts +20 -0
- package/dist/cli/commands/swarm.d.ts.map +1 -0
- package/dist/cli/commands/swarm.js +174 -0
- package/dist/cli/commands/swarm.js.map +1 -0
- package/dist/cli/config.d.ts +103 -0
- package/dist/cli/config.d.ts.map +1 -0
- package/dist/cli/config.js +307 -0
- package/dist/cli/config.js.map +1 -0
- package/dist/cli/discovery.d.ts +31 -0
- package/dist/cli/discovery.d.ts.map +1 -0
- package/dist/cli/discovery.js +212 -0
- package/dist/cli/discovery.js.map +1 -0
- package/dist/cli/formatters/index.d.ts +15 -0
- package/dist/cli/formatters/index.d.ts.map +1 -0
- package/dist/cli/formatters/index.js +51 -0
- package/dist/cli/formatters/index.js.map +1 -0
- package/dist/cli/formatters/json.d.ts +11 -0
- package/dist/cli/formatters/json.d.ts.map +1 -0
- package/dist/cli/formatters/json.js +12 -0
- package/dist/cli/formatters/json.js.map +1 -0
- package/dist/cli/formatters/project-json.d.ts +11 -0
- package/dist/cli/formatters/project-json.d.ts.map +1 -0
- package/dist/cli/formatters/project-json.js +12 -0
- package/dist/cli/formatters/project-json.js.map +1 -0
- package/dist/cli/formatters/project-sarif.d.ts +11 -0
- package/dist/cli/formatters/project-sarif.d.ts.map +1 -0
- package/dist/cli/formatters/project-sarif.js +127 -0
- package/dist/cli/formatters/project-sarif.js.map +1 -0
- package/dist/cli/formatters/project-summary.d.ts +11 -0
- package/dist/cli/formatters/project-summary.d.ts.map +1 -0
- package/dist/cli/formatters/project-summary.js +202 -0
- package/dist/cli/formatters/project-summary.js.map +1 -0
- package/dist/cli/formatters/sarif-shared.d.ts +101 -0
- package/dist/cli/formatters/sarif-shared.d.ts.map +1 -0
- package/dist/cli/formatters/sarif-shared.js +57 -0
- package/dist/cli/formatters/sarif-shared.js.map +1 -0
- package/dist/cli/formatters/sarif.d.ts +12 -0
- package/dist/cli/formatters/sarif.d.ts.map +1 -0
- package/dist/cli/formatters/sarif.js +92 -0
- package/dist/cli/formatters/sarif.js.map +1 -0
- package/dist/cli/formatters/summary.d.ts +11 -0
- package/dist/cli/formatters/summary.d.ts.map +1 -0
- package/dist/cli/formatters/summary.js +240 -0
- package/dist/cli/formatters/summary.js.map +1 -0
- package/dist/cli/formatters/two-phase-summary.d.ts +11 -0
- package/dist/cli/formatters/two-phase-summary.d.ts.map +1 -0
- package/dist/cli/formatters/two-phase-summary.js +188 -0
- package/dist/cli/formatters/two-phase-summary.js.map +1 -0
- package/dist/cli/index.d.ts +15 -0
- package/dist/cli/index.d.ts.map +1 -0
- package/dist/cli/index.js +555 -0
- package/dist/cli/index.js.map +1 -0
- package/dist/components/clustering.d.ts +60 -0
- package/dist/components/clustering.d.ts.map +1 -0
- package/dist/components/clustering.js +129 -0
- package/dist/components/clustering.js.map +1 -0
- package/dist/components/enrichment.d.ts +45 -0
- package/dist/components/enrichment.d.ts.map +1 -0
- package/dist/components/enrichment.js +193 -0
- package/dist/components/enrichment.js.map +1 -0
- package/dist/components/index.d.ts +29 -0
- package/dist/components/index.d.ts.map +1 -0
- package/dist/components/index.js +56 -0
- package/dist/components/index.js.map +1 -0
- package/dist/dead-code/detector.d.ts +200 -0
- package/dist/dead-code/detector.d.ts.map +1 -0
- package/dist/dead-code/detector.js +1003 -0
- package/dist/dead-code/detector.js.map +1 -0
- package/dist/dead-code/index.d.ts +7 -0
- package/dist/dead-code/index.d.ts.map +1 -0
- package/dist/dead-code/index.js +7 -0
- package/dist/dead-code/index.js.map +1 -0
- package/dist/extractors/index.d.ts +15 -0
- package/dist/extractors/index.d.ts.map +1 -0
- package/dist/extractors/index.js +14 -0
- package/dist/extractors/index.js.map +1 -0
- package/dist/extractors/natural-language.d.ts +46 -0
- package/dist/extractors/natural-language.d.ts.map +1 -0
- package/dist/extractors/natural-language.js +228 -0
- package/dist/extractors/natural-language.js.map +1 -0
- package/dist/extractors/tree-sitter.d.ts +33 -0
- package/dist/extractors/tree-sitter.d.ts.map +1 -0
- package/dist/extractors/tree-sitter.js +69 -0
- package/dist/extractors/tree-sitter.js.map +1 -0
- package/dist/extractors/types.d.ts +62 -0
- package/dist/extractors/types.d.ts.map +1 -0
- package/dist/extractors/types.js +54 -0
- package/dist/extractors/types.js.map +1 -0
- package/dist/health-score/calculator.d.ts +123 -0
- package/dist/health-score/calculator.d.ts.map +1 -0
- package/dist/health-score/calculator.js +444 -0
- package/dist/health-score/calculator.js.map +1 -0
- package/dist/health-score/index.d.ts +12 -0
- package/dist/health-score/index.d.ts.map +1 -0
- package/dist/health-score/index.js +14 -0
- package/dist/health-score/index.js.map +1 -0
- package/dist/health-score/metrics.d.ts +142 -0
- package/dist/health-score/metrics.d.ts.map +1 -0
- package/dist/health-score/metrics.js +332 -0
- package/dist/health-score/metrics.js.map +1 -0
- package/dist/index.d.ts +26 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +43 -0
- package/dist/index.js.map +1 -0
- package/dist/llm/ax-client.d.ts +477 -0
- package/dist/llm/ax-client.d.ts.map +1 -0
- package/dist/llm/ax-client.js +1641 -0
- package/dist/llm/ax-client.js.map +1 -0
- package/dist/llm/config.d.ts +58 -0
- package/dist/llm/config.d.ts.map +1 -0
- package/dist/llm/config.js +97 -0
- package/dist/llm/config.js.map +1 -0
- package/dist/llm/discovery.d.ts +123 -0
- package/dist/llm/discovery.d.ts.map +1 -0
- package/dist/llm/discovery.js +505 -0
- package/dist/llm/discovery.js.map +1 -0
- package/dist/llm/enrichment.d.ts +108 -0
- package/dist/llm/enrichment.d.ts.map +1 -0
- package/dist/llm/enrichment.js +312 -0
- package/dist/llm/enrichment.js.map +1 -0
- package/dist/llm/index.d.ts +13 -0
- package/dist/llm/index.d.ts.map +1 -0
- package/dist/llm/index.js +22 -0
- package/dist/llm/index.js.map +1 -0
- package/dist/llm/language-context.d.ts +64 -0
- package/dist/llm/language-context.d.ts.map +1 -0
- package/dist/llm/language-context.js +492 -0
- package/dist/llm/language-context.js.map +1 -0
- package/dist/llm/pattern-verification.d.ts +39 -0
- package/dist/llm/pattern-verification.d.ts.map +1 -0
- package/dist/llm/pattern-verification.js +127 -0
- package/dist/llm/pattern-verification.js.map +1 -0
- package/dist/llm/prompt-security.d.ts +120 -0
- package/dist/llm/prompt-security.d.ts.map +1 -0
- package/dist/llm/prompt-security.js +301 -0
- package/dist/llm/prompt-security.js.map +1 -0
- package/dist/llm/prompts/index.d.ts +31 -0
- package/dist/llm/prompts/index.d.ts.map +1 -0
- package/dist/llm/prompts/index.js +92 -0
- package/dist/llm/prompts/index.js.map +1 -0
- package/dist/llm/prompts/rust.d.ts +30 -0
- package/dist/llm/prompts/rust.d.ts.map +1 -0
- package/dist/llm/prompts/rust.js +121 -0
- package/dist/llm/prompts/rust.js.map +1 -0
- package/dist/llm/schemas.d.ts +892 -0
- package/dist/llm/schemas.d.ts.map +1 -0
- package/dist/llm/schemas.js +258 -0
- package/dist/llm/schemas.js.map +1 -0
- package/dist/llm/verification.d.ts +127 -0
- package/dist/llm/verification.d.ts.map +1 -0
- package/dist/llm/verification.js +394 -0
- package/dist/llm/verification.js.map +1 -0
- package/dist/project/analyzer.d.ts +30 -0
- package/dist/project/analyzer.d.ts.map +1 -0
- package/dist/project/analyzer.js +358 -0
- package/dist/project/analyzer.js.map +1 -0
- package/dist/project/call-graph.d.ts +22 -0
- package/dist/project/call-graph.d.ts.map +1 -0
- package/dist/project/call-graph.js +246 -0
- package/dist/project/call-graph.js.map +1 -0
- package/dist/project/index.d.ts +18 -0
- package/dist/project/index.d.ts.map +1 -0
- package/dist/project/index.js +20 -0
- package/dist/project/index.js.map +1 -0
- package/dist/project/taint-paths.d.ts +22 -0
- package/dist/project/taint-paths.d.ts.map +1 -0
- package/dist/project/taint-paths.js +265 -0
- package/dist/project/taint-paths.js.map +1 -0
- package/dist/project/two-phase-analyzer.d.ts +143 -0
- package/dist/project/two-phase-analyzer.d.ts.map +1 -0
- package/dist/project/two-phase-analyzer.js +646 -0
- package/dist/project/two-phase-analyzer.js.map +1 -0
- package/dist/project/type-hierarchy.d.ts +28 -0
- package/dist/project/type-hierarchy.d.ts.map +1 -0
- package/dist/project/type-hierarchy.js +218 -0
- package/dist/project/type-hierarchy.js.map +1 -0
- package/dist/secret-scan/index.d.ts +12 -0
- package/dist/secret-scan/index.d.ts.map +1 -0
- package/dist/secret-scan/index.js +14 -0
- package/dist/secret-scan/index.js.map +1 -0
- package/dist/secret-scan/patterns.d.ts +38 -0
- package/dist/secret-scan/patterns.d.ts.map +1 -0
- package/dist/secret-scan/patterns.js +473 -0
- package/dist/secret-scan/patterns.js.map +1 -0
- package/dist/secret-scan/scanner.d.ts +162 -0
- package/dist/secret-scan/scanner.d.ts.map +1 -0
- package/dist/secret-scan/scanner.js +511 -0
- package/dist/secret-scan/scanner.js.map +1 -0
- package/dist/security-scan/index.d.ts +12 -0
- package/dist/security-scan/index.d.ts.map +1 -0
- package/dist/security-scan/index.js +15 -0
- package/dist/security-scan/index.js.map +1 -0
- package/dist/security-scan/owasp-mapping.d.ts +29 -0
- package/dist/security-scan/owasp-mapping.d.ts.map +1 -0
- package/dist/security-scan/owasp-mapping.js +246 -0
- package/dist/security-scan/owasp-mapping.js.map +1 -0
- package/dist/security-scan/scanner.d.ts +204 -0
- package/dist/security-scan/scanner.d.ts.map +1 -0
- package/dist/security-scan/scanner.js +693 -0
- package/dist/security-scan/scanner.js.map +1 -0
- package/dist/security-scan/trend-tracker.d.ts +150 -0
- package/dist/security-scan/trend-tracker.d.ts.map +1 -0
- package/dist/security-scan/trend-tracker.js +299 -0
- package/dist/security-scan/trend-tracker.js.map +1 -0
- package/dist/skills/bundle-loader.d.ts +26 -0
- package/dist/skills/bundle-loader.d.ts.map +1 -0
- package/dist/skills/bundle-loader.js +284 -0
- package/dist/skills/bundle-loader.js.map +1 -0
- package/dist/skills/capability-mismatch.d.ts +21 -0
- package/dist/skills/capability-mismatch.d.ts.map +1 -0
- package/dist/skills/capability-mismatch.js +188 -0
- package/dist/skills/capability-mismatch.js.map +1 -0
- package/dist/skills/index.d.ts +10 -0
- package/dist/skills/index.d.ts.map +1 -0
- package/dist/skills/index.js +9 -0
- package/dist/skills/index.js.map +1 -0
- package/dist/skills/skill-analyzer.d.ts +16 -0
- package/dist/skills/skill-analyzer.d.ts.map +1 -0
- package/dist/skills/skill-analyzer.js +361 -0
- package/dist/skills/skill-analyzer.js.map +1 -0
- package/dist/skills/types.d.ts +195 -0
- package/dist/skills/types.d.ts.map +1 -0
- package/dist/skills/types.js +7 -0
- package/dist/skills/types.js.map +1 -0
- package/dist/specifica/conflict-resolver.d.ts +23 -0
- package/dist/specifica/conflict-resolver.d.ts.map +1 -0
- package/dist/specifica/conflict-resolver.js +129 -0
- package/dist/specifica/conflict-resolver.js.map +1 -0
- package/dist/specifica/evidence-aggregator.d.ts +33 -0
- package/dist/specifica/evidence-aggregator.d.ts.map +1 -0
- package/dist/specifica/evidence-aggregator.js +236 -0
- package/dist/specifica/evidence-aggregator.js.map +1 -0
- package/dist/specifica/evidence-extractor.d.ts +13 -0
- package/dist/specifica/evidence-extractor.d.ts.map +1 -0
- package/dist/specifica/evidence-extractor.js +431 -0
- package/dist/specifica/evidence-extractor.js.map +1 -0
- package/dist/specifica/feature-clustering.d.ts +19 -0
- package/dist/specifica/feature-clustering.d.ts.map +1 -0
- package/dist/specifica/feature-clustering.js +231 -0
- package/dist/specifica/feature-clustering.js.map +1 -0
- package/dist/specifica/generator.d.ts +16 -0
- package/dist/specifica/generator.d.ts.map +1 -0
- package/dist/specifica/generator.js +277 -0
- package/dist/specifica/generator.js.map +1 -0
- package/dist/specifica/index.d.ts +15 -0
- package/dist/specifica/index.d.ts.map +1 -0
- package/dist/specifica/index.js +18 -0
- package/dist/specifica/index.js.map +1 -0
- package/dist/specifica/prompts.d.ts +21 -0
- package/dist/specifica/prompts.d.ts.map +1 -0
- package/dist/specifica/prompts.js +196 -0
- package/dist/specifica/prompts.js.map +1 -0
- package/dist/specifica/spec-generator.d.ts +22 -0
- package/dist/specifica/spec-generator.d.ts.map +1 -0
- package/dist/specifica/spec-generator.js +229 -0
- package/dist/specifica/spec-generator.js.map +1 -0
- package/dist/specifica/types.d.ts +213 -0
- package/dist/specifica/types.d.ts.map +1 -0
- package/dist/specifica/types.js +7 -0
- package/dist/specifica/types.js.map +1 -0
- package/dist/utils/logger.d.ts +17 -0
- package/dist/utils/logger.d.ts.map +1 -0
- package/dist/utils/logger.js +51 -0
- package/dist/utils/logger.js.map +1 -0
- package/package.json +99 -0
|
@@ -0,0 +1,383 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Mastra Instance Configuration
|
|
3
|
+
*
|
|
4
|
+
* Provides factory functions to create configured Mastra instances
|
|
5
|
+
* with agents and workflows for security analysis.
|
|
6
|
+
*/
|
|
7
|
+
import { Mastra } from '@mastra/core';
|
|
8
|
+
import { analyzeFile, analyzeFileStream } from './workflow.js';
|
|
9
|
+
import { analyzeFilesSwarm, analyzeFilesSwarmStream } from './swarm.js';
|
|
10
|
+
export interface MastraInstanceOptions {
|
|
11
|
+
logLevel?: 'debug' | 'info' | 'warn' | 'error';
|
|
12
|
+
}
|
|
13
|
+
/**
|
|
14
|
+
* Create a configured Mastra instance for security analysis
|
|
15
|
+
*
|
|
16
|
+
* This sets up the Mastra framework with:
|
|
17
|
+
* - Security analysis agents (enrichment, verification, cross-file, orchestrator)
|
|
18
|
+
* - Single-file analysis workflow
|
|
19
|
+
* - Multi-file swarm analysis workflow
|
|
20
|
+
*/
|
|
21
|
+
export declare function createMastraInstance(options?: MastraInstanceOptions): {
|
|
22
|
+
mastra: Mastra<{
|
|
23
|
+
enrichment: import("@mastra/core/agent").Agent<"enrichment-agent", {
|
|
24
|
+
classifyRole: import("@mastra/core/tools").Tool<{
|
|
25
|
+
className: string;
|
|
26
|
+
methodNames: string;
|
|
27
|
+
annotations: string;
|
|
28
|
+
imports: string;
|
|
29
|
+
}, {
|
|
30
|
+
role: "controller" | "service" | "repository" | "utility" | "entity" | "unknown";
|
|
31
|
+
confidence: number;
|
|
32
|
+
reasoning: string;
|
|
33
|
+
indicators: string[];
|
|
34
|
+
}, unknown, unknown, import("@mastra/core/tools").ToolExecutionContext<unknown, unknown, unknown>, "classify-role", unknown>;
|
|
35
|
+
discoverSources: import("@mastra/core/tools").Tool<{
|
|
36
|
+
methodName: string;
|
|
37
|
+
classRole: string;
|
|
38
|
+
existingSources: string;
|
|
39
|
+
methodCode: string;
|
|
40
|
+
}, {
|
|
41
|
+
sources: {
|
|
42
|
+
line: number;
|
|
43
|
+
variable: string;
|
|
44
|
+
type: string;
|
|
45
|
+
confidence: number;
|
|
46
|
+
reasoning: string;
|
|
47
|
+
}[];
|
|
48
|
+
}, unknown, unknown, import("@mastra/core/tools").ToolExecutionContext<unknown, unknown, unknown>, "discover-sources", unknown>;
|
|
49
|
+
discoverSinks: import("@mastra/core/tools").Tool<{
|
|
50
|
+
methodName: string;
|
|
51
|
+
methodCalls: string;
|
|
52
|
+
existingSinks: string;
|
|
53
|
+
methodCode: string;
|
|
54
|
+
}, {
|
|
55
|
+
sinks: {
|
|
56
|
+
line: number;
|
|
57
|
+
method: string;
|
|
58
|
+
type: string;
|
|
59
|
+
cwe: string;
|
|
60
|
+
argPositions: number[];
|
|
61
|
+
confidence: number;
|
|
62
|
+
reasoning: string;
|
|
63
|
+
}[];
|
|
64
|
+
}, unknown, unknown, import("@mastra/core/tools").ToolExecutionContext<unknown, unknown, unknown>, "discover-sinks", unknown>;
|
|
65
|
+
}, undefined, unknown>;
|
|
66
|
+
verification: import("@mastra/core/agent").Agent<"verification-agent", {
|
|
67
|
+
verifyVulnerability: import("@mastra/core/tools").Tool<{
|
|
68
|
+
cwe: string;
|
|
69
|
+
sourceType: string;
|
|
70
|
+
className: string;
|
|
71
|
+
methodName: string;
|
|
72
|
+
methodCode: string;
|
|
73
|
+
sourceLine: number;
|
|
74
|
+
sourceCode: string;
|
|
75
|
+
sinkLine: number;
|
|
76
|
+
sinkCode: string;
|
|
77
|
+
sinkType: string;
|
|
78
|
+
sanitizersInPath: string[];
|
|
79
|
+
}, {
|
|
80
|
+
verdict: "TRUE_POSITIVE" | "FALSE_POSITIVE" | "UNCERTAIN";
|
|
81
|
+
confidence: number;
|
|
82
|
+
reasoning: string;
|
|
83
|
+
exploitability: "high" | "medium" | "low" | "none";
|
|
84
|
+
sanitizersFound: string[];
|
|
85
|
+
attackVector: string;
|
|
86
|
+
}, unknown, unknown, import("@mastra/core/tools").ToolExecutionContext<unknown, unknown, unknown>, "verify-vulnerability", unknown>;
|
|
87
|
+
}, undefined, unknown>;
|
|
88
|
+
crossFile: import("@mastra/core/agent").Agent<"cross-file-agent", {
|
|
89
|
+
crossFileTaint: import("@mastra/core/tools").Tool<{
|
|
90
|
+
sourceCode: string;
|
|
91
|
+
sourceFile: string;
|
|
92
|
+
targetFile: string;
|
|
93
|
+
targetCode: string;
|
|
94
|
+
exportedTaint: {
|
|
95
|
+
symbol: string;
|
|
96
|
+
type: string;
|
|
97
|
+
line: number;
|
|
98
|
+
}[];
|
|
99
|
+
importedSymbols: string[];
|
|
100
|
+
}, {
|
|
101
|
+
taintFlows: Array<{
|
|
102
|
+
sourceSymbol: string;
|
|
103
|
+
targetSymbol: string;
|
|
104
|
+
flowType: "direct" | "transitive" | "conditional";
|
|
105
|
+
confidence: number;
|
|
106
|
+
}>;
|
|
107
|
+
reasoning: string;
|
|
108
|
+
}, unknown, unknown, import("@mastra/core/tools").ToolExecutionContext<unknown, unknown, unknown>, "cross-file-taint", unknown>;
|
|
109
|
+
}, undefined, unknown>;
|
|
110
|
+
orchestrator: import("@mastra/core/agent").Agent<"orchestrator-agent", {
|
|
111
|
+
classifyRole: import("@mastra/core/tools").Tool<{
|
|
112
|
+
className: string;
|
|
113
|
+
methodNames: string;
|
|
114
|
+
annotations: string;
|
|
115
|
+
imports: string;
|
|
116
|
+
}, {
|
|
117
|
+
role: "controller" | "service" | "repository" | "utility" | "entity" | "unknown";
|
|
118
|
+
confidence: number;
|
|
119
|
+
reasoning: string;
|
|
120
|
+
indicators: string[];
|
|
121
|
+
}, unknown, unknown, import("@mastra/core/tools").ToolExecutionContext<unknown, unknown, unknown>, "classify-role", unknown>;
|
|
122
|
+
discoverSources: import("@mastra/core/tools").Tool<{
|
|
123
|
+
methodName: string;
|
|
124
|
+
classRole: string;
|
|
125
|
+
existingSources: string;
|
|
126
|
+
methodCode: string;
|
|
127
|
+
}, {
|
|
128
|
+
sources: {
|
|
129
|
+
line: number;
|
|
130
|
+
variable: string;
|
|
131
|
+
type: string;
|
|
132
|
+
confidence: number;
|
|
133
|
+
reasoning: string;
|
|
134
|
+
}[];
|
|
135
|
+
}, unknown, unknown, import("@mastra/core/tools").ToolExecutionContext<unknown, unknown, unknown>, "discover-sources", unknown>;
|
|
136
|
+
discoverSinks: import("@mastra/core/tools").Tool<{
|
|
137
|
+
methodName: string;
|
|
138
|
+
methodCalls: string;
|
|
139
|
+
existingSinks: string;
|
|
140
|
+
methodCode: string;
|
|
141
|
+
}, {
|
|
142
|
+
sinks: {
|
|
143
|
+
line: number;
|
|
144
|
+
method: string;
|
|
145
|
+
type: string;
|
|
146
|
+
cwe: string;
|
|
147
|
+
argPositions: number[];
|
|
148
|
+
confidence: number;
|
|
149
|
+
reasoning: string;
|
|
150
|
+
}[];
|
|
151
|
+
}, unknown, unknown, import("@mastra/core/tools").ToolExecutionContext<unknown, unknown, unknown>, "discover-sinks", unknown>;
|
|
152
|
+
verifyVulnerability: import("@mastra/core/tools").Tool<{
|
|
153
|
+
cwe: string;
|
|
154
|
+
sourceType: string;
|
|
155
|
+
className: string;
|
|
156
|
+
methodName: string;
|
|
157
|
+
methodCode: string;
|
|
158
|
+
sourceLine: number;
|
|
159
|
+
sourceCode: string;
|
|
160
|
+
sinkLine: number;
|
|
161
|
+
sinkCode: string;
|
|
162
|
+
sinkType: string;
|
|
163
|
+
sanitizersInPath: string[];
|
|
164
|
+
}, {
|
|
165
|
+
verdict: "TRUE_POSITIVE" | "FALSE_POSITIVE" | "UNCERTAIN";
|
|
166
|
+
confidence: number;
|
|
167
|
+
reasoning: string;
|
|
168
|
+
exploitability: "high" | "medium" | "low" | "none";
|
|
169
|
+
sanitizersFound: string[];
|
|
170
|
+
attackVector: string;
|
|
171
|
+
}, unknown, unknown, import("@mastra/core/tools").ToolExecutionContext<unknown, unknown, unknown>, "verify-vulnerability", unknown>;
|
|
172
|
+
crossFileTaint: import("@mastra/core/tools").Tool<{
|
|
173
|
+
sourceCode: string;
|
|
174
|
+
sourceFile: string;
|
|
175
|
+
targetFile: string;
|
|
176
|
+
targetCode: string;
|
|
177
|
+
exportedTaint: {
|
|
178
|
+
symbol: string;
|
|
179
|
+
type: string;
|
|
180
|
+
line: number;
|
|
181
|
+
}[];
|
|
182
|
+
importedSymbols: string[];
|
|
183
|
+
}, {
|
|
184
|
+
taintFlows: Array<{
|
|
185
|
+
sourceSymbol: string;
|
|
186
|
+
targetSymbol: string;
|
|
187
|
+
flowType: "direct" | "transitive" | "conditional";
|
|
188
|
+
confidence: number;
|
|
189
|
+
}>;
|
|
190
|
+
reasoning: string;
|
|
191
|
+
}, unknown, unknown, import("@mastra/core/tools").ToolExecutionContext<unknown, unknown, unknown>, "cross-file-taint", unknown>;
|
|
192
|
+
}, undefined, unknown>;
|
|
193
|
+
}, Record<string, import("@mastra/core/workflows").Workflow<any, any, any, any, any, any, any, unknown>>, Record<string, import("@mastra/core/vector").MastraVector<any>>, Record<string, import("@mastra/core/tts").MastraTTS>, import("@mastra/core/logger").IMastraLogger, Record<string, import("@mastra/core/mcp").MCPServerBase<any>>, Record<string, import("@mastra/core/evals").MastraScorer<any, any, any, any>>, Record<string, import("@mastra/core/tools").ToolAction<any, any, any, any, any, any, unknown>>, Record<string, import("@mastra/core/processors").Processor<any, unknown>>, Record<string, import("@mastra/core/memory").MastraMemory>>;
|
|
194
|
+
agents: {
|
|
195
|
+
enrichment: import("@mastra/core/agent").Agent<"enrichment-agent", {
|
|
196
|
+
classifyRole: import("@mastra/core/tools").Tool<{
|
|
197
|
+
className: string;
|
|
198
|
+
methodNames: string;
|
|
199
|
+
annotations: string;
|
|
200
|
+
imports: string;
|
|
201
|
+
}, {
|
|
202
|
+
role: "controller" | "service" | "repository" | "utility" | "entity" | "unknown";
|
|
203
|
+
confidence: number;
|
|
204
|
+
reasoning: string;
|
|
205
|
+
indicators: string[];
|
|
206
|
+
}, unknown, unknown, import("@mastra/core/tools").ToolExecutionContext<unknown, unknown, unknown>, "classify-role", unknown>;
|
|
207
|
+
discoverSources: import("@mastra/core/tools").Tool<{
|
|
208
|
+
methodName: string;
|
|
209
|
+
classRole: string;
|
|
210
|
+
existingSources: string;
|
|
211
|
+
methodCode: string;
|
|
212
|
+
}, {
|
|
213
|
+
sources: {
|
|
214
|
+
line: number;
|
|
215
|
+
variable: string;
|
|
216
|
+
type: string;
|
|
217
|
+
confidence: number;
|
|
218
|
+
reasoning: string;
|
|
219
|
+
}[];
|
|
220
|
+
}, unknown, unknown, import("@mastra/core/tools").ToolExecutionContext<unknown, unknown, unknown>, "discover-sources", unknown>;
|
|
221
|
+
discoverSinks: import("@mastra/core/tools").Tool<{
|
|
222
|
+
methodName: string;
|
|
223
|
+
methodCalls: string;
|
|
224
|
+
existingSinks: string;
|
|
225
|
+
methodCode: string;
|
|
226
|
+
}, {
|
|
227
|
+
sinks: {
|
|
228
|
+
line: number;
|
|
229
|
+
method: string;
|
|
230
|
+
type: string;
|
|
231
|
+
cwe: string;
|
|
232
|
+
argPositions: number[];
|
|
233
|
+
confidence: number;
|
|
234
|
+
reasoning: string;
|
|
235
|
+
}[];
|
|
236
|
+
}, unknown, unknown, import("@mastra/core/tools").ToolExecutionContext<unknown, unknown, unknown>, "discover-sinks", unknown>;
|
|
237
|
+
}, undefined, unknown>;
|
|
238
|
+
verification: import("@mastra/core/agent").Agent<"verification-agent", {
|
|
239
|
+
verifyVulnerability: import("@mastra/core/tools").Tool<{
|
|
240
|
+
cwe: string;
|
|
241
|
+
sourceType: string;
|
|
242
|
+
className: string;
|
|
243
|
+
methodName: string;
|
|
244
|
+
methodCode: string;
|
|
245
|
+
sourceLine: number;
|
|
246
|
+
sourceCode: string;
|
|
247
|
+
sinkLine: number;
|
|
248
|
+
sinkCode: string;
|
|
249
|
+
sinkType: string;
|
|
250
|
+
sanitizersInPath: string[];
|
|
251
|
+
}, {
|
|
252
|
+
verdict: "TRUE_POSITIVE" | "FALSE_POSITIVE" | "UNCERTAIN";
|
|
253
|
+
confidence: number;
|
|
254
|
+
reasoning: string;
|
|
255
|
+
exploitability: "high" | "medium" | "low" | "none";
|
|
256
|
+
sanitizersFound: string[];
|
|
257
|
+
attackVector: string;
|
|
258
|
+
}, unknown, unknown, import("@mastra/core/tools").ToolExecutionContext<unknown, unknown, unknown>, "verify-vulnerability", unknown>;
|
|
259
|
+
}, undefined, unknown>;
|
|
260
|
+
crossFile: import("@mastra/core/agent").Agent<"cross-file-agent", {
|
|
261
|
+
crossFileTaint: import("@mastra/core/tools").Tool<{
|
|
262
|
+
sourceCode: string;
|
|
263
|
+
sourceFile: string;
|
|
264
|
+
targetFile: string;
|
|
265
|
+
targetCode: string;
|
|
266
|
+
exportedTaint: {
|
|
267
|
+
symbol: string;
|
|
268
|
+
type: string;
|
|
269
|
+
line: number;
|
|
270
|
+
}[];
|
|
271
|
+
importedSymbols: string[];
|
|
272
|
+
}, {
|
|
273
|
+
taintFlows: Array<{
|
|
274
|
+
sourceSymbol: string;
|
|
275
|
+
targetSymbol: string;
|
|
276
|
+
flowType: "direct" | "transitive" | "conditional";
|
|
277
|
+
confidence: number;
|
|
278
|
+
}>;
|
|
279
|
+
reasoning: string;
|
|
280
|
+
}, unknown, unknown, import("@mastra/core/tools").ToolExecutionContext<unknown, unknown, unknown>, "cross-file-taint", unknown>;
|
|
281
|
+
}, undefined, unknown>;
|
|
282
|
+
orchestrator: import("@mastra/core/agent").Agent<"orchestrator-agent", {
|
|
283
|
+
classifyRole: import("@mastra/core/tools").Tool<{
|
|
284
|
+
className: string;
|
|
285
|
+
methodNames: string;
|
|
286
|
+
annotations: string;
|
|
287
|
+
imports: string;
|
|
288
|
+
}, {
|
|
289
|
+
role: "controller" | "service" | "repository" | "utility" | "entity" | "unknown";
|
|
290
|
+
confidence: number;
|
|
291
|
+
reasoning: string;
|
|
292
|
+
indicators: string[];
|
|
293
|
+
}, unknown, unknown, import("@mastra/core/tools").ToolExecutionContext<unknown, unknown, unknown>, "classify-role", unknown>;
|
|
294
|
+
discoverSources: import("@mastra/core/tools").Tool<{
|
|
295
|
+
methodName: string;
|
|
296
|
+
classRole: string;
|
|
297
|
+
existingSources: string;
|
|
298
|
+
methodCode: string;
|
|
299
|
+
}, {
|
|
300
|
+
sources: {
|
|
301
|
+
line: number;
|
|
302
|
+
variable: string;
|
|
303
|
+
type: string;
|
|
304
|
+
confidence: number;
|
|
305
|
+
reasoning: string;
|
|
306
|
+
}[];
|
|
307
|
+
}, unknown, unknown, import("@mastra/core/tools").ToolExecutionContext<unknown, unknown, unknown>, "discover-sources", unknown>;
|
|
308
|
+
discoverSinks: import("@mastra/core/tools").Tool<{
|
|
309
|
+
methodName: string;
|
|
310
|
+
methodCalls: string;
|
|
311
|
+
existingSinks: string;
|
|
312
|
+
methodCode: string;
|
|
313
|
+
}, {
|
|
314
|
+
sinks: {
|
|
315
|
+
line: number;
|
|
316
|
+
method: string;
|
|
317
|
+
type: string;
|
|
318
|
+
cwe: string;
|
|
319
|
+
argPositions: number[];
|
|
320
|
+
confidence: number;
|
|
321
|
+
reasoning: string;
|
|
322
|
+
}[];
|
|
323
|
+
}, unknown, unknown, import("@mastra/core/tools").ToolExecutionContext<unknown, unknown, unknown>, "discover-sinks", unknown>;
|
|
324
|
+
verifyVulnerability: import("@mastra/core/tools").Tool<{
|
|
325
|
+
cwe: string;
|
|
326
|
+
sourceType: string;
|
|
327
|
+
className: string;
|
|
328
|
+
methodName: string;
|
|
329
|
+
methodCode: string;
|
|
330
|
+
sourceLine: number;
|
|
331
|
+
sourceCode: string;
|
|
332
|
+
sinkLine: number;
|
|
333
|
+
sinkCode: string;
|
|
334
|
+
sinkType: string;
|
|
335
|
+
sanitizersInPath: string[];
|
|
336
|
+
}, {
|
|
337
|
+
verdict: "TRUE_POSITIVE" | "FALSE_POSITIVE" | "UNCERTAIN";
|
|
338
|
+
confidence: number;
|
|
339
|
+
reasoning: string;
|
|
340
|
+
exploitability: "high" | "medium" | "low" | "none";
|
|
341
|
+
sanitizersFound: string[];
|
|
342
|
+
attackVector: string;
|
|
343
|
+
}, unknown, unknown, import("@mastra/core/tools").ToolExecutionContext<unknown, unknown, unknown>, "verify-vulnerability", unknown>;
|
|
344
|
+
crossFileTaint: import("@mastra/core/tools").Tool<{
|
|
345
|
+
sourceCode: string;
|
|
346
|
+
sourceFile: string;
|
|
347
|
+
targetFile: string;
|
|
348
|
+
targetCode: string;
|
|
349
|
+
exportedTaint: {
|
|
350
|
+
symbol: string;
|
|
351
|
+
type: string;
|
|
352
|
+
line: number;
|
|
353
|
+
}[];
|
|
354
|
+
importedSymbols: string[];
|
|
355
|
+
}, {
|
|
356
|
+
taintFlows: Array<{
|
|
357
|
+
sourceSymbol: string;
|
|
358
|
+
targetSymbol: string;
|
|
359
|
+
flowType: "direct" | "transitive" | "conditional";
|
|
360
|
+
confidence: number;
|
|
361
|
+
}>;
|
|
362
|
+
reasoning: string;
|
|
363
|
+
}, unknown, unknown, import("@mastra/core/tools").ToolExecutionContext<unknown, unknown, unknown>, "cross-file-taint", unknown>;
|
|
364
|
+
}, undefined, unknown>;
|
|
365
|
+
};
|
|
366
|
+
analyzeFile: typeof analyzeFile;
|
|
367
|
+
analyzeFileStream: typeof analyzeFileStream;
|
|
368
|
+
securityAnalysisWorkflow: {
|
|
369
|
+
id: string;
|
|
370
|
+
run: typeof analyzeFile;
|
|
371
|
+
stream: typeof analyzeFileStream;
|
|
372
|
+
};
|
|
373
|
+
analyzeFilesSwarm: typeof analyzeFilesSwarm;
|
|
374
|
+
analyzeFilesSwarmStream: typeof analyzeFilesSwarmStream;
|
|
375
|
+
swarmAnalysisWorkflow: {
|
|
376
|
+
id: string;
|
|
377
|
+
run: typeof analyzeFilesSwarm;
|
|
378
|
+
stream: typeof analyzeFilesSwarmStream;
|
|
379
|
+
runInBatches: typeof import("./swarm.js").analyzeFilesInBatches;
|
|
380
|
+
};
|
|
381
|
+
};
|
|
382
|
+
export default createMastraInstance;
|
|
383
|
+
//# sourceMappingURL=instance.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"instance.d.ts","sourceRoot":"","sources":["../../../src/agents/mastra/instance.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,MAAM,EAAE,MAAM,cAAc,CAAC;AAEtC,OAAO,EAA4B,WAAW,EAAE,iBAAiB,EAAE,MAAM,eAAe,CAAC;AACzF,OAAO,EAAyB,iBAAiB,EAAE,uBAAuB,EAAE,MAAM,YAAY,CAAC;AAM/F,MAAM,WAAW,qBAAqB;IACpC,QAAQ,CAAC,EAAE,OAAO,GAAG,MAAM,GAAG,MAAM,GAAG,OAAO,CAAC;CAChD;AAED;;;;;;;GAOG;AACH,wBAAgB,oBAAoB,CAAC,OAAO,CAAC,EAAE,qBAAqB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAmBnE;AAED,eAAe,oBAAoB,CAAC"}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Mastra Instance Configuration
|
|
3
|
+
*
|
|
4
|
+
* Provides factory functions to create configured Mastra instances
|
|
5
|
+
* with agents and workflows for security analysis.
|
|
6
|
+
*/
|
|
7
|
+
import { Mastra } from '@mastra/core';
|
|
8
|
+
import { agents } from './agents.js';
|
|
9
|
+
import { securityAnalysisWorkflow, analyzeFile, analyzeFileStream } from './workflow.js';
|
|
10
|
+
import { swarmAnalysisWorkflow, analyzeFilesSwarm, analyzeFilesSwarmStream } from './swarm.js';
|
|
11
|
+
/**
|
|
12
|
+
* Create a configured Mastra instance for security analysis
|
|
13
|
+
*
|
|
14
|
+
* This sets up the Mastra framework with:
|
|
15
|
+
* - Security analysis agents (enrichment, verification, cross-file, orchestrator)
|
|
16
|
+
* - Single-file analysis workflow
|
|
17
|
+
* - Multi-file swarm analysis workflow
|
|
18
|
+
*/
|
|
19
|
+
export function createMastraInstance(options) {
|
|
20
|
+
const mastra = new Mastra({
|
|
21
|
+
agents,
|
|
22
|
+
});
|
|
23
|
+
return {
|
|
24
|
+
mastra,
|
|
25
|
+
agents,
|
|
26
|
+
// Single-file analysis
|
|
27
|
+
analyzeFile,
|
|
28
|
+
analyzeFileStream,
|
|
29
|
+
securityAnalysisWorkflow,
|
|
30
|
+
// Multi-file swarm analysis
|
|
31
|
+
analyzeFilesSwarm,
|
|
32
|
+
analyzeFilesSwarmStream,
|
|
33
|
+
swarmAnalysisWorkflow,
|
|
34
|
+
};
|
|
35
|
+
}
|
|
36
|
+
export default createMastraInstance;
|
|
37
|
+
//# sourceMappingURL=instance.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"instance.js","sourceRoot":"","sources":["../../../src/agents/mastra/instance.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,MAAM,EAAE,MAAM,cAAc,CAAC;AACtC,OAAO,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AACrC,OAAO,EAAE,wBAAwB,EAAE,WAAW,EAAE,iBAAiB,EAAE,MAAM,eAAe,CAAC;AACzF,OAAO,EAAE,qBAAqB,EAAE,iBAAiB,EAAE,uBAAuB,EAAE,MAAM,YAAY,CAAC;AAU/F;;;;;;;GAOG;AACH,MAAM,UAAU,oBAAoB,CAAC,OAA+B;IAClE,MAAM,MAAM,GAAG,IAAI,MAAM,CAAC;QACxB,MAAM;KACP,CAAC,CAAC;IAEH,OAAO;QACL,MAAM;QACN,MAAM;QAEN,uBAAuB;QACvB,WAAW;QACX,iBAAiB;QACjB,wBAAwB;QAExB,4BAA4B;QAC5B,iBAAiB;QACjB,uBAAuB;QACvB,qBAAqB;KACtB,CAAC;AACJ,CAAC;AAED,eAAe,oBAAoB,CAAC"}
|