symbiote-cli 0.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/LICENSE +21 -0
- package/dist/bin/symbiote.d.ts +3 -0
- package/dist/bin/symbiote.d.ts.map +1 -0
- package/dist/bin/symbiote.js +202 -0
- package/dist/bin/symbiote.js.map +1 -0
- package/dist/bin/synapse.d.ts +3 -0
- package/dist/bin/synapse.d.ts.map +1 -0
- package/dist/bin/synapse.js +369 -0
- package/dist/bin/synapse.js.map +1 -0
- package/dist/src/brain/embeddings.d.ts +9 -0
- package/dist/src/brain/embeddings.d.ts.map +1 -0
- package/dist/src/brain/embeddings.js +24 -0
- package/dist/src/brain/embeddings.js.map +1 -0
- package/dist/src/brain/health/constraint-checker.d.ts +16 -0
- package/dist/src/brain/health/constraint-checker.d.ts.map +1 -0
- package/dist/src/brain/health/constraint-checker.js +93 -0
- package/dist/src/brain/health/constraint-checker.js.map +1 -0
- package/dist/src/brain/health/coupling-analyzer.d.ts +9 -0
- package/dist/src/brain/health/coupling-analyzer.d.ts.map +1 -0
- package/dist/src/brain/health/coupling-analyzer.js +105 -0
- package/dist/src/brain/health/coupling-analyzer.js.map +1 -0
- package/dist/src/brain/health/cycle-detector.d.ts +12 -0
- package/dist/src/brain/health/cycle-detector.d.ts.map +1 -0
- package/dist/src/brain/health/cycle-detector.js +79 -0
- package/dist/src/brain/health/cycle-detector.js.map +1 -0
- package/dist/src/brain/health/dead-code-detector.d.ts +9 -0
- package/dist/src/brain/health/dead-code-detector.d.ts.map +1 -0
- package/dist/src/brain/health/dead-code-detector.js +72 -0
- package/dist/src/brain/health/dead-code-detector.js.map +1 -0
- package/dist/src/brain/health/history.d.ts +21 -0
- package/dist/src/brain/health/history.d.ts.map +1 -0
- package/dist/src/brain/health/history.js +35 -0
- package/dist/src/brain/health/history.js.map +1 -0
- package/dist/src/brain/health/index.d.ts +25 -0
- package/dist/src/brain/health/index.d.ts.map +1 -0
- package/dist/src/brain/health/index.js +76 -0
- package/dist/src/brain/health/index.js.map +1 -0
- package/dist/src/brain/health/scorer.d.ts +19 -0
- package/dist/src/brain/health/scorer.d.ts.map +1 -0
- package/dist/src/brain/health/scorer.js +47 -0
- package/dist/src/brain/health/scorer.js.map +1 -0
- package/dist/src/brain/health/types.d.ts +67 -0
- package/dist/src/brain/health/types.d.ts.map +1 -0
- package/dist/src/brain/health/types.js +2 -0
- package/dist/src/brain/health/types.js.map +1 -0
- package/dist/src/brain/health.d.ts +30 -0
- package/dist/src/brain/health.d.ts.map +1 -0
- package/dist/src/brain/health.js +147 -0
- package/dist/src/brain/health.js.map +1 -0
- package/dist/src/brain/index.d.ts +3 -0
- package/dist/src/brain/index.d.ts.map +1 -0
- package/dist/src/brain/index.js +3 -0
- package/dist/src/brain/index.js.map +1 -0
- package/dist/src/brain/intent.d.ts +31 -0
- package/dist/src/brain/intent.d.ts.map +1 -0
- package/dist/src/brain/intent.js +120 -0
- package/dist/src/brain/intent.js.map +1 -0
- package/dist/src/commands/dna.d.ts +2 -0
- package/dist/src/commands/dna.d.ts.map +1 -0
- package/dist/src/commands/dna.js +128 -0
- package/dist/src/commands/dna.js.map +1 -0
- package/dist/src/commands/hooks.d.ts +6 -0
- package/dist/src/commands/hooks.d.ts.map +1 -0
- package/dist/src/commands/hooks.js +210 -0
- package/dist/src/commands/hooks.js.map +1 -0
- package/dist/src/commands/impact.d.ts +2 -0
- package/dist/src/commands/impact.d.ts.map +1 -0
- package/dist/src/commands/impact.js +50 -0
- package/dist/src/commands/impact.js.map +1 -0
- package/dist/src/commands/index.d.ts +9 -0
- package/dist/src/commands/index.d.ts.map +1 -0
- package/dist/src/commands/index.js +9 -0
- package/dist/src/commands/index.js.map +1 -0
- package/dist/src/commands/init.d.ts +2 -0
- package/dist/src/commands/init.d.ts.map +1 -0
- package/dist/src/commands/init.js +132 -0
- package/dist/src/commands/init.js.map +1 -0
- package/dist/src/commands/install.d.ts +2 -0
- package/dist/src/commands/install.d.ts.map +1 -0
- package/dist/src/commands/install.js +67 -0
- package/dist/src/commands/install.js.map +1 -0
- package/dist/src/commands/mcp.d.ts +2 -0
- package/dist/src/commands/mcp.d.ts.map +1 -0
- package/dist/src/commands/mcp.js +51 -0
- package/dist/src/commands/mcp.js.map +1 -0
- package/dist/src/commands/scan.d.ts +2 -0
- package/dist/src/commands/scan.d.ts.map +1 -0
- package/dist/src/commands/scan.js +46 -0
- package/dist/src/commands/scan.js.map +1 -0
- package/dist/src/commands/serve.d.ts +2 -0
- package/dist/src/commands/serve.d.ts.map +1 -0
- package/dist/src/commands/serve.js +93 -0
- package/dist/src/commands/serve.js.map +1 -0
- package/dist/src/commands/shared.d.ts +11 -0
- package/dist/src/commands/shared.d.ts.map +1 -0
- package/dist/src/commands/shared.js +137 -0
- package/dist/src/commands/shared.js.map +1 -0
- package/dist/src/commands/unbond.d.ts +2 -0
- package/dist/src/commands/unbond.d.ts.map +1 -0
- package/dist/src/commands/unbond.js +29 -0
- package/dist/src/commands/unbond.js.map +1 -0
- package/dist/src/core/algorithms.d.ts +19 -0
- package/dist/src/core/algorithms.d.ts.map +1 -0
- package/dist/src/core/algorithms.js +98 -0
- package/dist/src/core/algorithms.js.map +1 -0
- package/dist/src/core/embeddings.d.ts +12 -0
- package/dist/src/core/embeddings.d.ts.map +1 -0
- package/dist/src/core/embeddings.js +64 -0
- package/dist/src/core/embeddings.js.map +1 -0
- package/dist/src/core/git-impact.d.ts +25 -0
- package/dist/src/core/git-impact.d.ts.map +1 -0
- package/dist/src/core/git-impact.js +97 -0
- package/dist/src/core/git-impact.js.map +1 -0
- package/dist/src/core/graph-builder.d.ts +5 -0
- package/dist/src/core/graph-builder.d.ts.map +1 -0
- package/dist/src/core/graph-builder.js +88 -0
- package/dist/src/core/graph-builder.js.map +1 -0
- package/dist/src/core/graph.d.ts +34 -0
- package/dist/src/core/graph.d.ts.map +1 -0
- package/dist/src/core/graph.js +95 -0
- package/dist/src/core/graph.js.map +1 -0
- package/dist/src/core/impact.d.ts +22 -0
- package/dist/src/core/impact.d.ts.map +1 -0
- package/dist/src/core/impact.js +68 -0
- package/dist/src/core/impact.js.map +1 -0
- package/dist/src/core/languages.d.ts +4 -0
- package/dist/src/core/languages.d.ts.map +1 -0
- package/dist/src/core/languages.js +59 -0
- package/dist/src/core/languages.js.map +1 -0
- package/dist/src/core/parser.d.ts +16 -0
- package/dist/src/core/parser.d.ts.map +1 -0
- package/dist/src/core/parser.js +689 -0
- package/dist/src/core/parser.js.map +1 -0
- package/dist/src/core/scanner.d.ts +26 -0
- package/dist/src/core/scanner.d.ts.map +1 -0
- package/dist/src/core/scanner.js +87 -0
- package/dist/src/core/scanner.js.map +1 -0
- package/dist/src/core/search.d.ts +34 -0
- package/dist/src/core/search.d.ts.map +1 -0
- package/dist/src/core/search.js +146 -0
- package/dist/src/core/search.js.map +1 -0
- package/dist/src/core/types.d.ts +29 -0
- package/dist/src/core/types.d.ts.map +1 -0
- package/dist/src/core/types.js +12 -0
- package/dist/src/core/types.js.map +1 -0
- package/dist/src/cortex/engine.d.ts +10 -0
- package/dist/src/cortex/engine.d.ts.map +1 -0
- package/dist/src/cortex/engine.js +93 -0
- package/dist/src/cortex/engine.js.map +1 -0
- package/dist/src/cortex/index.d.ts +13 -0
- package/dist/src/cortex/index.d.ts.map +1 -0
- package/dist/src/cortex/index.js +12 -0
- package/dist/src/cortex/index.js.map +1 -0
- package/dist/src/cortex/patterns.d.ts +63 -0
- package/dist/src/cortex/patterns.d.ts.map +1 -0
- package/dist/src/cortex/patterns.js +242 -0
- package/dist/src/cortex/patterns.js.map +1 -0
- package/dist/src/cortex/pgq-queries.d.ts +11 -0
- package/dist/src/cortex/pgq-queries.d.ts.map +1 -0
- package/dist/src/cortex/pgq-queries.js +23 -0
- package/dist/src/cortex/pgq-queries.js.map +1 -0
- package/dist/src/cortex/pgq.d.ts +5 -0
- package/dist/src/cortex/pgq.d.ts.map +1 -0
- package/dist/src/cortex/pgq.js +54 -0
- package/dist/src/cortex/pgq.js.map +1 -0
- package/dist/src/cortex/real-time-enrichment.d.ts +20 -0
- package/dist/src/cortex/real-time-enrichment.d.ts.map +1 -0
- package/dist/src/cortex/real-time-enrichment.js +96 -0
- package/dist/src/cortex/real-time-enrichment.js.map +1 -0
- package/dist/src/cortex/repository.d.ts +231 -0
- package/dist/src/cortex/repository.d.ts.map +1 -0
- package/dist/src/cortex/repository.js +1078 -0
- package/dist/src/cortex/repository.js.map +1 -0
- package/dist/src/cortex/schema.d.ts +9 -0
- package/dist/src/cortex/schema.d.ts.map +1 -0
- package/dist/src/cortex/schema.js +364 -0
- package/dist/src/cortex/schema.js.map +1 -0
- package/dist/src/cortex/stage-0-structure.d.ts +7 -0
- package/dist/src/cortex/stage-0-structure.d.ts.map +1 -0
- package/dist/src/cortex/stage-0-structure.js +119 -0
- package/dist/src/cortex/stage-0-structure.js.map +1 -0
- package/dist/src/cortex/stage-1-symbols.d.ts +7 -0
- package/dist/src/cortex/stage-1-symbols.d.ts.map +1 -0
- package/dist/src/cortex/stage-1-symbols.js +605 -0
- package/dist/src/cortex/stage-1-symbols.js.map +1 -0
- package/dist/src/cortex/stage-2-resolution.d.ts +7 -0
- package/dist/src/cortex/stage-2-resolution.d.ts.map +1 -0
- package/dist/src/cortex/stage-2-resolution.js +469 -0
- package/dist/src/cortex/stage-2-resolution.js.map +1 -0
- package/dist/src/cortex/stage-3-callgraph.d.ts +7 -0
- package/dist/src/cortex/stage-3-callgraph.d.ts.map +1 -0
- package/dist/src/cortex/stage-3-callgraph.js +323 -0
- package/dist/src/cortex/stage-3-callgraph.js.map +1 -0
- package/dist/src/cortex/stage-4-types.d.ts +7 -0
- package/dist/src/cortex/stage-4-types.d.ts.map +1 -0
- package/dist/src/cortex/stage-4-types.js +462 -0
- package/dist/src/cortex/stage-4-types.js.map +1 -0
- package/dist/src/cortex/stage-5-flow.d.ts +7 -0
- package/dist/src/cortex/stage-5-flow.d.ts.map +1 -0
- package/dist/src/cortex/stage-5-flow.js +702 -0
- package/dist/src/cortex/stage-5-flow.js.map +1 -0
- package/dist/src/cortex/stage-6-topology.d.ts +15 -0
- package/dist/src/cortex/stage-6-topology.d.ts.map +1 -0
- package/dist/src/cortex/stage-6-topology.js +382 -0
- package/dist/src/cortex/stage-6-topology.js.map +1 -0
- package/dist/src/cortex/stage-7-intelligence.d.ts +34 -0
- package/dist/src/cortex/stage-7-intelligence.d.ts.map +1 -0
- package/dist/src/cortex/stage-7-intelligence.js +258 -0
- package/dist/src/cortex/stage-7-intelligence.js.map +1 -0
- package/dist/src/cortex/topology-types.d.ts +78 -0
- package/dist/src/cortex/topology-types.d.ts.map +1 -0
- package/dist/src/cortex/topology-types.js +2 -0
- package/dist/src/cortex/topology-types.js.map +1 -0
- package/dist/src/cortex/types.d.ts +250 -0
- package/dist/src/cortex/types.d.ts.map +1 -0
- package/dist/src/cortex/types.js +2 -0
- package/dist/src/cortex/types.js.map +1 -0
- package/dist/src/dna/embeddings.d.ts +10 -0
- package/dist/src/dna/embeddings.d.ts.map +1 -0
- package/dist/src/dna/embeddings.js +46 -0
- package/dist/src/dna/embeddings.js.map +1 -0
- package/dist/src/dna/engine.d.ts +30 -0
- package/dist/src/dna/engine.d.ts.map +1 -0
- package/dist/src/dna/engine.js +254 -0
- package/dist/src/dna/engine.js.map +1 -0
- package/dist/src/dna/index.d.ts +5 -0
- package/dist/src/dna/index.d.ts.map +1 -0
- package/dist/src/dna/index.js +5 -0
- package/dist/src/dna/index.js.map +1 -0
- package/dist/src/dna/storage.d.ts +19 -0
- package/dist/src/dna/storage.d.ts.map +1 -0
- package/dist/src/dna/storage.js +112 -0
- package/dist/src/dna/storage.js.map +1 -0
- package/dist/src/dna/types.d.ts +38 -0
- package/dist/src/dna/types.d.ts.map +1 -0
- package/dist/src/dna/types.js +114 -0
- package/dist/src/dna/types.js.map +1 -0
- package/dist/src/events/bus.d.ts +10 -0
- package/dist/src/events/bus.d.ts.map +1 -0
- package/dist/src/events/bus.js +36 -0
- package/dist/src/events/bus.js.map +1 -0
- package/dist/src/events/ipc.d.ts +3 -0
- package/dist/src/events/ipc.d.ts.map +1 -0
- package/dist/src/events/ipc.js +25 -0
- package/dist/src/events/ipc.js.map +1 -0
- package/dist/src/events/session.d.ts +21 -0
- package/dist/src/events/session.d.ts.map +1 -0
- package/dist/src/events/session.js +39 -0
- package/dist/src/events/session.js.map +1 -0
- package/dist/src/events/types.d.ts +15 -0
- package/dist/src/events/types.d.ts.map +1 -0
- package/dist/src/events/types.js +26 -0
- package/dist/src/events/types.js.map +1 -0
- package/dist/src/hooks/attention.d.ts +26 -0
- package/dist/src/hooks/attention.d.ts.map +1 -0
- package/dist/src/hooks/attention.js +90 -0
- package/dist/src/hooks/attention.js.map +1 -0
- package/dist/src/hooks/handlers/post-tool-use-failure.d.ts +20 -0
- package/dist/src/hooks/handlers/post-tool-use-failure.d.ts.map +1 -0
- package/dist/src/hooks/handlers/post-tool-use-failure.js +60 -0
- package/dist/src/hooks/handlers/post-tool-use-failure.js.map +1 -0
- package/dist/src/hooks/handlers/post-tool-use.d.ts +22 -0
- package/dist/src/hooks/handlers/post-tool-use.d.ts.map +1 -0
- package/dist/src/hooks/handlers/post-tool-use.js +96 -0
- package/dist/src/hooks/handlers/post-tool-use.js.map +1 -0
- package/dist/src/hooks/handlers/pre-compact.d.ts +17 -0
- package/dist/src/hooks/handlers/pre-compact.d.ts.map +1 -0
- package/dist/src/hooks/handlers/pre-compact.js +28 -0
- package/dist/src/hooks/handlers/pre-compact.js.map +1 -0
- package/dist/src/hooks/handlers/pre-tool-use.d.ts +32 -0
- package/dist/src/hooks/handlers/pre-tool-use.d.ts.map +1 -0
- package/dist/src/hooks/handlers/pre-tool-use.js +219 -0
- package/dist/src/hooks/handlers/pre-tool-use.js.map +1 -0
- package/dist/src/hooks/handlers/session-end.d.ts +18 -0
- package/dist/src/hooks/handlers/session-end.d.ts.map +1 -0
- package/dist/src/hooks/handlers/session-end.js +42 -0
- package/dist/src/hooks/handlers/session-end.js.map +1 -0
- package/dist/src/hooks/handlers/session-start.d.ts +25 -0
- package/dist/src/hooks/handlers/session-start.d.ts.map +1 -0
- package/dist/src/hooks/handlers/session-start.js +61 -0
- package/dist/src/hooks/handlers/session-start.js.map +1 -0
- package/dist/src/hooks/handlers/stop.d.ts +21 -0
- package/dist/src/hooks/handlers/stop.d.ts.map +1 -0
- package/dist/src/hooks/handlers/stop.js +40 -0
- package/dist/src/hooks/handlers/stop.js.map +1 -0
- package/dist/src/hooks/handlers/subagent-start.d.ts +17 -0
- package/dist/src/hooks/handlers/subagent-start.d.ts.map +1 -0
- package/dist/src/hooks/handlers/subagent-start.js +48 -0
- package/dist/src/hooks/handlers/subagent-start.js.map +1 -0
- package/dist/src/hooks/handlers/user-prompt-submit.d.ts +12 -0
- package/dist/src/hooks/handlers/user-prompt-submit.d.ts.map +1 -0
- package/dist/src/hooks/handlers/user-prompt-submit.js +31 -0
- package/dist/src/hooks/handlers/user-prompt-submit.js.map +1 -0
- package/dist/src/hooks/index.d.ts +14 -0
- package/dist/src/hooks/index.d.ts.map +1 -0
- package/dist/src/hooks/index.js +13 -0
- package/dist/src/hooks/index.js.map +1 -0
- package/dist/src/hooks/post-tool-use.d.ts +12 -0
- package/dist/src/hooks/post-tool-use.d.ts.map +1 -0
- package/dist/src/hooks/post-tool-use.js +33 -0
- package/dist/src/hooks/post-tool-use.js.map +1 -0
- package/dist/src/hooks/pre-tool-use.d.ts +24 -0
- package/dist/src/hooks/pre-tool-use.d.ts.map +1 -0
- package/dist/src/hooks/pre-tool-use.js +117 -0
- package/dist/src/hooks/pre-tool-use.js.map +1 -0
- package/dist/src/hooks/session-store.d.ts +55 -0
- package/dist/src/hooks/session-store.d.ts.map +1 -0
- package/dist/src/hooks/session-store.js +69 -0
- package/dist/src/hooks/session-store.js.map +1 -0
- package/dist/src/hooks/types.d.ts +67 -0
- package/dist/src/hooks/types.d.ts.map +1 -0
- package/dist/src/hooks/types.js +28 -0
- package/dist/src/hooks/types.js.map +1 -0
- package/dist/src/index.d.ts +16 -0
- package/dist/src/index.d.ts.map +1 -0
- package/dist/src/index.js +16 -0
- package/dist/src/index.js.map +1 -0
- package/dist/src/init/agent-connector.d.ts +43 -0
- package/dist/src/init/agent-connector.d.ts.map +1 -0
- package/dist/src/init/agent-connector.js +338 -0
- package/dist/src/init/agent-connector.js.map +1 -0
- package/dist/src/init/dna-bootstrap.d.ts +10 -0
- package/dist/src/init/dna-bootstrap.d.ts.map +1 -0
- package/dist/src/init/dna-bootstrap.js +32 -0
- package/dist/src/init/dna-bootstrap.js.map +1 -0
- package/dist/src/init/index.d.ts +29 -0
- package/dist/src/init/index.d.ts.map +1 -0
- package/dist/src/init/index.js +81 -0
- package/dist/src/init/index.js.map +1 -0
- package/dist/src/init/overview-generator.d.ts +5 -0
- package/dist/src/init/overview-generator.d.ts.map +1 -0
- package/dist/src/init/overview-generator.js +85 -0
- package/dist/src/init/overview-generator.js.map +1 -0
- package/dist/src/init/parsers/eslint-config.d.ts +10 -0
- package/dist/src/init/parsers/eslint-config.d.ts.map +1 -0
- package/dist/src/init/parsers/eslint-config.js +50 -0
- package/dist/src/init/parsers/eslint-config.js.map +1 -0
- package/dist/src/init/parsers/markdown-rules.d.ts +3 -0
- package/dist/src/init/parsers/markdown-rules.d.ts.map +1 -0
- package/dist/src/init/parsers/markdown-rules.js +90 -0
- package/dist/src/init/parsers/markdown-rules.js.map +1 -0
- package/dist/src/init/parsers/package-json.d.ts +17 -0
- package/dist/src/init/parsers/package-json.d.ts.map +1 -0
- package/dist/src/init/parsers/package-json.js +75 -0
- package/dist/src/init/parsers/package-json.js.map +1 -0
- package/dist/src/init/parsers/prettier-config.d.ts +16 -0
- package/dist/src/init/parsers/prettier-config.d.ts.map +1 -0
- package/dist/src/init/parsers/prettier-config.js +30 -0
- package/dist/src/init/parsers/prettier-config.js.map +1 -0
- package/dist/src/init/parsers/tsconfig.d.ts +32 -0
- package/dist/src/init/parsers/tsconfig.d.ts.map +1 -0
- package/dist/src/init/parsers/tsconfig.js +64 -0
- package/dist/src/init/parsers/tsconfig.js.map +1 -0
- package/dist/src/init/parsers/types.d.ts +27 -0
- package/dist/src/init/parsers/types.d.ts.map +1 -0
- package/dist/src/init/parsers/types.js +2 -0
- package/dist/src/init/parsers/types.js.map +1 -0
- package/dist/src/init/project-analyzer.d.ts +3 -0
- package/dist/src/init/project-analyzer.d.ts.map +1 -0
- package/dist/src/init/project-analyzer.js +102 -0
- package/dist/src/init/project-analyzer.js.map +1 -0
- package/dist/src/init/rule-importer.d.ts +3 -0
- package/dist/src/init/rule-importer.d.ts.map +1 -0
- package/dist/src/init/rule-importer.js +101 -0
- package/dist/src/init/rule-importer.js.map +1 -0
- package/dist/src/mcp/context.d.ts +43 -0
- package/dist/src/mcp/context.d.ts.map +1 -0
- package/dist/src/mcp/context.js +167 -0
- package/dist/src/mcp/context.js.map +1 -0
- package/dist/src/mcp/http-api.d.ts +10 -0
- package/dist/src/mcp/http-api.d.ts.map +1 -0
- package/dist/src/mcp/http-api.js +580 -0
- package/dist/src/mcp/http-api.js.map +1 -0
- package/dist/src/mcp/index.d.ts +8 -0
- package/dist/src/mcp/index.d.ts.map +1 -0
- package/dist/src/mcp/index.js +8 -0
- package/dist/src/mcp/index.js.map +1 -0
- package/dist/src/mcp/resources.d.ts +5 -0
- package/dist/src/mcp/resources.d.ts.map +1 -0
- package/dist/src/mcp/resources.js +78 -0
- package/dist/src/mcp/resources.js.map +1 -0
- package/dist/src/mcp/server.d.ts +6 -0
- package/dist/src/mcp/server.d.ts.map +1 -0
- package/dist/src/mcp/server.js +265 -0
- package/dist/src/mcp/server.js.map +1 -0
- package/dist/src/mcp/tool-response.d.ts +6 -0
- package/dist/src/mcp/tool-response.d.ts.map +1 -0
- package/dist/src/mcp/tool-response.js +19 -0
- package/dist/src/mcp/tool-response.js.map +1 -0
- package/dist/src/mcp/tools/architecture-tools.d.ts +15 -0
- package/dist/src/mcp/tools/architecture-tools.d.ts.map +1 -0
- package/dist/src/mcp/tools/architecture-tools.js +56 -0
- package/dist/src/mcp/tools/architecture-tools.js.map +1 -0
- package/dist/src/mcp/tools/dna-tools.d.ts +21 -0
- package/dist/src/mcp/tools/dna-tools.d.ts.map +1 -0
- package/dist/src/mcp/tools/dna-tools.js +15 -0
- package/dist/src/mcp/tools/dna-tools.js.map +1 -0
- package/dist/src/mcp/tools/graph-tools.d.ts +49 -0
- package/dist/src/mcp/tools/graph-tools.d.ts.map +1 -0
- package/dist/src/mcp/tools/graph-tools.js +45 -0
- package/dist/src/mcp/tools/graph-tools.js.map +1 -0
- package/dist/src/mcp/tools/health-tools.d.ts +5 -0
- package/dist/src/mcp/tools/health-tools.d.ts.map +1 -0
- package/dist/src/mcp/tools/health-tools.js +7 -0
- package/dist/src/mcp/tools/health-tools.js.map +1 -0
- package/dist/src/mcp/tools/impact-tools.d.ts +21 -0
- package/dist/src/mcp/tools/impact-tools.d.ts.map +1 -0
- package/dist/src/mcp/tools/impact-tools.js +23 -0
- package/dist/src/mcp/tools/impact-tools.js.map +1 -0
- package/dist/src/mcp/tools/intent-tools.d.ts +32 -0
- package/dist/src/mcp/tools/intent-tools.d.ts.map +1 -0
- package/dist/src/mcp/tools/intent-tools.js +77 -0
- package/dist/src/mcp/tools/intent-tools.js.map +1 -0
- package/dist/src/mcp/tools/project-tools.d.ts +53 -0
- package/dist/src/mcp/tools/project-tools.d.ts.map +1 -0
- package/dist/src/mcp/tools/project-tools.js +91 -0
- package/dist/src/mcp/tools/project-tools.js.map +1 -0
- package/dist/src/mcp/tools/rename-tool.d.ts +25 -0
- package/dist/src/mcp/tools/rename-tool.d.ts.map +1 -0
- package/dist/src/mcp/tools/rename-tool.js +106 -0
- package/dist/src/mcp/tools/rename-tool.js.map +1 -0
- package/dist/src/mcp/tools/trace-tools.d.ts +4 -0
- package/dist/src/mcp/tools/trace-tools.d.ts.map +1 -0
- package/dist/src/mcp/tools/trace-tools.js +268 -0
- package/dist/src/mcp/tools/trace-tools.js.map +1 -0
- package/dist/src/storage/db.d.ts +13 -0
- package/dist/src/storage/db.d.ts.map +1 -0
- package/dist/src/storage/db.js +230 -0
- package/dist/src/storage/db.js.map +1 -0
- package/dist/src/storage/repository.d.ts +54 -0
- package/dist/src/storage/repository.d.ts.map +1 -0
- package/dist/src/storage/repository.js +257 -0
- package/dist/src/storage/repository.js.map +1 -0
- package/dist/src/utils/config.d.ts +18 -0
- package/dist/src/utils/config.d.ts.map +1 -0
- package/dist/src/utils/config.js +93 -0
- package/dist/src/utils/config.js.map +1 -0
- package/dist/src/utils/files.d.ts +3 -0
- package/dist/src/utils/files.d.ts.map +1 -0
- package/dist/src/utils/files.js +52 -0
- package/dist/src/utils/files.js.map +1 -0
- package/dist/src/utils/strings.d.ts +2 -0
- package/dist/src/utils/strings.d.ts.map +1 -0
- package/dist/src/utils/strings.js +11 -0
- package/dist/src/utils/strings.js.map +1 -0
- package/dist/tsconfig.tsbuildinfo +1 -0
- package/hooks/post-tool-use.sh +37 -0
- package/hooks/pre-tool-use.sh +43 -0
- package/hooks/session-start.sh +67 -0
- package/package.json +103 -0
- package/skills/symbiote-init/SKILL.md +104 -0
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
#!/bin/bash
|
|
2
|
+
|
|
3
|
+
INPUT=$(cat)
|
|
4
|
+
|
|
5
|
+
CWD=$(echo "$INPUT" | python3 -c "import sys,json; print(json.load(sys.stdin).get('cwd',''))" 2>/dev/null) || exit 0
|
|
6
|
+
TOOL=$(echo "$INPUT" | python3 -c "import sys,json; print(json.load(sys.stdin).get('tool_name',''))" 2>/dev/null) || exit 0
|
|
7
|
+
FILE=$(echo "$INPUT" | python3 -c "import sys,json; print(json.load(sys.stdin).get('tool_input',{}).get('file_path',''))" 2>/dev/null) || exit 0
|
|
8
|
+
|
|
9
|
+
[ -z "$CWD" ] && exit 0
|
|
10
|
+
|
|
11
|
+
BRAIN_DIR="$CWD/.brain"
|
|
12
|
+
[ -d "$BRAIN_DIR" ] || exit 0
|
|
13
|
+
|
|
14
|
+
case "$TOOL" in
|
|
15
|
+
Read|Edit|Write) ;;
|
|
16
|
+
*) exit 0 ;;
|
|
17
|
+
esac
|
|
18
|
+
|
|
19
|
+
[ -z "$FILE" ] && exit 0
|
|
20
|
+
|
|
21
|
+
PORT_FILE="$BRAIN_DIR/port"
|
|
22
|
+
[ -f "$PORT_FILE" ] || exit 0
|
|
23
|
+
PORT=$(cat "$PORT_FILE" 2>/dev/null | tr -d '[:space:]')
|
|
24
|
+
[ -z "$PORT" ] && exit 0
|
|
25
|
+
|
|
26
|
+
ENCODED_FILE=$(python3 -c "import urllib.parse,sys; print(urllib.parse.quote(sys.argv[1]))" "$FILE" 2>/dev/null) || exit 0
|
|
27
|
+
ENCODED_TOOL=$(python3 -c "import urllib.parse,sys; print(urllib.parse.quote(sys.argv[1]))" "$TOOL" 2>/dev/null) || exit 0
|
|
28
|
+
ENCODED_ROOT=$(python3 -c "import urllib.parse,sys; print(urllib.parse.quote(sys.argv[1]))" "$CWD" 2>/dev/null) || exit 0
|
|
29
|
+
|
|
30
|
+
RESULT=$(curl -s --max-time 3 "http://127.0.0.1:${PORT}/internal/hook-context?file=${ENCODED_FILE}&tool=${ENCODED_TOOL}&root=${ENCODED_ROOT}" 2>/dev/null) || exit 0
|
|
31
|
+
|
|
32
|
+
CONTEXT=$(echo "$RESULT" | python3 -c "import sys,json; d=json.load(sys.stdin); c=d.get('additionalContext',''); print(c) if c else sys.exit(1)" 2>/dev/null) || exit 0
|
|
33
|
+
|
|
34
|
+
python3 -c "
|
|
35
|
+
import json,sys
|
|
36
|
+
print(json.dumps({
|
|
37
|
+
'hookSpecificOutput': {
|
|
38
|
+
'hookEventName': 'PreToolUse',
|
|
39
|
+
'additionalContext': sys.argv[1]
|
|
40
|
+
}
|
|
41
|
+
}))
|
|
42
|
+
" "$CONTEXT"
|
|
43
|
+
exit 0
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
#!/bin/bash
|
|
2
|
+
# Symbiote SessionStart hook for Claude Code
|
|
3
|
+
# Fires on session startup. Stdout is injected into Claude's context.
|
|
4
|
+
|
|
5
|
+
dir="$PWD"
|
|
6
|
+
found=false
|
|
7
|
+
for i in 1 2 3 4 5; do
|
|
8
|
+
if [ -d "$dir/.brain" ]; then
|
|
9
|
+
found=true
|
|
10
|
+
break
|
|
11
|
+
fi
|
|
12
|
+
parent="$(dirname "$dir")"
|
|
13
|
+
[ "$parent" = "$dir" ] && break
|
|
14
|
+
dir="$parent"
|
|
15
|
+
done
|
|
16
|
+
|
|
17
|
+
if [ "$found" = false ]; then
|
|
18
|
+
exit 0
|
|
19
|
+
fi
|
|
20
|
+
|
|
21
|
+
# Auto-start symbiote serve if not already running
|
|
22
|
+
port_file="$dir/.brain/port"
|
|
23
|
+
if [ -f "$port_file" ]; then
|
|
24
|
+
port=$(cat "$port_file" | tr -d '[:space:]')
|
|
25
|
+
# Check if the server is actually responding
|
|
26
|
+
if ! curl -sf --max-time 1 "http://127.0.0.1:$port/internal/health" > /dev/null 2>&1; then
|
|
27
|
+
# Port file exists but server is dead — clean up and restart
|
|
28
|
+
rm -f "$port_file"
|
|
29
|
+
nohup npx symbiote-cli serve --no-open > /dev/null 2>&1 &
|
|
30
|
+
sleep 1
|
|
31
|
+
fi
|
|
32
|
+
else
|
|
33
|
+
# No port file — start the server
|
|
34
|
+
nohup npx symbiote-cli serve --no-open > /dev/null 2>&1 &
|
|
35
|
+
sleep 1
|
|
36
|
+
fi
|
|
37
|
+
|
|
38
|
+
cat << 'EOF'
|
|
39
|
+
## Symbiote — Project Brain Active
|
|
40
|
+
|
|
41
|
+
This codebase is indexed by Symbiote, providing a living knowledge graph with code structure, dependencies, impact analysis, and developer DNA.
|
|
42
|
+
|
|
43
|
+
**Before making changes, use these MCP tools:**
|
|
44
|
+
- `get_context_for_file` — Dependencies, dependents, constraints for any file (use BEFORE editing)
|
|
45
|
+
- `get_developer_dna` — The developer's coding style and preferences (use to match their conventions)
|
|
46
|
+
- `query_graph` — Search symbols, trace call chains, find dependents
|
|
47
|
+
- `semantic_search` — Natural language search over the codebase
|
|
48
|
+
- `get_health` — Dead code, circular deps, coupling hotspots, constraint violations
|
|
49
|
+
- `get_impact` — Blast radius analysis: what breaks if you change a symbol
|
|
50
|
+
- `detect_changes` — Git diff mapped to affected graph nodes
|
|
51
|
+
- `get_constraints` — Active project rules (enforce these)
|
|
52
|
+
- `get_decisions` — Architectural decisions with rationale
|
|
53
|
+
|
|
54
|
+
**IMPORTANT — When the developer corrects you or states a preference:**
|
|
55
|
+
You MUST call the `record_instruction` MCP tool to capture it in Symbiote's DNA system. This is how Symbiote learns across sessions and tools. Do this IN ADDITION to any other memory you save. Examples of when to call it:
|
|
56
|
+
- "don't use semicolons" → call `record_instruction` with instruction="Don't use semicolons"
|
|
57
|
+
- "prefer early returns" → call `record_instruction` with instruction="Prefer early returns over nested conditions"
|
|
58
|
+
- "no, use X instead of Y" → call `record_instruction` with the correction
|
|
59
|
+
|
|
60
|
+
**Workflow:**
|
|
61
|
+
1. Start with `get_developer_dna` to understand the developer's style
|
|
62
|
+
2. Use `get_context_for_file` before reading or editing any file
|
|
63
|
+
3. Use `get_constraints` to know what rules to follow
|
|
64
|
+
4. When the developer corrects you, ALWAYS call `record_instruction` with their feedback
|
|
65
|
+
EOF
|
|
66
|
+
|
|
67
|
+
exit 0
|
package/package.json
ADDED
|
@@ -0,0 +1,103 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "symbiote-cli",
|
|
3
|
+
"version": "0.1.0",
|
|
4
|
+
"description": "Symbiote bonds with your AI tools — giving them memory, context, and your coding DNA.",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"imports": {
|
|
7
|
+
"#storage/*": "./dist/src/storage/*",
|
|
8
|
+
"#core/*": "./dist/src/core/*",
|
|
9
|
+
"#cortex/*": "./dist/src/cortex/*",
|
|
10
|
+
"#dna/*": "./dist/src/dna/*",
|
|
11
|
+
"#brain/*": "./dist/src/brain/*",
|
|
12
|
+
"#events/*": "./dist/src/events/*",
|
|
13
|
+
"#mcp/*": "./dist/src/mcp/*",
|
|
14
|
+
"#utils/*": "./dist/src/utils/*",
|
|
15
|
+
"#commands/*": "./dist/src/commands/*",
|
|
16
|
+
"#hooks/*": "./dist/src/hooks/*",
|
|
17
|
+
"#init/*": "./dist/src/init/*"
|
|
18
|
+
},
|
|
19
|
+
"bin": {
|
|
20
|
+
"symbiote": "dist/bin/symbiote.js"
|
|
21
|
+
},
|
|
22
|
+
"main": "./dist/src/index.js",
|
|
23
|
+
"types": "./dist/src/index.d.ts",
|
|
24
|
+
"exports": {
|
|
25
|
+
".": {
|
|
26
|
+
"types": "./dist/src/index.d.ts",
|
|
27
|
+
"import": "./dist/src/index.js"
|
|
28
|
+
}
|
|
29
|
+
},
|
|
30
|
+
"files": [
|
|
31
|
+
"dist/",
|
|
32
|
+
"skills/",
|
|
33
|
+
"hooks/",
|
|
34
|
+
"README.md",
|
|
35
|
+
"LICENSE"
|
|
36
|
+
],
|
|
37
|
+
"engines": {
|
|
38
|
+
"node": ">=20"
|
|
39
|
+
},
|
|
40
|
+
"scripts": {
|
|
41
|
+
"build": "tsc",
|
|
42
|
+
"dev": "tsc --watch",
|
|
43
|
+
"test": "vitest run",
|
|
44
|
+
"test:watch": "vitest",
|
|
45
|
+
"type-check": "tsc --noEmit",
|
|
46
|
+
"prepublishOnly": "npm run build"
|
|
47
|
+
},
|
|
48
|
+
"dependencies": {
|
|
49
|
+
"@clack/prompts": "^0.10.0",
|
|
50
|
+
"@duckdb/node-api": "1.5.0-r.1",
|
|
51
|
+
"@huggingface/transformers": "^3.8.1",
|
|
52
|
+
"@modelcontextprotocol/sdk": "^1.27.1",
|
|
53
|
+
"chokidar": "^4.0.0",
|
|
54
|
+
"glob": "^11.0.0",
|
|
55
|
+
"graphology": "^0.25.4",
|
|
56
|
+
"graphology-communities-louvain": "^2.0.1",
|
|
57
|
+
"graphology-metrics": "^2.3.0",
|
|
58
|
+
"picocolors": "^1.1.0",
|
|
59
|
+
"tree-sitter": "^0.22.0",
|
|
60
|
+
"tree-sitter-c": "^0.23.0",
|
|
61
|
+
"tree-sitter-cpp": "^0.23.0",
|
|
62
|
+
"tree-sitter-go": "^0.23.0",
|
|
63
|
+
"tree-sitter-java": "^0.23.0",
|
|
64
|
+
"tree-sitter-javascript": "^0.23.0",
|
|
65
|
+
"tree-sitter-php": "^0.23.0",
|
|
66
|
+
"tree-sitter-python": "^0.23.0",
|
|
67
|
+
"tree-sitter-ruby": "^0.23.0",
|
|
68
|
+
"tree-sitter-rust": "^0.23.0",
|
|
69
|
+
"tree-sitter-typescript": "^0.23.0",
|
|
70
|
+
"zod": "^4.3.6"
|
|
71
|
+
},
|
|
72
|
+
"devDependencies": {
|
|
73
|
+
"@types/node": "^22.0.0",
|
|
74
|
+
"typescript": "^5.7.0",
|
|
75
|
+
"vite-tsconfig-paths": "^6.1.1",
|
|
76
|
+
"vitest": "^3.0.0"
|
|
77
|
+
},
|
|
78
|
+
"keywords": [
|
|
79
|
+
"ai",
|
|
80
|
+
"mcp",
|
|
81
|
+
"mcp-server",
|
|
82
|
+
"ai-coding",
|
|
83
|
+
"claude",
|
|
84
|
+
"cursor",
|
|
85
|
+
"copilot",
|
|
86
|
+
"windsurf",
|
|
87
|
+
"code-context",
|
|
88
|
+
"code-intelligence",
|
|
89
|
+
"tree-sitter",
|
|
90
|
+
"knowledge-graph",
|
|
91
|
+
"developer-tools"
|
|
92
|
+
],
|
|
93
|
+
"author": {
|
|
94
|
+
"name": "Mohamed Ashraf",
|
|
95
|
+
"email": "cupo.ashraf@gmail.com"
|
|
96
|
+
},
|
|
97
|
+
"license": "MIT",
|
|
98
|
+
"repository": {
|
|
99
|
+
"type": "git",
|
|
100
|
+
"url": "git+https://github.com/MohmmedAshraf/symbiote.git"
|
|
101
|
+
},
|
|
102
|
+
"homepage": "https://github.com/MohmmedAshraf/symbiote"
|
|
103
|
+
}
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: symbiote-init
|
|
3
|
+
description: Initialize Symbiote for the current project. Scans the codebase and extracts developer DNA (coding preferences), project constraints, and architectural decisions from the current context. Use when the developer runs /symbiote-init, asks to "initialize symbiote", "set up symbiote", or "scan my project". Requires symbiote-cli to be installed (npx symbiote-cli install).
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Symbiote Project Init
|
|
7
|
+
|
|
8
|
+
Initialize Symbiote for the current project — scan codebase and extract DNA + intent.
|
|
9
|
+
|
|
10
|
+
MCP server is already registered globally by `symbiote install`. This skill only scans and extracts.
|
|
11
|
+
|
|
12
|
+
## Process
|
|
13
|
+
|
|
14
|
+
1. Scan the codebase
|
|
15
|
+
2. Build extraction lists from context
|
|
16
|
+
3. Dispatch subagent to record everything
|
|
17
|
+
4. Print one-line summary
|
|
18
|
+
|
|
19
|
+
## Step 1: Scan
|
|
20
|
+
|
|
21
|
+
```bash
|
|
22
|
+
npx symbiote-cli scan
|
|
23
|
+
```
|
|
24
|
+
|
|
25
|
+
## Step 2: Build Extraction Lists
|
|
26
|
+
|
|
27
|
+
Read your context (CLAUDE.md, memories, rule files) and build three separate lists:
|
|
28
|
+
|
|
29
|
+
### DNA (coding preferences) → `record_instruction`
|
|
30
|
+
|
|
31
|
+
Extract how the developer writes code:
|
|
32
|
+
|
|
33
|
+
- Formatting (indentation, quotes, semicolons, line length)
|
|
34
|
+
- Language conventions (strict TypeScript, ESM, etc.)
|
|
35
|
+
- Code structure (early returns, composition, small functions)
|
|
36
|
+
- Anti-patterns (no `any`, no dead code, no comments)
|
|
37
|
+
- Testing preferences (TDD, isolation, framework)
|
|
38
|
+
- Workflow (conventional commits, small commits)
|
|
39
|
+
|
|
40
|
+
### Constraints (project rules) → `propose_constraint`
|
|
41
|
+
|
|
42
|
+
Extract rules the project enforces:
|
|
43
|
+
|
|
44
|
+
- "All mutations through server actions"
|
|
45
|
+
- "Validate external input with Zod at boundaries"
|
|
46
|
+
- "Tests must mirror src/ structure"
|
|
47
|
+
|
|
48
|
+
### Decisions (architectural choices) → `propose_decision`
|
|
49
|
+
|
|
50
|
+
Extract choices with rationale:
|
|
51
|
+
|
|
52
|
+
- "Chose Vitest over Jest for native ESM support"
|
|
53
|
+
- "Using DuckDB for graph storage — local-first, no external deps"
|
|
54
|
+
- "Switched to Drizzle for better type safety"
|
|
55
|
+
|
|
56
|
+
### What to Skip (applies to all three)
|
|
57
|
+
|
|
58
|
+
- File paths or directory descriptions
|
|
59
|
+
- Tool/product feature lists
|
|
60
|
+
- Author identity
|
|
61
|
+
- CLI commands or usage examples
|
|
62
|
+
- Anything describing WHAT the project IS rather than rules/choices/preferences
|
|
63
|
+
|
|
64
|
+
### Formatting Rules (applies to all three)
|
|
65
|
+
|
|
66
|
+
Each entry must be:
|
|
67
|
+
|
|
68
|
+
- One clear, grammatically correct sentence
|
|
69
|
+
- Self-contained — understandable without context
|
|
70
|
+
- Specific — not vague or overly broad
|
|
71
|
+
|
|
72
|
+
## Step 3: Dispatch Subagent
|
|
73
|
+
|
|
74
|
+
Launch a single Agent to record everything. Pass it all three lists.
|
|
75
|
+
|
|
76
|
+
**Agent prompt template:**
|
|
77
|
+
|
|
78
|
+
```
|
|
79
|
+
Record the following Symbiote entries using MCP tools. Call tools in parallel where possible.
|
|
80
|
+
|
|
81
|
+
**DNA entries** — use `record_instruction` with `isExplicit: true` for each:
|
|
82
|
+
1. [instruction]
|
|
83
|
+
2. [instruction]
|
|
84
|
+
|
|
85
|
+
**Constraints** — use `propose_constraint` for each with `scope: "global"` and a slugified `id`:
|
|
86
|
+
1. [constraint]
|
|
87
|
+
2. [constraint]
|
|
88
|
+
|
|
89
|
+
**Decisions** — use `propose_decision` for each with `scope: "global"` and a slugified `id`:
|
|
90
|
+
1. [decision]
|
|
91
|
+
2. [decision]
|
|
92
|
+
|
|
93
|
+
Return counts: { dna: N, constraints: N, decisions: N, failed: N }
|
|
94
|
+
```
|
|
95
|
+
|
|
96
|
+
## Step 4: Output
|
|
97
|
+
|
|
98
|
+
One line, nothing more:
|
|
99
|
+
|
|
100
|
+
```
|
|
101
|
+
Symbiote initialized — scanned 350 files, recorded 18 DNA entries, 5 constraints, 3 decisions.
|
|
102
|
+
```
|
|
103
|
+
|
|
104
|
+
Do NOT render tables, lists, or per-entry details.
|