moflo 4.8.31 → 4.8.32
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/bin/generate-code-map.mjs +1 -1
- package/bin/index-guidance.mjs +1 -1
- package/bin/index-tests.mjs +1 -1
- package/bin/setup-project.mjs +1 -1
- package/package.json +6 -7
- package/src/@claude-flow/cli/package.json +106 -106
- package/.claude/agents/browser/browser-agent.yaml +0 -182
- package/.claude/agents/database-specialist.yaml +0 -21
- package/.claude/agents/index.yaml +0 -17
- package/.claude/agents/project-coordinator.yaml +0 -15
- package/.claude/agents/python-specialist.yaml +0 -21
- package/.claude/agents/security-auditor.yaml +0 -20
- package/.claude/agents/typescript-specialist.yaml +0 -21
- package/.claude/checkpoints/1767754460.json +0 -8
- package/.claude/config/v3-dependency-optimization.json +0 -266
- package/.claude/config/v3-performance-targets.json +0 -251
- package/.claude/guidance/moflo-bootstrap.md +0 -129
- package/.claude/mcp.json +0 -13
- package/.claude/settings.json +0 -351
- package/.claude/settings.local.json +0 -18
- package/.claude/skills/agentdb-advanced/SKILL.md +0 -550
- package/.claude/skills/agentdb-learning/SKILL.md +0 -545
- package/.claude/skills/agentdb-memory-patterns/SKILL.md +0 -339
- package/.claude/skills/agentdb-optimization/SKILL.md +0 -509
- package/.claude/skills/agentdb-vector-search/SKILL.md +0 -339
- package/.claude/skills/browser/SKILL.md +0 -204
- package/.claude/skills/fl/SKILL.md +0 -583
- package/.claude/skills/flo/SKILL.md +0 -583
- package/.claude/skills/github-code-review/SKILL.md +0 -1140
- package/.claude/skills/github-multi-repo/SKILL.md +0 -874
- package/.claude/skills/github-project-management/SKILL.md +0 -1277
- package/.claude/skills/github-release-management/SKILL.md +0 -1081
- package/.claude/skills/github-workflow-automation/SKILL.md +0 -1065
- package/.claude/skills/hive-mind-advanced/SKILL.md +0 -712
- package/.claude/skills/hooks-automation/SKILL.md +0 -1201
- package/.claude/skills/pair-programming/SKILL.md +0 -1202
- package/.claude/skills/performance-analysis/SKILL.md +0 -563
- package/.claude/skills/reasoningbank-agentdb/SKILL.md +0 -446
- package/.claude/skills/reasoningbank-intelligence/SKILL.md +0 -201
- package/.claude/skills/skill-builder/SKILL.md +0 -910
- package/.claude/skills/sparc-methodology/SKILL.md +0 -1115
- package/.claude/skills/stream-chain/SKILL.md +0 -563
- package/.claude/skills/swarm-advanced/SKILL.md +0 -973
- package/.claude/skills/swarm-orchestration/SKILL.md +0 -179
- package/.claude/skills/v3-cli-modernization/SKILL.md +0 -872
- package/.claude/skills/v3-core-implementation/SKILL.md +0 -797
- package/.claude/skills/v3-ddd-architecture/SKILL.md +0 -442
- package/.claude/skills/v3-integration-deep/SKILL.md +0 -241
- package/.claude/skills/v3-mcp-optimization/SKILL.md +0 -777
- package/.claude/skills/v3-memory-unification/SKILL.md +0 -174
- package/.claude/skills/v3-performance-optimization/SKILL.md +0 -390
- package/.claude/skills/v3-security-overhaul/SKILL.md +0 -82
- package/.claude/skills/v3-swarm-coordination/SKILL.md +0 -340
- package/.claude/skills/verification-quality/SKILL.md +0 -649
- package/.claude/skills/worker-benchmarks/skill.md +0 -135
- package/.claude/skills/worker-integration/skill.md +0 -154
- package/.claude/workflow-state.json +0 -9
- package/src/@claude-flow/cli/dist/src/appliance/gguf-engine.d.ts +0 -91
- package/src/@claude-flow/cli/dist/src/appliance/ruvllm-bridge.d.ts +0 -102
- package/src/@claude-flow/cli/dist/src/appliance/rvfa-builder.d.ts +0 -44
- package/src/@claude-flow/cli/dist/src/appliance/rvfa-distribution.d.ts +0 -97
- package/src/@claude-flow/cli/dist/src/appliance/rvfa-format.d.ts +0 -111
- package/src/@claude-flow/cli/dist/src/appliance/rvfa-runner.d.ts +0 -69
- package/src/@claude-flow/cli/dist/src/appliance/rvfa-signing.d.ts +0 -123
- package/src/@claude-flow/cli/dist/src/benchmarks/pretrain/index.d.ts +0 -58
- package/src/@claude-flow/cli/dist/src/commands/agent.d.ts +0 -8
- package/src/@claude-flow/cli/dist/src/commands/analyze.d.ts +0 -19
- package/src/@claude-flow/cli/dist/src/commands/appliance-advanced.d.ts +0 -9
- package/src/@claude-flow/cli/dist/src/commands/appliance.d.ts +0 -8
- package/src/@claude-flow/cli/dist/src/commands/benchmark.d.ts +0 -10
- package/src/@claude-flow/cli/dist/src/commands/claims.d.ts +0 -10
- package/src/@claude-flow/cli/dist/src/commands/completions.d.ts +0 -10
- package/src/@claude-flow/cli/dist/src/commands/config.d.ts +0 -8
- package/src/@claude-flow/cli/dist/src/commands/daemon.d.ts +0 -8
- package/src/@claude-flow/cli/dist/src/commands/deployment.d.ts +0 -10
- package/src/@claude-flow/cli/dist/src/commands/diagnose.d.ts +0 -16
- package/src/@claude-flow/cli/dist/src/commands/doctor.d.ts +0 -10
- package/src/@claude-flow/cli/dist/src/commands/embeddings.d.ts +0 -18
- package/src/@claude-flow/cli/dist/src/commands/gate.d.ts +0 -23
- package/src/@claude-flow/cli/dist/src/commands/github.d.ts +0 -12
- package/src/@claude-flow/cli/dist/src/commands/guidance.d.ts +0 -8
- package/src/@claude-flow/cli/dist/src/commands/hive-mind.d.ts +0 -11
- package/src/@claude-flow/cli/dist/src/commands/hooks.d.ts +0 -8
- package/src/@claude-flow/cli/dist/src/commands/index.d.ts +0 -115
- package/src/@claude-flow/cli/dist/src/commands/init.d.ts +0 -8
- package/src/@claude-flow/cli/dist/src/commands/issues.d.ts +0 -21
- package/src/@claude-flow/cli/dist/src/commands/mcp.d.ts +0 -11
- package/src/@claude-flow/cli/dist/src/commands/memory.d.ts +0 -8
- package/src/@claude-flow/cli/dist/src/commands/migrate.d.ts +0 -8
- package/src/@claude-flow/cli/dist/src/commands/neural.d.ts +0 -10
- package/src/@claude-flow/cli/dist/src/commands/orc.d.ts +0 -21
- package/src/@claude-flow/cli/dist/src/commands/performance.d.ts +0 -10
- package/src/@claude-flow/cli/dist/src/commands/plugins.d.ts +0 -11
- package/src/@claude-flow/cli/dist/src/commands/process.d.ts +0 -10
- package/src/@claude-flow/cli/dist/src/commands/progress.d.ts +0 -11
- package/src/@claude-flow/cli/dist/src/commands/providers.d.ts +0 -10
- package/src/@claude-flow/cli/dist/src/commands/route.d.ts +0 -16
- package/src/@claude-flow/cli/dist/src/commands/ruvector/backup.d.ts +0 -11
- package/src/@claude-flow/cli/dist/src/commands/ruvector/benchmark.d.ts +0 -11
- package/src/@claude-flow/cli/dist/src/commands/ruvector/import.d.ts +0 -18
- package/src/@claude-flow/cli/dist/src/commands/ruvector/index.d.ts +0 -29
- package/src/@claude-flow/cli/dist/src/commands/ruvector/init.d.ts +0 -11
- package/src/@claude-flow/cli/dist/src/commands/ruvector/migrate.d.ts +0 -11
- package/src/@claude-flow/cli/dist/src/commands/ruvector/optimize.d.ts +0 -11
- package/src/@claude-flow/cli/dist/src/commands/ruvector/setup.d.ts +0 -18
- package/src/@claude-flow/cli/dist/src/commands/ruvector/status.d.ts +0 -11
- package/src/@claude-flow/cli/dist/src/commands/security.d.ts +0 -10
- package/src/@claude-flow/cli/dist/src/commands/session.d.ts +0 -8
- package/src/@claude-flow/cli/dist/src/commands/start.d.ts +0 -8
- package/src/@claude-flow/cli/dist/src/commands/status.d.ts +0 -8
- package/src/@claude-flow/cli/dist/src/commands/swarm.d.ts +0 -8
- package/src/@claude-flow/cli/dist/src/commands/task.d.ts +0 -8
- package/src/@claude-flow/cli/dist/src/commands/transfer-store.d.ts +0 -13
- package/src/@claude-flow/cli/dist/src/commands/update.d.ts +0 -8
- package/src/@claude-flow/cli/dist/src/commands/workflow.d.ts +0 -8
- package/src/@claude-flow/cli/dist/src/config/moflo-config.d.ts +0 -93
- package/src/@claude-flow/cli/dist/src/config-adapter.d.ts +0 -15
- package/src/@claude-flow/cli/dist/src/index.d.ts +0 -81
- package/src/@claude-flow/cli/dist/src/infrastructure/in-memory-repositories.d.ts +0 -68
- package/src/@claude-flow/cli/dist/src/init/claudemd-generator.d.ts +0 -30
- package/src/@claude-flow/cli/dist/src/init/executor.d.ts +0 -41
- package/src/@claude-flow/cli/dist/src/init/helpers-generator.d.ts +0 -51
- package/src/@claude-flow/cli/dist/src/init/index.d.ts +0 -13
- package/src/@claude-flow/cli/dist/src/init/mcp-generator.d.ts +0 -29
- package/src/@claude-flow/cli/dist/src/init/moflo-init.d.ts +0 -31
- package/src/@claude-flow/cli/dist/src/init/settings-generator.d.ts +0 -14
- package/src/@claude-flow/cli/dist/src/init/statusline-generator.d.ts +0 -28
- package/src/@claude-flow/cli/dist/src/init/types.d.ts +0 -285
- package/src/@claude-flow/cli/dist/src/mcp-client.d.ts +0 -92
- package/src/@claude-flow/cli/dist/src/mcp-server.d.ts +0 -161
- package/src/@claude-flow/cli/dist/src/mcp-tools/agent-tools.d.ts +0 -9
- package/src/@claude-flow/cli/dist/src/mcp-tools/agentdb-tools.d.ts +0 -30
- package/src/@claude-flow/cli/dist/src/mcp-tools/analyze-tools.d.ts +0 -38
- package/src/@claude-flow/cli/dist/src/mcp-tools/auto-install.d.ts +0 -83
- package/src/@claude-flow/cli/dist/src/mcp-tools/browser-tools.d.ts +0 -13
- package/src/@claude-flow/cli/dist/src/mcp-tools/claims-tools.d.ts +0 -12
- package/src/@claude-flow/cli/dist/src/mcp-tools/config-tools.d.ts +0 -8
- package/src/@claude-flow/cli/dist/src/mcp-tools/coordination-tools.d.ts +0 -13
- package/src/@claude-flow/cli/dist/src/mcp-tools/daa-tools.d.ts +0 -13
- package/src/@claude-flow/cli/dist/src/mcp-tools/embeddings-tools.d.ts +0 -9
- package/src/@claude-flow/cli/dist/src/mcp-tools/github-tools.d.ts +0 -13
- package/src/@claude-flow/cli/dist/src/mcp-tools/hive-mind-tools.d.ts +0 -8
- package/src/@claude-flow/cli/dist/src/mcp-tools/hooks-tools.d.ts +0 -44
- package/src/@claude-flow/cli/dist/src/mcp-tools/index.d.ts +0 -23
- package/src/@claude-flow/cli/dist/src/mcp-tools/memory-tools.d.ts +0 -14
- package/src/@claude-flow/cli/dist/src/mcp-tools/neural-tools.d.ts +0 -16
- package/src/@claude-flow/cli/dist/src/mcp-tools/performance-tools.d.ts +0 -16
- package/src/@claude-flow/cli/dist/src/mcp-tools/progress-tools.d.ts +0 -14
- package/src/@claude-flow/cli/dist/src/mcp-tools/security-tools.d.ts +0 -18
- package/src/@claude-flow/cli/dist/src/mcp-tools/session-tools.d.ts +0 -8
- package/src/@claude-flow/cli/dist/src/mcp-tools/swarm-tools.d.ts +0 -8
- package/src/@claude-flow/cli/dist/src/mcp-tools/system-tools.d.ts +0 -13
- package/src/@claude-flow/cli/dist/src/mcp-tools/task-tools.d.ts +0 -8
- package/src/@claude-flow/cli/dist/src/mcp-tools/terminal-tools.d.ts +0 -13
- package/src/@claude-flow/cli/dist/src/mcp-tools/transfer-tools.d.ts +0 -14
- package/src/@claude-flow/cli/dist/src/mcp-tools/types.d.ts +0 -31
- package/src/@claude-flow/cli/dist/src/mcp-tools/workflow-tools.d.ts +0 -8
- package/src/@claude-flow/cli/dist/src/memory/ewc-consolidation.d.ts +0 -271
- package/src/@claude-flow/cli/dist/src/memory/intelligence.d.ts +0 -285
- package/src/@claude-flow/cli/dist/src/memory/memory-bridge.d.ts +0 -413
- package/src/@claude-flow/cli/dist/src/memory/memory-initializer.d.ts +0 -405
- package/src/@claude-flow/cli/dist/src/memory/sona-optimizer.d.ts +0 -227
- package/src/@claude-flow/cli/dist/src/output.d.ts +0 -133
- package/src/@claude-flow/cli/dist/src/parser.d.ts +0 -51
- package/src/@claude-flow/cli/dist/src/plugins/manager.d.ts +0 -133
- package/src/@claude-flow/cli/dist/src/plugins/store/discovery.d.ts +0 -88
- package/src/@claude-flow/cli/dist/src/plugins/store/index.d.ts +0 -76
- package/src/@claude-flow/cli/dist/src/plugins/store/search.d.ts +0 -46
- package/src/@claude-flow/cli/dist/src/plugins/store/types.d.ts +0 -274
- package/src/@claude-flow/cli/dist/src/plugins/tests/demo-plugin-store.d.ts +0 -7
- package/src/@claude-flow/cli/dist/src/plugins/tests/standalone-test.d.ts +0 -12
- package/src/@claude-flow/cli/dist/src/plugins/tests/test-plugin-store.d.ts +0 -7
- package/src/@claude-flow/cli/dist/src/production/circuit-breaker.d.ts +0 -101
- package/src/@claude-flow/cli/dist/src/production/error-handler.d.ts +0 -92
- package/src/@claude-flow/cli/dist/src/production/index.d.ts +0 -23
- package/src/@claude-flow/cli/dist/src/production/monitoring.d.ts +0 -161
- package/src/@claude-flow/cli/dist/src/production/rate-limiter.d.ts +0 -80
- package/src/@claude-flow/cli/dist/src/production/retry.d.ts +0 -48
- package/src/@claude-flow/cli/dist/src/prompt.d.ts +0 -44
- package/src/@claude-flow/cli/dist/src/runtime/headless.d.ts +0 -60
- package/src/@claude-flow/cli/dist/src/ruvector/ast-analyzer.d.ts +0 -67
- package/src/@claude-flow/cli/dist/src/ruvector/coverage-router.d.ts +0 -160
- package/src/@claude-flow/cli/dist/src/ruvector/coverage-tools.d.ts +0 -33
- package/src/@claude-flow/cli/dist/src/ruvector/diff-classifier.d.ts +0 -175
- package/src/@claude-flow/cli/dist/src/ruvector/enhanced-model-router.d.ts +0 -146
- package/src/@claude-flow/cli/dist/src/ruvector/flash-attention.d.ts +0 -195
- package/src/@claude-flow/cli/dist/src/ruvector/graph-analyzer.d.ts +0 -187
- package/src/@claude-flow/cli/dist/src/ruvector/index.d.ts +0 -34
- package/src/@claude-flow/cli/dist/src/ruvector/lora-adapter.d.ts +0 -218
- package/src/@claude-flow/cli/dist/src/ruvector/model-router.d.ts +0 -220
- package/src/@claude-flow/cli/dist/src/ruvector/moe-router.d.ts +0 -206
- package/src/@claude-flow/cli/dist/src/ruvector/q-learning-router.d.ts +0 -211
- package/src/@claude-flow/cli/dist/src/ruvector/semantic-router.d.ts +0 -77
- package/src/@claude-flow/cli/dist/src/ruvector/vector-db.d.ts +0 -69
- package/src/@claude-flow/cli/dist/src/services/agent-router.d.ts +0 -63
- package/src/@claude-flow/cli/dist/src/services/agentic-flow-bridge.d.ts +0 -50
- package/src/@claude-flow/cli/dist/src/services/claim-service.d.ts +0 -204
- package/src/@claude-flow/cli/dist/src/services/container-worker-pool.d.ts +0 -197
- package/src/@claude-flow/cli/dist/src/services/daemon-lock.d.ts +0 -60
- package/src/@claude-flow/cli/dist/src/services/headless-worker-executor.d.ts +0 -304
- package/src/@claude-flow/cli/dist/src/services/index.d.ts +0 -13
- package/src/@claude-flow/cli/dist/src/services/learning-service.d.ts +0 -161
- package/src/@claude-flow/cli/dist/src/services/moflo-require.d.ts +0 -34
- package/src/@claude-flow/cli/dist/src/services/registry-api.d.ts +0 -58
- package/src/@claude-flow/cli/dist/src/services/ruvector-training.d.ts +0 -214
- package/src/@claude-flow/cli/dist/src/services/worker-daemon.d.ts +0 -225
- package/src/@claude-flow/cli/dist/src/services/worker-queue.d.ts +0 -194
- package/src/@claude-flow/cli/dist/src/services/workflow-gate.d.ts +0 -88
- package/src/@claude-flow/cli/dist/src/suggest.d.ts +0 -53
- package/src/@claude-flow/cli/dist/src/transfer/anonymization/index.d.ts +0 -25
- package/src/@claude-flow/cli/dist/src/transfer/deploy-seraphine.d.ts +0 -13
- package/src/@claude-flow/cli/dist/src/transfer/export.d.ts +0 -25
- package/src/@claude-flow/cli/dist/src/transfer/index.d.ts +0 -12
- package/src/@claude-flow/cli/dist/src/transfer/ipfs/client.d.ts +0 -109
- package/src/@claude-flow/cli/dist/src/transfer/ipfs/upload.d.ts +0 -95
- package/src/@claude-flow/cli/dist/src/transfer/models/seraphine.d.ts +0 -72
- package/src/@claude-flow/cli/dist/src/transfer/serialization/cfp.d.ts +0 -49
- package/src/@claude-flow/cli/dist/src/transfer/storage/gcs.d.ts +0 -82
- package/src/@claude-flow/cli/dist/src/transfer/storage/index.d.ts +0 -6
- package/src/@claude-flow/cli/dist/src/transfer/store/discovery.d.ts +0 -84
- package/src/@claude-flow/cli/dist/src/transfer/store/download.d.ts +0 -70
- package/src/@claude-flow/cli/dist/src/transfer/store/index.d.ts +0 -84
- package/src/@claude-flow/cli/dist/src/transfer/store/publish.d.ts +0 -76
- package/src/@claude-flow/cli/dist/src/transfer/store/registry.d.ts +0 -58
- package/src/@claude-flow/cli/dist/src/transfer/store/search.d.ts +0 -54
- package/src/@claude-flow/cli/dist/src/transfer/store/tests/standalone-test.d.ts +0 -12
- package/src/@claude-flow/cli/dist/src/transfer/store/types.d.ts +0 -193
- package/src/@claude-flow/cli/dist/src/transfer/test-seraphine.d.ts +0 -6
- package/src/@claude-flow/cli/dist/src/transfer/tests/test-store.d.ts +0 -7
- package/src/@claude-flow/cli/dist/src/transfer/types.d.ts +0 -245
- package/src/@claude-flow/cli/dist/src/types.d.ts +0 -198
- package/src/@claude-flow/cli/dist/src/update/checker.d.ts +0 -34
- package/src/@claude-flow/cli/dist/src/update/executor.d.ts +0 -32
- package/src/@claude-flow/cli/dist/src/update/index.d.ts +0 -33
- package/src/@claude-flow/cli/dist/src/update/rate-limiter.d.ts +0 -20
- package/src/@claude-flow/cli/dist/src/update/validator.d.ts +0 -17
- package/src/@claude-flow/guidance/dist/adversarial.d.ts +0 -284
- package/src/@claude-flow/guidance/dist/analyzer.d.ts +0 -530
- package/src/@claude-flow/guidance/dist/artifacts.d.ts +0 -283
- package/src/@claude-flow/guidance/dist/authority.d.ts +0 -290
- package/src/@claude-flow/guidance/dist/capabilities.d.ts +0 -209
- package/src/@claude-flow/guidance/dist/coherence.d.ts +0 -233
- package/src/@claude-flow/guidance/dist/compiler.d.ts +0 -87
- package/src/@claude-flow/guidance/dist/conformance-kit.d.ts +0 -225
- package/src/@claude-flow/guidance/dist/continue-gate.d.ts +0 -214
- package/src/@claude-flow/guidance/dist/crypto-utils.d.ts +0 -17
- package/src/@claude-flow/guidance/dist/evolution.d.ts +0 -282
- package/src/@claude-flow/guidance/dist/gates.d.ts +0 -79
- package/src/@claude-flow/guidance/dist/gateway.d.ts +0 -206
- package/src/@claude-flow/guidance/dist/generators.d.ts +0 -153
- package/src/@claude-flow/guidance/dist/headless.d.ts +0 -177
- package/src/@claude-flow/guidance/dist/hooks.d.ts +0 -109
- package/src/@claude-flow/guidance/dist/index.d.ts +0 -205
- package/src/@claude-flow/guidance/dist/ledger.d.ts +0 -162
- package/src/@claude-flow/guidance/dist/manifest-validator.d.ts +0 -289
- package/src/@claude-flow/guidance/dist/memory-gate.d.ts +0 -222
- package/src/@claude-flow/guidance/dist/meta-governance.d.ts +0 -265
- package/src/@claude-flow/guidance/dist/optimizer.d.ts +0 -104
- package/src/@claude-flow/guidance/dist/persistence.d.ts +0 -189
- package/src/@claude-flow/guidance/dist/proof.d.ts +0 -185
- package/src/@claude-flow/guidance/dist/retriever.d.ts +0 -116
- package/src/@claude-flow/guidance/dist/ruvbot-integration.d.ts +0 -370
- package/src/@claude-flow/guidance/dist/temporal.d.ts +0 -426
- package/src/@claude-flow/guidance/dist/trust.d.ts +0 -283
- package/src/@claude-flow/guidance/dist/truth-anchors.d.ts +0 -276
- package/src/@claude-flow/guidance/dist/types.d.ts +0 -378
- package/src/@claude-flow/guidance/dist/uncertainty.d.ts +0 -372
- package/src/@claude-flow/guidance/dist/wasm-kernel.d.ts +0 -48
- package/src/@claude-flow/memory/dist/agent-memory-scope.d.ts +0 -131
- package/src/@claude-flow/memory/dist/agent-memory-scope.test.d.ts +0 -8
- package/src/@claude-flow/memory/dist/agentdb-adapter.d.ts +0 -165
- package/src/@claude-flow/memory/dist/agentdb-backend.d.ts +0 -212
- package/src/@claude-flow/memory/dist/agentdb-backend.test.d.ts +0 -7
- package/src/@claude-flow/memory/dist/application/commands/delete-memory.command.d.ts +0 -65
- package/src/@claude-flow/memory/dist/application/commands/store-memory.command.d.ts +0 -48
- package/src/@claude-flow/memory/dist/application/index.d.ts +0 -12
- package/src/@claude-flow/memory/dist/application/queries/search-memory.query.d.ts +0 -72
- package/src/@claude-flow/memory/dist/application/services/memory-application-service.d.ts +0 -121
- package/src/@claude-flow/memory/dist/auto-memory-bridge.d.ts +0 -226
- package/src/@claude-flow/memory/dist/auto-memory-bridge.test.d.ts +0 -8
- package/src/@claude-flow/memory/dist/benchmark.test.d.ts +0 -2
- package/src/@claude-flow/memory/dist/cache-manager.d.ts +0 -134
- package/src/@claude-flow/memory/dist/controller-registry.d.ts +0 -216
- package/src/@claude-flow/memory/dist/controller-registry.test.d.ts +0 -14
- package/src/@claude-flow/memory/dist/database-provider.d.ts +0 -87
- package/src/@claude-flow/memory/dist/database-provider.test.d.ts +0 -7
- package/src/@claude-flow/memory/dist/domain/entities/memory-entry.d.ts +0 -143
- package/src/@claude-flow/memory/dist/domain/index.d.ts +0 -11
- package/src/@claude-flow/memory/dist/domain/repositories/memory-repository.interface.d.ts +0 -102
- package/src/@claude-flow/memory/dist/domain/services/memory-domain-service.d.ts +0 -105
- package/src/@claude-flow/memory/dist/hnsw-index.d.ts +0 -111
- package/src/@claude-flow/memory/dist/hnsw-lite.d.ts +0 -23
- package/src/@claude-flow/memory/dist/hybrid-backend.d.ts +0 -245
- package/src/@claude-flow/memory/dist/hybrid-backend.test.d.ts +0 -8
- package/src/@claude-flow/memory/dist/index.d.ts +0 -204
- package/src/@claude-flow/memory/dist/infrastructure/index.d.ts +0 -17
- package/src/@claude-flow/memory/dist/infrastructure/repositories/hybrid-memory-repository.d.ts +0 -66
- package/src/@claude-flow/memory/dist/learning-bridge.d.ts +0 -137
- package/src/@claude-flow/memory/dist/learning-bridge.test.d.ts +0 -8
- package/src/@claude-flow/memory/dist/memory-graph.d.ts +0 -100
- package/src/@claude-flow/memory/dist/memory-graph.test.d.ts +0 -8
- package/src/@claude-flow/memory/dist/migration.d.ts +0 -68
- package/src/@claude-flow/memory/dist/persistent-sona.d.ts +0 -144
- package/src/@claude-flow/memory/dist/query-builder.d.ts +0 -211
- package/src/@claude-flow/memory/dist/rvf-backend.d.ts +0 -51
- package/src/@claude-flow/memory/dist/rvf-learning-store.d.ts +0 -139
- package/src/@claude-flow/memory/dist/rvf-migration.d.ts +0 -45
- package/src/@claude-flow/memory/dist/sqlite-backend.d.ts +0 -121
- package/src/@claude-flow/memory/dist/sqljs-backend.d.ts +0 -127
- package/src/@claude-flow/memory/dist/types.d.ts +0 -484
- package/src/@claude-flow/shared/dist/core/config/defaults.d.ts +0 -41
- package/src/@claude-flow/shared/dist/core/config/index.d.ts +0 -8
- package/src/@claude-flow/shared/dist/core/config/loader.d.ts +0 -45
- package/src/@claude-flow/shared/dist/core/config/schema.d.ts +0 -1134
- package/src/@claude-flow/shared/dist/core/config/validator.d.ts +0 -92
- package/src/@claude-flow/shared/dist/core/event-bus.d.ts +0 -31
- package/src/@claude-flow/shared/dist/core/index.d.ts +0 -15
- package/src/@claude-flow/shared/dist/core/interfaces/agent.interface.d.ts +0 -200
- package/src/@claude-flow/shared/dist/core/interfaces/coordinator.interface.d.ts +0 -310
- package/src/@claude-flow/shared/dist/core/interfaces/event.interface.d.ts +0 -224
- package/src/@claude-flow/shared/dist/core/interfaces/index.d.ts +0 -10
- package/src/@claude-flow/shared/dist/core/interfaces/memory.interface.d.ts +0 -298
- package/src/@claude-flow/shared/dist/core/interfaces/task.interface.d.ts +0 -185
- package/src/@claude-flow/shared/dist/core/orchestrator/event-coordinator.d.ts +0 -35
- package/src/@claude-flow/shared/dist/core/orchestrator/health-monitor.d.ts +0 -60
- package/src/@claude-flow/shared/dist/core/orchestrator/index.d.ts +0 -46
- package/src/@claude-flow/shared/dist/core/orchestrator/lifecycle-manager.d.ts +0 -56
- package/src/@claude-flow/shared/dist/core/orchestrator/session-manager.d.ts +0 -83
- package/src/@claude-flow/shared/dist/core/orchestrator/task-manager.d.ts +0 -49
- package/src/@claude-flow/shared/dist/events/domain-events.d.ts +0 -282
- package/src/@claude-flow/shared/dist/events/event-store.d.ts +0 -126
- package/src/@claude-flow/shared/dist/events/event-store.test.d.ts +0 -8
- package/src/@claude-flow/shared/dist/events/example-usage.d.ts +0 -10
- package/src/@claude-flow/shared/dist/events/index.d.ts +0 -21
- package/src/@claude-flow/shared/dist/events/projections.d.ts +0 -177
- package/src/@claude-flow/shared/dist/events/rvf-event-log.d.ts +0 -82
- package/src/@claude-flow/shared/dist/events/state-reconstructor.d.ts +0 -101
- package/src/@claude-flow/shared/dist/events.d.ts +0 -80
- package/src/@claude-flow/shared/dist/hooks/example-usage.d.ts +0 -42
- package/src/@claude-flow/shared/dist/hooks/executor.d.ts +0 -100
- package/src/@claude-flow/shared/dist/hooks/hooks.test.d.ts +0 -9
- package/src/@claude-flow/shared/dist/hooks/index.d.ts +0 -52
- package/src/@claude-flow/shared/dist/hooks/registry.d.ts +0 -133
- package/src/@claude-flow/shared/dist/hooks/safety/bash-safety.d.ts +0 -105
- package/src/@claude-flow/shared/dist/hooks/safety/file-organization.d.ts +0 -144
- package/src/@claude-flow/shared/dist/hooks/safety/git-commit.d.ts +0 -158
- package/src/@claude-flow/shared/dist/hooks/safety/index.d.ts +0 -17
- package/src/@claude-flow/shared/dist/hooks/session-hooks.d.ts +0 -234
- package/src/@claude-flow/shared/dist/hooks/task-hooks.d.ts +0 -163
- package/src/@claude-flow/shared/dist/hooks/types.d.ts +0 -267
- package/src/@claude-flow/shared/dist/hooks/verify-exports.test.d.ts +0 -9
- package/src/@claude-flow/shared/dist/index.d.ts +0 -20
- package/src/@claude-flow/shared/dist/mcp/connection-pool.d.ts +0 -98
- package/src/@claude-flow/shared/dist/mcp/index.d.ts +0 -69
- package/src/@claude-flow/shared/dist/mcp/server.d.ts +0 -166
- package/src/@claude-flow/shared/dist/mcp/session-manager.d.ts +0 -136
- package/src/@claude-flow/shared/dist/mcp/tool-registry.d.ts +0 -178
- package/src/@claude-flow/shared/dist/mcp/transport/http.d.ts +0 -104
- package/src/@claude-flow/shared/dist/mcp/transport/index.d.ts +0 -102
- package/src/@claude-flow/shared/dist/mcp/transport/stdio.d.ts +0 -104
- package/src/@claude-flow/shared/dist/mcp/transport/websocket.d.ts +0 -133
- package/src/@claude-flow/shared/dist/mcp/types.d.ts +0 -438
- package/src/@claude-flow/shared/dist/plugin-interface.d.ts +0 -544
- package/src/@claude-flow/shared/dist/plugin-loader.d.ts +0 -139
- package/src/@claude-flow/shared/dist/plugin-registry.d.ts +0 -183
- package/src/@claude-flow/shared/dist/plugins/index.d.ts +0 -10
- package/src/@claude-flow/shared/dist/plugins/official/hive-mind-plugin.d.ts +0 -106
- package/src/@claude-flow/shared/dist/plugins/official/index.d.ts +0 -10
- package/src/@claude-flow/shared/dist/plugins/official/maestro-plugin.d.ts +0 -121
- package/src/@claude-flow/shared/dist/plugins/types.d.ts +0 -93
- package/src/@claude-flow/shared/dist/resilience/bulkhead.d.ts +0 -105
- package/src/@claude-flow/shared/dist/resilience/circuit-breaker.d.ts +0 -132
- package/src/@claude-flow/shared/dist/resilience/index.d.ts +0 -19
- package/src/@claude-flow/shared/dist/resilience/rate-limiter.d.ts +0 -168
- package/src/@claude-flow/shared/dist/resilience/retry.d.ts +0 -91
- package/src/@claude-flow/shared/dist/security/index.d.ts +0 -10
- package/src/@claude-flow/shared/dist/security/input-validation.d.ts +0 -73
- package/src/@claude-flow/shared/dist/security/secure-random.d.ts +0 -92
- package/src/@claude-flow/shared/dist/services/index.d.ts +0 -7
- package/src/@claude-flow/shared/dist/services/v3-progress.service.d.ts +0 -124
- package/src/@claude-flow/shared/dist/types/agent.types.d.ts +0 -137
- package/src/@claude-flow/shared/dist/types/index.d.ts +0 -11
- package/src/@claude-flow/shared/dist/types/mcp.types.d.ts +0 -266
- package/src/@claude-flow/shared/dist/types/memory.types.d.ts +0 -236
- package/src/@claude-flow/shared/dist/types/swarm.types.d.ts +0 -186
- package/src/@claude-flow/shared/dist/types/task.types.d.ts +0 -178
- package/src/@claude-flow/shared/dist/types.d.ts +0 -197
- package/src/@claude-flow/shared/dist/utils/secure-logger.d.ts +0 -69
|
@@ -1,197 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Container Worker Pool
|
|
3
|
-
* Docker-based worker pool for high-throughput headless execution.
|
|
4
|
-
*
|
|
5
|
-
* ADR-020: Headless Worker Integration Architecture - Phase 3
|
|
6
|
-
* - Manages pool of Docker containers for isolated worker execution
|
|
7
|
-
* - Supports dynamic scaling based on workload
|
|
8
|
-
* - Provides container lifecycle management
|
|
9
|
-
* - Integrates with WorkerQueue for task distribution
|
|
10
|
-
*
|
|
11
|
-
* Key Features:
|
|
12
|
-
* - Container pooling with configurable size
|
|
13
|
-
* - Health checking and auto-recovery
|
|
14
|
-
* - Resource limits (CPU, memory)
|
|
15
|
-
* - Volume mounting for workspace access
|
|
16
|
-
* - Network isolation per worker type
|
|
17
|
-
*/
|
|
18
|
-
import { EventEmitter } from 'events';
|
|
19
|
-
import type { HeadlessWorkerType, HeadlessExecutionResult, SandboxMode } from './headless-worker-executor.js';
|
|
20
|
-
/**
|
|
21
|
-
* Container state
|
|
22
|
-
*/
|
|
23
|
-
export type ContainerState = 'creating' | 'ready' | 'busy' | 'unhealthy' | 'terminated';
|
|
24
|
-
/**
|
|
25
|
-
* Container info
|
|
26
|
-
*/
|
|
27
|
-
export interface ContainerInfo {
|
|
28
|
-
id: string;
|
|
29
|
-
name: string;
|
|
30
|
-
state: ContainerState;
|
|
31
|
-
createdAt: Date;
|
|
32
|
-
lastUsedAt?: Date;
|
|
33
|
-
workerType?: HeadlessWorkerType;
|
|
34
|
-
executionCount: number;
|
|
35
|
-
healthCheckFailures: number;
|
|
36
|
-
pid?: number;
|
|
37
|
-
}
|
|
38
|
-
/**
|
|
39
|
-
* Container pool configuration
|
|
40
|
-
*/
|
|
41
|
-
export interface ContainerPoolConfig {
|
|
42
|
-
/** Maximum number of containers in the pool */
|
|
43
|
-
maxContainers: number;
|
|
44
|
-
/** Minimum number of containers to keep warm */
|
|
45
|
-
minContainers: number;
|
|
46
|
-
/** Docker image to use */
|
|
47
|
-
image: string;
|
|
48
|
-
/** Container resource limits */
|
|
49
|
-
resources: {
|
|
50
|
-
cpus: string;
|
|
51
|
-
memory: string;
|
|
52
|
-
};
|
|
53
|
-
/** Health check interval in ms */
|
|
54
|
-
healthCheckIntervalMs: number;
|
|
55
|
-
/** Container idle timeout in ms */
|
|
56
|
-
idleTimeoutMs: number;
|
|
57
|
-
/** Workspace volume mount path */
|
|
58
|
-
workspacePath: string;
|
|
59
|
-
/** State persistence path */
|
|
60
|
-
statePath: string;
|
|
61
|
-
/** Network name for container isolation */
|
|
62
|
-
network?: string;
|
|
63
|
-
/** Environment variables for containers */
|
|
64
|
-
env?: Record<string, string>;
|
|
65
|
-
/** Default sandbox mode */
|
|
66
|
-
defaultSandbox: SandboxMode;
|
|
67
|
-
}
|
|
68
|
-
/**
|
|
69
|
-
* Container execution options
|
|
70
|
-
*/
|
|
71
|
-
export interface ContainerExecutionOptions {
|
|
72
|
-
workerType: HeadlessWorkerType;
|
|
73
|
-
prompt: string;
|
|
74
|
-
contextPatterns?: string[];
|
|
75
|
-
sandbox?: SandboxMode;
|
|
76
|
-
model?: string;
|
|
77
|
-
timeoutMs?: number;
|
|
78
|
-
}
|
|
79
|
-
/**
|
|
80
|
-
* Pool status
|
|
81
|
-
*/
|
|
82
|
-
export interface ContainerPoolStatus {
|
|
83
|
-
totalContainers: number;
|
|
84
|
-
readyContainers: number;
|
|
85
|
-
busyContainers: number;
|
|
86
|
-
unhealthyContainers: number;
|
|
87
|
-
queuedTasks: number;
|
|
88
|
-
containers: ContainerInfo[];
|
|
89
|
-
dockerAvailable: boolean;
|
|
90
|
-
lastHealthCheck?: Date;
|
|
91
|
-
}
|
|
92
|
-
/**
|
|
93
|
-
* ContainerWorkerPool - Manages Docker containers for headless worker execution
|
|
94
|
-
*/
|
|
95
|
-
export declare class ContainerWorkerPool extends EventEmitter {
|
|
96
|
-
private config;
|
|
97
|
-
private projectRoot;
|
|
98
|
-
private containers;
|
|
99
|
-
private taskQueue;
|
|
100
|
-
private healthCheckTimer?;
|
|
101
|
-
private idleCheckTimer?;
|
|
102
|
-
private dockerAvailable;
|
|
103
|
-
private initialized;
|
|
104
|
-
private isShuttingDown;
|
|
105
|
-
private exitHandlersRegistered;
|
|
106
|
-
constructor(projectRoot: string, config?: Partial<ContainerPoolConfig>);
|
|
107
|
-
/**
|
|
108
|
-
* Initialize the container pool
|
|
109
|
-
*/
|
|
110
|
-
initialize(): Promise<boolean>;
|
|
111
|
-
/**
|
|
112
|
-
* Register process exit handlers to clean up containers
|
|
113
|
-
*/
|
|
114
|
-
private registerExitHandlers;
|
|
115
|
-
/**
|
|
116
|
-
* Execute a worker in a container
|
|
117
|
-
*/
|
|
118
|
-
execute(options: ContainerExecutionOptions): Promise<HeadlessExecutionResult>;
|
|
119
|
-
/**
|
|
120
|
-
* Scale pool for batch execution
|
|
121
|
-
*/
|
|
122
|
-
scaleForBatch(workerCount: number): Promise<void>;
|
|
123
|
-
/**
|
|
124
|
-
* Get pool status
|
|
125
|
-
*/
|
|
126
|
-
getStatus(): ContainerPoolStatus;
|
|
127
|
-
/**
|
|
128
|
-
* Shutdown the pool
|
|
129
|
-
*/
|
|
130
|
-
shutdown(): Promise<void>;
|
|
131
|
-
/**
|
|
132
|
-
* Check if Docker is available (async)
|
|
133
|
-
*/
|
|
134
|
-
private checkDockerAvailable;
|
|
135
|
-
/**
|
|
136
|
-
* Ensure the container image exists (async)
|
|
137
|
-
*/
|
|
138
|
-
private ensureImage;
|
|
139
|
-
/**
|
|
140
|
-
* Create a new container
|
|
141
|
-
*/
|
|
142
|
-
private createContainer;
|
|
143
|
-
/**
|
|
144
|
-
* Terminate a container (async)
|
|
145
|
-
*/
|
|
146
|
-
private terminateContainer;
|
|
147
|
-
/**
|
|
148
|
-
* Get a ready container
|
|
149
|
-
*/
|
|
150
|
-
private getReadyContainer;
|
|
151
|
-
/**
|
|
152
|
-
* Scale to minimum containers
|
|
153
|
-
*/
|
|
154
|
-
private scaleToMinimum;
|
|
155
|
-
/**
|
|
156
|
-
* Execute worker in a specific container
|
|
157
|
-
*/
|
|
158
|
-
private executeInContainer;
|
|
159
|
-
/**
|
|
160
|
-
* Execute command in container
|
|
161
|
-
*/
|
|
162
|
-
private execInContainer;
|
|
163
|
-
/**
|
|
164
|
-
* Build worker command for container execution
|
|
165
|
-
*/
|
|
166
|
-
private buildWorkerCommand;
|
|
167
|
-
/**
|
|
168
|
-
* Process queued tasks
|
|
169
|
-
*/
|
|
170
|
-
private processQueue;
|
|
171
|
-
/**
|
|
172
|
-
* Start health check timer
|
|
173
|
-
*/
|
|
174
|
-
private startHealthChecks;
|
|
175
|
-
/**
|
|
176
|
-
* Run health checks on all containers
|
|
177
|
-
*/
|
|
178
|
-
private runHealthChecks;
|
|
179
|
-
/**
|
|
180
|
-
* Start idle check timer
|
|
181
|
-
*/
|
|
182
|
-
private startIdleChecks;
|
|
183
|
-
/**
|
|
184
|
-
* Terminate idle containers above minimum
|
|
185
|
-
*/
|
|
186
|
-
private runIdleChecks;
|
|
187
|
-
/**
|
|
188
|
-
* Try to parse JSON from output
|
|
189
|
-
*/
|
|
190
|
-
private tryParseJson;
|
|
191
|
-
/**
|
|
192
|
-
* Create an error result
|
|
193
|
-
*/
|
|
194
|
-
private createErrorResult;
|
|
195
|
-
}
|
|
196
|
-
export default ContainerWorkerPool;
|
|
197
|
-
//# sourceMappingURL=container-worker-pool.d.ts.map
|
|
@@ -1,60 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Atomic daemon lock — prevents duplicate daemon processes.
|
|
3
|
-
*
|
|
4
|
-
* Uses fs.writeFileSync with { flag: 'wx' } (O_CREAT | O_EXCL) which is
|
|
5
|
-
* atomic on all platforms: the write fails immediately if the file exists,
|
|
6
|
-
* eliminating the TOCTOU race in the old PID-file approach.
|
|
7
|
-
*
|
|
8
|
-
* Also solves Windows PID recycling by storing a label in the lock payload
|
|
9
|
-
* and verifying the process command line before trusting a "live" PID.
|
|
10
|
-
*/
|
|
11
|
-
export interface DaemonLockPayload {
|
|
12
|
-
pid: number;
|
|
13
|
-
startedAt: number;
|
|
14
|
-
label: string;
|
|
15
|
-
}
|
|
16
|
-
/** Resolve the lock file path for a project root. */
|
|
17
|
-
export declare function lockPath(projectRoot: string): string;
|
|
18
|
-
/**
|
|
19
|
-
* Try to acquire the daemon lock atomically.
|
|
20
|
-
*
|
|
21
|
-
* @returns `{ acquired: true }` on success,
|
|
22
|
-
* `{ acquired: false, holder: pid }` if another daemon owns the lock.
|
|
23
|
-
*/
|
|
24
|
-
export declare function acquireDaemonLock(projectRoot: string, pid?: number): {
|
|
25
|
-
acquired: true;
|
|
26
|
-
} | {
|
|
27
|
-
acquired: false;
|
|
28
|
-
holder: number;
|
|
29
|
-
};
|
|
30
|
-
/**
|
|
31
|
-
* Release the daemon lock. Only removes if we own it (or force = true).
|
|
32
|
-
*/
|
|
33
|
-
export declare function releaseDaemonLock(projectRoot: string, pid?: number, force?: boolean): void;
|
|
34
|
-
/**
|
|
35
|
-
* Atomically transfer the daemon lock to a new PID (e.g. parent → child).
|
|
36
|
-
*
|
|
37
|
-
* Overwrites the lock file in-place so there is no window where the lock
|
|
38
|
-
* is absent. Only succeeds if the lock is currently held by `fromPid`.
|
|
39
|
-
*/
|
|
40
|
-
export declare function transferDaemonLock(projectRoot: string, newPid: number, fromPid?: number): boolean;
|
|
41
|
-
/**
|
|
42
|
-
* Check if the daemon lock is currently held by a live daemon.
|
|
43
|
-
* Returns the holder PID or null.
|
|
44
|
-
*/
|
|
45
|
-
export declare function getDaemonLockHolder(projectRoot: string): number | null;
|
|
46
|
-
/**
|
|
47
|
-
* Cross-platform check: is this PID actually a moflo/claude-flow daemon?
|
|
48
|
-
*
|
|
49
|
-
* This prevents false positives from Windows PID recycling, where a dead
|
|
50
|
-
* daemon's PID gets reused by an unrelated process (e.g. Chrome).
|
|
51
|
-
*
|
|
52
|
-
* - Windows: uses `tasklist /FI` to check the process image + command line
|
|
53
|
-
* - Linux: reads /proc/<pid>/cmdline
|
|
54
|
-
* - macOS: uses `ps -p <pid> -o command=`
|
|
55
|
-
*
|
|
56
|
-
* Falls back to `true` (trust process.kill) if the platform check fails,
|
|
57
|
-
* to avoid accidentally allowing duplicates on exotic platforms.
|
|
58
|
-
*/
|
|
59
|
-
export declare function isDaemonProcess(pid: number): boolean;
|
|
60
|
-
//# sourceMappingURL=daemon-lock.d.ts.map
|
|
@@ -1,304 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Headless Worker Executor
|
|
3
|
-
* Enables workers to invoke Claude Code in headless mode with configurable sandbox profiles.
|
|
4
|
-
*
|
|
5
|
-
* ADR-020: Headless Worker Integration Architecture
|
|
6
|
-
* - Integrates with CLAUDE_CODE_HEADLESS and CLAUDE_CODE_SANDBOX_MODE environment variables
|
|
7
|
-
* - Provides process pool for concurrent execution
|
|
8
|
-
* - Builds context from file glob patterns
|
|
9
|
-
* - Supports prompt templates and output parsing
|
|
10
|
-
* - Implements timeout and graceful error handling
|
|
11
|
-
*
|
|
12
|
-
* Key Features:
|
|
13
|
-
* - Process pool with configurable maxConcurrent
|
|
14
|
-
* - Context building from file glob patterns with caching
|
|
15
|
-
* - Prompt template system with context injection
|
|
16
|
-
* - Output parsing (text, json, markdown)
|
|
17
|
-
* - Timeout handling with graceful termination
|
|
18
|
-
* - Execution logging for debugging
|
|
19
|
-
* - Event emission for monitoring
|
|
20
|
-
*/
|
|
21
|
-
import { EventEmitter } from 'events';
|
|
22
|
-
import type { WorkerType } from './worker-daemon.js';
|
|
23
|
-
/**
|
|
24
|
-
* Headless worker types - workers that use Claude Code AI
|
|
25
|
-
*/
|
|
26
|
-
export type HeadlessWorkerType = 'audit' | 'optimize' | 'testgaps' | 'document' | 'ultralearn' | 'refactor' | 'deepdive' | 'predict';
|
|
27
|
-
/**
|
|
28
|
-
* Local worker types - workers that run locally without AI
|
|
29
|
-
*/
|
|
30
|
-
export type LocalWorkerType = 'map' | 'consolidate' | 'benchmark' | 'preload';
|
|
31
|
-
/**
|
|
32
|
-
* Sandbox mode for headless execution
|
|
33
|
-
*/
|
|
34
|
-
export type SandboxMode = 'strict' | 'permissive' | 'disabled';
|
|
35
|
-
/**
|
|
36
|
-
* Model types for Claude Code
|
|
37
|
-
*/
|
|
38
|
-
export type ModelType = 'sonnet' | 'opus' | 'haiku';
|
|
39
|
-
/**
|
|
40
|
-
* Output format for worker results
|
|
41
|
-
*/
|
|
42
|
-
export type OutputFormat = 'text' | 'json' | 'markdown';
|
|
43
|
-
/**
|
|
44
|
-
* Execution mode for workers
|
|
45
|
-
*/
|
|
46
|
-
export type ExecutionMode = 'local' | 'headless';
|
|
47
|
-
/**
|
|
48
|
-
* Worker priority levels
|
|
49
|
-
*/
|
|
50
|
-
export type WorkerPriority = 'low' | 'normal' | 'high' | 'critical';
|
|
51
|
-
/**
|
|
52
|
-
* Base worker configuration (matching worker-daemon.ts)
|
|
53
|
-
*/
|
|
54
|
-
export interface WorkerConfig {
|
|
55
|
-
type: WorkerType;
|
|
56
|
-
intervalMs: number;
|
|
57
|
-
priority: WorkerPriority;
|
|
58
|
-
description: string;
|
|
59
|
-
enabled: boolean;
|
|
60
|
-
}
|
|
61
|
-
/**
|
|
62
|
-
* Headless-specific options
|
|
63
|
-
*/
|
|
64
|
-
export interface HeadlessOptions {
|
|
65
|
-
/** Prompt template for Claude Code */
|
|
66
|
-
promptTemplate: string;
|
|
67
|
-
/** Sandbox profile: strict, permissive, or disabled */
|
|
68
|
-
sandbox: SandboxMode;
|
|
69
|
-
/** Model to use: sonnet, opus, or haiku */
|
|
70
|
-
model?: ModelType;
|
|
71
|
-
/** Maximum tokens for output */
|
|
72
|
-
maxOutputTokens?: number;
|
|
73
|
-
/** Timeout in milliseconds (overrides default) */
|
|
74
|
-
timeoutMs?: number;
|
|
75
|
-
/** File glob patterns to include as context */
|
|
76
|
-
contextPatterns?: string[];
|
|
77
|
-
/** Output parsing format */
|
|
78
|
-
outputFormat?: OutputFormat;
|
|
79
|
-
}
|
|
80
|
-
/**
|
|
81
|
-
* Extended worker configuration with headless options
|
|
82
|
-
*/
|
|
83
|
-
export interface HeadlessWorkerConfig extends WorkerConfig {
|
|
84
|
-
/** Execution mode: local or headless */
|
|
85
|
-
mode: ExecutionMode;
|
|
86
|
-
/** Headless-specific options (required when mode is 'headless') */
|
|
87
|
-
headless?: HeadlessOptions;
|
|
88
|
-
}
|
|
89
|
-
/**
|
|
90
|
-
* Executor configuration options
|
|
91
|
-
*/
|
|
92
|
-
export interface HeadlessExecutorConfig {
|
|
93
|
-
/** Maximum concurrent headless processes */
|
|
94
|
-
maxConcurrent?: number;
|
|
95
|
-
/** Default timeout in milliseconds */
|
|
96
|
-
defaultTimeoutMs?: number;
|
|
97
|
-
/** Maximum files to include in context */
|
|
98
|
-
maxContextFiles?: number;
|
|
99
|
-
/** Maximum characters per file in context */
|
|
100
|
-
maxCharsPerFile?: number;
|
|
101
|
-
/** Log directory for execution logs */
|
|
102
|
-
logDir?: string;
|
|
103
|
-
/** Whether to cache context between runs */
|
|
104
|
-
cacheContext?: boolean;
|
|
105
|
-
/** Context cache TTL in milliseconds */
|
|
106
|
-
cacheTtlMs?: number;
|
|
107
|
-
}
|
|
108
|
-
/**
|
|
109
|
-
* Result from headless execution
|
|
110
|
-
*/
|
|
111
|
-
export interface HeadlessExecutionResult {
|
|
112
|
-
/** Whether execution completed successfully */
|
|
113
|
-
success: boolean;
|
|
114
|
-
/** Raw output from Claude Code */
|
|
115
|
-
output: string;
|
|
116
|
-
/** Parsed output (if outputFormat is json or markdown) */
|
|
117
|
-
parsedOutput?: unknown;
|
|
118
|
-
/** Execution duration in milliseconds */
|
|
119
|
-
durationMs: number;
|
|
120
|
-
/** Estimated tokens used (if available) */
|
|
121
|
-
tokensUsed?: number;
|
|
122
|
-
/** Model used for execution */
|
|
123
|
-
model: string;
|
|
124
|
-
/** Sandbox mode used */
|
|
125
|
-
sandboxMode: SandboxMode;
|
|
126
|
-
/** Worker type that was executed */
|
|
127
|
-
workerType: HeadlessWorkerType;
|
|
128
|
-
/** Timestamp of execution */
|
|
129
|
-
timestamp: Date;
|
|
130
|
-
/** Error message if execution failed */
|
|
131
|
-
error?: string;
|
|
132
|
-
/** Execution ID for tracking */
|
|
133
|
-
executionId: string;
|
|
134
|
-
}
|
|
135
|
-
/**
|
|
136
|
-
* Pool status information
|
|
137
|
-
*/
|
|
138
|
-
export interface PoolStatus {
|
|
139
|
-
activeCount: number;
|
|
140
|
-
queueLength: number;
|
|
141
|
-
maxConcurrent: number;
|
|
142
|
-
activeWorkers: Array<{
|
|
143
|
-
executionId: string;
|
|
144
|
-
workerType: HeadlessWorkerType;
|
|
145
|
-
startTime: Date;
|
|
146
|
-
elapsedMs: number;
|
|
147
|
-
}>;
|
|
148
|
-
queuedWorkers: Array<{
|
|
149
|
-
workerType: HeadlessWorkerType;
|
|
150
|
-
queuedAt: Date;
|
|
151
|
-
waitingMs: number;
|
|
152
|
-
}>;
|
|
153
|
-
}
|
|
154
|
-
/**
|
|
155
|
-
* Array of headless worker types for runtime checking
|
|
156
|
-
*/
|
|
157
|
-
export declare const HEADLESS_WORKER_TYPES: HeadlessWorkerType[];
|
|
158
|
-
/**
|
|
159
|
-
* Array of local worker types
|
|
160
|
-
*/
|
|
161
|
-
export declare const LOCAL_WORKER_TYPES: LocalWorkerType[];
|
|
162
|
-
/**
|
|
163
|
-
* Default headless worker configurations based on ADR-020
|
|
164
|
-
*/
|
|
165
|
-
export declare const HEADLESS_WORKER_CONFIGS: Record<HeadlessWorkerType, HeadlessWorkerConfig>;
|
|
166
|
-
/**
|
|
167
|
-
* Local worker configurations
|
|
168
|
-
*/
|
|
169
|
-
export declare const LOCAL_WORKER_CONFIGS: Record<LocalWorkerType, HeadlessWorkerConfig>;
|
|
170
|
-
/**
|
|
171
|
-
* Combined worker configurations
|
|
172
|
-
*/
|
|
173
|
-
export declare const ALL_WORKER_CONFIGS: HeadlessWorkerConfig[];
|
|
174
|
-
/**
|
|
175
|
-
* Check if a worker type is a headless worker
|
|
176
|
-
*/
|
|
177
|
-
export declare function isHeadlessWorker(type: WorkerType): type is HeadlessWorkerType;
|
|
178
|
-
/**
|
|
179
|
-
* Check if a worker type is a local worker
|
|
180
|
-
*/
|
|
181
|
-
export declare function isLocalWorker(type: WorkerType): type is LocalWorkerType;
|
|
182
|
-
/**
|
|
183
|
-
* Get model ID from model type
|
|
184
|
-
*/
|
|
185
|
-
export declare function getModelId(model: ModelType): string;
|
|
186
|
-
/**
|
|
187
|
-
* Get worker configuration by type
|
|
188
|
-
*/
|
|
189
|
-
export declare function getWorkerConfig(type: WorkerType): HeadlessWorkerConfig | undefined;
|
|
190
|
-
/**
|
|
191
|
-
* HeadlessWorkerExecutor - Executes workers using Claude Code in headless mode
|
|
192
|
-
*
|
|
193
|
-
* Features:
|
|
194
|
-
* - Process pool with configurable concurrency limit
|
|
195
|
-
* - Pending queue for overflow requests
|
|
196
|
-
* - Context caching with configurable TTL
|
|
197
|
-
* - Execution logging for debugging
|
|
198
|
-
* - Event emission for monitoring
|
|
199
|
-
* - Graceful termination
|
|
200
|
-
*/
|
|
201
|
-
export declare class HeadlessWorkerExecutor extends EventEmitter {
|
|
202
|
-
private projectRoot;
|
|
203
|
-
private config;
|
|
204
|
-
private processPool;
|
|
205
|
-
private pendingQueue;
|
|
206
|
-
private contextCache;
|
|
207
|
-
private claudeCodeAvailable;
|
|
208
|
-
private claudeCodeVersion;
|
|
209
|
-
constructor(projectRoot: string, options?: HeadlessExecutorConfig);
|
|
210
|
-
/**
|
|
211
|
-
* Check if Claude Code CLI is available
|
|
212
|
-
*/
|
|
213
|
-
isAvailable(): Promise<boolean>;
|
|
214
|
-
/**
|
|
215
|
-
* Get Claude Code version
|
|
216
|
-
*/
|
|
217
|
-
getVersion(): Promise<string | null>;
|
|
218
|
-
/**
|
|
219
|
-
* Execute a headless worker
|
|
220
|
-
*/
|
|
221
|
-
execute(workerType: HeadlessWorkerType, configOverrides?: Partial<HeadlessOptions>): Promise<HeadlessExecutionResult>;
|
|
222
|
-
/**
|
|
223
|
-
* Get pool status
|
|
224
|
-
*/
|
|
225
|
-
getPoolStatus(): PoolStatus;
|
|
226
|
-
/**
|
|
227
|
-
* Get number of active executions
|
|
228
|
-
*/
|
|
229
|
-
getActiveCount(): number;
|
|
230
|
-
/**
|
|
231
|
-
* Cancel a running execution
|
|
232
|
-
*/
|
|
233
|
-
cancel(executionId: string): boolean;
|
|
234
|
-
/**
|
|
235
|
-
* Cancel all running executions
|
|
236
|
-
*/
|
|
237
|
-
cancelAll(): number;
|
|
238
|
-
/**
|
|
239
|
-
* Clear context cache
|
|
240
|
-
*/
|
|
241
|
-
clearContextCache(): void;
|
|
242
|
-
/**
|
|
243
|
-
* Get worker configuration
|
|
244
|
-
*/
|
|
245
|
-
getConfig(workerType: HeadlessWorkerType): HeadlessWorkerConfig | undefined;
|
|
246
|
-
/**
|
|
247
|
-
* Get all headless worker types
|
|
248
|
-
*/
|
|
249
|
-
getHeadlessWorkerTypes(): HeadlessWorkerType[];
|
|
250
|
-
/**
|
|
251
|
-
* Get all local worker types
|
|
252
|
-
*/
|
|
253
|
-
getLocalWorkerTypes(): LocalWorkerType[];
|
|
254
|
-
/**
|
|
255
|
-
* Ensure log directory exists
|
|
256
|
-
*/
|
|
257
|
-
private ensureLogDir;
|
|
258
|
-
/**
|
|
259
|
-
* Internal execution logic
|
|
260
|
-
*/
|
|
261
|
-
private executeInternal;
|
|
262
|
-
/**
|
|
263
|
-
* Process the pending queue
|
|
264
|
-
*/
|
|
265
|
-
private processQueue;
|
|
266
|
-
/**
|
|
267
|
-
* Build context from file patterns
|
|
268
|
-
*/
|
|
269
|
-
private buildContext;
|
|
270
|
-
/**
|
|
271
|
-
* Simple glob implementation for file matching
|
|
272
|
-
*/
|
|
273
|
-
private simpleGlob;
|
|
274
|
-
/**
|
|
275
|
-
* Match filename against a simple pattern
|
|
276
|
-
*/
|
|
277
|
-
private matchesPattern;
|
|
278
|
-
/**
|
|
279
|
-
* Build full prompt with context
|
|
280
|
-
*/
|
|
281
|
-
private buildPrompt;
|
|
282
|
-
/**
|
|
283
|
-
* Execute Claude Code in headless mode
|
|
284
|
-
*/
|
|
285
|
-
private executeClaudeCode;
|
|
286
|
-
/**
|
|
287
|
-
* Parse JSON output from Claude Code
|
|
288
|
-
*/
|
|
289
|
-
private parseJsonOutput;
|
|
290
|
-
/**
|
|
291
|
-
* Parse markdown output into sections
|
|
292
|
-
*/
|
|
293
|
-
private parseMarkdownOutput;
|
|
294
|
-
/**
|
|
295
|
-
* Create an error result
|
|
296
|
-
*/
|
|
297
|
-
private createErrorResult;
|
|
298
|
-
/**
|
|
299
|
-
* Log execution details for debugging
|
|
300
|
-
*/
|
|
301
|
-
private logExecution;
|
|
302
|
-
}
|
|
303
|
-
export default HeadlessWorkerExecutor;
|
|
304
|
-
//# sourceMappingURL=headless-worker-executor.d.ts.map
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* V3 CLI Services Index
|
|
3
|
-
* Central registry for all background services
|
|
4
|
-
*/
|
|
5
|
-
export { WorkerDaemon, getDaemon, startDaemon, stopDaemon, type WorkerType, } from './worker-daemon.js';
|
|
6
|
-
export { HeadlessWorkerExecutor, HEADLESS_WORKER_TYPES, HEADLESS_WORKER_CONFIGS, LOCAL_WORKER_TYPES, LOCAL_WORKER_CONFIGS, ALL_WORKER_CONFIGS, isHeadlessWorker, isLocalWorker, getModelId, getWorkerConfig, type HeadlessWorkerType, type LocalWorkerType, type HeadlessWorkerConfig, type HeadlessExecutionResult, type HeadlessExecutorConfig, type HeadlessOptions, type PoolStatus, type SandboxMode, type ModelType, type OutputFormat, type ExecutionMode, type WorkerPriority, type WorkerConfig, } from './headless-worker-executor.js';
|
|
7
|
-
export { WorkerQueue, type QueueTask, type WorkerQueueConfig, type QueueStats, type WorkerRegistration, type TaskStatus, } from './worker-queue.js';
|
|
8
|
-
export { LearningService, getLearningService, HNSWIndex, hashEmbed, cosineSimilarity, LEARNING_CONFIG, type PatternSearchResult, type StoreResult, type ConsolidateResult, type LearningStats, type PatternRow, } from './learning-service.js';
|
|
9
|
-
export { AgentRouter, getAgentRouter, routeTask, AGENT_CAPABILITIES, type RouteResult, type AgentType, } from './agent-router.js';
|
|
10
|
-
export type { default as WorkerDaemonType, DaemonConfig } from './worker-daemon.js';
|
|
11
|
-
export type { default as HeadlessWorkerExecutorType } from './headless-worker-executor.js';
|
|
12
|
-
export type { default as WorkerQueueType } from './worker-queue.js';
|
|
13
|
-
//# sourceMappingURL=index.d.ts.map
|