@dirgha/code 1.2.1 → 1.4.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/.changeset/README.md +23 -0
- package/.changeset/config.json +11 -0
- package/.changeset/sprint-1.3.0.md +5 -0
- package/CHANGELOG.md +135 -0
- package/CLA.md +104 -0
- package/CODE_OF_CONDUCT.md +50 -0
- package/CONTRIBUTING.md +81 -0
- package/CREDITS.md +46 -0
- package/LICENSING.md +105 -0
- package/README.md +71 -626
- package/SECURITY.md +61 -0
- package/SUPPORT.md +53 -0
- package/assets/audio/dirgha-ambient-150s.m4a +0 -0
- package/assets/logo/dirgha-mark-amber.svg +8 -0
- package/assets/logo/dirgha-mark-cream.svg +8 -0
- package/assets/logo/dirgha-wordmark-cream.svg +5 -0
- package/assets/logo/dirgha-wordmark-ink.svg +5 -0
- package/changelog/1.4.0-promo.mp4 +0 -0
- package/changelog/1.4.0.md +89 -0
- package/changelog/1.4.1-promo.mp4 +0 -0
- package/changelog/README.md +73 -0
- package/dist/agent/capabilities.d.ts +1 -0
- package/dist/agent/capabilities.js +21 -0
- package/dist/agent/collaboration/consensus.d.ts +77 -0
- package/dist/agent/collaboration/consensus.js +279 -0
- package/dist/agent/collaboration/index.d.ts +7 -0
- package/dist/agent/collaboration/index.js +7 -0
- package/dist/agent/collaboration/message-bus.d.ts +48 -0
- package/dist/agent/collaboration/message-bus.js +219 -0
- package/dist/agent/collaboration/shared-context.d.ts +67 -0
- package/dist/agent/collaboration/shared-context.js +217 -0
- package/dist/agent/collaboration/types.d.ts +95 -0
- package/dist/agent/collaboration/types.js +6 -0
- package/dist/agent/commands/chat.d.ts +21 -0
- package/dist/agent/commands/chat.js +55 -0
- package/dist/agent/compaction-tiers.d.ts +10 -0
- package/dist/agent/compaction-tiers.js +70 -0
- package/dist/agent/compaction.d.ts +16 -0
- package/dist/agent/compaction.js +129 -0
- package/dist/agent/context-optimizer.d.ts +2 -0
- package/dist/agent/context-optimizer.js +30 -0
- package/dist/agent/context.d.ts +14 -0
- package/dist/agent/context.js +241 -0
- package/dist/agent/error-classifier.d.ts +10 -0
- package/dist/agent/error-classifier.js +67 -0
- package/dist/agent/event-emit.d.ts +6 -0
- package/dist/agent/event-emit.js +98 -0
- package/dist/agent/executor.d.ts +9 -0
- package/dist/agent/executor.js +44 -0
- package/dist/agent/gateway.d.ts +11 -0
- package/dist/agent/gateway.js +11 -0
- package/dist/agent/index.d.ts +7 -0
- package/dist/agent/index.js +58 -0
- package/dist/agent/injector.d.ts +35 -0
- package/dist/agent/injector.js +57 -0
- package/dist/agent/loop-detector.d.ts +18 -0
- package/dist/agent/loop-detector.js +91 -0
- package/dist/agent/loop.d.ts +22 -0
- package/dist/agent/loop.js +348 -0
- package/dist/agent/memory-sync.d.ts +5 -0
- package/dist/agent/memory-sync.js +17 -0
- package/dist/agent/model-fallback.d.ts +23 -0
- package/dist/agent/model-fallback.js +112 -0
- package/dist/agent/moim.d.ts +5 -0
- package/dist/agent/moim.js +29 -0
- package/dist/agent/orchestration/agent-pool.d.ts +59 -0
- package/dist/agent/orchestration/agent-pool.js +165 -0
- package/dist/agent/orchestration/circuit-breaker.d.ts +121 -0
- package/dist/agent/orchestration/circuit-breaker.js +298 -0
- package/dist/agent/orchestration/coordinator.d.ts +17 -0
- package/dist/agent/orchestration/coordinator.js +150 -0
- package/dist/agent/orchestration/dag-runner.d.ts +18 -0
- package/dist/agent/orchestration/dag-runner.js +172 -0
- package/dist/agent/orchestration/dag.d.ts +33 -0
- package/dist/agent/orchestration/dag.js +209 -0
- package/dist/agent/orchestration/decomposer.d.ts +19 -0
- package/dist/agent/orchestration/decomposer.js +65 -0
- package/dist/agent/orchestration/observability.d.ts +117 -0
- package/dist/agent/orchestration/observability.js +244 -0
- package/dist/agent/orchestration/parallel.d.ts +8 -0
- package/dist/agent/orchestration/parallel.js +191 -0
- package/dist/agent/orchestration/pool-cleanup.d.ts +16 -0
- package/dist/agent/orchestration/pool-cleanup.js +21 -0
- package/dist/agent/orchestration/pool-queue.d.ts +23 -0
- package/dist/agent/orchestration/pool-queue.js +62 -0
- package/dist/agent/orchestration/pool-scaler.d.ts +22 -0
- package/dist/agent/orchestration/pool-scaler.js +53 -0
- package/dist/agent/orchestration/researcher.d.ts +28 -0
- package/dist/agent/orchestration/researcher.js +78 -0
- package/dist/agent/orchestration/retry.d.ts +14 -0
- package/dist/agent/orchestration/retry.js +107 -0
- package/dist/agent/orchestration/scheduler.d.ts +24 -0
- package/dist/agent/orchestration/scheduler.js +66 -0
- package/dist/agent/orchestration/shared-memory.d.ts +31 -0
- package/dist/agent/orchestration/shared-memory.js +57 -0
- package/dist/agent/orchestration/structured.d.ts +63 -0
- package/dist/agent/orchestration/structured.js +152 -0
- package/dist/agent/orchestration/task-queue.d.ts +32 -0
- package/dist/agent/orchestration/task-queue.js +105 -0
- package/dist/agent/orchestration/types.d.ts +139 -0
- package/dist/agent/orchestration/types.js +7 -0
- package/dist/agent/output.d.ts +31 -0
- package/dist/agent/output.js +108 -0
- package/dist/agent/parser.d.ts +5 -0
- package/dist/agent/parser.js +74 -0
- package/dist/agent/pending-messages.d.ts +33 -0
- package/dist/agent/pending-messages.js +57 -0
- package/dist/agent/project.d.ts +2 -0
- package/dist/agent/project.js +19 -0
- package/dist/agent/reflection.d.ts +36 -0
- package/dist/agent/reflection.js +93 -0
- package/dist/agent/rerank-engine.d.ts +18 -0
- package/dist/agent/rerank-engine.js +52 -0
- package/dist/agent/routing.d.ts +10 -0
- package/dist/agent/routing.js +95 -0
- package/dist/agent/secrets.d.ts +6 -0
- package/dist/agent/secrets.js +84 -0
- package/dist/agent/skill-registry.d.ts +37 -0
- package/dist/agent/skill-registry.js +113 -0
- package/dist/agent/spawn/index.d.ts +8 -0
- package/dist/agent/spawn/index.js +5 -0
- package/dist/agent/spawn/lifecycle.d.ts +9 -0
- package/dist/agent/spawn/lifecycle.js +92 -0
- package/dist/agent/spawn/messaging.d.ts +6 -0
- package/dist/agent/spawn/messaging.js +36 -0
- package/dist/agent/spawn/state.d.ts +7 -0
- package/dist/agent/spawn/state.js +57 -0
- package/dist/agent/spawn/types.d.ts +55 -0
- package/dist/agent/spawn/types.js +5 -0
- package/dist/agent/spawn/utils.d.ts +14 -0
- package/dist/agent/spawn/utils.js +72 -0
- package/dist/agent/spawn-agent.d.ts +47 -0
- package/dist/agent/spawn-agent.js +114 -0
- package/dist/agent/structured-output.d.ts +15 -0
- package/dist/agent/structured-output.js +66 -0
- package/dist/agent/tool-execution.d.ts +18 -0
- package/dist/agent/tool-execution.js +242 -0
- package/dist/agent/tools.d.ts +6 -0
- package/dist/agent/tools.js +7 -0
- package/dist/agent/types.d.ts +62 -0
- package/dist/agent/types.js +6 -0
- package/dist/agents/consensus.d.ts +14 -0
- package/dist/agents/consensus.js +34 -0
- package/dist/agents/delegate.d.ts +18 -0
- package/dist/agents/delegate.js +32 -0
- package/dist/agents/ensemble.d.ts +18 -0
- package/dist/agents/ensemble.js +33 -0
- package/dist/agents/orchestrate.d.ts +12 -0
- package/dist/agents/orchestrate.js +32 -0
- package/dist/agents/types.d.ts +29 -0
- package/dist/agents/types.js +2 -0
- package/dist/analytics/export.d.ts +11 -0
- package/dist/analytics/export.js +58 -0
- package/dist/analytics/insights.d.ts +27 -0
- package/dist/analytics/insights.js +33 -0
- package/dist/api/knowledge.d.ts +38 -0
- package/dist/api/knowledge.js +65 -0
- package/dist/billing/db.d.ts +11 -0
- package/dist/billing/db.js +88 -0
- package/dist/billing/index.d.ts +10 -0
- package/dist/billing/index.js +12 -0
- package/dist/billing/meter.d.ts +11 -0
- package/dist/billing/meter.js +46 -0
- package/dist/billing/middleware.d.ts +28 -0
- package/dist/billing/middleware.js +103 -0
- package/dist/billing/pricing.d.ts +6 -0
- package/dist/billing/pricing.js +48 -0
- package/dist/billing/quota.d.ts +24 -0
- package/dist/billing/quota.js +105 -0
- package/dist/billing/ratelimit-fixed.d.ts +16 -0
- package/dist/billing/ratelimit-fixed.js +112 -0
- package/dist/billing/ratelimit.d.ts +7 -0
- package/dist/billing/ratelimit.js +58 -0
- package/dist/billing/tokenizer-v2.d.ts +76 -0
- package/dist/billing/tokenizer-v2.js +263 -0
- package/dist/billing/tokenizer.d.ts +9 -0
- package/dist/billing/tokenizer.js +46 -0
- package/dist/billing/types.d.ts +60 -0
- package/dist/billing/types.js +17 -0
- package/dist/browser/accessibility.d.ts +6 -0
- package/dist/browser/accessibility.js +47 -0
- package/dist/browser/commands.d.ts +5 -0
- package/dist/browser/commands.js +82 -0
- package/dist/browser/ipc-client.d.ts +26 -0
- package/dist/browser/ipc-client.js +60 -0
- package/dist/browser/launcher.d.ts +13 -0
- package/dist/browser/launcher.js +78 -0
- package/dist/browser/navigation.d.ts +12 -0
- package/dist/browser/navigation.js +28 -0
- package/dist/browser/snapshot.d.ts +7 -0
- package/dist/browser/snapshot.js +18 -0
- package/dist/browser/types.d.ts +28 -0
- package/dist/browser/types.js +2 -0
- package/dist/checkpoint/create.d.ts +2 -0
- package/dist/checkpoint/create.js +44 -0
- package/dist/checkpoint/git.d.ts +8 -0
- package/dist/checkpoint/git.js +45 -0
- package/dist/checkpoint/restore.d.ts +5 -0
- package/dist/checkpoint/restore.js +18 -0
- package/dist/checkpoint/store.d.ts +9 -0
- package/dist/checkpoint/store.js +40 -0
- package/dist/checkpoint/types.d.ts +23 -0
- package/dist/checkpoint/types.js +2 -0
- package/dist/commands/agent-swarm.d.ts +7 -0
- package/dist/commands/agent-swarm.js +223 -0
- package/dist/commands/analytics.d.ts +5 -0
- package/dist/commands/analytics.js +20 -0
- package/dist/commands/ask.d.ts +12 -0
- package/dist/commands/ask.js +99 -0
- package/dist/commands/audit.d.ts +5 -0
- package/dist/commands/audit.js +78 -0
- package/dist/commands/auth.d.ts +1 -0
- package/dist/commands/auth.js +126 -0
- package/dist/commands/autocomplete.d.ts +10 -0
- package/dist/commands/autocomplete.js +89 -0
- package/dist/commands/bounties.d.ts +2 -0
- package/dist/commands/bounties.js +107 -0
- package/dist/commands/browser-cmd.d.ts +7 -0
- package/dist/commands/browser-cmd.js +101 -0
- package/dist/commands/browser-integration.d.ts +15 -0
- package/dist/commands/browser-integration.js +58 -0
- package/dist/commands/btw.d.ts +7 -0
- package/dist/commands/btw.js +62 -0
- package/dist/commands/bucky.d.ts +19 -0
- package/dist/commands/bucky.js +328 -0
- package/dist/commands/bug-hunter.d.ts +6 -0
- package/dist/commands/bug-hunter.js +55 -0
- package/dist/commands/capture.d.ts +10 -0
- package/dist/commands/capture.js +167 -0
- package/dist/commands/chat.d.ts +4 -0
- package/dist/commands/chat.js +107 -0
- package/dist/commands/checkpoint.d.ts +6 -0
- package/dist/commands/checkpoint.js +83 -0
- package/dist/commands/coming-soon.d.ts +2 -0
- package/dist/commands/coming-soon.js +50 -0
- package/dist/commands/compact.d.ts +5 -0
- package/dist/commands/compact.js +38 -0
- package/dist/commands/connect.d.ts +7 -0
- package/dist/commands/connect.js +155 -0
- package/dist/commands/curate/embeddings.d.ts +7 -0
- package/dist/commands/curate/embeddings.js +38 -0
- package/dist/commands/curate/files.d.ts +4 -0
- package/dist/commands/curate/files.js +28 -0
- package/dist/commands/curate/project.d.ts +1 -0
- package/dist/commands/curate/project.js +20 -0
- package/dist/commands/curate/schema.d.ts +1 -0
- package/dist/commands/curate/schema.js +30 -0
- package/dist/commands/curate/types.d.ts +26 -0
- package/dist/commands/curate/types.js +6 -0
- package/dist/commands/curate/vss-integration.d.ts +1 -0
- package/dist/commands/curate/vss-integration.js +19 -0
- package/dist/commands/curate.d.ts +9 -0
- package/dist/commands/curate.js +50 -0
- package/dist/commands/dao.d.ts +8 -0
- package/dist/commands/dao.js +290 -0
- package/dist/commands/data-query.d.ts +7 -0
- package/dist/commands/data-query.js +55 -0
- package/dist/commands/doctor.d.ts +2 -0
- package/dist/commands/doctor.js +145 -0
- package/dist/commands/ensemble.d.ts +7 -0
- package/dist/commands/ensemble.js +88 -0
- package/dist/commands/error-recovery.d.ts +10 -0
- package/dist/commands/error-recovery.js +50 -0
- package/dist/commands/export-session.d.ts +7 -0
- package/dist/commands/export-session.js +70 -0
- package/dist/commands/import-session.d.ts +7 -0
- package/dist/commands/import-session.js +49 -0
- package/dist/commands/index.d.ts +62 -0
- package/dist/commands/index.js +76 -0
- package/dist/commands/init.d.ts +5 -0
- package/dist/commands/init.js +101 -0
- package/dist/commands/jobs.d.ts +2 -0
- package/dist/commands/jobs.js +108 -0
- package/dist/commands/join-mesh.d.ts +5 -0
- package/dist/commands/join-mesh.js +97 -0
- package/dist/commands/knowledge.d.ts +19 -0
- package/dist/commands/knowledge.js +218 -0
- package/dist/commands/local.d.ts +2 -0
- package/dist/commands/local.js +77 -0
- package/dist/commands/login.d.ts +10 -0
- package/dist/commands/login.js +160 -0
- package/dist/commands/logout.d.ts +2 -0
- package/dist/commands/logout.js +12 -0
- package/dist/commands/make.d.ts +2 -0
- package/dist/commands/make.js +69 -0
- package/dist/commands/mcp.d.ts +7 -0
- package/dist/commands/mcp.js +202 -0
- package/dist/commands/mesh/add-member.d.ts +2 -0
- package/dist/commands/mesh/add-member.js +23 -0
- package/dist/commands/mesh/ask.d.ts +2 -0
- package/dist/commands/mesh/ask.js +60 -0
- package/dist/commands/mesh/billing.d.ts +1 -0
- package/dist/commands/mesh/billing.js +16 -0
- package/dist/commands/mesh/consensus.d.ts +1 -0
- package/dist/commands/mesh/consensus.js +17 -0
- package/dist/commands/mesh/context.d.ts +4 -0
- package/dist/commands/mesh/context.js +11 -0
- package/dist/commands/mesh/index.d.ts +4 -0
- package/dist/commands/mesh/index.js +64 -0
- package/dist/commands/mesh/join.d.ts +2 -0
- package/dist/commands/mesh/join.js +38 -0
- package/dist/commands/mesh/leave.d.ts +1 -0
- package/dist/commands/mesh/leave.js +14 -0
- package/dist/commands/mesh/quota.d.ts +1 -0
- package/dist/commands/mesh/quota.js +31 -0
- package/dist/commands/mesh/status.d.ts +1 -0
- package/dist/commands/mesh/status.js +48 -0
- package/dist/commands/mesh/types.d.ts +36 -0
- package/dist/commands/mesh/types.js +2 -0
- package/dist/commands/mesh.d.ts +6 -0
- package/dist/commands/mesh.js +258 -0
- package/dist/commands/models.d.ts +1 -0
- package/dist/commands/models.js +194 -0
- package/dist/commands/pay.d.ts +7 -0
- package/dist/commands/pay.js +305 -0
- package/dist/commands/profile.d.ts +2 -0
- package/dist/commands/profile.js +99 -0
- package/dist/commands/progress.d.ts +23 -0
- package/dist/commands/progress.js +93 -0
- package/dist/commands/prune.d.ts +2 -0
- package/dist/commands/prune.js +64 -0
- package/dist/commands/query.d.ts +9 -0
- package/dist/commands/query.js +135 -0
- package/dist/commands/recall-cmd.d.ts +7 -0
- package/dist/commands/recall-cmd.js +65 -0
- package/dist/commands/remember-cmd.d.ts +7 -0
- package/dist/commands/remember-cmd.js +40 -0
- package/dist/commands/research.d.ts +5 -0
- package/dist/commands/research.js +40 -0
- package/dist/commands/sandbox-connect.d.ts +2 -0
- package/dist/commands/sandbox-connect.js +171 -0
- package/dist/commands/scan/arniko.d.ts +1 -0
- package/dist/commands/scan/arniko.js +79 -0
- package/dist/commands/scan/deps.d.ts +21 -0
- package/dist/commands/scan/deps.js +56 -0
- package/dist/commands/scan/index.d.ts +7 -0
- package/dist/commands/scan/index.js +97 -0
- package/dist/commands/scan/output.d.ts +2 -0
- package/dist/commands/scan/output.js +42 -0
- package/dist/commands/scan/types.d.ts +21 -0
- package/dist/commands/scan/types.js +2 -0
- package/dist/commands/scan/utils.d.ts +5 -0
- package/dist/commands/scan/utils.js +101 -0
- package/dist/commands/scan.d.ts +7 -0
- package/dist/commands/scan.js +327 -0
- package/dist/commands/scratchpad.d.ts +8 -0
- package/dist/commands/scratchpad.js +82 -0
- package/dist/commands/session.d.ts +3 -0
- package/dist/commands/session.js +70 -0
- package/dist/commands/setup-local.d.ts +2 -0
- package/dist/commands/setup-local.js +137 -0
- package/dist/commands/setup.d.ts +1 -0
- package/dist/commands/setup.js +230 -0
- package/dist/commands/smart-exec.d.ts +2 -0
- package/dist/commands/smart-exec.js +217 -0
- package/dist/commands/sprint.d.ts +9 -0
- package/dist/commands/sprint.js +321 -0
- package/dist/commands/stats.d.ts +1 -0
- package/dist/commands/stats.js +163 -0
- package/dist/commands/status.d.ts +1 -0
- package/dist/commands/status.js +97 -0
- package/dist/commands/support.d.ts +5 -0
- package/dist/commands/support.js +43 -0
- package/dist/commands/sync.d.ts +7 -0
- package/dist/commands/sync.js +130 -0
- package/dist/commands/unified-memory/context.d.ts +5 -0
- package/dist/commands/unified-memory/context.js +33 -0
- package/dist/commands/unified-memory/index.d.ts +12 -0
- package/dist/commands/unified-memory/index.js +23 -0
- package/dist/commands/unified-memory/recall.d.ts +5 -0
- package/dist/commands/unified-memory/recall.js +50 -0
- package/dist/commands/unified-memory/remember.d.ts +5 -0
- package/dist/commands/unified-memory/remember.js +49 -0
- package/dist/commands/unified-memory/session.d.ts +5 -0
- package/dist/commands/unified-memory/session.js +64 -0
- package/dist/commands/unified-memory/stats.d.ts +5 -0
- package/dist/commands/unified-memory/stats.js +29 -0
- package/dist/commands/update.d.ts +7 -0
- package/dist/commands/update.js +45 -0
- package/dist/commands/voice-entry.d.ts +8 -0
- package/dist/commands/voice-entry.js +120 -0
- package/dist/commands/yolo.d.ts +8 -0
- package/dist/commands/yolo.js +88 -0
- package/dist/compaction/index.d.ts +15 -0
- package/dist/compaction/index.js +21 -0
- package/dist/compaction/protect.d.ts +8 -0
- package/dist/compaction/protect.js +15 -0
- package/dist/compaction/prune.d.ts +5 -0
- package/dist/compaction/prune.js +19 -0
- package/dist/compaction/summarize.d.ts +6 -0
- package/dist/compaction/summarize.js +27 -0
- package/dist/compaction/types.d.ts +27 -0
- package/dist/compaction/types.js +2 -0
- package/dist/compaction/update.d.ts +6 -0
- package/dist/compaction/update.js +18 -0
- package/dist/config/execution.d.ts +22 -0
- package/dist/config/execution.js +59 -0
- package/dist/config/rate-limits.d.ts +15 -0
- package/dist/config/rate-limits.js +34 -0
- package/dist/context/jit.d.ts +16 -0
- package/dist/context/jit.js +120 -0
- package/dist/context/todos.d.ts +7 -0
- package/dist/context/todos.js +21 -0
- package/dist/cron/runner.d.ts +16 -0
- package/dist/cron/runner.js +57 -0
- package/dist/cron/store.d.ts +19 -0
- package/dist/cron/store.js +91 -0
- package/dist/dirgha.mjs +2 -2
- package/dist/embeddings/gateway.d.ts +9 -0
- package/dist/embeddings/gateway.js +55 -0
- package/dist/embeddings/math.d.ts +17 -0
- package/dist/embeddings/math.js +33 -0
- package/dist/embeddings/ollama.d.ts +10 -0
- package/dist/embeddings/ollama.js +74 -0
- package/dist/embeddings/provider.d.ts +28 -0
- package/dist/embeddings/provider.js +73 -0
- package/dist/embeddings/vss.d.ts +22 -0
- package/dist/embeddings/vss.js +102 -0
- package/dist/errors/tokenLimit.d.ts +15 -0
- package/dist/errors/tokenLimit.js +93 -0
- package/dist/extensions/manager.d.ts +6 -0
- package/dist/extensions/manager.js +62 -0
- package/dist/extensions/rpc.d.ts +10 -0
- package/dist/extensions/rpc.js +90 -0
- package/dist/extensions/types.d.ts +24 -0
- package/dist/extensions/types.js +5 -0
- package/dist/fleet/apply-back.d.ts +11 -0
- package/dist/fleet/apply-back.js +82 -0
- package/dist/fleet/commands.d.ts +2 -0
- package/dist/fleet/commands.js +227 -0
- package/dist/fleet/decompose.d.ts +7 -0
- package/dist/fleet/decompose.js +80 -0
- package/dist/fleet/events.d.ts +24 -0
- package/dist/fleet/events.js +35 -0
- package/dist/fleet/runtime.d.ts +9 -0
- package/dist/fleet/runtime.js +131 -0
- package/dist/fleet/tripleshot.d.ts +9 -0
- package/dist/fleet/tripleshot.js +114 -0
- package/dist/fleet/types.d.ts +60 -0
- package/dist/fleet/types.js +11 -0
- package/dist/fleet/worktree.d.ts +17 -0
- package/dist/fleet/worktree.js +80 -0
- package/dist/gateway/acp/adapter.d.ts +46 -0
- package/dist/gateway/acp/adapter.js +181 -0
- package/dist/gateway/acp/index.d.ts +6 -0
- package/dist/gateway/acp/index.js +6 -0
- package/dist/gateway/acp/registry.d.ts +51 -0
- package/dist/gateway/acp/registry.js +171 -0
- package/dist/gateway/acp/types.d.ts +123 -0
- package/dist/gateway/acp/types.js +7 -0
- package/dist/gateway/index.d.ts +5 -0
- package/dist/gateway/index.js +6 -0
- package/dist/gateway/orchestrator.d.ts +8 -0
- package/dist/gateway/orchestrator.js +37 -0
- package/dist/gateway/router.d.ts +34 -0
- package/dist/gateway/router.js +123 -0
- package/dist/gateway/telegram.d.ts +13 -0
- package/dist/gateway/telegram.js +35 -0
- package/dist/gateway/types.d.ts +15 -0
- package/dist/gateway/types.js +2 -0
- package/dist/git/rotation.d.ts +8 -0
- package/dist/git/rotation.js +36 -0
- package/dist/hub/commands.d.ts +15 -0
- package/dist/hub/commands.js +189 -0
- package/dist/hub/index.d.ts +8 -0
- package/dist/hub/index.js +9 -0
- package/dist/hub/installer.d.ts +7 -0
- package/dist/hub/installer.js +148 -0
- package/dist/hub/registry.d.ts +9 -0
- package/dist/hub/registry.js +81 -0
- package/dist/hub/registry.json +82 -0
- package/dist/hub/types.d.ts +73 -0
- package/dist/hub/types.js +6 -0
- package/dist/index-agent.d.ts +1 -0
- package/dist/index-agent.js +17 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.js +442 -0
- package/dist/knowledge/compiler.d.ts +11 -0
- package/dist/knowledge/compiler.js +100 -0
- package/dist/knowledge/git-sync.d.ts +6 -0
- package/dist/knowledge/git-sync.js +81 -0
- package/dist/knowledge/linter.d.ts +9 -0
- package/dist/knowledge/linter.js +136 -0
- package/dist/knowledge/raw.d.ts +20 -0
- package/dist/knowledge/raw.js +87 -0
- package/dist/knowledge/wiki.d.ts +26 -0
- package/dist/knowledge/wiki.js +127 -0
- package/dist/llm/cache.d.ts +16 -0
- package/dist/llm/cache.js +25 -0
- package/dist/llm/costs.d.ts +18 -0
- package/dist/llm/costs.js +30 -0
- package/dist/llm/ensemble.d.ts +5 -0
- package/dist/llm/ensemble.js +40 -0
- package/dist/llm/local.d.ts +23 -0
- package/dist/llm/local.js +78 -0
- package/dist/llm/router.d.ts +7 -0
- package/dist/llm/router.js +68 -0
- package/dist/llm/types.d.ts +18 -0
- package/dist/llm/types.js +2 -0
- package/dist/mcp/client.d.ts +25 -0
- package/dist/mcp/client.js +115 -0
- package/dist/mcp/commands.d.ts +5 -0
- package/dist/mcp/commands.js +30 -0
- package/dist/mcp/index.d.ts +7 -0
- package/dist/mcp/index.js +6 -0
- package/dist/mcp/manager.d.ts +17 -0
- package/dist/mcp/manager.js +67 -0
- package/dist/mcp/marketplace.d.ts +42 -0
- package/dist/mcp/marketplace.js +188 -0
- package/dist/mcp/resources.d.ts +6 -0
- package/dist/mcp/resources.js +26 -0
- package/dist/mcp/server.d.ts +84 -0
- package/dist/mcp/server.js +288 -0
- package/dist/mcp/transport.d.ts +10 -0
- package/dist/mcp/transport.js +30 -0
- package/dist/memory/builtin.d.ts +17 -0
- package/dist/memory/builtin.js +43 -0
- package/dist/memory/gepa-integration.d.ts +49 -0
- package/dist/memory/gepa-integration.js +271 -0
- package/dist/memory/graph.d.ts +19 -0
- package/dist/memory/graph.js +44 -0
- package/dist/memory/holographic.d.ts +11 -0
- package/dist/memory/holographic.js +192 -0
- package/dist/memory/manager.d.ts +36 -0
- package/dist/memory/manager.js +152 -0
- package/dist/memory/provider.d.ts +29 -0
- package/dist/memory/provider.js +9 -0
- package/dist/memory/unified.d.ts +19 -0
- package/dist/memory/unified.js +91 -0
- package/dist/mesh/ConsensusEngine.d.ts +85 -0
- package/dist/mesh/ConsensusEngine.js +187 -0
- package/dist/mesh/LightningBilling.d.ts +124 -0
- package/dist/mesh/LightningBilling.js +284 -0
- package/dist/mesh/MeshNode.d.ts +82 -0
- package/dist/mesh/MeshNode.js +401 -0
- package/dist/mesh/TeamResourcePool.d.ts +93 -0
- package/dist/mesh/TeamResourcePool.js +277 -0
- package/dist/mesh/agent-payments.d.ts +25 -0
- package/dist/mesh/agent-payments.js +79 -0
- package/dist/mesh/capabilities.d.ts +25 -0
- package/dist/mesh/capabilities.js +44 -0
- package/dist/mesh/config.d.ts +37 -0
- package/dist/mesh/config.js +38 -0
- package/dist/mesh/index.d.ts +13 -0
- package/dist/mesh/index.js +11 -0
- package/dist/mesh/reputation.d.ts +21 -0
- package/dist/mesh/reputation.js +51 -0
- package/dist/mesh/revenue-split.d.ts +20 -0
- package/dist/mesh/revenue-split.js +52 -0
- package/dist/mesh/validation.d.ts +5 -0
- package/dist/mesh/validation.js +31 -0
- package/dist/models/credential-pool.d.ts +37 -0
- package/dist/models/credential-pool.js +165 -0
- package/dist/models/index.d.ts +10 -0
- package/dist/models/index.js +13 -0
- package/dist/models/manager.d.ts +34 -0
- package/dist/models/manager.js +197 -0
- package/dist/models/registry.d.ts +27 -0
- package/dist/models/registry.js +359 -0
- package/dist/models/types.d.ts +119 -0
- package/dist/models/types.js +5 -0
- package/dist/multimodal/attachments.d.ts +13 -0
- package/dist/multimodal/attachments.js +99 -0
- package/dist/multimodal/index.d.ts +6 -0
- package/dist/multimodal/index.js +3 -0
- package/dist/multimodal/slash.d.ts +9 -0
- package/dist/multimodal/slash.js +111 -0
- package/dist/multimodal/types.d.ts +30 -0
- package/dist/multimodal/types.js +5 -0
- package/dist/permission/approval.d.ts +18 -0
- package/dist/permission/approval.js +86 -0
- package/dist/permission/confirmation.d.ts +33 -0
- package/dist/permission/confirmation.js +130 -0
- package/dist/permission/judge.d.ts +25 -0
- package/dist/permission/judge.js +162 -0
- package/dist/permission/store.d.ts +12 -0
- package/dist/permission/store.js +50 -0
- package/dist/platform/sync.d.ts +17 -0
- package/dist/platform/sync.js +38 -0
- package/dist/project-session/commands.d.ts +5 -0
- package/dist/project-session/commands.js +220 -0
- package/dist/project-session/context.d.ts +21 -0
- package/dist/project-session/context.js +145 -0
- package/dist/project-session/index.d.ts +8 -0
- package/dist/project-session/index.js +8 -0
- package/dist/project-session/project.d.ts +15 -0
- package/dist/project-session/project.js +107 -0
- package/dist/project-session/session.d.ts +14 -0
- package/dist/project-session/session.js +124 -0
- package/dist/project-session/types.d.ts +85 -0
- package/dist/project-session/types.js +6 -0
- package/dist/providers/anthropic.d.ts +4 -0
- package/dist/providers/anthropic.js +94 -0
- package/dist/providers/circuit-breaker.d.ts +30 -0
- package/dist/providers/circuit-breaker.js +109 -0
- package/dist/providers/cohere.d.ts +2 -0
- package/dist/providers/cohere.js +49 -0
- package/dist/providers/deepinfra.d.ts +32 -0
- package/dist/providers/deepinfra.js +44 -0
- package/dist/providers/detection.d.ts +21 -0
- package/dist/providers/detection.js +88 -0
- package/dist/providers/dirgha.d.ts +3 -0
- package/dist/providers/dirgha.js +26 -0
- package/dist/providers/dispatch.d.ts +28 -0
- package/dist/providers/dispatch.js +262 -0
- package/dist/providers/fireworks.d.ts +2 -0
- package/dist/providers/fireworks.js +109 -0
- package/dist/providers/gateway.d.ts +2 -0
- package/dist/providers/gateway.js +80 -0
- package/dist/providers/gemini.d.ts +3 -0
- package/dist/providers/gemini.js +103 -0
- package/dist/providers/groq.d.ts +2 -0
- package/dist/providers/groq.js +39 -0
- package/dist/providers/http.d.ts +27 -0
- package/dist/providers/http.js +245 -0
- package/dist/providers/index.d.ts +16 -0
- package/dist/providers/index.js +18 -0
- package/dist/providers/messages.d.ts +21 -0
- package/dist/providers/messages.js +116 -0
- package/dist/providers/mistral.d.ts +2 -0
- package/dist/providers/mistral.js +39 -0
- package/dist/providers/normalise.d.ts +5 -0
- package/dist/providers/normalise.js +29 -0
- package/dist/providers/nvidia.d.ts +2 -0
- package/dist/providers/nvidia.js +62 -0
- package/dist/providers/openai.d.ts +3 -0
- package/dist/providers/openai.js +20 -0
- package/dist/providers/openrouter.d.ts +2 -0
- package/dist/providers/openrouter.js +54 -0
- package/dist/providers/perplexity.d.ts +34 -0
- package/dist/providers/perplexity.js +66 -0
- package/dist/providers/rate-limit.d.ts +31 -0
- package/dist/providers/rate-limit.js +101 -0
- package/dist/providers/togetherai.d.ts +32 -0
- package/dist/providers/togetherai.js +44 -0
- package/dist/providers/tools-format.d.ts +2437 -0
- package/dist/providers/tools-format.js +15 -0
- package/dist/providers/types.d.ts +29 -0
- package/dist/providers/types.js +2 -0
- package/dist/providers/unified-rate-limiter.d.ts +116 -0
- package/dist/providers/unified-rate-limiter.js +385 -0
- package/dist/providers/vercel.d.ts +32 -0
- package/dist/providers/vercel.js +44 -0
- package/dist/providers/xai.d.ts +2 -0
- package/dist/providers/xai.js +39 -0
- package/dist/realtime/hub.d.ts +42 -0
- package/dist/realtime/hub.js +147 -0
- package/dist/repl/escape-recovery.d.ts +75 -0
- package/dist/repl/escape-recovery.js +236 -0
- package/dist/repl/index.d.ts +2 -0
- package/dist/repl/index.js +226 -0
- package/dist/repl/input.d.ts +12 -0
- package/dist/repl/input.js +345 -0
- package/dist/repl/renderer.d.ts +23 -0
- package/dist/repl/renderer.js +232 -0
- package/dist/repl/slash/account.d.ts +2 -0
- package/dist/repl/slash/account.js +70 -0
- package/dist/repl/slash/agent-discovery.d.ts +15 -0
- package/dist/repl/slash/agent-discovery.js +227 -0
- package/dist/repl/slash/config.d.ts +2 -0
- package/dist/repl/slash/config.js +223 -0
- package/dist/repl/slash/consensus.d.ts +14 -0
- package/dist/repl/slash/consensus.js +173 -0
- package/dist/repl/slash/context.d.ts +3 -0
- package/dist/repl/slash/context.js +188 -0
- package/dist/repl/slash/cron.d.ts +2 -0
- package/dist/repl/slash/cron.js +83 -0
- package/dist/repl/slash/dev.d.ts +5 -0
- package/dist/repl/slash/dev.js +240 -0
- package/dist/repl/slash/fs.d.ts +10 -0
- package/dist/repl/slash/fs.js +105 -0
- package/dist/repl/slash/git-ext.d.ts +2 -0
- package/dist/repl/slash/git-ext.js +95 -0
- package/dist/repl/slash/git.d.ts +3 -0
- package/dist/repl/slash/git.js +167 -0
- package/dist/repl/slash/hermes.d.ts +2 -0
- package/dist/repl/slash/hermes.js +180 -0
- package/dist/repl/slash/index.d.ts +28 -0
- package/dist/repl/slash/index.js +160 -0
- package/dist/repl/slash/knowledge.d.ts +8 -0
- package/dist/repl/slash/knowledge.js +287 -0
- package/dist/repl/slash/local.d.ts +5 -0
- package/dist/repl/slash/local.js +24 -0
- package/dist/repl/slash/mcp.d.ts +2 -0
- package/dist/repl/slash/mcp.js +63 -0
- package/dist/repl/slash/memory.d.ts +2 -0
- package/dist/repl/slash/memory.js +232 -0
- package/dist/repl/slash/net.d.ts +11 -0
- package/dist/repl/slash/net.js +83 -0
- package/dist/repl/slash/orchestration.d.ts +2 -0
- package/dist/repl/slash/orchestration.js +61 -0
- package/dist/repl/slash/safety.d.ts +2 -0
- package/dist/repl/slash/safety.js +131 -0
- package/dist/repl/slash/screen.d.ts +2 -0
- package/dist/repl/slash/screen.js +202 -0
- package/dist/repl/slash/search.d.ts +2 -0
- package/dist/repl/slash/search.js +211 -0
- package/dist/repl/slash/security.d.ts +2 -0
- package/dist/repl/slash/security.js +102 -0
- package/dist/repl/slash/session.d.ts +2 -0
- package/dist/repl/slash/session.js +498 -0
- package/dist/repl/slash/shortcuts.d.ts +2 -0
- package/dist/repl/slash/shortcuts.js +180 -0
- package/dist/repl/slash/side.d.ts +9 -0
- package/dist/repl/slash/side.js +27 -0
- package/dist/repl/slash/sprint.d.ts +2 -0
- package/dist/repl/slash/sprint.js +189 -0
- package/dist/repl/slash/team.d.ts +15 -0
- package/dist/repl/slash/team.js +235 -0
- package/dist/repl/slash/theme.d.ts +10 -0
- package/dist/repl/slash/theme.js +112 -0
- package/dist/repl/slash/types.d.ts +30 -0
- package/dist/repl/slash/types.js +2 -0
- package/dist/repl/slash/verbose.d.ts +18 -0
- package/dist/repl/slash/verbose.js +38 -0
- package/dist/repl/slash/verify.d.ts +10 -0
- package/dist/repl/slash/verify.js +171 -0
- package/dist/repl/slash/voice.d.ts +5 -0
- package/dist/repl/slash/voice.js +72 -0
- package/dist/repl/slash-git.d.ts +2 -0
- package/dist/repl/slash-git.js +132 -0
- package/dist/repl/slash-workflow.d.ts +2 -0
- package/dist/repl/slash-workflow.js +108 -0
- package/dist/repl/themes.d.ts +24 -0
- package/dist/repl/themes.js +253 -0
- package/dist/runtime/host-tools.d.ts +63 -0
- package/dist/runtime/host-tools.js +204 -0
- package/dist/runtime/index.d.ts +25 -0
- package/dist/runtime/index.js +19 -0
- package/dist/runtime/isolate.d.ts +88 -0
- package/dist/runtime/isolate.js +277 -0
- package/dist/runtime/mount.d.ts +105 -0
- package/dist/runtime/mount.js +458 -0
- package/dist/runtime/multiplayer.d.ts +128 -0
- package/dist/runtime/multiplayer.js +285 -0
- package/dist/runtime/network-control.d.ts +65 -0
- package/dist/runtime/network-control.js +195 -0
- package/dist/runtime/transcript.d.ts +128 -0
- package/dist/runtime/transcript.js +252 -0
- package/dist/runtime/wasm-commands.d.ts +27 -0
- package/dist/runtime/wasm-commands.js +156 -0
- package/dist/security/capabilityTokens.d.ts +44 -0
- package/dist/security/capabilityTokens.js +122 -0
- package/dist/security/csrf.d.ts +53 -0
- package/dist/security/csrf.js +181 -0
- package/dist/security/index.d.ts +6 -0
- package/dist/security/index.js +6 -0
- package/dist/security/rules.d.ts +12 -0
- package/dist/security/rules.js +212 -0
- package/dist/security/safeShell.d.ts +19 -0
- package/dist/security/safeShell.js +82 -0
- package/dist/security/scanner.d.ts +22 -0
- package/dist/security/scanner.js +190 -0
- package/dist/security/types.d.ts +53 -0
- package/dist/security/types.js +6 -0
- package/dist/services/UnifiedAgentClient.d.ts +75 -0
- package/dist/services/UnifiedAgentClient.js +180 -0
- package/dist/services/memory/feature-flag.d.ts +38 -0
- package/dist/services/memory/feature-flag.js +95 -0
- package/dist/services/memory/gepa-wrapper.d.ts +38 -0
- package/dist/services/memory/gepa-wrapper.js +177 -0
- package/dist/session/caps.d.ts +9 -0
- package/dist/session/caps.js +46 -0
- package/dist/session/checkpoint.d.ts +4 -0
- package/dist/session/checkpoint.js +91 -0
- package/dist/session/commands/delete.d.ts +2 -0
- package/dist/session/commands/delete.js +22 -0
- package/dist/session/commands/index.d.ts +7 -0
- package/dist/session/commands/index.js +8 -0
- package/dist/session/commands/list.d.ts +2 -0
- package/dist/session/commands/list.js +39 -0
- package/dist/session/commands/load.d.ts +2 -0
- package/dist/session/commands/load.js +35 -0
- package/dist/session/commands/save.d.ts +2 -0
- package/dist/session/commands/save.js +19 -0
- package/dist/session/db.d.ts +21 -0
- package/dist/session/db.js +289 -0
- package/dist/session/memory.d.ts +6 -0
- package/dist/session/memory.js +67 -0
- package/dist/session/persistence.d.ts +35 -0
- package/dist/session/persistence.js +166 -0
- package/dist/setup/hardwareDetect.d.ts +10 -0
- package/dist/setup/hardwareDetect.js +61 -0
- package/dist/setup/localAIPrompt.d.ts +1 -0
- package/dist/setup/localAIPrompt.js +84 -0
- package/dist/setup/modelCurator.d.ts +20 -0
- package/dist/setup/modelCurator.js +171 -0
- package/dist/skills/generator.d.ts +7 -0
- package/dist/skills/generator.js +76 -0
- package/dist/skills/index.d.ts +71 -0
- package/dist/skills/index.js +365 -0
- package/dist/skills/registry.d.ts +37 -0
- package/dist/skills/registry.js +120 -0
- package/dist/sprint/compressor.d.ts +9 -0
- package/dist/sprint/compressor.js +95 -0
- package/dist/sprint/critic.d.ts +12 -0
- package/dist/sprint/critic.js +44 -0
- package/dist/sprint/escalation.d.ts +12 -0
- package/dist/sprint/escalation.js +116 -0
- package/dist/sprint/executor.d.ts +13 -0
- package/dist/sprint/executor.js +231 -0
- package/dist/sprint/journal.d.ts +28 -0
- package/dist/sprint/journal.js +270 -0
- package/dist/sprint/manifest.d.ts +5 -0
- package/dist/sprint/manifest.js +183 -0
- package/dist/sprint/types.d.ts +96 -0
- package/dist/sprint/types.js +5 -0
- package/dist/sprint/verifier.d.ts +2 -0
- package/dist/sprint/verifier.js +152 -0
- package/dist/sprint/watchdog.d.ts +6 -0
- package/dist/sprint/watchdog.js +144 -0
- package/dist/swarm/agents/VerificationQuorum.d.ts +22 -0
- package/dist/swarm/agents/VerificationQuorum.js +146 -0
- package/dist/swarm/agents/WorkerAgent.d.ts +42 -0
- package/dist/swarm/agents/WorkerAgent.js +130 -0
- package/dist/swarm/collaboration/AgentGit.d.ts +39 -0
- package/dist/swarm/collaboration/AgentGit.js +102 -0
- package/dist/swarm/collaboration/CRDT.d.ts +28 -0
- package/dist/swarm/collaboration/CRDT.js +116 -0
- package/dist/swarm/commands.d.ts +5 -0
- package/dist/swarm/commands.js +144 -0
- package/dist/swarm/governance/CostOptimizer.d.ts +40 -0
- package/dist/swarm/governance/CostOptimizer.js +162 -0
- package/dist/swarm/index.d.ts +15 -0
- package/dist/swarm/index.js +16 -0
- package/dist/swarm/orchestration/ColonyManager.d.ts +45 -0
- package/dist/swarm/orchestration/ColonyManager.js +166 -0
- package/dist/swarm/runtime/ModelPool.d.ts +37 -0
- package/dist/swarm/runtime/ModelPool.js +162 -0
- package/dist/swarm/templates/SalesforceDomains.d.ts +25 -0
- package/dist/swarm/templates/SalesforceDomains.js +340 -0
- package/dist/swarm/testing/MacroTestFramework.d.ts +25 -0
- package/dist/swarm/testing/MacroTestFramework.js +109 -0
- package/dist/swarm/testing/MicroTestFramework.d.ts +23 -0
- package/dist/swarm/testing/MicroTestFramework.js +128 -0
- package/dist/swarm/types.d.ts +227 -0
- package/dist/swarm/types.js +5 -0
- package/dist/sync/engine.d.ts +17 -0
- package/dist/sync/engine.js +107 -0
- package/dist/sync/knowledge.d.ts +30 -0
- package/dist/sync/knowledge.js +155 -0
- package/dist/sync/schema.d.ts +1 -0
- package/dist/sync/schema.js +13 -0
- package/dist/sync/session.d.ts +24 -0
- package/dist/sync/session.js +70 -0
- package/dist/sync/types.d.ts +32 -0
- package/dist/sync/types.js +2 -0
- package/dist/sync/wiki-git.d.ts +17 -0
- package/dist/sync/wiki-git.js +80 -0
- package/dist/task/queue.d.ts +36 -0
- package/dist/task/queue.js +97 -0
- package/dist/tools/browser/agent.d.ts +12 -0
- package/dist/tools/browser/agent.js +119 -0
- package/dist/tools/browser/legacy.d.ts +5 -0
- package/dist/tools/browser/legacy.js +66 -0
- package/dist/tools/browser/utils.d.ts +5 -0
- package/dist/tools/browser/utils.js +27 -0
- package/dist/tools/browser/vision.d.ts +2 -0
- package/dist/tools/browser/vision.js +154 -0
- package/dist/tools/browser.d.ts +7 -0
- package/dist/tools/browser.js +100 -0
- package/dist/tools/defs.d.ts +2575 -0
- package/dist/tools/defs.js +129 -0
- package/dist/tools/deploy.d.ts +17 -0
- package/dist/tools/deploy.js +94 -0
- package/dist/tools/diff-util.d.ts +8 -0
- package/dist/tools/diff-util.js +100 -0
- package/dist/tools/file.d.ts +11 -0
- package/dist/tools/file.js +297 -0
- package/dist/tools/git.d.ts +11 -0
- package/dist/tools/git.js +139 -0
- package/dist/tools/index.d.ts +4 -0
- package/dist/tools/index.js +172 -0
- package/dist/tools/memory-graph.d.ts +21 -0
- package/dist/tools/memory-graph.js +72 -0
- package/dist/tools/memory.d.ts +5 -0
- package/dist/tools/memory.js +55 -0
- package/dist/tools/patch.d.ts +2 -0
- package/dist/tools/patch.js +103 -0
- package/dist/tools/repo.d.ts +2 -0
- package/dist/tools/repo.js +203 -0
- package/dist/tools/sandbox.d.ts +7 -0
- package/dist/tools/sandbox.js +101 -0
- package/dist/tools/search.d.ts +11 -0
- package/dist/tools/search.js +217 -0
- package/dist/tools/session-search.d.ts +2 -0
- package/dist/tools/session-search.js +31 -0
- package/dist/tools/shell-guards.spec.d.ts +1 -0
- package/dist/tools/shell-guards.spec.js +95 -0
- package/dist/tools/shell.d.ts +3 -0
- package/dist/tools/shell.js +241 -0
- package/dist/tools/symbol-graph.d.ts +2 -0
- package/dist/tools/symbol-graph.js +166 -0
- package/dist/tui/App.d.ts +5 -0
- package/dist/tui/App.js +670 -0
- package/dist/tui/TaskQueue.d.ts +68 -0
- package/dist/tui/TaskQueue.js +178 -0
- package/dist/tui/TaskQueueClass.d.ts +18 -0
- package/dist/tui/TaskQueueClass.js +83 -0
- package/dist/tui/TaskQueueTypes.d.ts +20 -0
- package/dist/tui/TaskQueueTypes.js +2 -0
- package/dist/tui/colors.d.ts +6 -0
- package/dist/tui/colors.js +48 -0
- package/dist/tui/commands.d.ts +14 -0
- package/dist/tui/commands.js +109 -0
- package/dist/tui/components/ActivitySummary.d.ts +8 -0
- package/dist/tui/components/ActivitySummary.js +59 -0
- package/dist/tui/components/CodeEditBox.d.ts +42 -0
- package/dist/tui/components/CodeEditBox.js +187 -0
- package/dist/tui/components/CompletedMsg.d.ts +4 -0
- package/dist/tui/components/CompletedMsg.js +40 -0
- package/dist/tui/components/CompletedSystemMsg.d.ts +3 -0
- package/dist/tui/components/CompletedSystemMsg.js +16 -0
- package/dist/tui/components/CompletedToolGroup.d.ts +9 -0
- package/dist/tui/components/CompletedToolGroup.js +47 -0
- package/dist/tui/components/DiffLineItem.d.ts +1 -0
- package/dist/tui/components/DiffLineItem.js +14 -0
- package/dist/tui/components/DiffView.d.ts +2 -0
- package/dist/tui/components/DiffView.js +34 -0
- package/dist/tui/components/ErrorMsg.d.ts +3 -0
- package/dist/tui/components/ErrorMsg.js +24 -0
- package/dist/tui/components/FileComplete.d.ts +8 -0
- package/dist/tui/components/FileComplete.js +18 -0
- package/dist/tui/components/FleetPanel.d.ts +1 -0
- package/dist/tui/components/FleetPanel.js +80 -0
- package/dist/tui/components/HelpOverlay.d.ts +5 -0
- package/dist/tui/components/HelpOverlay.js +88 -0
- package/dist/tui/components/HistorySearch.d.ts +7 -0
- package/dist/tui/components/HistorySearch.js +60 -0
- package/dist/tui/components/InputBox.d.ts +17 -0
- package/dist/tui/components/InputBox.js +57 -0
- package/dist/tui/components/InputHooks.d.ts +12 -0
- package/dist/tui/components/InputHooks.js +214 -0
- package/dist/tui/components/JitterFreeRenderer.d.ts +51 -0
- package/dist/tui/components/JitterFreeRenderer.js +289 -0
- package/dist/tui/components/KeysPicker.d.ts +1 -0
- package/dist/tui/components/KeysPicker.js +54 -0
- package/dist/tui/components/LiveThinkingNode.d.ts +1 -0
- package/dist/tui/components/LiveThinkingNode.js +8 -0
- package/dist/tui/components/LiveView.d.ts +1 -0
- package/dist/tui/components/LiveView.js +34 -0
- package/dist/tui/components/LocalModelRow.d.ts +1 -0
- package/dist/tui/components/LocalModelRow.js +9 -0
- package/dist/tui/components/ModelPicker.d.ts +1 -0
- package/dist/tui/components/ModelPicker.js +41 -0
- package/dist/tui/components/ModelRow.d.ts +1 -0
- package/dist/tui/components/ModelRow.js +8 -0
- package/dist/tui/components/ScrollLogic.d.ts +11 -0
- package/dist/tui/components/ScrollLogic.js +38 -0
- package/dist/tui/components/ScrollView.d.ts +7 -0
- package/dist/tui/components/ScrollView.js +45 -0
- package/dist/tui/components/SessionPicker.d.ts +14 -0
- package/dist/tui/components/SessionPicker.js +37 -0
- package/dist/tui/components/SlashHint.d.ts +3 -0
- package/dist/tui/components/SlashHint.js +16 -0
- package/dist/tui/components/SprintHelpers.d.ts +3 -0
- package/dist/tui/components/SprintHelpers.js +15 -0
- package/dist/tui/components/SprintStatus.d.ts +2 -0
- package/dist/tui/components/SprintStatus.js +31 -0
- package/dist/tui/components/SprintTaskRow.d.ts +1 -0
- package/dist/tui/components/SprintTaskRow.js +8 -0
- package/dist/tui/components/StatusBar.d.ts +16 -0
- package/dist/tui/components/StatusBar.js +29 -0
- package/dist/tui/components/__demos__/CodeEditDemo.d.ts +8 -0
- package/dist/tui/components/__demos__/CodeEditDemo.js +85 -0
- package/dist/tui/components/code-edit/CodeEditBox.d.ts +7 -0
- package/dist/tui/components/code-edit/CodeEditBox.js +16 -0
- package/dist/tui/components/code-edit/components/EditBadge.d.ts +10 -0
- package/dist/tui/components/code-edit/components/EditBadge.js +14 -0
- package/dist/tui/components/code-edit/components/EditItem.d.ts +7 -0
- package/dist/tui/components/code-edit/components/EditItem.js +20 -0
- package/dist/tui/components/code-edit/components/SyntaxHighlighter.d.ts +11 -0
- package/dist/tui/components/code-edit/components/SyntaxHighlighter.js +43 -0
- package/dist/tui/components/code-edit/index.d.ts +17 -0
- package/dist/tui/components/code-edit/index.js +29 -0
- package/dist/tui/components/code-edit/patterns/index.d.ts +6 -0
- package/dist/tui/components/code-edit/patterns/index.js +38 -0
- package/dist/tui/components/code-edit/patterns/javascript.d.ts +5 -0
- package/dist/tui/components/code-edit/patterns/javascript.js +17 -0
- package/dist/tui/components/code-edit/patterns/python.d.ts +5 -0
- package/dist/tui/components/code-edit/patterns/python.js +14 -0
- package/dist/tui/components/code-edit/patterns/typescript.d.ts +5 -0
- package/dist/tui/components/code-edit/patterns/typescript.js +20 -0
- package/dist/tui/components/code-edit/types.d.ts +32 -0
- package/dist/tui/components/code-edit/types.js +5 -0
- package/dist/tui/components/code-edit/utils.d.ts +8 -0
- package/dist/tui/components/code-edit/utils.js +35 -0
- package/dist/tui/components/jitter-free/FrameController.d.ts +13 -0
- package/dist/tui/components/jitter-free/FrameController.js +44 -0
- package/dist/tui/components/jitter-free/JitterFreeRenderer.d.ts +7 -0
- package/dist/tui/components/jitter-free/JitterFreeRenderer.js +22 -0
- package/dist/tui/components/jitter-free/SmoothSpinner.d.ts +7 -0
- package/dist/tui/components/jitter-free/SmoothSpinner.js +23 -0
- package/dist/tui/components/jitter-free/StableCursor.d.ts +7 -0
- package/dist/tui/components/jitter-free/StableCursor.js +15 -0
- package/dist/tui/components/jitter-free/StableScroll.d.ts +7 -0
- package/dist/tui/components/jitter-free/StableScroll.js +27 -0
- package/dist/tui/components/jitter-free/config.d.ts +7 -0
- package/dist/tui/components/jitter-free/config.js +8 -0
- package/dist/tui/components/jitter-free/hooks/index.d.ts +6 -0
- package/dist/tui/components/jitter-free/hooks/index.js +7 -0
- package/dist/tui/components/jitter-free/hooks/useDebounceRender.d.ts +9 -0
- package/dist/tui/components/jitter-free/hooks/useDebounceRender.js +33 -0
- package/dist/tui/components/jitter-free/hooks/useDoubleBuffer.d.ts +10 -0
- package/dist/tui/components/jitter-free/hooks/useDoubleBuffer.js +24 -0
- package/dist/tui/components/jitter-free/hooks/useScrollBuffer.d.ts +9 -0
- package/dist/tui/components/jitter-free/hooks/useScrollBuffer.js +25 -0
- package/dist/tui/components/jitter-free/index.d.ts +12 -0
- package/dist/tui/components/jitter-free/index.js +17 -0
- package/dist/tui/components/jitter-free/types.d.ts +26 -0
- package/dist/tui/components/jitter-free/types.js +5 -0
- package/dist/tui/components/jitter-free/utils.d.ts +15 -0
- package/dist/tui/components/jitter-free/utils.js +46 -0
- package/dist/tui/components/stream/StreamContainer.d.ts +6 -0
- package/dist/tui/components/stream/StreamContainer.js +75 -0
- package/dist/tui/components/stream/ThinkingStream.d.ts +13 -0
- package/dist/tui/components/stream/ThinkingStream.js +21 -0
- package/dist/tui/components/stream/ToolCallArgs.d.ts +3 -0
- package/dist/tui/components/stream/ToolCallArgs.js +7 -0
- package/dist/tui/components/stream/ToolCallBox.d.ts +13 -0
- package/dist/tui/components/stream/ToolCallBox.js +13 -0
- package/dist/tui/components/stream/ToolItem.d.ts +1 -0
- package/dist/tui/components/stream/ToolItem.js +59 -0
- package/dist/tui/components/stream/index.d.ts +9 -0
- package/dist/tui/components/stream/index.js +8 -0
- package/dist/tui/components/stream/types.d.ts +20 -0
- package/dist/tui/components/stream/types.js +2 -0
- package/dist/tui/components/useKeyInput.d.ts +6 -0
- package/dist/tui/components/useKeyInput.js +28 -0
- package/dist/tui/constants.d.ts +7 -0
- package/dist/tui/constants.js +7 -0
- package/dist/tui/helpers/grapheme.d.ts +27 -0
- package/dist/tui/helpers/grapheme.js +116 -0
- package/dist/tui/helpers.d.ts +7 -0
- package/dist/tui/helpers.js +43 -0
- package/dist/tui/index.d.ts +5 -0
- package/dist/tui/index.js +70 -0
- package/dist/tui/input/index.d.ts +5 -0
- package/dist/tui/input/index.js +2 -0
- package/dist/tui/keybindings.d.ts +10 -0
- package/dist/tui/keybindings.js +94 -0
- package/dist/tui/logo.d.ts +1 -0
- package/dist/tui/logo.js +57 -0
- package/dist/tui/markdown.d.ts +6 -0
- package/dist/tui/markdown.js +27 -0
- package/dist/tui/models.d.ts +142 -0
- package/dist/tui/models.js +47 -0
- package/dist/tui/polyfill.d.ts +3 -0
- package/dist/tui/polyfill.js +20 -0
- package/dist/tui/startup-cta.d.ts +18 -0
- package/dist/tui/startup-cta.js +123 -0
- package/dist/tui/syntax-languages.d.ts +4 -0
- package/dist/tui/syntax-languages.js +42 -0
- package/dist/tui/syntax-tokenizer.d.ts +7 -0
- package/dist/tui/syntax-tokenizer.js +137 -0
- package/dist/tui/syntax.d.ts +2 -0
- package/dist/tui/syntax.js +27 -0
- package/dist/tui/system.d.ts +5 -0
- package/dist/tui/system.js +29 -0
- package/dist/tui/themes.d.ts +19 -0
- package/dist/tui/themes.js +75 -0
- package/dist/tui/tui-types.d.ts +28 -0
- package/dist/tui/tui-types.js +2 -0
- package/dist/tui/useAppProcessor.d.ts +5 -0
- package/dist/tui/useAppProcessor.js +63 -0
- package/dist/tui/useAppSession.d.ts +26 -0
- package/dist/tui/useAppSession.js +57 -0
- package/dist/tui/useAppTaskQueue.d.ts +13 -0
- package/dist/tui/useAppTaskQueue.js +26 -0
- package/dist/tui/useStreamThrottle.d.ts +11 -0
- package/dist/tui/useStreamThrottle.js +39 -0
- package/dist/types.d.ts +182 -0
- package/dist/types.js +13 -0
- package/dist/utils/auth.d.ts +5 -0
- package/dist/utils/auth.js +46 -0
- package/dist/utils/config.d.ts +9 -0
- package/dist/utils/config.js +100 -0
- package/dist/utils/context.d.ts +4 -0
- package/dist/utils/context.js +142 -0
- package/dist/utils/credentials.d.ts +23 -0
- package/dist/utils/credentials.js +69 -0
- package/dist/utils/execution-controller.d.ts +45 -0
- package/dist/utils/execution-controller.js +228 -0
- package/dist/utils/experimental.d.ts +16 -0
- package/dist/utils/experimental.js +23 -0
- package/dist/utils/features.d.ts +18 -0
- package/dist/utils/features.js +38 -0
- package/dist/utils/health-monitor.d.ts +49 -0
- package/dist/utils/health-monitor.js +159 -0
- package/dist/utils/id.d.ts +19 -0
- package/dist/utils/id.js +42 -0
- package/dist/utils/index.d.ts +10 -0
- package/dist/utils/index.js +13 -0
- package/dist/utils/keys.d.ts +12 -0
- package/dist/utils/keys.js +50 -0
- package/dist/utils/logger.d.ts +12 -0
- package/dist/utils/logger.js +89 -0
- package/dist/utils/metrics.d.ts +12 -0
- package/dist/utils/metrics.js +36 -0
- package/dist/utils/paste-handler.d.ts +26 -0
- package/dist/utils/paste-handler.js +140 -0
- package/dist/utils/profile.d.ts +16 -0
- package/dist/utils/profile.js +68 -0
- package/dist/utils/project-tracker.d.ts +8 -0
- package/dist/utils/project-tracker.js +66 -0
- package/dist/utils/safe-exec.d.ts +20 -0
- package/dist/utils/safe-exec.js +32 -0
- package/dist/utils/security-boundary.d.ts +53 -0
- package/dist/utils/security-boundary.js +145 -0
- package/dist/utils/session-cache.d.ts +29 -0
- package/dist/utils/session-cache.js +112 -0
- package/dist/utils/soul.d.ts +4 -0
- package/dist/utils/soul.js +104 -0
- package/dist/utils/sqlite-future.d.ts +35 -0
- package/dist/utils/sqlite-future.js +66 -0
- package/dist/utils/sqlite.d.ts +35 -0
- package/dist/utils/sqlite.js +65 -0
- package/dist/utils/startup-profiler.d.ts +26 -0
- package/dist/utils/startup-profiler.js +61 -0
- package/dist/utils/state.d.ts +9 -0
- package/dist/utils/state.js +29 -0
- package/dist/utils/sum.d.ts +6 -0
- package/dist/utils/sum.js +11 -0
- package/dist/utils/token-counter.d.ts +18 -0
- package/dist/utils/token-counter.js +84 -0
- package/dist/utils/unified-memory.d.ts +80 -0
- package/dist/utils/unified-memory.js +171 -0
- package/dist/utils/update-verify.d.ts +7 -0
- package/dist/utils/update-verify.js +64 -0
- package/dist/voice/browser-extension.d.ts +37 -0
- package/dist/voice/browser-extension.js +97 -0
- package/dist/voice/commands.d.ts +5 -0
- package/dist/voice/commands.js +65 -0
- package/dist/voice/desktop.d.ts +42 -0
- package/dist/voice/desktop.js +254 -0
- package/dist/voice/index.d.ts +16 -0
- package/dist/voice/index.js +123 -0
- package/dist/voice/mobile-bridge.d.ts +12 -0
- package/dist/voice/mobile-bridge.js +139 -0
- package/dist/voice/personal-plex.d.ts +61 -0
- package/dist/voice/personal-plex.js +280 -0
- package/dist/voice/plex.d.ts +19 -0
- package/dist/voice/plex.js +55 -0
- package/dist/voice/recorder.d.ts +10 -0
- package/dist/voice/recorder.js +43 -0
- package/dist/voice/shortcuts.d.ts +16 -0
- package/dist/voice/shortcuts.js +31 -0
- package/dist/voice/transcribe.d.ts +3 -0
- package/dist/voice/transcribe.js +36 -0
- package/dist/voice/tts.d.ts +35 -0
- package/dist/voice/tts.js +190 -0
- package/dist/voice/types.d.ts +25 -0
- package/dist/voice/types.js +2 -0
- package/dist/workspace/store.d.ts +48 -0
- package/dist/workspace/store.js +106 -0
- package/dist_v2/audit/writer.d.ts +23 -0
- package/dist_v2/audit/writer.js +34 -0
- package/dist_v2/auth/keypool.d.ts +62 -0
- package/dist_v2/auth/keypool.js +211 -0
- package/dist_v2/auth/keystore.d.ts +20 -0
- package/dist_v2/auth/keystore.js +45 -0
- package/dist_v2/auth/providers.d.ts +35 -0
- package/dist_v2/auth/providers.js +66 -0
- package/dist_v2/cli/config.d.ts +51 -0
- package/dist_v2/cli/flags.js +2 -0
- package/dist_v2/cli/interactive.js +65 -7
- package/dist_v2/cli/main.js +331 -13
- package/dist_v2/cli/setup.js +2 -2
- package/dist_v2/cli/slash/fleet.d.ts +5 -3
- package/dist_v2/cli/slash/fleet.js +40 -13
- package/dist_v2/cli/subcommands/ask.js +3 -1
- package/dist_v2/cli/subcommands/audit-codebase.d.ts +18 -0
- package/dist_v2/cli/subcommands/audit-codebase.js +148 -0
- package/dist_v2/cli/subcommands/audit.js +36 -11
- package/dist_v2/cli/subcommands/chat.js +3 -1
- package/dist_v2/cli/subcommands/cost.d.ts +15 -0
- package/dist_v2/cli/subcommands/cost.js +143 -0
- package/dist_v2/cli/subcommands/index.js +20 -0
- package/dist_v2/cli/subcommands/kb.d.ts +19 -0
- package/dist_v2/cli/subcommands/kb.js +151 -0
- package/dist_v2/cli/subcommands/keys.js +117 -26
- package/dist_v2/cli/subcommands/ledger.d.ts +9 -0
- package/dist_v2/cli/subcommands/ledger.js +130 -0
- package/dist_v2/cli/subcommands/login.d.ts +9 -4
- package/dist_v2/cli/subcommands/login.js +92 -5
- package/dist_v2/cli/subcommands/memory.d.ts +10 -0
- package/dist_v2/cli/subcommands/memory.js +140 -0
- package/dist_v2/cli/subcommands/models.js +80 -3
- package/dist_v2/cli/subcommands/resume.d.ts +11 -0
- package/dist_v2/cli/subcommands/resume.js +138 -0
- package/dist_v2/cli/subcommands/skills.d.ts +14 -0
- package/dist_v2/cli/subcommands/skills.js +207 -0
- package/dist_v2/cli/subcommands/undo.d.ts +17 -0
- package/dist_v2/cli/subcommands/undo.js +144 -0
- package/dist_v2/cli/subcommands/update.d.ts +42 -0
- package/dist_v2/cli/subcommands/update.js +228 -0
- package/dist_v2/cli/subcommands/verify.d.ts +21 -0
- package/dist_v2/cli/subcommands/verify.js +126 -0
- package/dist_v2/context/compaction.d.ts +22 -0
- package/dist_v2/context/compaction.js +38 -0
- package/dist_v2/context/default-soul.md +36 -0
- package/dist_v2/context/git-state.d.ts +23 -0
- package/dist_v2/context/git-state.js +71 -0
- package/dist_v2/context/ledger.d.ts +58 -0
- package/dist_v2/context/ledger.js +178 -0
- package/dist_v2/context/mode-enforcement.d.ts +32 -0
- package/dist_v2/context/mode-enforcement.js +96 -0
- package/dist_v2/context/mode.d.ts +1 -1
- package/dist_v2/context/mode.js +5 -1
- package/dist_v2/context/primer.d.ts +45 -0
- package/dist_v2/context/primer.js +81 -0
- package/dist_v2/context/soul.d.ts +31 -0
- package/dist_v2/context/soul.js +63 -0
- package/dist_v2/extensions/api.d.ts +65 -0
- package/dist_v2/extensions/api.js +126 -0
- package/dist_v2/fleet/cli-command.js +56 -6
- package/dist_v2/fleet/runner.js +18 -4
- package/dist_v2/fleet/types.d.ts +4 -0
- package/dist_v2/hooks/config-bridge.d.ts +22 -0
- package/dist_v2/hooks/config-bridge.js +117 -0
- package/dist_v2/intelligence/models-refresh.d.ts +52 -0
- package/dist_v2/intelligence/models-refresh.js +82 -0
- package/dist_v2/intelligence/prices.d.ts +46 -0
- package/dist_v2/intelligence/prices.js +241 -3
- package/dist_v2/kernel/agent-loop.js +10 -0
- package/dist_v2/mcp/client.d.ts +5 -1
- package/dist_v2/mcp/client.js +34 -4
- package/dist_v2/mcp/loader.d.ts +36 -0
- package/dist_v2/mcp/loader.js +51 -0
- package/dist_v2/mcp/transport.d.ts +44 -0
- package/dist_v2/mcp/transport.js +120 -0
- package/dist_v2/providers/define-openai-compat.d.ts +53 -0
- package/dist_v2/providers/define-openai-compat.js +69 -0
- package/dist_v2/providers/dispatch.js +22 -20
- package/dist_v2/providers/nvidia.js +4 -3
- package/dist_v2/providers/openai-compat.js +49 -2
- package/dist_v2/providers/openrouter.js +7 -2
- package/dist_v2/providers/presets.d.ts +30 -0
- package/dist_v2/providers/presets.js +80 -0
- package/dist_v2/providers/rate-limiter.d.ts +50 -0
- package/dist_v2/providers/rate-limiter.js +93 -0
- package/dist_v2/security/skill-scanner.d.ts +43 -0
- package/dist_v2/security/skill-scanner.js +144 -0
- package/dist_v2/skills/loader.js +50 -5
- package/dist_v2/tools/git.js +8 -0
- package/dist_v2/tui/ink/App.js +143 -13
- package/dist_v2/tui/ink/components/ModelPicker.js +7 -1
- package/dist_v2/tui/ink/components/StatusBar.d.ts +8 -0
- package/dist_v2/tui/ink/components/StatusBar.js +20 -1
- package/dist_v2/tui/theme-loader.d.ts +29 -0
- package/dist_v2/tui/theme-loader.js +67 -0
- package/docs/ARCHITECTURE.md +163 -0
- package/docs/ROADMAP.md +52 -0
- package/docs/agents/arniko-plugin-spec.md +123 -0
- package/docs/agents/files-and-search.md +87 -0
- package/docs/agents/skill-security.md +127 -0
- package/docs/architecture/001-dependency-pinning.md +37 -0
- package/docs/architecture/002-mesh-security.md +36 -0
- package/docs/architecture/003-file-size-limits.md +37 -0
- package/docs/architecture/004-trust-levels.md +40 -0
- package/docs/audits/HY3-AUDIT-2026-04-25.md +47 -0
- package/docs/memory/architecture-efficiency.md +114 -0
- package/docs/memory/km-architecture.md +116 -0
- package/extensions/vscode/README.md +67 -0
- package/extensions/vscode/package.json +105 -0
- package/package.json +62 -94
- package/promo/assets/audio/dirgha-ambient-150s.m4a +0 -0
- package/promo/hyperframes.json +9 -0
- package/promo/index.html +363 -0
- package/promo/meta.json +5 -0
- package/scripts/gen-skill-md.mjs +97 -0
- package/scripts/preview-logos.mjs +113 -0
- package/scripts/qa-app/aliases_test.mjs +70 -0
- package/scripts/qa-app/audit_test.mjs +71 -0
- package/scripts/qa-app/browser_test.mjs +60 -0
- package/scripts/qa-app/cancel_offline_test.mjs +151 -0
- package/scripts/qa-app/cancel_test.mjs +112 -0
- package/scripts/qa-app/checkpoint_test.mjs +87 -0
- package/scripts/qa-app/compaction_test.mjs +112 -0
- package/scripts/qa-app/cost_test.mjs +72 -0
- package/scripts/qa-app/error_classifier_test.mjs +81 -0
- package/scripts/qa-app/extensions_test.mjs +148 -0
- package/scripts/qa-app/git_state_test.mjs +89 -0
- package/scripts/qa-app/hooks_test.mjs +105 -0
- package/scripts/qa-app/ink_smoke.py +151 -0
- package/scripts/qa-app/ink_unit_test.mjs +176 -0
- package/scripts/qa-app/kb_test.mjs +85 -0
- package/scripts/qa-app/kernel_hooks_test.mjs +178 -0
- package/scripts/qa-app/keypool_test.mjs +105 -0
- package/scripts/qa-app/keys_test.mjs +73 -0
- package/scripts/qa-app/ledger_search_test.mjs +74 -0
- package/scripts/qa-app/ledger_test.mjs +73 -0
- package/scripts/qa-app/login_byok_test.mjs +84 -0
- package/scripts/qa-app/mcp_oauth_test.mjs +109 -0
- package/scripts/qa-app/mcp_test.mjs +129 -0
- package/scripts/qa-app/mode_enforcement_test.mjs +88 -0
- package/scripts/qa-app/models_refresh_test.mjs +155 -0
- package/scripts/qa-app/nim_stream_test.mjs +132 -0
- package/scripts/qa-app/output/admin-secrets.json +17 -0
- package/scripts/qa-app/output/admin-secrets.png +0 -0
- package/scripts/qa-app/output/agents.json +17 -0
- package/scripts/qa-app/output/agents.png +0 -0
- package/scripts/qa-app/output/build.json +17 -0
- package/scripts/qa-app/output/build.png +0 -0
- package/scripts/qa-app/output/chat.json +17 -0
- package/scripts/qa-app/output/chat.png +0 -0
- package/scripts/qa-app/output/deploy.json +17 -0
- package/scripts/qa-app/output/deploy.png +0 -0
- package/scripts/qa-app/output/home.json +20 -0
- package/scripts/qa-app/output/home.png +0 -0
- package/scripts/qa-app/output/media.json +17 -0
- package/scripts/qa-app/output/media.png +0 -0
- package/scripts/qa-app/output/memory.json +17 -0
- package/scripts/qa-app/output/memory.png +0 -0
- package/scripts/qa-app/output/models.json +17 -0
- package/scripts/qa-app/output/models.png +0 -0
- package/scripts/qa-app/output/report.json +240 -0
- package/scripts/qa-app/output/report.md +307 -0
- package/scripts/qa-app/output/research.json +17 -0
- package/scripts/qa-app/output/research.png +0 -0
- package/scripts/qa-app/output/security.json +17 -0
- package/scripts/qa-app/output/security.png +0 -0
- package/scripts/qa-app/output/settings.json +17 -0
- package/scripts/qa-app/output/settings.png +0 -0
- package/scripts/qa-app/output/skills.json +17 -0
- package/scripts/qa-app/output/skills.png +0 -0
- package/scripts/qa-app/output/store.json +17 -0
- package/scripts/qa-app/output/store.png +0 -0
- package/scripts/qa-app/primer_test.mjs +71 -0
- package/scripts/qa-app/provider_matrix.mjs +176 -0
- package/scripts/qa-app/qa.py +271 -0
- package/scripts/qa-app/rate_limit_test.mjs +127 -0
- package/scripts/qa-app/registry_test.mjs +57 -0
- package/scripts/qa-app/rescore.py +87 -0
- package/scripts/qa-app/routes.json +20 -0
- package/scripts/qa-app/run-all.mjs +158 -0
- package/scripts/qa-app/session_test.mjs +81 -0
- package/scripts/qa-app/skill_scanner_test.mjs +156 -0
- package/scripts/qa-app/skills_install_test.mjs +100 -0
- package/scripts/qa-app/skills_test.mjs +98 -0
- package/scripts/qa-app/slash_audit.mjs +97 -0
- package/scripts/qa-app/soul_test.mjs +79 -0
- package/scripts/qa-app/task_tool_test.mjs +148 -0
- package/scripts/qa-app/themes_test.mjs +56 -0
- package/scripts/qa-app/tmux_debug.sh +37 -0
- package/scripts/qa-app/tmux_minimal.sh +66 -0
- package/scripts/qa-app/tmux_smoke.sh +119 -0
- package/scripts/qa-app/tokrate_test.mjs +108 -0
- package/scripts/qa-app/tool_registry_test.mjs +118 -0
- package/scripts/qa-app/tools_smoke.mjs +90 -0
- package/scripts/qa-app/transport_test.mjs +88 -0
- package/scripts/qa-app/undo_test.mjs +136 -0
- package/scripts/qa-app/update_test.mjs +94 -0
- package/scripts/test-browser-integration.sh +162 -0
- package/scripts/verify-deps.sh +19 -0
- package/src_v2/README.md +43 -0
- package/src_v2/acp/index.ts +1 -0
- package/src_v2/acp/server.ts +162 -0
- package/src_v2/audit/writer.ts +43 -0
- package/src_v2/auth/keypool.ts +216 -0
- package/src_v2/auth/keystore.ts +43 -0
- package/src_v2/auth/providers.ts +83 -0
- package/src_v2/cli/auth-cmd.ts +78 -0
- package/src_v2/cli/config.ts +130 -0
- package/src_v2/cli/flags.ts +75 -0
- package/src_v2/cli/flows/full-cycle.ts +72 -0
- package/src_v2/cli/flows/index.ts +2 -0
- package/src_v2/cli/flows/tarball.ts +55 -0
- package/src_v2/cli/index.ts +4 -0
- package/src_v2/cli/interactive.ts +307 -0
- package/src_v2/cli/main.ts +486 -0
- package/src_v2/cli/models-cmd.ts +62 -0
- package/src_v2/cli/setup.ts +143 -0
- package/src_v2/cli/slash/account.ts +62 -0
- package/src_v2/cli/slash/clear.ts +17 -0
- package/src_v2/cli/slash/compact.ts +15 -0
- package/src_v2/cli/slash/config.ts +53 -0
- package/src_v2/cli/slash/exit.ts +18 -0
- package/src_v2/cli/slash/fleet.ts +52 -0
- package/src_v2/cli/slash/help.ts +35 -0
- package/src_v2/cli/slash/history.ts +41 -0
- package/src_v2/cli/slash/index.ts +79 -0
- package/src_v2/cli/slash/init.ts +62 -0
- package/src_v2/cli/slash/keys.ts +102 -0
- package/src_v2/cli/slash/login.ts +55 -0
- package/src_v2/cli/slash/memory.ts +102 -0
- package/src_v2/cli/slash/mode.ts +32 -0
- package/src_v2/cli/slash/models.ts +79 -0
- package/src_v2/cli/slash/resume.ts +26 -0
- package/src_v2/cli/slash/session.ts +73 -0
- package/src_v2/cli/slash/setup.ts +48 -0
- package/src_v2/cli/slash/status.ts +38 -0
- package/src_v2/cli/slash/theme.ts +54 -0
- package/src_v2/cli/slash/types.ts +16 -0
- package/src_v2/cli/slash/upgrade.ts +73 -0
- package/src_v2/cli/slash.ts +128 -0
- package/src_v2/cli/subcommands/ask.ts +83 -0
- package/src_v2/cli/subcommands/audit-codebase.ts +161 -0
- package/src_v2/cli/subcommands/audit.ts +152 -0
- package/src_v2/cli/subcommands/chat.ts +72 -0
- package/src_v2/cli/subcommands/compact.ts +110 -0
- package/src_v2/cli/subcommands/cost.ts +157 -0
- package/src_v2/cli/subcommands/doctor.ts +121 -0
- package/src_v2/cli/subcommands/export-session.ts +63 -0
- package/src_v2/cli/subcommands/import-session.ts +87 -0
- package/src_v2/cli/subcommands/index.ts +99 -0
- package/src_v2/cli/subcommands/init.ts +78 -0
- package/src_v2/cli/subcommands/kb.ts +151 -0
- package/src_v2/cli/subcommands/keys.ts +197 -0
- package/src_v2/cli/subcommands/ledger.ts +118 -0
- package/src_v2/cli/subcommands/login.ts +149 -0
- package/src_v2/cli/subcommands/logout.ts +24 -0
- package/src_v2/cli/subcommands/memory.ts +124 -0
- package/src_v2/cli/subcommands/models.ts +210 -0
- package/src_v2/cli/subcommands/resume.ts +142 -0
- package/src_v2/cli/subcommands/setup.ts +111 -0
- package/src_v2/cli/subcommands/skills.ts +190 -0
- package/src_v2/cli/subcommands/stats.ts +151 -0
- package/src_v2/cli/subcommands/status.ts +101 -0
- package/src_v2/cli/subcommands/undo.ts +139 -0
- package/src_v2/cli/subcommands/update.ts +219 -0
- package/src_v2/cli/subcommands/verify.ts +147 -0
- package/src_v2/cli/submit-paper.ts +94 -0
- package/src_v2/context/_fts.ts +251 -0
- package/src_v2/context/branch.ts +86 -0
- package/src_v2/context/compaction.ts +199 -0
- package/src_v2/context/default-soul.md +36 -0
- package/src_v2/context/git-state.ts +78 -0
- package/src_v2/context/index.ts +5 -0
- package/src_v2/context/knowledge.ts +181 -0
- package/src_v2/context/ledger.ts +197 -0
- package/src_v2/context/memory.ts +337 -0
- package/src_v2/context/mode-enforcement.ts +87 -0
- package/src_v2/context/mode.ts +97 -0
- package/src_v2/context/primer.ts +88 -0
- package/src_v2/context/session.ts +115 -0
- package/src_v2/context/soul.ts +72 -0
- package/src_v2/daemon/index.ts +2 -0
- package/src_v2/daemon/protocol.ts +62 -0
- package/src_v2/daemon/server.ts +228 -0
- package/src_v2/eval/index.ts +5 -0
- package/src_v2/eval/regression.ts +116 -0
- package/src_v2/eval/reporter.ts +35 -0
- package/src_v2/eval/swe-bench.ts +32 -0
- package/src_v2/eval/terminal-bench.ts +27 -0
- package/src_v2/eval/types.ts +31 -0
- package/src_v2/extensions/api.ts +144 -0
- package/src_v2/fleet/apply-back.ts +210 -0
- package/src_v2/fleet/cli-command.ts +423 -0
- package/src_v2/fleet/index.ts +37 -0
- package/src_v2/fleet/runner.ts +412 -0
- package/src_v2/fleet/tripleshot.ts +282 -0
- package/src_v2/fleet/types.ts +210 -0
- package/src_v2/fleet/worktree.ts +189 -0
- package/src_v2/hooks/config-bridge.ts +116 -0
- package/src_v2/hooks/index.ts +1 -0
- package/src_v2/hooks/registry.ts +57 -0
- package/src_v2/index.ts +51 -0
- package/src_v2/integrations/arniko-client.ts +108 -0
- package/src_v2/integrations/auth.ts +90 -0
- package/src_v2/integrations/billing.ts +184 -0
- package/src_v2/integrations/bucky-client.ts +93 -0
- package/src_v2/integrations/deploy-client.ts +113 -0
- package/src_v2/integrations/device-auth.ts +224 -0
- package/src_v2/integrations/entitlements.ts +80 -0
- package/src_v2/integrations/http.ts +111 -0
- package/src_v2/integrations/index.ts +17 -0
- package/src_v2/intelligence/cost.ts +80 -0
- package/src_v2/intelligence/error-classifier.ts +76 -0
- package/src_v2/intelligence/index.ts +5 -0
- package/src_v2/intelligence/models-refresh.ts +105 -0
- package/src_v2/intelligence/prices.ts +292 -0
- package/src_v2/intelligence/smart-router.ts +75 -0
- package/src_v2/intelligence/telemetry.ts +50 -0
- package/src_v2/kernel/agent-loop.ts +207 -0
- package/src_v2/kernel/event-stream.ts +122 -0
- package/src_v2/kernel/index.ts +4 -0
- package/src_v2/kernel/message.ts +130 -0
- package/src_v2/kernel/types.ts +175 -0
- package/src_v2/mcp/client.ts +132 -0
- package/src_v2/mcp/index.ts +3 -0
- package/src_v2/mcp/loader.ts +76 -0
- package/src_v2/mcp/tool-bridge.ts +42 -0
- package/src_v2/mcp/transport.ts +217 -0
- package/src_v2/parity/index.ts +3 -0
- package/src_v2/parity/mock-openai-compat.ts +49 -0
- package/src_v2/parity/runner.ts +95 -0
- package/src_v2/parity/scenarios.ts +85 -0
- package/src_v2/providers/anthropic.ts +196 -0
- package/src_v2/providers/define-openai-compat.ts +107 -0
- package/src_v2/providers/dispatch.ts +65 -0
- package/src_v2/providers/fireworks.ts +51 -0
- package/src_v2/providers/gemini.ts +184 -0
- package/src_v2/providers/http.ts +201 -0
- package/src_v2/providers/iface.ts +31 -0
- package/src_v2/providers/index.ts +63 -0
- package/src_v2/providers/nvidia.ts +170 -0
- package/src_v2/providers/ollama.ts +45 -0
- package/src_v2/providers/openai-compat.ts +313 -0
- package/src_v2/providers/openai.ts +124 -0
- package/src_v2/providers/openrouter.ts +83 -0
- package/src_v2/providers/presets.ts +90 -0
- package/src_v2/providers/rate-limiter.ts +103 -0
- package/src_v2/safety/approval-bus.ts +65 -0
- package/src_v2/safety/audit-log.ts +100 -0
- package/src_v2/safety/index.ts +4 -0
- package/src_v2/safety/policy.ts +150 -0
- package/src_v2/safety/sandbox/bwrap.ts +51 -0
- package/src_v2/safety/sandbox/iface.ts +33 -0
- package/src_v2/safety/sandbox/index.ts +7 -0
- package/src_v2/safety/sandbox/landlock.ts +29 -0
- package/src_v2/safety/sandbox/noop.ts +60 -0
- package/src_v2/safety/sandbox/seatbelt.ts +53 -0
- package/src_v2/safety/sandbox/select.ts +37 -0
- package/src_v2/safety/sandbox/windows.ts +26 -0
- package/src_v2/security/skill-scanner.ts +167 -0
- package/src_v2/skills/index.ts +3 -0
- package/src_v2/skills/loader.ts +150 -0
- package/src_v2/skills/matcher.ts +66 -0
- package/src_v2/skills/runtime.ts +47 -0
- package/src_v2/subagents/delegator.ts +116 -0
- package/src_v2/subagents/index.ts +2 -0
- package/src_v2/subagents/pool.ts +41 -0
- package/src_v2/tools/browser.ts +249 -0
- package/src_v2/tools/checkpoint.ts +278 -0
- package/src_v2/tools/cron.ts +191 -0
- package/src_v2/tools/diff.ts +109 -0
- package/src_v2/tools/exec.ts +62 -0
- package/src_v2/tools/fs-edit.ts +96 -0
- package/src_v2/tools/fs-ls.ts +64 -0
- package/src_v2/tools/fs-read.ts +70 -0
- package/src_v2/tools/fs-write.ts +57 -0
- package/src_v2/tools/git.ts +78 -0
- package/src_v2/tools/index.ts +56 -0
- package/src_v2/tools/multimodal.ts +492 -0
- package/src_v2/tools/permission.ts +56 -0
- package/src_v2/tools/registry.ts +97 -0
- package/src_v2/tools/search-glob.ts +97 -0
- package/src_v2/tools/search-grep.ts +116 -0
- package/src_v2/tools/shell.ts +97 -0
- package/src_v2/tools/task.ts +49 -0
- package/src_v2/tui/approval.ts +57 -0
- package/src_v2/tui/index.ts +4 -0
- package/src_v2/tui/ink/App.tsx +439 -0
- package/src_v2/tui/ink/components/AtFileComplete.tsx +183 -0
- package/src_v2/tui/ink/components/HelpOverlay.tsx +181 -0
- package/src_v2/tui/ink/components/InputBox.tsx +199 -0
- package/src_v2/tui/ink/components/Logo.tsx +77 -0
- package/src_v2/tui/ink/components/ModelPicker.tsx +148 -0
- package/src_v2/tui/ink/components/PasteCollapse.tsx +98 -0
- package/src_v2/tui/ink/components/StatusBar.tsx +98 -0
- package/src_v2/tui/ink/components/StreamingText.tsx +30 -0
- package/src_v2/tui/ink/components/ThinkingBlock.tsx +39 -0
- package/src_v2/tui/ink/components/ToolBox.tsx +95 -0
- package/src_v2/tui/ink/components/vim-bindings.ts +150 -0
- package/src_v2/tui/ink/index.ts +69 -0
- package/src_v2/tui/ink/use-event-projection.ts +161 -0
- package/src_v2/tui/ink/use-overlays.ts +69 -0
- package/src_v2/tui/renderer.ts +112 -0
- package/src_v2/tui/status-bar.ts +25 -0
- package/src_v2/tui/theme-loader.ts +68 -0
- package/src_v2/tui/theme.ts +81 -0
- package/src_v2/utils/json-repair.ts +47 -0
- package/tsconfig.tsbuildinfo +1 -0
- package/tsconfig.v2.json +27 -0
package/README.md
CHANGED
|
@@ -1,675 +1,120 @@
|
|
|
1
|
-
|
|
1
|
+
<div align="center">
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
# Dirgha Code
|
|
4
4
|
|
|
5
5
|
[](https://www.npmjs.com/package/@dirgha/code)
|
|
6
|
-
[](https://dirgha.ai/contribute)
|
|
9
|
-
|
|
10
|
-
---
|
|
11
|
-
|
|
12
|
-
```
|
|
13
|
-
◈ Dirgha Code · dirgha.ai · 1.2.0 · nvidia/minimax-m2.7
|
|
14
|
-
──────────────────────────────────────────────────────────
|
|
15
|
-
❯ dirgha fleet launch "migrate auth to JWT + add rate limiter"
|
|
16
|
-
∇ decomposing goal into parallel streams…
|
|
17
|
-
|
|
18
|
-
fleet × 3
|
|
19
|
-
⠙ auth-middleware fleet/auth-middleware 12s
|
|
20
|
-
⠹ jwt-service fleet/jwt-service 9s
|
|
21
|
-
· rate-limiter fleet/rate-limiter 5s — done
|
|
22
|
-
|
|
23
|
-
✓ 3/3 agents completed in 47s · review with `git diff`
|
|
24
|
-
```
|
|
25
|
-
|
|
26
|
-
Dirgha Code writes, edits, runs, and verifies code from your terminal —
|
|
27
|
-
alone or as a **fleet of parallel agents** working in isolated git
|
|
28
|
-
worktrees. It ships with 43 built-in tools, a dispatcher that speaks to
|
|
29
|
-
16 LLM providers with automatic failover, a multi-tier memory system,
|
|
30
|
-
persistent sessions, a sandboxed runtime for user code, and a plugin
|
|
31
|
-
registry. It is entirely one binary you install from npm. No Electron,
|
|
32
|
-
no cloud dependency if you BYOK, no telemetry, full CLI-Anything
|
|
33
|
-
compliance (`--json` on every command).
|
|
34
|
-
|
|
35
|
-
## Install
|
|
36
|
-
|
|
37
|
-
```bash
|
|
38
|
-
npm install -g @dirgha/code # or: pnpm add -g @dirgha/code
|
|
39
|
-
```
|
|
40
|
-
|
|
41
|
-
Requires Node 20+. Binary installs as both `dirgha` and `d`.
|
|
42
|
-
|
|
43
|
-
## Start in 30 seconds
|
|
6
|
+
[](./LICENSE)
|
|
7
|
+
[](https://dirgha.ai/contribute)
|
|
44
8
|
|
|
45
|
-
|
|
46
|
-
reinstalling.
|
|
9
|
+
**Dirgha Code is a CLI coding agent built on four pillars: BYOK, persistent memory, parallel agents, and scanned skills.**
|
|
47
10
|
|
|
48
|
-
|
|
11
|
+
</div>
|
|
49
12
|
|
|
50
|
-
|
|
51
|
-
dirgha login # device-flow browser handshake
|
|
52
|
-
dirgha # launch the TUI
|
|
53
|
-
```
|
|
13
|
+
## What it is
|
|
54
14
|
|
|
55
|
-
|
|
56
|
-
quotas, zero key management.
|
|
15
|
+
A terminal coding assistant that reads your codebase, edits files, runs tests, commits, and audits every step. It runs on your keys, on your machine, with your transcripts staying local until you choose otherwise. When a model rate-limits or times out, the loop swaps to the next-priority key in your pool and resumes from the partial transcript. Your work doesn't vanish when an API hiccups.
|
|
57
16
|
|
|
58
|
-
|
|
17
|
+
## The four pillars
|
|
59
18
|
|
|
60
|
-
|
|
19
|
+
### BYOK across 17 providers
|
|
61
20
|
|
|
62
|
-
|
|
63
|
-
dirgha keys set NVIDIA_API_KEY nvapi-… # MiniMax M2.7, Kimi K2, Llama 4
|
|
64
|
-
dirgha keys set ANTHROPIC_API_KEY sk-ant-… # Claude
|
|
65
|
-
dirgha keys set OPENROUTER_API_KEY sk-or-… # 300+ models
|
|
66
|
-
# …or 11 others — see "Providers" below
|
|
21
|
+
Anthropic, OpenAI, Gemini, OpenRouter, NVIDIA, Fireworks, DeepSeek, Groq, Cerebras, Together, DeepInfra, Mistral, xAI, Perplexity, Cohere, Kimi, Z.AI. Drop multiple keys per provider into a pool — Dirgha rotates with priority + LRU + cooldown when one hits a 429. When a model dies mid-turn, registered backups take over and the agent continues from the partial transcript intact. Other tools restart the conversation.
|
|
67
22
|
|
|
68
|
-
|
|
69
|
-
```
|
|
23
|
+
### Persistent memory that compounds
|
|
70
24
|
|
|
71
|
-
|
|
72
|
-
env at boot. No telemetry, no gateway round-trip.
|
|
25
|
+
Four layers, each cheaper to write than the one above and more curated than the one below:
|
|
73
26
|
|
|
74
|
-
|
|
27
|
+
- **Audit log** — append-only JSONL of every event for forensics.
|
|
28
|
+
- **Memory** — curated key-value facts loaded into the system prompt at boot.
|
|
29
|
+
- **Ledger** — per-scope JSONL of decisions and observations, plus an agent-rewritten digest, searchable by TF-IDF cosine ranking.
|
|
30
|
+
- **Knowledge base** — your `docs/` compiled into a wiki via OpenKB + PageIndex. Vectorless, reasoning-based retrieval. The agent reasons over a table of contents instead of re-reading files every turn.
|
|
75
31
|
|
|
76
|
-
|
|
77
|
-
# Single-turn
|
|
78
|
-
dirgha ask "summarise the failing tests" --json
|
|
32
|
+
Information flows up. Old context gets distilled, not discarded.
|
|
79
33
|
|
|
80
|
-
|
|
81
|
-
dirgha fleet launch "refactor auth + add tests" --concurrency 3
|
|
34
|
+
### Parallel agents
|
|
82
35
|
|
|
83
|
-
|
|
84
|
-
dirgha signup
|
|
85
|
-
```
|
|
86
|
-
|
|
87
|
-
Every command supports `--json` — parseable envelope with `data`, `text`,
|
|
88
|
-
`exitCode`, `timestamp`, and `meta.durationMs` (CLI-Anything spec).
|
|
36
|
+
`dirgha fleet launch "<goal>"` decomposes the goal into N independent tasks, spawns each in its own git worktree, runs them in parallel, and merges the winners back. `dirgha fleet triple "<goal>"` runs three approaches and lets a judge pick. Inside any session, the agent can call the `task` tool to dispatch a fresh sub-agent with its own context budget for a sub-problem — no compaction loss on the parent.
|
|
89
37
|
|
|
90
|
-
|
|
38
|
+
### Skills, scanned
|
|
91
39
|
|
|
92
|
-
|
|
40
|
+
SKILL.md packs are portable Markdown agents — share one git URL, anyone can `dirgha skills install <url>`. Every third-party skill is scanned at install AND load time by a heuristic prompt-injection / supply-chain check. Critical findings block. Today: 112 installed across 4 packs, 74 allow · 36 warn · 2 block. TypeScript / ESM plugins are the sibling concept — drop a `.mjs` at `~/.dirgha/extensions/<name>/index.mjs` and register tools, slashes, subcommands, or lifecycle hooks in ~20 lines.
|
|
93
41
|
|
|
94
|
-
|
|
95
|
-
worktrees**. One command decomposes a goal into independent streams,
|
|
96
|
-
spawns N agents concurrently, and lets you review their diffs before
|
|
97
|
-
anything touches your working tree.
|
|
42
|
+
## Install
|
|
98
43
|
|
|
99
44
|
```bash
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
dirgha
|
|
103
|
-
dirgha fleet merge <agent-id> # 3-way apply-back to your branch
|
|
104
|
-
dirgha fleet cleanup # tear down worktrees + branches
|
|
45
|
+
npm install -g @dirgha/code # or: pnpm add -g @dirgha/code
|
|
46
|
+
export NVIDIA_API_KEY=nvapi-… # or OPENROUTER_API_KEY, ANTHROPIC_API_KEY, …
|
|
47
|
+
dirgha "say ok in one word" -m deepseek
|
|
105
48
|
```
|
|
106
49
|
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
## Why this exists
|
|
110
|
-
|
|
111
|
-
Frontier coding assistants are closed SaaS on someone else's cluster, charging
|
|
112
|
-
per-seat, piping your repository through their telemetry. The assumption is
|
|
113
|
-
that the intelligence must live at the vendor.
|
|
114
|
-
|
|
115
|
-
Dirgha Code is built from the opposite assumption. Your laptop is the unit of
|
|
116
|
-
sovereignty. Your keys, your wallet, your session database, your tool
|
|
117
|
-
executions all live on your machine until you explicitly choose to hit a
|
|
118
|
-
network. Providers are swappable, not sacred. The agent loop itself is open
|
|
119
|
-
source and forkable.
|
|
50
|
+
The interactive TUI is `dirgha` with no args. Resume a session with `dirgha resume <id>`. Fan a parallel sub-agent fleet with `dirgha fleet launch "<goal>"`.
|
|
120
51
|
|
|
121
|
-
|
|
52
|
+
## What's in the box
|
|
122
53
|
|
|
123
|
-
|
|
54
|
+
| | |
|
|
55
|
+
|---|---|
|
|
56
|
+
| **17 providers** | anthropic, openai, gemini, openrouter, nvidia, fireworks, deepseek, groq, cerebras, together, deepinfra, mistral, xai, perplexity, cohere, kimi, zai |
|
|
57
|
+
| **34 model aliases** | `kimi`, `opus`, `sonnet`, `haiku`, `gemini`, `flash`, `deepseek`, `llama`, `ling`, `hy3`, … resolved before routing |
|
|
58
|
+
| **12 built-in tools** | `fs_read`, `fs_write`, `fs_edit`, `fs_ls`, `shell`, `search_grep`, `search_glob`, `git`, `browser`, `checkpoint`, `cron`, `task` |
|
|
59
|
+
| **20 slash commands** | `/account`, `/clear`, `/compact`, `/cost`, `/fleet`, `/keys`, `/login`, `/memory`, `/mode`, `/models`, `/resume`, `/session`, `/status`, `/theme`, `/upgrade`, … |
|
|
60
|
+
| **18 subcommands** | `audit`, `audit-codebase`, `cost`, `kb`, `keys`, `ledger`, `login`, `models`, `resume`, `skills`, `undo`, `update`, `verify`, … |
|
|
61
|
+
| **4 modes** | `act` · `plan` (read-only thinking) · `verify` (read-only audit) · `ask` (read-only Q&A) |
|
|
62
|
+
| **MCP** | stdio + HTTP/SSE + `bearerProvider` async OAuth rotation |
|
|
63
|
+
| **Source** | ~14.5 K LOC across 23 modules in `src_v2/`. Hard rule: every src file ≤ 200 lines. |
|
|
124
64
|
|
|
125
|
-
|
|
126
|
-
┌──────────────────────────────────────────────────────────────────────┐
|
|
127
|
-
│ Ink/React TUI │
|
|
128
|
-
│ InputBox · LiveView · StatusBar · ModelPicker · SlashHint │
|
|
129
|
-
│ ─── useInput (raw mode) · bracketed paste · cursor blink ── │
|
|
130
|
-
└────────────────────────┬─────────────────────────────────────────────┘
|
|
131
|
-
│ user turn
|
|
132
|
-
┌────────────────────────▼─────────────────────────────────────────────┐
|
|
133
|
-
│ Agent Loop │
|
|
134
|
-
│ ┌──────────────┐ ┌─────────────┐ ┌───────────────┐ │
|
|
135
|
-
│ │ context/JIT │ │ compaction │ │ loop-detector │ │
|
|
136
|
-
│ │ system-prompt│→ │ tiered │→ │ 60k-tok ceil. │ │
|
|
137
|
-
│ └──────────────┘ └─────────────┘ └───────────────┘ │
|
|
138
|
-
│ │ │ │
|
|
139
|
-
│ ▼ ▼ │
|
|
140
|
-
│ ┌──────────────┐ pending-messages ┌───────────────┐ │
|
|
141
|
-
│ │ providers/ │◀ ─ mid-turn inject ─ │ tool exec │ │
|
|
142
|
-
│ │ dispatch │ │ 11 tools │ │
|
|
143
|
-
│ └──────┬───────┘ └───────┬──────┘ │
|
|
144
|
-
│ │ │ │
|
|
145
|
-
│ ▼ 429/502/timeout → next hop ▼ │
|
|
146
|
-
│ ┌──────────────┐ ┌────────────┐ │
|
|
147
|
-
│ │ 14 providers│ │ tool runtime│ │
|
|
148
|
-
│ └──────────────┘ │ · host │ │
|
|
149
|
-
│ │ · sandbox │ │
|
|
150
|
-
│ │ · MCP │ │
|
|
151
|
-
│ │ · hub │ │
|
|
152
|
-
│ └────────────┘ │
|
|
153
|
-
└──────────────────────────────────────────────────────────────────────┘
|
|
154
|
-
│ │ │
|
|
155
|
-
▼ ▼ ▼
|
|
156
|
-
┌──────────┐ ┌──────────────────┐ ┌─────────────────┐
|
|
157
|
-
│ sessions │ │ memory system │ │ filesystem │
|
|
158
|
-
│ SQLite │ │ · builtin │ │ edit/diff/patch│
|
|
159
|
-
│ ~/.dirgha│ │ · holographic │ │ repo-rooted │
|
|
160
|
-
│ │ │ · gepa (LLM-opt)│ │ │
|
|
161
|
-
│ │ │ · memory-graph │ │ │
|
|
162
|
-
└──────────┘ └──────────────────┘ └─────────────────┘
|
|
163
|
-
```
|
|
65
|
+
## Numbers worth checking
|
|
164
66
|
|
|
165
|
-
|
|
166
|
-
across ~50,000 lines of TypeScript**, 59 test files, one bundled distribution.
|
|
167
|
-
|
|
168
|
-
## Memory system
|
|
169
|
-
|
|
170
|
-
Dirgha Code has four layers of memory, each with a different persistence
|
|
171
|
-
model and retrieval pattern. They compose — a single `save_memory` call can
|
|
172
|
-
write through all four. Retrieval picks the lightest tier that answers the
|
|
173
|
-
query.
|
|
174
|
-
|
|
175
|
-
### 1. Built-in memory (`memory/builtin.ts`)
|
|
176
|
-
|
|
177
|
-
- **Where:** `~/.dirgha/sessions.db` (SQLite), `memories` table
|
|
178
|
-
- **Shape:** key → content, key is caller-chosen
|
|
179
|
-
- **Retrieval:** exact key match via `read_memory`, full-text scan via
|
|
180
|
-
`search_knowledge`
|
|
181
|
-
- **Use:** the classic "persist this across sessions" slot. Reliable,
|
|
182
|
-
synchronous, local-only.
|
|
183
|
-
|
|
184
|
-
### 2. Holographic memory (`memory/holographic.ts`)
|
|
185
|
-
|
|
186
|
-
- **Where:** SQLite FTS5 virtual table, same DB
|
|
187
|
-
- **Shape:** text + trust score + timestamp + source
|
|
188
|
-
- **Retrieval:** BM25-ranked full-text, weighted by freshness and trust
|
|
189
|
-
- **Use:** "show me everything the agent learned about the auth module last
|
|
190
|
-
week" — dense, forgettable, repo-aware. Trust score decays; stale entries
|
|
191
|
-
get pruned by the maintenance job.
|
|
192
|
-
|
|
193
|
-
### 3. GEPA integration (`memory/gepa-integration.ts`)
|
|
194
|
-
|
|
195
|
-
- **Where:** model-specific prompt compilation, cached on disk
|
|
196
|
-
- **Shape:** optimised few-shot prompts produced by GEPA
|
|
197
|
-
(Gradient-free Evolutionary Prompt Adaptation)
|
|
198
|
-
- **Retrieval:** loaded into the system prompt when a matching task is
|
|
199
|
-
detected
|
|
200
|
-
- **Use:** the agent gets better at recurring tasks (test writing, refactor
|
|
201
|
-
patterns, PR reviews) because each round's success/failure retrains the
|
|
202
|
-
prompt library. Opt-in; does not block the basic loop.
|
|
203
|
-
|
|
204
|
-
### 4. Memory graph (`tools/memory-graph.ts`, Qdrant-backed)
|
|
205
|
-
|
|
206
|
-
- **Where:** a running Qdrant instance (local or hosted) + local cache
|
|
207
|
-
- **Shape:** nodes with embeddings + directed edges with types
|
|
208
|
-
- **Retrieval:** semantic search + graph walk via `memory_graph_query`
|
|
209
|
-
- **Use:** "show me everything related to `OrderBuilder` across all my
|
|
210
|
-
projects and sessions." Cross-repo, cross-temporal, knowledge-graph style.
|
|
211
|
-
Heavy — optional infrastructure.
|
|
212
|
-
|
|
213
|
-
All four are addressable from tools the model actually uses:
|
|
214
|
-
`save_memory`, `read_memory`, `search_knowledge`, `memory_graph_add`,
|
|
215
|
-
`memory_graph_query`, `memory_graph_link`.
|
|
216
|
-
|
|
217
|
-
## The agent loop
|
|
218
|
-
|
|
219
|
-
`agent/loop.ts` (~560 lines) is the heart. Each turn:
|
|
220
|
-
|
|
221
|
-
1. **Build system prompt** — `agent/context.ts` parallelises four contributors:
|
|
222
|
-
JIT-discovered repo context, the wiki index, the active skills prompt, and
|
|
223
|
-
installed extensions. All wrapped in try/catch so no single source blocks
|
|
224
|
-
the turn.
|
|
225
|
-
2. **Classify the query** — `agent/routing.ts` picks a tier (fast / full)
|
|
226
|
-
from trigger heuristics (length, verb, language markers). Tier maps to a
|
|
227
|
-
model ID per provider.
|
|
228
|
-
3. **Compact if needed** — `agent/compaction.ts` runs tiered summarization
|
|
229
|
-
when history crosses 40 messages / 60k tokens. Earlier messages become a
|
|
230
|
-
terse summary the agent references as "[turns 1-28 summary: …]".
|
|
231
|
-
4. **Dispatch** — `providers/dispatch.ts` picks the right provider, walks the
|
|
232
|
-
fallback chain on 429 / 5xx / timeout, resumes interrupted streams.
|
|
233
|
-
5. **Execute tools** — as the model emits tool calls, `agent/tool-execution.ts`
|
|
234
|
-
sanitises frame markers, enforces per-call output caps, and records results.
|
|
235
|
-
6. **Drain pending messages** — `agent/pending-messages.ts` picks up anything
|
|
236
|
-
you typed mid-turn and appends it as a fresh user message for the next turn.
|
|
237
|
-
7. **Emit events** — `agent/event-emit.ts` pushes live updates (with a
|
|
238
|
-
circuit breaker on 5 consecutive send failures) to the TUI so you see what
|
|
239
|
-
the agent is doing in real time.
|
|
240
|
-
8. **Self-reflect** — `agent/reflection.ts` checks for loop-detection
|
|
241
|
-
signals (same tool called 3× with identical args) and forces a correction
|
|
242
|
-
prompt before the next iteration.
|
|
243
|
-
|
|
244
|
-
The loop terminates when the model emits `stop_reason: end_turn` or the user
|
|
245
|
-
presses Esc. Every step is individually failure-isolated; a broken wiki
|
|
246
|
-
index, a flaky provider, or a tool that times out don't cascade.
|
|
247
|
-
|
|
248
|
-
## Tools (43 built-in, plus MCP and hub)
|
|
249
|
-
|
|
250
|
-
All 43 ship as first-class tool definitions the model sees in its schema.
|
|
251
|
-
Catalogued in `src/tools/defs.ts`:
|
|
252
|
-
|
|
253
|
-
| Category | Tools |
|
|
67
|
+
| | |
|
|
254
68
|
|---|---|
|
|
255
|
-
| **
|
|
256
|
-
|
|
|
257
|
-
|
|
|
258
|
-
| **Git** | `git_status`, `git_diff`, `git_log`, `git_commit`, `checkpoint` (stash-based), `git_branch`, `git_push`, `git_stash`, `git_patch`, `git_auto_message` (AI-generated conventional commits) |
|
|
259
|
-
| **Memory** | `save_memory`, `read_memory`, `search_knowledge`, `session_search` (cross-session history), `write_todos`, `ask_user`, `memory_graph_add`, `memory_graph_query`, `memory_graph_link`, `memory_graph_prune` |
|
|
260
|
-
| **Sandbox** | `execute_code` — runs Python or JS in an isolated VM with network-deny, CPU/memory caps, transcript logging |
|
|
261
|
-
| **Browser** | `browser` — navigate, snapshot, click, type, fill, screenshot, find, get, batch, eval, extract, search (Playwright-backed when available) |
|
|
262
|
-
| **Agent orchestration** | `spawn_agent` (depth-limited sub-agents), `orchestrate` (plan → code → verify three-agent chain) |
|
|
263
|
-
| **Deployment** | `deploy_trigger`, `deploy_status` (wired to CI systems via webhooks) |
|
|
264
|
-
|
|
265
|
-
**MCP (Model Context Protocol):** Dirgha Code is an MCP **client**. `mcp/` has
|
|
266
|
-
stdio, SSE, and HTTP transports; `mcp/manager.ts` starts and supervises
|
|
267
|
-
servers you configure in `~/.dirgha/mcp.json`. MCP tools show up in the
|
|
268
|
-
model's tool list alongside built-ins, namespaced by server.
|
|
269
|
-
|
|
270
|
-
**Hub:** `dirgha hub install <plugin>` installs a package from the Dirgha
|
|
271
|
-
plugin registry. Each plugin can contribute new tools, slash commands, or
|
|
272
|
-
output renderers. The registry ships bundled so `hub list` / `hub search`
|
|
273
|
-
work offline.
|
|
274
|
-
|
|
275
|
-
## Provider dispatch (14 providers, automatic failover)
|
|
276
|
-
|
|
277
|
-
`providers/dispatch.ts` has three primitives:
|
|
278
|
-
|
|
279
|
-
- **`providerFromModelId()`** — infers the provider from the model ID prefix
|
|
280
|
-
(`claude-*` → Anthropic, `accounts/fireworks/*` → Fireworks,
|
|
281
|
-
`minimaxai/*` → NVIDIA, `gpt-*` → OpenAI, …).
|
|
282
|
-
- **`buildFallbackChain()`** — family-aware chain builder. A request for
|
|
283
|
-
a MiniMax model walks: `NVIDIA MiniMax M2.7` → `NVIDIA Kimi K2` →
|
|
284
|
-
`NVIDIA MiniMax M2.5` → `OpenRouter Kimi K2.5` → `Anthropic Claude Sonnet`.
|
|
285
|
-
Each hop is a different billing account with independent quotas, so 429
|
|
286
|
-
on one doesn't throttle the rest.
|
|
287
|
-
- **`withNetworkResume()`** — catches pure network errors (ECONNRESET,
|
|
288
|
-
socket hangup, 502, 503) and retries on the same provider with stream
|
|
289
|
-
resume. 429 is NOT retried here — it jumps to the next provider.
|
|
290
|
-
|
|
291
|
-
| Provider | Env var | Notes |
|
|
292
|
-
|---|---|---|
|
|
293
|
-
| **NVIDIA NIM** | `NVIDIA_API_KEY` | MiniMax M2.7, Kimi K2, Llama 4, Mistral Nemotron — 60s per-call timeout guard |
|
|
294
|
-
| **Anthropic** | `ANTHROPIC_API_KEY` | Claude Opus 4.7, Sonnet 4.6, Haiku 4.5 — extended thinking supported |
|
|
295
|
-
| **OpenAI** | `OPENAI_API_KEY` | GPT-5.4 family, o-series reasoning models |
|
|
296
|
-
| **OpenRouter** | `OPENROUTER_API_KEY` | 300+ models, unified billing, global routing |
|
|
297
|
-
| **Google Gemini** | `GEMINI_API_KEY` | 3.1 Pro, 3.1 Flash — 2M-token context |
|
|
298
|
-
| **Groq** | `GROQ_API_KEY` | Llama, Qwen at extreme TPS |
|
|
299
|
-
| **xAI** | `XAI_API_KEY` | Grok 4 family |
|
|
300
|
-
| **Mistral** | `MISTRAL_API_KEY` | Mistral Large, Codestral |
|
|
301
|
-
| **Cohere** | `COHERE_API_KEY` | Command R / R+ |
|
|
302
|
-
| **Fireworks** | `FIREWORKS_API_KEY` | Self-hosted open models |
|
|
303
|
-
| **DeepInfra** | `DEEPINFRA_API_KEY` | Alt hosting |
|
|
304
|
-
| **Perplexity** | `PERPLEXITY_API_KEY` | Sonar, web-grounded |
|
|
305
|
-
| **Together AI** | `TOGETHER_API_KEY` | Llama, Qwen, DeepSeek |
|
|
306
|
-
| **Ollama** | (none) | Any model running on `localhost:11434` |
|
|
307
|
-
| **Dirgha Gateway** | `dirgha login` | Managed cross-provider routing |
|
|
308
|
-
|
|
309
|
-
Each provider module is a thin adapter (average ~120 lines). New providers
|
|
310
|
-
are a half-day's work: implement `call<Name>(messages, systemPrompt, model, onStream)`
|
|
311
|
-
in `providers/<name>.ts`, add it to the switch in `dispatch.ts`.
|
|
312
|
-
|
|
313
|
-
A **circuit breaker** (`providers/circuit-breaker.ts`) tracks per-provider
|
|
314
|
-
health. Three consecutive failures open the breaker for 30 seconds — the
|
|
315
|
-
dispatcher skips that provider entirely until it heals.
|
|
316
|
-
|
|
317
|
-
## Sessions & persistence
|
|
318
|
-
|
|
319
|
-
Everything runs on one SQLite database at `~/.dirgha/sessions.db` (via
|
|
320
|
-
`better-sqlite3`, synchronous writes, WAL mode).
|
|
321
|
-
|
|
322
|
-
**Tables:**
|
|
323
|
-
- `sessions(id, title, model, tokens, created_at, updated_at)`
|
|
324
|
-
- `messages(id, session_id, role, content, ...)` with ON DELETE CASCADE
|
|
325
|
-
- `memories(id, key, content, created_at, updated_at)`
|
|
326
|
-
- `file_index(id, filepath, project, content, symbols, indexed_at)` — FTS5
|
|
327
|
-
virtual table for local semantic search
|
|
328
|
-
|
|
329
|
-
`dirgha --resume` picks up the last session. `dirgha --resume <id>` picks up a
|
|
330
|
-
specific one. `session_search` lets the agent itself pull relevant prior turns
|
|
331
|
-
into the current context.
|
|
332
|
-
|
|
333
|
-
Crash recovery is automatic: `dirgha` catches `uncaughtException` and
|
|
334
|
-
`unhandledRejection`, writes to `~/.dirgha/crash.log`, and calls
|
|
335
|
-
`restoreTerminal()` so your shell doesn't end up in bracketed-paste mode
|
|
336
|
-
or with the cursor hidden.
|
|
337
|
-
|
|
338
|
-
## Safety model
|
|
339
|
-
|
|
340
|
-
### Secrets in transit
|
|
341
|
-
`agent/secrets.ts` runs every user message through `redactSecrets()` before
|
|
342
|
-
it's saved to history or sent to the model. Detects and masks: Anthropic
|
|
343
|
-
keys, OpenAI keys, Fireworks keys, GitHub PATs, AWS credentials, JWT tokens,
|
|
344
|
-
SSH keys, and 33 other common patterns.
|
|
345
|
-
|
|
346
|
-
### Shell execution
|
|
347
|
-
`tools/shell.ts` enforces:
|
|
348
|
-
- **Output caps** — 8k chars default, 50k hard ceiling. Model can request
|
|
349
|
-
more via `max_output`. Prevents single tool results from eating the entire
|
|
350
|
-
context window.
|
|
351
|
-
- **Dangerous patterns blocked** — `rm -rf /`, `find -delete` with no scope,
|
|
352
|
-
`git clean -fdx`, `curl | sh`, process substitution `<(...)`,
|
|
353
|
-
`eval $(...)`, and a dozen others. List in `DANGEROUS_PATTERNS`.
|
|
354
|
-
- **Timeout bands** — 60s default, 300s for `npm install` / `bun test` /
|
|
355
|
-
build commands (pattern-matched), max 600s. Timeout errors suggest the
|
|
356
|
-
exact `timeout_ms` to retry with.
|
|
357
|
-
|
|
358
|
-
### Agent spawning
|
|
359
|
-
`agent/spawn-agent.ts`:
|
|
360
|
-
- `MAX_SPAWN_DEPTH = 3` — a sub-agent can spawn a sub-sub-agent, but no
|
|
361
|
-
further. Prevents recursive fork bombs.
|
|
362
|
-
- `MAX_CONCURRENT_AGENTS = 4` — total active spawns across the session.
|
|
363
|
-
- `spawn_agent` itself is filtered out of sub-agent tool lists so only the
|
|
364
|
-
root can spawn.
|
|
365
|
-
|
|
366
|
-
### Gateway URL integrity
|
|
367
|
-
`providers/gateway.ts` — `assertSafeGatewayUrl()` rejects any
|
|
368
|
-
`DIRGHA_GATEWAY_URL` that isn't HTTPS (localhost allowed). Prevents a
|
|
369
|
-
shell-rc injection from exfiltrating your bearer token to an attacker host.
|
|
370
|
-
|
|
371
|
-
### Tool output sanitisation
|
|
372
|
-
`agent/tool-execution.ts` — `sanitizeToolFrameMarkers()` strips `<system>`,
|
|
373
|
-
`<|im_start|>`, Llama 3 chat headers, and Mistral `[INST]` markers from tool
|
|
374
|
-
outputs before they re-enter the context. Blocks prompt-injection via file
|
|
375
|
-
contents.
|
|
376
|
-
|
|
377
|
-
### Permissions
|
|
378
|
-
`permission/` module — every tool tagged with a capability level
|
|
379
|
-
(`WorkspaceRead`, `WorkspaceWrite`, `SystemWrite`, `Network`). User can pin
|
|
380
|
-
the session to a capability level via `/security`. YOLO mode
|
|
381
|
-
(`--dangerously-skip-permissions` or `DIRGHA_YOLO=1`) disables checks for
|
|
382
|
-
trusted environments.
|
|
383
|
-
|
|
384
|
-
### Capability tokens
|
|
385
|
-
`security/capabilityTokens.ts` — short-lived HMAC-signed tokens for
|
|
386
|
-
delegating tool access to sub-agents, scoped to specific paths / capabilities.
|
|
387
|
-
|
|
388
|
-
## Headless & machine-readable — `--json` on every command
|
|
389
|
-
|
|
390
|
-
Every Dirgha command emits machine-readable JSON when `--json` is passed
|
|
391
|
-
(either at the root — `dirgha --json <cmd>` — or at the subcommand —
|
|
392
|
-
`dirgha <cmd> --json`). This is the CLI-Anything contract. Two-tier
|
|
393
|
-
implementation:
|
|
394
|
-
|
|
395
|
-
1. **Universal capture** — stdout is intercepted for any command and
|
|
396
|
-
wrapped in the standard envelope on exit. Zero per-command changes.
|
|
397
|
-
2. **Native emit** — commands that want to expose structured `data`
|
|
398
|
-
fields (like `dirgha hub list`, `dirgha fleet launch`) use the
|
|
399
|
-
`emit()` helper and set the natively-emitted flag so the wrapper
|
|
400
|
-
skips.
|
|
69
|
+
| Tests | **40/40** offline in ~16 s. CI green is a precondition for any PR. |
|
|
70
|
+
| 17 providers | Multi-key BYOK pool with cooldown rotation. |
|
|
71
|
+
| 112 skills | Scanned by the heuristic prompt-injection / supply-chain check at install + load. |
|
|
401
72
|
|
|
402
|
-
|
|
403
|
-
dirgha status --json # account, quota, sessions
|
|
404
|
-
dirgha fleet list --json # all active worktrees + branches
|
|
405
|
-
dirgha hub search ollama --json
|
|
406
|
-
dirgha ask "explain this repo" --json
|
|
407
|
-
```
|
|
408
|
-
|
|
409
|
-
The envelope shape:
|
|
410
|
-
|
|
411
|
-
```json
|
|
412
|
-
{
|
|
413
|
-
"data": { "…": "command-specific structured payload" },
|
|
414
|
-
"text": "human-readable output (ANSI-stripped)",
|
|
415
|
-
"exitCode": 0,
|
|
416
|
-
"command": "fleet launch",
|
|
417
|
-
"timestamp": "2026-04-20T07:45:22.118Z",
|
|
418
|
-
"meta": { "durationMs": 27 }
|
|
419
|
-
}
|
|
420
|
-
```
|
|
73
|
+
## Why this exists
|
|
421
74
|
|
|
422
|
-
|
|
423
|
-
shell scripts. `dirgha __dump_spec` returns the full commander tree as
|
|
424
|
-
JSON for tooling/automation.
|
|
425
|
-
|
|
426
|
-
## Slash commands (80+ in the TUI)
|
|
427
|
-
|
|
428
|
-
Available inside the interactive TUI. Open the modal help (`/help` —
|
|
429
|
-
type to filter, ↑↓ to scroll, `Esc` to close) or see
|
|
430
|
-
[`docs/COMMANDS.md`](./docs/COMMANDS.md) for the full reference. Grouped:
|
|
431
|
-
|
|
432
|
-
- **Session** — `/help`, `/status`, `/clear`, `/compact`, `/save`,
|
|
433
|
-
`/resume`, `/export`, `/summary`, `/cost`, `/tokens`, `/usage`
|
|
434
|
-
- **Auth & config** — `/login`, `/logout`, `/setup`, `/model`, `/keys`,
|
|
435
|
-
`/config`, `/theme`, `/soul`
|
|
436
|
-
- **Dev workflow** — `/spec`, `/plan`, `/review`, `/qa`, `/fix`,
|
|
437
|
-
`/refactor`, `/scaffold`, `/changes`, `/fast`, `/verbose`
|
|
438
|
-
- **Git** — `/diff`, `/commit`, `/stash`, `/push`, `/branch`, `/checkout`
|
|
439
|
-
- **Memory & knowledge** — `/memory`, `/remember`, `/recall`, `/curate`
|
|
440
|
-
- **Safety** — `/checkpoint`, `/rollback`, `/permissions`, `/yolo`,
|
|
441
|
-
`/approvals`, `/btw`
|
|
442
|
-
- **Skills & tools** — `/skills`, `/init`, `/scan`, `/secrets`
|
|
443
|
-
- **System** — `/verify`, `/doctor`
|
|
444
|
-
- **Integrations** — `/mcp`, `/voice`, `/cron`, `/net`, `/fs`, `/team`,
|
|
445
|
-
`/consensus`, `/screen`, `/drop`, `/undo`
|
|
446
|
-
- **Sprint engine** — `/sprint`, `/run`
|
|
447
|
-
- **Multi-agent** — `/side` (ephemeral sub-agent fork), `/orchestrate`
|
|
448
|
-
|
|
449
|
-
Auto-complete on partial entry — `/hel` expands to `/help`, `/sta` to
|
|
450
|
-
`/status`. `/side <prompt>` runs an isolated sub-agent that does NOT
|
|
451
|
-
pollute the main conversation history (Codex pattern, useful for quick
|
|
452
|
-
tangents).
|
|
453
|
-
|
|
454
|
-
## Configuration surface
|
|
455
|
-
|
|
456
|
-
Everything lives in `~/.dirgha/`:
|
|
75
|
+
Frontier coding assistants are closed SaaS, charging per-seat, piping your repository through someone else's telemetry. The assumption is that the intelligence must live at the vendor.
|
|
457
76
|
|
|
458
|
-
|
|
459
|
-
~/.dirgha/
|
|
460
|
-
├── keys.json # BYOK keys (mode 0600), auto-loaded into env at boot
|
|
461
|
-
├── credentials.json # Gateway login token (if signed in)
|
|
462
|
-
├── config.json # Theme, defaults, feature flags
|
|
463
|
-
├── sessions.db # SQLite — sessions, messages, memory, file index
|
|
464
|
-
├── mcp.json # MCP server configurations
|
|
465
|
-
├── hub/ # Installed plugins + cached registry
|
|
466
|
-
│ ├── plugins/
|
|
467
|
-
│ └── registry.json
|
|
468
|
-
├── soul.md # Persistent context you want in every turn
|
|
469
|
-
├── MEMORY.md # Legacy memory file (still read)
|
|
470
|
-
├── crash.log # Last unclean exit transcript
|
|
471
|
-
└── transcripts/ # Full tool-execution transcripts for audit
|
|
472
|
-
```
|
|
77
|
+
The opposite assumption is the right one. Your laptop is the unit of sovereignty. Your keys, your wallet, your session log, your tool executions live on your machine until you choose to hit a network. Providers are swappable. The agent loop is open source.
|
|
473
78
|
|
|
474
|
-
|
|
79
|
+
## Documentation
|
|
475
80
|
|
|
476
|
-
|
|
|
81
|
+
| | |
|
|
477
82
|
|---|---|
|
|
478
|
-
|
|
|
479
|
-
|
|
|
480
|
-
|
|
|
481
|
-
|
|
|
482
|
-
|
|
|
483
|
-
|
|
|
484
|
-
|
|
|
485
|
-
|
|
486
|
-
## Runtime & sandbox
|
|
487
|
-
|
|
488
|
-
`runtime/` implements the isolated execution environment for the
|
|
489
|
-
`execute_code` tool. It uses Node's VM module with:
|
|
490
|
-
- Network deny by default (`runtime/network-control.ts`)
|
|
491
|
-
- Filesystem mount scoping (`runtime/mount.ts`) — the sandbox only sees
|
|
492
|
-
directories explicitly mounted
|
|
493
|
-
- CPU + memory caps
|
|
494
|
-
- Transcript logging (`runtime/transcript.ts`) — everything executed is
|
|
495
|
-
recorded and can be replayed
|
|
496
|
-
- Multiplayer mode (`runtime/multiplayer.ts`) — shared sandbox sessions for
|
|
497
|
-
agent collaboration
|
|
498
|
-
|
|
499
|
-
## Agent orchestration
|
|
500
|
-
|
|
501
|
-
`agent/orchestration/` provides the primitives behind `orchestrate` and
|
|
502
|
-
`spawn_agent`:
|
|
503
|
-
|
|
504
|
-
- **Agent pool** — pre-warmed workers, queue, auto-scaler, idle cleanup
|
|
505
|
-
- **DAG runner** — directed-acyclic-graph task execution with dependencies
|
|
506
|
-
- **Decomposer** — splits high-level goals into sub-tasks
|
|
507
|
-
- **Circuit breaker** — per-agent-type failure tracking
|
|
508
|
-
- **Structured results** — every agent returns a typed result shape
|
|
509
|
-
- **Scheduler** — priority queue, retries, back-off
|
|
510
|
-
|
|
511
|
-
The `swarm/` subsystem (14 files) is a higher-level orchestration primitive
|
|
512
|
-
for multi-agent collaboration patterns: `governance`, `templates`,
|
|
513
|
-
`collaboration`, `runtime` — used by `/team` and `/consensus` slash commands.
|
|
514
|
-
|
|
515
|
-
## Voice
|
|
516
|
-
|
|
517
|
-
`voice/` (12 files) — optional voice-first mode. Desktop capture via system
|
|
518
|
-
audio, mobile bridge for remote dictation, Whisper-compatible transcription,
|
|
519
|
-
TTS playback via system voices or remote endpoints. `dirgha voice` starts
|
|
520
|
-
the voice loop; `dirgha voice-config` manages shortcuts and hotwords.
|
|
521
|
-
|
|
522
|
-
## Knowledge engine
|
|
523
|
-
|
|
524
|
-
`knowledge/` (5 files) — Dirgha's local wiki. `dirgha knowledge sync --from
|
|
525
|
-
articles.jsonl` bulk-imports; `dirgha k search "<query>"` does FTS5 search
|
|
526
|
-
over the corpus; `dirgha k wiki` rebuilds the index. Backed by
|
|
527
|
-
`knowledge/compiler.ts` (markdown → searchable), `knowledge/linter.ts`
|
|
528
|
-
(link validation), `knowledge/git-sync.ts` (syncs knowledge files to a git
|
|
529
|
-
remote).
|
|
530
|
-
|
|
531
|
-
## Source tree overview
|
|
83
|
+
| Architecture | [`docs/ARCHITECTURE.md`](./docs/ARCHITECTURE.md) |
|
|
84
|
+
| Roadmap | [`docs/ROADMAP.md`](./docs/ROADMAP.md) |
|
|
85
|
+
| Knowledge management | [`docs/memory/km-architecture.md`](./docs/memory/km-architecture.md) |
|
|
86
|
+
| Architecture efficiency | [`docs/memory/architecture-efficiency.md`](./docs/memory/architecture-efficiency.md) |
|
|
87
|
+
| Skill security | [`docs/agents/skill-security.md`](./docs/agents/skill-security.md) |
|
|
88
|
+
| Files & search contract | [`docs/agents/files-and-search.md`](./docs/agents/files-and-search.md) |
|
|
89
|
+
| Per-release notes | [`changelog/`](./changelog) |
|
|
532
90
|
|
|
533
|
-
|
|
534
|
-
src/
|
|
535
|
-
├── agent/ # Loop, context, compaction, dispatch glue, spawning
|
|
536
|
-
├── commands/ # 80 commander.js subcommand handlers
|
|
537
|
-
├── repl/ # TUI REPL shell, slash commands (30 files)
|
|
538
|
-
├── tui/ # Ink/React 19 components (58 files)
|
|
539
|
-
├── providers/ # 16 LLM adapters + dispatcher + circuit breaker
|
|
540
|
-
├── tools/ # 43 built-in tool implementations
|
|
541
|
-
├── runtime/ # Sandbox: VM, mounts, network control, transcripts
|
|
542
|
-
├── memory/ # 4-tier memory: builtin, holographic, GEPA, graph
|
|
543
|
-
├── swarm/ # Multi-agent collaboration patterns
|
|
544
|
-
├── mcp/ # MCP client: stdio, SSE, HTTP transports
|
|
545
|
-
├── hub/ # Plugin registry + installer + commands
|
|
546
|
-
├── knowledge/ # Wiki, compiler, linter, git sync
|
|
547
|
-
├── security/ # Capability tokens, safe shell, CSRF, scanner
|
|
548
|
-
├── permission/ # Per-tool capability model
|
|
549
|
-
├── billing/ # Client-side usage tracking
|
|
550
|
-
├── session/ # SQLite persistence layer
|
|
551
|
-
├── voice/ # Whisper + TTS + hotword
|
|
552
|
-
├── browser/ # Browser automation helpers
|
|
553
|
-
├── sprint/ # Sprint/recipe orchestration (critic, verifier, watchdog)
|
|
554
|
-
├── checkpoint/ # Checkpoint/rollback primitives
|
|
555
|
-
├── skills/ # Built-in skill prompts (plan, debug, review, …)
|
|
556
|
-
├── extensions/ # Extension host + RPC
|
|
557
|
-
├── evals/ # Built-in eval suite
|
|
558
|
-
└── utils/ # Credentials, keys, logger, health monitor, security boundary
|
|
559
|
-
```
|
|
91
|
+
## Contributing
|
|
560
92
|
|
|
561
|
-
|
|
562
|
-
output to `dist/dirgha.mjs` (~7.3 MB minified).
|
|
93
|
+
We'd genuinely love your help.
|
|
563
94
|
|
|
564
|
-
|
|
95
|
+
The fastest path is to **try it on a real project**, then tell us what worked and what didn't. Open an issue at [github.com/Dirgha-AI/dirgha-code/issues](https://github.com/Dirgha-AI/dirgha-code/issues) — bugs, feature ideas, "this confused me," "this surprised me in a good way," all welcome. There's no bug too small. There's no question too basic.
|
|
565
96
|
|
|
566
|
-
|
|
97
|
+
A few specific ways to plug in:
|
|
567
98
|
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
|
|
571
|
-
|
|
572
|
-
|
|
573
|
-
|
|
574
|
-
| [`arniko`](https://github.com/Dirgha-AI/arniko) | AI security scanner. Every tool, one unified report. | Apache-2.0 |
|
|
99
|
+
- **Try it.** `npm i -g @dirgha/code`. Run it on something you actually care about. The free-tier endpoints on OpenRouter and NVIDIA work fine for most coding tasks.
|
|
100
|
+
- **File issues.** Anything that doesn't match the README, anything that crashes, anything that wastes your tokens. We read everything.
|
|
101
|
+
- **Suggest providers.** If your favourite provider isn't in the 17 we support, open an issue and tell us which one + the env var. Most are a single config-blob diff.
|
|
102
|
+
- **Write a skill.** SKILL.md packs work across compatible agent CLIs. Publish a git repo, share the URL, anyone can `dirgha skills install <url>`.
|
|
103
|
+
- **Write a plugin.** TypeScript extensions API takes ~20 lines for a real tool. We're keen to feature good ones — drop a link.
|
|
104
|
+
- **Send a PR.** Every PR adds a `.changeset/<random-name>.md` describing what changed and at what semver tier. Tests must stay green: `npm run test:cli:offline`.
|
|
575
105
|
|
|
576
|
-
|
|
106
|
+
We're a small team. We answer issues. We accept PRs from first-time contributors. If something feels off about the project, the docs, or the experience — tell us.
|
|
577
107
|
|
|
578
108
|
## License
|
|
579
109
|
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
**Dirgha LLC owns the “Dirgha” name, logo, and product family** as registered trademarks. The code is open — the brand isn't. Forks of this repository must rename the product and remove Dirgha branding before distribution. Reasonable nominative use (“a fork of Dirgha Code”) is fine.
|
|
583
|
-
|
|
584
|
-
See [`LICENSE`](./LICENSE) and [`NOTICE.md`](./NOTICE.md) for the full legal text. Related documents:
|
|
585
|
-
|
|
586
|
-
- [`SECURITY.md`](./SECURITY.md) — vulnerability disclosure policy.
|
|
587
|
-
- [`CODE_OF_CONDUCT.md`](./CODE_OF_CONDUCT.md) — Contributor Covenant 2.1.
|
|
588
|
-
- [`SUPPORT.md`](./SUPPORT.md) — where to ask for help.
|
|
589
|
-
- [`CONTRIBUTING.md`](./CONTRIBUTING.md) — how to send a PR.
|
|
590
|
-
- [`LICENSING.md`](./LICENSING.md) — honest rationale for the FSL choice (why not pure MIT? bootstrapped, not VC-funded).
|
|
591
|
-
|
|
592
|
-
## Troubleshooting
|
|
593
|
-
|
|
594
|
-
**`npm install` fails with peer-dep errors.** We align `marked` to the
|
|
595
|
-
major version `marked-terminal` accepts on every release — if you see
|
|
596
|
-
a conflict, you're probably on an older release. Either upgrade or
|
|
597
|
-
pass `--legacy-peer-deps` as a one-off.
|
|
598
|
-
|
|
599
|
-
**`dirgha` command not found after `npm install -g`.** Your npm global
|
|
600
|
-
`bin` path isn't on `PATH`. Check `npm bin -g` and either add that
|
|
601
|
-
directory to `PATH` or install with pnpm (`pnpm add -g @dirgha/code`).
|
|
602
|
-
|
|
603
|
-
**`better-sqlite3` build fails on Apple Silicon or Linux ARM.** You
|
|
604
|
-
need Xcode Command Line Tools (macOS) or `build-essential` + `python3`
|
|
605
|
-
(Linux). Then `npm rebuild better-sqlite3`.
|
|
606
|
-
|
|
607
|
-
**`dirgha` crashes with `Cannot find package 'libp2p'`.** libp2p is an
|
|
608
|
-
optional dep that only the experimental `mesh` command needs. Run
|
|
609
|
-
`npm install libp2p @libp2p/{tcp,noise,mplex,gossipsub}` if you're on
|
|
610
|
-
the experimental track; otherwise ignore.
|
|
611
|
-
|
|
612
|
-
**Node version warnings.** Minimum is Node 20. We run CI against 20
|
|
613
|
-
and 22. Earlier versions will not work.
|
|
614
|
-
|
|
615
|
-
**Commands like `dao`, `make`, `mesh` aren't in `--help`.** These are
|
|
616
|
-
experimental — run with `DIRGHA_EXPERIMENTAL=1` set.
|
|
617
|
-
|
|
618
|
-
**Seeing "models health" errors about unreachable gateway.** The
|
|
619
|
-
public gateway is at `https://api.dirgha.ai`. If you're offline or
|
|
620
|
-
behind a proxy, set `DIRGHA_API_URL` to a reachable endpoint or run
|
|
621
|
-
entirely in BYOK mode.
|
|
622
|
-
|
|
623
|
-
## Contribute
|
|
624
|
-
|
|
625
|
-
- **Code** — fork, branch, PR against `main`. Recipes in [`CONTRIBUTING.md`](./CONTRIBUTING.md).
|
|
626
|
-
- **Bugs** — file an issue using the [bug template](https://github.com/dirghaai/dirgha-code/issues/new?template=bug.md).
|
|
627
|
-
- **Features** — file an issue using the [feature template](https://github.com/dirghaai/dirgha-code/issues/new?template=feature.md).
|
|
628
|
-
- **Questions** — open a [Discussion](https://github.com/dirghaai/dirgha-code/discussions) rather than an issue.
|
|
629
|
-
- **Security** — email `security@dirgha.ai`. Do NOT file a public issue for vulnerabilities.
|
|
630
|
-
- **Sponsor** — [dirgha.ai/contribute](https://dirgha.ai/contribute) · Lightning, GitHub Sponsors, OpenCollective.
|
|
631
|
-
|
|
632
|
-
|
|
633
|
-
## Links
|
|
634
|
-
|
|
635
|
-
| | |
|
|
636
|
-
|---|---|
|
|
637
|
-
| Website | [https://dirgha.ai](https://dirgha.ai) |
|
|
638
|
-
| Repository | [github.com/dirghaai/dirgha-code](https://github.com/dirghaai/dirgha-code) |
|
|
639
|
-
| Issues | [github.com/dirghaai/dirgha-code/issues](https://github.com/dirghaai/dirgha-code/issues) |
|
|
640
|
-
| Discussions | [github.com/dirghaai/dirgha-code/discussions](https://github.com/dirghaai/dirgha-code/discussions) |
|
|
641
|
-
| Security | `security@dirgha.ai` |
|
|
642
|
-
| Enterprise | `enterprise@dirgha.ai` |
|
|
643
|
-
| Press / general | `hello@dirgha.ai` |
|
|
110
|
+
[FSL-1.1-MIT](./LICENSE) — Functional Source License with a 2-year sunset to MIT.
|
|
644
111
|
|
|
645
112
|
---
|
|
646
113
|
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
Named for the Sanskrit *dīrgha* — “long-horizon.” The agent is built for work that spans hours, not turns.
|
|
650
|
-
|
|
651
|
-
Built by [Dirgha LLC](https://dirgha.ai) in India. Open to the world.
|
|
114
|
+
<div align="center">
|
|
652
115
|
|
|
653
|
-
|
|
116
|
+
**Build to last. Code with Dirgha.**
|
|
654
117
|
|
|
655
|
-
|
|
656
|
-
|
|
657
|
-
## 🌐 The Dirgha Ecosystem
|
|
118
|
+
[`@dirgha/code`](https://www.npmjs.com/package/@dirgha/code) · [github.com/Dirgha-AI/dirgha-code](https://github.com/Dirgha-AI/dirgha-code) · [Sponsor](https://dirgha.ai/contribute)
|
|
658
119
|
|
|
659
|
-
|
|
660
|
-
|
|
661
|
-
| Repo | What it does |
|
|
662
|
-
|---|---|
|
|
663
|
-
| [Rama-I-Dirgha-AI-OS](https://github.com/Dirgha-AI/Rama-I-Dirgha-AI-OS) | Vision & roadmap for our agentic, sovereign AI operating system |
|
|
664
|
-
| [dirgha-code](https://github.com/Dirgha-AI/dirgha-code) | AI coding agent for your terminal |
|
|
665
|
-
| [writer-studio](https://github.com/Dirgha-AI/writer-studio) | Long-form writing studio — science, fiction, screenplays, research |
|
|
666
|
-
| [creator-studio](https://github.com/Dirgha-AI/creator-studio) | Creator workspace — agents for production, posting, monetization |
|
|
667
|
-
| [abundance-protocol](https://github.com/Dirgha-AI/abundance-protocol) | Decentralized compute and labor network |
|
|
668
|
-
| [arniko](https://github.com/Dirgha-AI/arniko) | AI security scanner — every tool, one unified report |
|
|
669
|
-
| [.github](https://github.com/Dirgha-AI/.github) | Org profile and community configuration |
|
|
670
|
-
|
|
671
|
-
- **Live platform:** [dirgha.ai](https://dirgha.ai) — chat, IDE, writer, research, library, marketplace, creator, education, manufacturing
|
|
672
|
-
- **Organization:** [github.com/Dirgha-AI](https://github.com/Dirgha-AI)
|
|
673
|
-
- **Partnerships:** [partner@dirgha.ai](mailto:partner@dirgha.ai)
|
|
674
|
-
|
|
675
|
-
*Dirgha — Accelerate Abundance. Built in India, for the world.*
|
|
120
|
+
</div>
|