swarm-engine 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/AGENTS.md +72 -0
- package/CLAUDE.md +89 -0
- package/LICENSE +21 -0
- package/README.md +235 -0
- package/agents/accessibility-reviewer.md +118 -0
- package/agents/api-contract-reviewer.md +99 -0
- package/agents/concurrency-reviewer.md +111 -0
- package/agents/data-integrity-reviewer.md +103 -0
- package/agents/debugger.md +99 -0
- package/agents/dependency-reviewer.md +115 -0
- package/agents/devils-advocate.md +94 -0
- package/agents/documentation-reviewer.md +114 -0
- package/agents/documenter.md +78 -0
- package/agents/error-handling-reviewer.md +113 -0
- package/agents/grounding.md +99 -0
- package/agents/guardian.md +87 -0
- package/agents/implementer.md +141 -0
- package/agents/integrator.md +95 -0
- package/agents/judge.md +79 -0
- package/agents/librarian.md +90 -0
- package/agents/orchestrator.md +331 -0
- package/agents/performance-reviewer.md +93 -0
- package/agents/planner.md +106 -0
- package/agents/refactorer.md +92 -0
- package/agents/researcher.md +97 -0
- package/agents/reviewer.md +117 -0
- package/agents/security-reviewer.md +107 -0
- package/agents/sentinel.md +92 -0
- package/agents/tester.md +93 -0
- package/agents/testing-reviewer.md +112 -0
- package/commands/diff-review.md +64 -0
- package/commands/fix-pr.md +78 -0
- package/commands/red-team.md +82 -0
- package/commands/research.md +59 -0
- package/commands/resume.md +80 -0
- package/commands/review-cycle.md +123 -0
- package/commands/swarm-setup.md +28 -0
- package/commands/swarm.md +126 -0
- package/commands/tdd.md +91 -0
- package/dist/cli/bin.d.ts +3 -0
- package/dist/cli/bin.d.ts.map +1 -0
- package/dist/cli/bin.js +3 -0
- package/dist/cli/bin.js.map +1 -0
- package/dist/cli/commands/acp.d.ts +3 -0
- package/dist/cli/commands/acp.d.ts.map +1 -0
- package/dist/cli/commands/acp.js +29 -0
- package/dist/cli/commands/acp.js.map +1 -0
- package/dist/cli/commands/agents.d.ts +3 -0
- package/dist/cli/commands/agents.d.ts.map +1 -0
- package/dist/cli/commands/agents.js +344 -0
- package/dist/cli/commands/agents.js.map +1 -0
- package/dist/cli/commands/backends.d.ts +3 -0
- package/dist/cli/commands/backends.d.ts.map +1 -0
- package/dist/cli/commands/backends.js +22 -0
- package/dist/cli/commands/backends.js.map +1 -0
- package/dist/cli/commands/completions.d.ts +3 -0
- package/dist/cli/commands/completions.d.ts.map +1 -0
- package/dist/cli/commands/completions.js +85 -0
- package/dist/cli/commands/completions.js.map +1 -0
- package/dist/cli/commands/compound.d.ts +3 -0
- package/dist/cli/commands/compound.d.ts.map +1 -0
- package/dist/cli/commands/compound.js +119 -0
- package/dist/cli/commands/compound.js.map +1 -0
- package/dist/cli/commands/configure.d.ts +3 -0
- package/dist/cli/commands/configure.d.ts.map +1 -0
- package/dist/cli/commands/configure.js +151 -0
- package/dist/cli/commands/configure.js.map +1 -0
- package/dist/cli/commands/convert.d.ts +15 -0
- package/dist/cli/commands/convert.d.ts.map +1 -0
- package/dist/cli/commands/convert.js +218 -0
- package/dist/cli/commands/convert.js.map +1 -0
- package/dist/cli/commands/doctor.d.ts +3 -0
- package/dist/cli/commands/doctor.d.ts.map +1 -0
- package/dist/cli/commands/doctor.js +96 -0
- package/dist/cli/commands/doctor.js.map +1 -0
- package/dist/cli/commands/init.d.ts +3 -0
- package/dist/cli/commands/init.d.ts.map +1 -0
- package/dist/cli/commands/init.js +154 -0
- package/dist/cli/commands/init.js.map +1 -0
- package/dist/cli/commands/learn.d.ts +3 -0
- package/dist/cli/commands/learn.d.ts.map +1 -0
- package/dist/cli/commands/learn.js +163 -0
- package/dist/cli/commands/learn.js.map +1 -0
- package/dist/cli/commands/mcp.d.ts +3 -0
- package/dist/cli/commands/mcp.d.ts.map +1 -0
- package/dist/cli/commands/mcp.js +89 -0
- package/dist/cli/commands/mcp.js.map +1 -0
- package/dist/cli/commands/memory.d.ts +3 -0
- package/dist/cli/commands/memory.d.ts.map +1 -0
- package/dist/cli/commands/memory.js +134 -0
- package/dist/cli/commands/memory.js.map +1 -0
- package/dist/cli/commands/orchestrate.d.ts +3 -0
- package/dist/cli/commands/orchestrate.d.ts.map +1 -0
- package/dist/cli/commands/orchestrate.js +237 -0
- package/dist/cli/commands/orchestrate.js.map +1 -0
- package/dist/cli/commands/patterns.d.ts +3 -0
- package/dist/cli/commands/patterns.d.ts.map +1 -0
- package/dist/cli/commands/patterns.js +25 -0
- package/dist/cli/commands/patterns.js.map +1 -0
- package/dist/cli/commands/plan.d.ts +3 -0
- package/dist/cli/commands/plan.d.ts.map +1 -0
- package/dist/cli/commands/plan.js +77 -0
- package/dist/cli/commands/plan.js.map +1 -0
- package/dist/cli/commands/plugin.d.ts +3 -0
- package/dist/cli/commands/plugin.d.ts.map +1 -0
- package/dist/cli/commands/plugin.js +124 -0
- package/dist/cli/commands/plugin.js.map +1 -0
- package/dist/cli/commands/resume.d.ts +3 -0
- package/dist/cli/commands/resume.d.ts.map +1 -0
- package/dist/cli/commands/resume.js +55 -0
- package/dist/cli/commands/resume.js.map +1 -0
- package/dist/cli/commands/run.d.ts +3 -0
- package/dist/cli/commands/run.d.ts.map +1 -0
- package/dist/cli/commands/run.js +78 -0
- package/dist/cli/commands/run.js.map +1 -0
- package/dist/cli/commands/share.d.ts +3 -0
- package/dist/cli/commands/share.d.ts.map +1 -0
- package/dist/cli/commands/share.js +34 -0
- package/dist/cli/commands/share.js.map +1 -0
- package/dist/cli/commands/status.d.ts +3 -0
- package/dist/cli/commands/status.d.ts.map +1 -0
- package/dist/cli/commands/status.js +148 -0
- package/dist/cli/commands/status.js.map +1 -0
- package/dist/cli/commands/template.d.ts +3 -0
- package/dist/cli/commands/template.d.ts.map +1 -0
- package/dist/cli/commands/template.js +213 -0
- package/dist/cli/commands/template.js.map +1 -0
- package/dist/cli/commands/vault.d.ts +3 -0
- package/dist/cli/commands/vault.d.ts.map +1 -0
- package/dist/cli/commands/vault.js +402 -0
- package/dist/cli/commands/vault.js.map +1 -0
- package/dist/cli/commands/verify.d.ts +3 -0
- package/dist/cli/commands/verify.d.ts.map +1 -0
- package/dist/cli/commands/verify.js +38 -0
- package/dist/cli/commands/verify.js.map +1 -0
- package/dist/cli/commands/version.d.ts +3 -0
- package/dist/cli/commands/version.d.ts.map +1 -0
- package/dist/cli/commands/version.js +19 -0
- package/dist/cli/commands/version.js.map +1 -0
- package/dist/cli/commands/watch.d.ts +3 -0
- package/dist/cli/commands/watch.d.ts.map +1 -0
- package/dist/cli/commands/watch.js +179 -0
- package/dist/cli/commands/watch.js.map +1 -0
- package/dist/cli/index.d.ts +3 -0
- package/dist/cli/index.d.ts.map +1 -0
- package/dist/cli/index.js +118 -0
- package/dist/cli/index.js.map +1 -0
- package/dist/core/checkpoint.d.ts +35 -0
- package/dist/core/checkpoint.d.ts.map +1 -0
- package/dist/core/checkpoint.js +80 -0
- package/dist/core/checkpoint.js.map +1 -0
- package/dist/core/event-bus.d.ts +41 -0
- package/dist/core/event-bus.d.ts.map +1 -0
- package/dist/core/event-bus.js +115 -0
- package/dist/core/event-bus.js.map +1 -0
- package/dist/core/lifecycle.d.ts +30 -0
- package/dist/core/lifecycle.d.ts.map +1 -0
- package/dist/core/lifecycle.js +72 -0
- package/dist/core/lifecycle.js.map +1 -0
- package/dist/core/patterns.d.ts +43 -0
- package/dist/core/patterns.d.ts.map +1 -0
- package/dist/core/patterns.js +372 -0
- package/dist/core/patterns.js.map +1 -0
- package/dist/core/permissions.d.ts +40 -0
- package/dist/core/permissions.d.ts.map +1 -0
- package/dist/core/permissions.js +113 -0
- package/dist/core/permissions.js.map +1 -0
- package/dist/core/registry.d.ts +80 -0
- package/dist/core/registry.d.ts.map +1 -0
- package/dist/core/registry.js +308 -0
- package/dist/core/registry.js.map +1 -0
- package/dist/core/snapshots.d.ts +20 -0
- package/dist/core/snapshots.d.ts.map +1 -0
- package/dist/core/snapshots.js +73 -0
- package/dist/core/snapshots.js.map +1 -0
- package/dist/core/types.d.ts +168 -0
- package/dist/core/types.d.ts.map +1 -0
- package/dist/core/types.js +33 -0
- package/dist/core/types.js.map +1 -0
- package/dist/hooks/cli.d.ts +11 -0
- package/dist/hooks/cli.d.ts.map +1 -0
- package/dist/hooks/cli.js +32 -0
- package/dist/hooks/cli.js.map +1 -0
- package/dist/hooks/index.d.ts +23 -0
- package/dist/hooks/index.d.ts.map +1 -0
- package/dist/hooks/index.js +58 -0
- package/dist/hooks/index.js.map +1 -0
- package/dist/index.d.ts +82 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +49 -0
- package/dist/index.js.map +1 -0
- package/dist/memory/index.d.ts +105 -0
- package/dist/memory/index.d.ts.map +1 -0
- package/dist/memory/index.js +298 -0
- package/dist/memory/index.js.map +1 -0
- package/dist/memory/schema.d.ts +6 -0
- package/dist/memory/schema.d.ts.map +1 -0
- package/dist/memory/schema.js +71 -0
- package/dist/memory/schema.js.map +1 -0
- package/dist/plugin/index.d.ts +6 -0
- package/dist/plugin/index.d.ts.map +1 -0
- package/dist/plugin/index.js +182 -0
- package/dist/plugin/index.js.map +1 -0
- package/dist/runtime/acp.d.ts +41 -0
- package/dist/runtime/acp.d.ts.map +1 -0
- package/dist/runtime/acp.js +137 -0
- package/dist/runtime/acp.js.map +1 -0
- package/dist/runtime/adaptive.d.ts +34 -0
- package/dist/runtime/adaptive.d.ts.map +1 -0
- package/dist/runtime/adaptive.js +229 -0
- package/dist/runtime/adaptive.js.map +1 -0
- package/dist/runtime/autonomy.d.ts +21 -0
- package/dist/runtime/autonomy.d.ts.map +1 -0
- package/dist/runtime/autonomy.js +74 -0
- package/dist/runtime/autonomy.js.map +1 -0
- package/dist/runtime/backends/claude.d.ts +9 -0
- package/dist/runtime/backends/claude.d.ts.map +1 -0
- package/dist/runtime/backends/claude.js +134 -0
- package/dist/runtime/backends/claude.js.map +1 -0
- package/dist/runtime/backends/codex.d.ts +9 -0
- package/dist/runtime/backends/codex.d.ts.map +1 -0
- package/dist/runtime/backends/codex.js +132 -0
- package/dist/runtime/backends/codex.js.map +1 -0
- package/dist/runtime/backends/gemini.d.ts +9 -0
- package/dist/runtime/backends/gemini.d.ts.map +1 -0
- package/dist/runtime/backends/gemini.js +103 -0
- package/dist/runtime/backends/gemini.js.map +1 -0
- package/dist/runtime/backends/index.d.ts +17 -0
- package/dist/runtime/backends/index.d.ts.map +1 -0
- package/dist/runtime/backends/index.js +39 -0
- package/dist/runtime/backends/index.js.map +1 -0
- package/dist/runtime/backends/mock.d.ts +21 -0
- package/dist/runtime/backends/mock.d.ts.map +1 -0
- package/dist/runtime/backends/mock.js +46 -0
- package/dist/runtime/backends/mock.js.map +1 -0
- package/dist/runtime/backends/types.d.ts +34 -0
- package/dist/runtime/backends/types.d.ts.map +1 -0
- package/dist/runtime/backends/types.js +2 -0
- package/dist/runtime/backends/types.js.map +1 -0
- package/dist/runtime/backends/vercel-ai.d.ts +14 -0
- package/dist/runtime/backends/vercel-ai.d.ts.map +1 -0
- package/dist/runtime/backends/vercel-ai.js +137 -0
- package/dist/runtime/backends/vercel-ai.js.map +1 -0
- package/dist/runtime/cache-optimizer.d.ts +37 -0
- package/dist/runtime/cache-optimizer.d.ts.map +1 -0
- package/dist/runtime/cache-optimizer.js +54 -0
- package/dist/runtime/cache-optimizer.js.map +1 -0
- package/dist/runtime/cascade.d.ts +26 -0
- package/dist/runtime/cascade.d.ts.map +1 -0
- package/dist/runtime/cascade.js +54 -0
- package/dist/runtime/cascade.js.map +1 -0
- package/dist/runtime/chunker.d.ts +36 -0
- package/dist/runtime/chunker.d.ts.map +1 -0
- package/dist/runtime/chunker.js +210 -0
- package/dist/runtime/chunker.js.map +1 -0
- package/dist/runtime/compaction.d.ts +22 -0
- package/dist/runtime/compaction.d.ts.map +1 -0
- package/dist/runtime/compaction.js +36 -0
- package/dist/runtime/compaction.js.map +1 -0
- package/dist/runtime/compounder.d.ts +66 -0
- package/dist/runtime/compounder.d.ts.map +1 -0
- package/dist/runtime/compounder.js +276 -0
- package/dist/runtime/compounder.js.map +1 -0
- package/dist/runtime/cost-model.d.ts +24 -0
- package/dist/runtime/cost-model.d.ts.map +1 -0
- package/dist/runtime/cost-model.js +120 -0
- package/dist/runtime/cost-model.js.map +1 -0
- package/dist/runtime/distiller.d.ts +21 -0
- package/dist/runtime/distiller.d.ts.map +1 -0
- package/dist/runtime/distiller.js +70 -0
- package/dist/runtime/distiller.js.map +1 -0
- package/dist/runtime/engine.d.ts +123 -0
- package/dist/runtime/engine.d.ts.map +1 -0
- package/dist/runtime/engine.js +969 -0
- package/dist/runtime/engine.js.map +1 -0
- package/dist/runtime/executor.d.ts +71 -0
- package/dist/runtime/executor.d.ts.map +1 -0
- package/dist/runtime/executor.js +283 -0
- package/dist/runtime/executor.js.map +1 -0
- package/dist/runtime/heuristics.d.ts +33 -0
- package/dist/runtime/heuristics.d.ts.map +1 -0
- package/dist/runtime/heuristics.js +188 -0
- package/dist/runtime/heuristics.js.map +1 -0
- package/dist/runtime/living-spec.d.ts +34 -0
- package/dist/runtime/living-spec.d.ts.map +1 -0
- package/dist/runtime/living-spec.js +91 -0
- package/dist/runtime/living-spec.js.map +1 -0
- package/dist/runtime/lsp.d.ts +50 -0
- package/dist/runtime/lsp.d.ts.map +1 -0
- package/dist/runtime/lsp.js +110 -0
- package/dist/runtime/lsp.js.map +1 -0
- package/dist/runtime/mcp.d.ts +27 -0
- package/dist/runtime/mcp.d.ts.map +1 -0
- package/dist/runtime/mcp.js +154 -0
- package/dist/runtime/mcp.js.map +1 -0
- package/dist/runtime/model-router.d.ts +22 -0
- package/dist/runtime/model-router.d.ts.map +1 -0
- package/dist/runtime/model-router.js +94 -0
- package/dist/runtime/model-router.js.map +1 -0
- package/dist/runtime/panes.d.ts +76 -0
- package/dist/runtime/panes.d.ts.map +1 -0
- package/dist/runtime/panes.js +279 -0
- package/dist/runtime/panes.js.map +1 -0
- package/dist/runtime/plan-search.d.ts +41 -0
- package/dist/runtime/plan-search.d.ts.map +1 -0
- package/dist/runtime/plan-search.js +140 -0
- package/dist/runtime/plan-search.js.map +1 -0
- package/dist/runtime/plugins.d.ts +59 -0
- package/dist/runtime/plugins.d.ts.map +1 -0
- package/dist/runtime/plugins.js +121 -0
- package/dist/runtime/plugins.js.map +1 -0
- package/dist/runtime/reflexion.d.ts +22 -0
- package/dist/runtime/reflexion.d.ts.map +1 -0
- package/dist/runtime/reflexion.js +85 -0
- package/dist/runtime/reflexion.js.map +1 -0
- package/dist/runtime/review-schema.d.ts +75 -0
- package/dist/runtime/review-schema.d.ts.map +1 -0
- package/dist/runtime/review-schema.js +223 -0
- package/dist/runtime/review-schema.js.map +1 -0
- package/dist/runtime/rewriter.d.ts +8 -0
- package/dist/runtime/rewriter.d.ts.map +1 -0
- package/dist/runtime/rewriter.js +81 -0
- package/dist/runtime/rewriter.js.map +1 -0
- package/dist/runtime/sharing.d.ts +15 -0
- package/dist/runtime/sharing.d.ts.map +1 -0
- package/dist/runtime/sharing.js +48 -0
- package/dist/runtime/sharing.js.map +1 -0
- package/dist/runtime/stats.d.ts +53 -0
- package/dist/runtime/stats.d.ts.map +1 -0
- package/dist/runtime/stats.js +160 -0
- package/dist/runtime/stats.js.map +1 -0
- package/dist/runtime/templates.d.ts +77 -0
- package/dist/runtime/templates.d.ts.map +1 -0
- package/dist/runtime/templates.js +221 -0
- package/dist/runtime/templates.js.map +1 -0
- package/dist/runtime/traces.d.ts +60 -0
- package/dist/runtime/traces.d.ts.map +1 -0
- package/dist/runtime/traces.js +166 -0
- package/dist/runtime/traces.js.map +1 -0
- package/dist/runtime/verifier.d.ts +54 -0
- package/dist/runtime/verifier.d.ts.map +1 -0
- package/dist/runtime/verifier.js +172 -0
- package/dist/runtime/verifier.js.map +1 -0
- package/dist/runtime/worktree.d.ts +24 -0
- package/dist/runtime/worktree.d.ts.map +1 -0
- package/dist/runtime/worktree.js +82 -0
- package/dist/runtime/worktree.js.map +1 -0
- package/dist/tui/dashboard.d.ts +65 -0
- package/dist/tui/dashboard.d.ts.map +1 -0
- package/dist/tui/dashboard.js +496 -0
- package/dist/tui/dashboard.js.map +1 -0
- package/dist/tui/progress.d.ts +32 -0
- package/dist/tui/progress.d.ts.map +1 -0
- package/dist/tui/progress.js +257 -0
- package/dist/tui/progress.js.map +1 -0
- package/dist/tui/renderer.d.ts +72 -0
- package/dist/tui/renderer.d.ts.map +1 -0
- package/dist/tui/renderer.js +205 -0
- package/dist/tui/renderer.js.map +1 -0
- package/dist/utils/compact-format.d.ts +35 -0
- package/dist/utils/compact-format.d.ts.map +1 -0
- package/dist/utils/compact-format.js +106 -0
- package/dist/utils/compact-format.js.map +1 -0
- package/dist/utils/config.d.ts +73 -0
- package/dist/utils/config.d.ts.map +1 -0
- package/dist/utils/config.js +70 -0
- package/dist/utils/config.js.map +1 -0
- package/dist/utils/env.d.ts +6 -0
- package/dist/utils/env.d.ts.map +1 -0
- package/dist/utils/env.js +28 -0
- package/dist/utils/env.js.map +1 -0
- package/dist/utils/errors.d.ts +14 -0
- package/dist/utils/errors.d.ts.map +1 -0
- package/dist/utils/errors.js +120 -0
- package/dist/utils/errors.js.map +1 -0
- package/dist/utils/logger.d.ts +14 -0
- package/dist/utils/logger.d.ts.map +1 -0
- package/dist/utils/logger.js +56 -0
- package/dist/utils/logger.js.map +1 -0
- package/dist/utils/output.d.ts +10 -0
- package/dist/utils/output.d.ts.map +1 -0
- package/dist/utils/output.js +26 -0
- package/dist/utils/output.js.map +1 -0
- package/dist/utils/paths.d.ts +7 -0
- package/dist/utils/paths.d.ts.map +1 -0
- package/dist/utils/paths.js +16 -0
- package/dist/utils/paths.js.map +1 -0
- package/dist/utils/project-config.d.ts +18 -0
- package/dist/utils/project-config.d.ts.map +1 -0
- package/dist/utils/project-config.js +46 -0
- package/dist/utils/project-config.js.map +1 -0
- package/dist/utils/redact.d.ts +5 -0
- package/dist/utils/redact.d.ts.map +1 -0
- package/dist/utils/redact.js +25 -0
- package/dist/utils/redact.js.map +1 -0
- package/dist/utils/schemas.d.ts +109 -0
- package/dist/utils/schemas.d.ts.map +1 -0
- package/dist/utils/schemas.js +63 -0
- package/dist/utils/schemas.js.map +1 -0
- package/dist/utils/terminal.d.ts +33 -0
- package/dist/utils/terminal.d.ts.map +1 -0
- package/dist/utils/terminal.js +82 -0
- package/dist/utils/terminal.js.map +1 -0
- package/dist/utils/tokens.d.ts +9 -0
- package/dist/utils/tokens.d.ts.map +1 -0
- package/dist/utils/tokens.js +11 -0
- package/dist/utils/tokens.js.map +1 -0
- package/package.json +71 -0
- package/skills/design-system/SKILL.md +195 -0
- package/skills/orchestration-patterns/SKILL.md +81 -0
- package/skills/orchestration-patterns/examples/example-workflows.md +290 -0
- package/skills/orchestration-patterns/references/adversarial.md +51 -0
- package/skills/orchestration-patterns/references/batch.md +63 -0
- package/skills/orchestration-patterns/references/chaos.md +43 -0
- package/skills/orchestration-patterns/references/competitive.md +84 -0
- package/skills/orchestration-patterns/references/debate.md +44 -0
- package/skills/orchestration-patterns/references/emergence.md +50 -0
- package/skills/orchestration-patterns/references/fan-out-fan-in.md +74 -0
- package/skills/orchestration-patterns/references/iterative.md +99 -0
- package/skills/orchestration-patterns/references/pipeline.md +72 -0
- package/skills/swarm-output-style/SKILL.md +85 -0
- package/templates/add-endpoint.yml +44 -0
- package/templates/add-feature.yml +30 -0
- package/templates/agent-template.md +73 -0
- package/templates/bug-fix.yml +31 -0
- package/templates/explore.yml +21 -0
- package/templates/fix-pr.yml +30 -0
- package/templates/migration.yml +36 -0
- package/templates/refactor.yml +35 -0
- package/templates/security-audit.yml +27 -0
- package/templates/workflow-template.md +63 -0
|
@@ -0,0 +1,123 @@
|
|
|
1
|
+
---
|
|
2
|
+
description: "Implement then review code in a parallel review cycle"
|
|
3
|
+
argument-hint: "<implementation task>"
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
You are running an implement-then-review cycle with parallel reviewers for quality assurance.
|
|
7
|
+
|
|
8
|
+
## Task
|
|
9
|
+
$ARGUMENTS
|
|
10
|
+
|
|
11
|
+
## Workflow
|
|
12
|
+
|
|
13
|
+
### Setup: Create Team
|
|
14
|
+
1. Create a team with `TeamCreate` (name: `review-cycle-<timestamp>`, e.g., `review-cycle-1234`)
|
|
15
|
+
2. Create tasks with `TaskCreate` for each work unit identified in the plan
|
|
16
|
+
|
|
17
|
+
### Phase 1: Research (parallel)
|
|
18
|
+
Spawn 2-3 researcher teammates (sonnet) simultaneously, each with `team_name`, `name` (e.g., `researcher-arch`, `researcher-tests`, `researcher-deps`), and `run_in_background: true`:
|
|
19
|
+
- One for architecture and patterns
|
|
20
|
+
- One for related tests and test patterns
|
|
21
|
+
- One for dependencies and integration points
|
|
22
|
+
|
|
23
|
+
As each teammate completes, send it a `shutdown_request` via `SendMessage` to close its split pane.
|
|
24
|
+
|
|
25
|
+
Present the research findings and implementation plan to the user. Proceed after approval.
|
|
26
|
+
|
|
27
|
+
### Phase 2: Implement (sequential)
|
|
28
|
+
Based on research findings, spawn an implementer teammate (opus) with `team_name`, `name` (e.g., `implementer`), and `run_in_background: true`.
|
|
29
|
+
Include all research findings as context.
|
|
30
|
+
|
|
31
|
+
As the teammate completes, send it a `shutdown_request` via `SendMessage` to close its split pane.
|
|
32
|
+
|
|
33
|
+
### Phase 2b: Devil's Advocate (sequential)
|
|
34
|
+
|
|
35
|
+
After implementation, spawn a devils-advocate teammate (opus) with `team_name`, `name` (e.g., `devils-advocate`), and `run_in_background: true`.
|
|
36
|
+
|
|
37
|
+
Provide it with:
|
|
38
|
+
- All files changed in Phase 2
|
|
39
|
+
- The original task description
|
|
40
|
+
- Research findings from Phase 1
|
|
41
|
+
|
|
42
|
+
As the teammate completes, send it a `shutdown_request` via `SendMessage` to close its split pane.
|
|
43
|
+
|
|
44
|
+
If the devil's advocate found **Critical** challenges:
|
|
45
|
+
1. Spawn a new implementer teammate (opus, name: `implementer-hardened`) with `team_name` and `run_in_background: true`
|
|
46
|
+
2. Include the devil's advocate's Critical challenges as requirements to address
|
|
47
|
+
3. The implementer must address ALL Critical challenges before proceeding
|
|
48
|
+
4. As the teammate completes, send `shutdown_request`
|
|
49
|
+
|
|
50
|
+
If only Important challenges or Questions were raised, include them as context for the reviewers in Phase 3-4.
|
|
51
|
+
|
|
52
|
+
### Phase 3-4: Review-Fix Loop (max 3 iterations)
|
|
53
|
+
|
|
54
|
+
For each iteration (1 to 3):
|
|
55
|
+
|
|
56
|
+
#### Review (parallel)
|
|
57
|
+
Spawn 3 reviewer teammates simultaneously, each with `team_name`, `name` (e.g., `reviewer-correctness`, `reviewer-security`, `reviewer-convention`), and `run_in_background: true`, each with a different focus:
|
|
58
|
+
1. **Correctness reviewer** (opus) — Logic errors, edge cases, error handling, race conditions
|
|
59
|
+
2. **Security reviewer** (opus) — Injection, auth bypass, data exposure, OWASP top 10
|
|
60
|
+
3. **Convention reviewer** (sonnet) — Project patterns, naming, structure, CLAUDE.md compliance
|
|
61
|
+
|
|
62
|
+
As each reviewer teammate completes, send it a `shutdown_request` via `SendMessage` to close its split pane.
|
|
63
|
+
|
|
64
|
+
#### Gate Check
|
|
65
|
+
Parse review results:
|
|
66
|
+
- **PASS**: 0 Critical AND 0 Important findings → break loop, proceed to report
|
|
67
|
+
- **FAIL**: Any Critical or Important finding → continue to Fix
|
|
68
|
+
- **MAX ITERATIONS**: If iteration == 3 and still failing → report remaining issues to user
|
|
69
|
+
|
|
70
|
+
#### Fix (sequential)
|
|
71
|
+
If gate check failed:
|
|
72
|
+
1. Aggregate all Critical + Important findings from all reviewers
|
|
73
|
+
2. Present findings to user
|
|
74
|
+
|
|
75
|
+
#### Reflexion (REQUIRED)
|
|
76
|
+
The fixer's dispatch prompt MUST begin with this block — do not skip it:
|
|
77
|
+
|
|
78
|
+
"## Previous Attempt Analysis
|
|
79
|
+
The previous implementation failed review because:
|
|
80
|
+
- [list each Critical/Important finding from reviewers]
|
|
81
|
+
|
|
82
|
+
My approach to fix these issues:
|
|
83
|
+
- [specific plan for each finding]
|
|
84
|
+
|
|
85
|
+
I will avoid repeating:
|
|
86
|
+
- [patterns from prior iterations that didn't work]"
|
|
87
|
+
|
|
88
|
+
This block must be constructed from the actual reviewer findings and included verbatim at the start of the fixer's prompt. Without it, the fixer may repeat the same mistakes.
|
|
89
|
+
|
|
90
|
+
3. Spawn an implementer teammate (opus) with `team_name`, `name` (e.g., `fixer-iter-N`), and `run_in_background: true` to fix Critical and Important issues only
|
|
91
|
+
4. Do NOT fix Suggestions — they never trigger another iteration
|
|
92
|
+
|
|
93
|
+
As the fixer teammate completes, send it a `shutdown_request` via `SendMessage` to close its split pane.
|
|
94
|
+
|
|
95
|
+
### Phase 5: Report
|
|
96
|
+
```markdown
|
|
97
|
+
## Implementation Summary
|
|
98
|
+
[What was built/changed]
|
|
99
|
+
|
|
100
|
+
## Quality Gate: [PASS after N iterations | FAIL after 3 iterations]
|
|
101
|
+
|
|
102
|
+
### Per-Iteration Results
|
|
103
|
+
- **Iteration 1**: N critical, M important → [fixed / passed]
|
|
104
|
+
- **Iteration 2**: N critical, M important → [fixed / passed]
|
|
105
|
+
- **Iteration 3**: N critical, M important → [fixed / passed]
|
|
106
|
+
|
|
107
|
+
## Remaining Concerns
|
|
108
|
+
[Any Important/Suggestion findings from final iteration]
|
|
109
|
+
|
|
110
|
+
## Suggestions (non-blocking)
|
|
111
|
+
[Reviewer suggestions that did not trigger fixes]
|
|
112
|
+
```
|
|
113
|
+
|
|
114
|
+
### Cleanup
|
|
115
|
+
1. Send `shutdown_request` via `SendMessage` to any remaining active teammates
|
|
116
|
+
2. Call `TeamDelete` to clean up the team
|
|
117
|
+
|
|
118
|
+
## Rules
|
|
119
|
+
- All agents must be spawned as team members (TeamCreate → TaskCreate → Agent with team_name/name/run_in_background → SendMessage shutdown → TeamDelete)
|
|
120
|
+
- Only Critical and Important findings trigger a fix iteration — never Suggestions
|
|
121
|
+
- Maximum 3 review-fix iterations before escalating to user
|
|
122
|
+
- Present findings to user before each fix phase
|
|
123
|
+
- Each fix phase must only address findings from the current iteration's review
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
---
|
|
2
|
+
description: "Interactive setup wizard — configure which AI backend each agent uses"
|
|
3
|
+
argument-hint: ""
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
Run the Swarm Engine setup wizard to configure backends and models for your agents.
|
|
7
|
+
|
|
8
|
+
## How to Execute
|
|
9
|
+
|
|
10
|
+
Run this command in the terminal:
|
|
11
|
+
|
|
12
|
+
```bash
|
|
13
|
+
swarm setup
|
|
14
|
+
```
|
|
15
|
+
|
|
16
|
+
This walks you through 3 steps:
|
|
17
|
+
|
|
18
|
+
1. **Default Backend** — Choose Claude, Codex, or Gemini as the default
|
|
19
|
+
2. **Per-Agent Customization** — Same for all, or customize by role group (research, implementation, review)
|
|
20
|
+
3. **Model Preferences** — Keep defaults or adjust (opus/sonnet/haiku)
|
|
21
|
+
|
|
22
|
+
The wizard updates your agent `.md` files automatically. No manual editing needed.
|
|
23
|
+
|
|
24
|
+
## If `swarm` is not on PATH
|
|
25
|
+
|
|
26
|
+
```bash
|
|
27
|
+
cd ~/dev/swarm-engine && npx tsx src/cli/index.ts configure
|
|
28
|
+
```
|
|
@@ -0,0 +1,126 @@
|
|
|
1
|
+
---
|
|
2
|
+
description: "Swarm Engine — orchestrate multi-agent development with composable patterns"
|
|
3
|
+
argument-hint: "<task description> | setup | status | backends"
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
You are the Swarm Engine — a multi-agent orchestration system.
|
|
7
|
+
|
|
8
|
+
If the user says "setup", run: `swarm setup` in the terminal to launch the interactive configuration wizard.
|
|
9
|
+
If the user says "status", run: `swarm status` to show registered agents and backends.
|
|
10
|
+
If the user says "backends", run: `swarm backends` to show available execution backends.
|
|
11
|
+
|
|
12
|
+
Otherwise, orchestrate the task using formal patterns.
|
|
13
|
+
|
|
14
|
+
## Task
|
|
15
|
+
$ARGUMENTS
|
|
16
|
+
|
|
17
|
+
## Workflow
|
|
18
|
+
|
|
19
|
+
### Setup: Analyze and Select Pattern
|
|
20
|
+
|
|
21
|
+
1. **Check memory** for relevant context:
|
|
22
|
+
```bash
|
|
23
|
+
cd ~/dev/swarm-engine && npx tsx src/cli/index.ts memory search "<relevant keywords>"
|
|
24
|
+
```
|
|
25
|
+
|
|
26
|
+
2. **Assess the task** and select the best pattern:
|
|
27
|
+
|
|
28
|
+
| Task Type | Pattern | Why |
|
|
29
|
+
|-----------|---------|-----|
|
|
30
|
+
| General feature | `hybrid` | Research → Implement → Review (default) |
|
|
31
|
+
| Understanding code | `research` | Fan-out parallel exploration |
|
|
32
|
+
| Quality-critical code | `review-cycle` | Iterative review-fix loop |
|
|
33
|
+
| New feature with tests | `tdd` | Test-first guarantees coverage |
|
|
34
|
+
| Uncertain approach | `spike` | Two approaches compete, reviewer picks |
|
|
35
|
+
| Security-sensitive code | `red-team` | Build → Break → Harden |
|
|
36
|
+
| Complex/novel problem | `discover` | Hypothesize → Test → Implement winner |
|
|
37
|
+
|
|
38
|
+
If a dedicated command exists for the chosen pattern (e.g., `/review-cycle`, `/tdd`, `/spike`, `/red-team`, `/discover`, `/research`), **delegate to that command instead** of continuing here. Only continue with this command for `hybrid` or custom multi-phase orchestrations.
|
|
39
|
+
|
|
40
|
+
3. **Create team**: `TeamCreate` (name: `orchestrate-<timestamp>`)
|
|
41
|
+
4. **Create tasks**: `TaskCreate` for each planned phase
|
|
42
|
+
|
|
43
|
+
### Phase 1: Research (parallel)
|
|
44
|
+
|
|
45
|
+
Spawn 2-3 researcher teammates (sonnet) simultaneously, each with `team_name`, `name`, and `run_in_background: true`:
|
|
46
|
+
- **researcher-code** — Explore the relevant codebase: architecture, entry points, existing patterns
|
|
47
|
+
- **researcher-context** — Check memory and vault for past decisions, conventions, gotchas:
|
|
48
|
+
```bash
|
|
49
|
+
~/.claude/scripts/swarm-vault.sh repo "<repo-name>" conventions
|
|
50
|
+
~/.claude/scripts/swarm-vault.sh repo "<repo-name>" gotchas
|
|
51
|
+
```
|
|
52
|
+
- **researcher-deps** (optional) — Map dependencies, integration points, downstream consumers
|
|
53
|
+
|
|
54
|
+
As each teammate completes, send it a `shutdown_request` via `SendMessage` to close its split pane.
|
|
55
|
+
|
|
56
|
+
Present the research findings and proposed implementation plan to the user. Proceed after approval.
|
|
57
|
+
|
|
58
|
+
### Phase 2: Implement (parallel if independent, sequential if dependent)
|
|
59
|
+
|
|
60
|
+
Based on research findings, spawn implementer teammates (opus) with `team_name`, `name`, and `run_in_background: true`.
|
|
61
|
+
|
|
62
|
+
For each implementer, include:
|
|
63
|
+
- All relevant research findings as context
|
|
64
|
+
- Specific file assignments (no two implementers touch the same files)
|
|
65
|
+
- Reference patterns from the codebase
|
|
66
|
+
|
|
67
|
+
As each teammate completes, send it a `shutdown_request` via `SendMessage` to close its split pane.
|
|
68
|
+
|
|
69
|
+
### Phase 3: Review (parallel)
|
|
70
|
+
|
|
71
|
+
Spawn 2-3 reviewer teammates simultaneously, each with `team_name`, `name`, and `run_in_background: true`:
|
|
72
|
+
1. **reviewer-correctness** (opus) — Logic errors, edge cases, error handling, race conditions
|
|
73
|
+
2. **reviewer-security** (opus) — Injection, auth bypass, data exposure, OWASP top 10
|
|
74
|
+
3. **reviewer-convention** (sonnet) — Project patterns, naming, structure compliance
|
|
75
|
+
|
|
76
|
+
As each reviewer completes, send it a `shutdown_request` via `SendMessage` to close its split pane.
|
|
77
|
+
|
|
78
|
+
#### Gate Check
|
|
79
|
+
- **0 Critical AND 0 Important findings** → proceed to report
|
|
80
|
+
- **Any Critical or Important finding** → spawn a fixer implementer (opus) to address them, then re-review (max 2 fix iterations)
|
|
81
|
+
|
|
82
|
+
### Phase 4: Record Outcomes
|
|
83
|
+
|
|
84
|
+
Store results in engine memory:
|
|
85
|
+
```bash
|
|
86
|
+
echo "<outcome summary>" | cd ~/dev/swarm-engine && npx tsx src/cli/index.ts memory store outcome "<title>" --repo "<repo>"
|
|
87
|
+
```
|
|
88
|
+
|
|
89
|
+
### Phase 5: Report
|
|
90
|
+
|
|
91
|
+
```markdown
|
|
92
|
+
## Orchestration Summary
|
|
93
|
+
- **Pattern**: [hybrid / custom]
|
|
94
|
+
- **Phases completed**: N of N
|
|
95
|
+
|
|
96
|
+
## Changes Made
|
|
97
|
+
[List of files changed with brief descriptions]
|
|
98
|
+
|
|
99
|
+
## Research Findings
|
|
100
|
+
[Key insights that informed the implementation]
|
|
101
|
+
|
|
102
|
+
## Review Results
|
|
103
|
+
- **Gate**: PASS / FAIL after N iterations
|
|
104
|
+
- **Critical findings**: N (all resolved)
|
|
105
|
+
- **Important findings**: N (resolved / remaining)
|
|
106
|
+
|
|
107
|
+
## Suggestions (non-blocking)
|
|
108
|
+
[Reviewer suggestions not addressed]
|
|
109
|
+
|
|
110
|
+
## Knowledge Stored
|
|
111
|
+
[What was saved to memory/vault for future use]
|
|
112
|
+
```
|
|
113
|
+
|
|
114
|
+
### Cleanup
|
|
115
|
+
1. Send `shutdown_request` via `SendMessage` to any remaining active teammates
|
|
116
|
+
2. Call `TeamDelete` to clean up the team
|
|
117
|
+
|
|
118
|
+
## Rules
|
|
119
|
+
- All agents must be spawned as team members (TeamCreate → TaskCreate → Agent with team_name/name/run_in_background → SendMessage shutdown → TeamDelete)
|
|
120
|
+
- Present the plan before executing — wait for user approval
|
|
121
|
+
- If a dedicated command exists for the pattern, delegate to it
|
|
122
|
+
- Include full context in every agent dispatch (agents don't share memory within a session)
|
|
123
|
+
- Use the cheapest model that can handle each task (sonnet for research, opus for implementation/review)
|
|
124
|
+
- Check engine memory before starting for relevant context
|
|
125
|
+
- Record outcomes to engine memory after completion
|
|
126
|
+
- Maximum 2 fix iterations before escalating remaining issues to the user
|
package/commands/tdd.md
ADDED
|
@@ -0,0 +1,91 @@
|
|
|
1
|
+
---
|
|
2
|
+
description: "Test-driven development: write failing test, implement, verify green"
|
|
3
|
+
argument-hint: "<feature description>"
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
You are running a strict TDD cycle: Red → Green → Review.
|
|
7
|
+
|
|
8
|
+
## Task
|
|
9
|
+
$ARGUMENTS
|
|
10
|
+
|
|
11
|
+
## Workflow
|
|
12
|
+
|
|
13
|
+
### Setup: Create Team
|
|
14
|
+
1. Create a team with `TeamCreate` (name: `tdd-<timestamp>`, e.g., `tdd-1234`)
|
|
15
|
+
2. Create tasks with `TaskCreate` for each phase of the TDD cycle
|
|
16
|
+
|
|
17
|
+
### Phase 1: Research — parallel
|
|
18
|
+
Spawn 2 researcher teammates simultaneously, each with `team_name`, `name`, and `run_in_background: true`:
|
|
19
|
+
- **Researcher A** (`researcher-code`, sonnet): Existing code patterns, interfaces, and the module where the feature belongs
|
|
20
|
+
- **Researcher B** (`researcher-tests`, sonnet): Test patterns, fixtures, test infrastructure, and how similar features are tested
|
|
21
|
+
|
|
22
|
+
As each teammate completes, send it a `shutdown_request` via `SendMessage` to close its split pane.
|
|
23
|
+
|
|
24
|
+
### Phase 2: Write Failing Test — sequential (depends on Phase 1)
|
|
25
|
+
Spawn a tester teammate (opus) with `team_name`, `name` (e.g., `tester-red`), and `run_in_background: true`, with research context. The tester must:
|
|
26
|
+
1. Write test(s) that describe the desired behavior
|
|
27
|
+
2. Run the tests
|
|
28
|
+
3. Verify they **fail** (red phase)
|
|
29
|
+
|
|
30
|
+
If the tests pass, the feature already exists — report this and stop.
|
|
31
|
+
|
|
32
|
+
As the teammate completes, send it a `shutdown_request` via `SendMessage` to close its split pane.
|
|
33
|
+
|
|
34
|
+
Present the failing tests to the user. Proceed to implementation after approval.
|
|
35
|
+
|
|
36
|
+
### Phase 3: Implement — sequential (depends on Phase 2)
|
|
37
|
+
Spawn an implementer teammate (opus) with `team_name`, `name` (e.g., `implementer`), and `run_in_background: true`, with:
|
|
38
|
+
- The failing test(s) as the specification
|
|
39
|
+
- All research context from Phase 1
|
|
40
|
+
- Goal: make the tests pass with **minimal code** — no extras
|
|
41
|
+
|
|
42
|
+
As the teammate completes, send it a `shutdown_request` via `SendMessage` to close its split pane.
|
|
43
|
+
|
|
44
|
+
### Phase 4: Verify — sequential (depends on Phase 3)
|
|
45
|
+
Spawn a tester teammate (sonnet) with `team_name`, `name` (e.g., `tester-green`), and `run_in_background: true` to run the full test suite:
|
|
46
|
+
- All tests must pass (green phase)
|
|
47
|
+
- If **new** tests fail → send back to implementer with failure details
|
|
48
|
+
- If **unrelated** tests fail → report regression and stop
|
|
49
|
+
|
|
50
|
+
As the teammate completes, send it a `shutdown_request` via `SendMessage` to close its split pane.
|
|
51
|
+
|
|
52
|
+
### Phase 5: Review — parallel (depends on Phase 4)
|
|
53
|
+
Spawn 2 reviewer teammates simultaneously, each with `team_name`, `name`, and `run_in_background: true`, on the implementation (not the tests):
|
|
54
|
+
1. **Correctness reviewer** (`reviewer-correctness`, opus) — Logic, edge cases, error handling
|
|
55
|
+
2. **Convention reviewer** (`reviewer-convention`, sonnet) — Project patterns, naming, structure
|
|
56
|
+
|
|
57
|
+
As each reviewer teammate completes, send it a `shutdown_request` via `SendMessage` to close its split pane.
|
|
58
|
+
|
|
59
|
+
### Phase 6: Report
|
|
60
|
+
|
|
61
|
+
```
|
|
62
|
+
## TDD Report
|
|
63
|
+
|
|
64
|
+
### Feature
|
|
65
|
+
[What was built]
|
|
66
|
+
|
|
67
|
+
### Tests Written
|
|
68
|
+
- [test file:line — what each test covers]
|
|
69
|
+
|
|
70
|
+
### Implementation
|
|
71
|
+
- [file:line — what was added/changed]
|
|
72
|
+
|
|
73
|
+
### Review Findings
|
|
74
|
+
- Correctness: [PASS/FAIL — findings]
|
|
75
|
+
- Conventions: [PASS/FAIL — findings]
|
|
76
|
+
|
|
77
|
+
### Test Results
|
|
78
|
+
[Full suite pass/fail summary]
|
|
79
|
+
```
|
|
80
|
+
|
|
81
|
+
### Cleanup
|
|
82
|
+
1. Send `shutdown_request` via `SendMessage` to any remaining active teammates
|
|
83
|
+
2. Call `TeamDelete` to clean up the team
|
|
84
|
+
|
|
85
|
+
## Rules
|
|
86
|
+
- All agents must be spawned as team members (TeamCreate → TaskCreate → Agent with team_name/name/run_in_background → SendMessage shutdown → TeamDelete)
|
|
87
|
+
- The test is the spec — implement only what the test demands
|
|
88
|
+
- Never skip the red phase — tests MUST fail before implementation
|
|
89
|
+
- Implement minimally — no gold-plating, no anticipatory code
|
|
90
|
+
- If tests pass before implementation, the feature already exists — stop and report
|
|
91
|
+
- Use opus for writing tests and implementation, sonnet for verification and convention review
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"bin.d.ts","sourceRoot":"","sources":["../../src/cli/bin.ts"],"names":[],"mappings":";AACA,OAAO,YAAY,CAAC"}
|
package/dist/cli/bin.js
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"bin.js","sourceRoot":"","sources":["../../src/cli/bin.ts"],"names":[],"mappings":";AACA,OAAO,YAAY,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"acp.d.ts","sourceRoot":"","sources":["../../../src/cli/commands/acp.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAUpC,eAAO,MAAM,UAAU,SAoBnB,CAAC"}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { Command } from 'commander';
|
|
2
|
+
import chalk from 'chalk';
|
|
3
|
+
import { join } from 'path';
|
|
4
|
+
import { homedir } from 'os';
|
|
5
|
+
import { ACPServer } from '../../runtime/acp.js';
|
|
6
|
+
import { AgentRegistry } from '../../core/registry.js';
|
|
7
|
+
import { EventBus } from '../../core/event-bus.js';
|
|
8
|
+
import { Logger } from '../../utils/logger.js';
|
|
9
|
+
import { SwarmEngine } from '../../runtime/engine.js';
|
|
10
|
+
export const acpCommand = new Command('acp')
|
|
11
|
+
.description('Start ACP server (wired to orchestration engine)')
|
|
12
|
+
.option('-p, --port <port>', 'Port', '3100')
|
|
13
|
+
.option('-h, --host <host>', 'Host', '127.0.0.1')
|
|
14
|
+
.option('--no-engine', 'Start without orchestration engine')
|
|
15
|
+
.action(async (options) => {
|
|
16
|
+
const bus = new EventBus(), logger = new Logger('acp', 'info'), registry = new AgentRegistry(bus);
|
|
17
|
+
registry.loadDirectory(join(homedir(), 'dev', 'swarm-engine', 'agents'));
|
|
18
|
+
let engine;
|
|
19
|
+
if (options.engine) {
|
|
20
|
+
engine = new SwarmEngine({ registry, bus, logger, mock: false, nonInteractive: true });
|
|
21
|
+
}
|
|
22
|
+
const server = new ACPServer({ port: parseInt(options.port, 10), host: options.host, registry, bus, logger, engine });
|
|
23
|
+
await server.start();
|
|
24
|
+
console.log(chalk.green(`ACP server on http://${options.host}:${options.port}`));
|
|
25
|
+
console.log(` Engine: ${engine ? chalk.green('connected') : chalk.dim('disabled (--no-engine)')}`);
|
|
26
|
+
console.log(` GET /health | GET /agents | POST /sessions | POST /sessions/:id/messages`);
|
|
27
|
+
process.on('SIGINT', async () => { await server.stop(); process.exit(0); });
|
|
28
|
+
});
|
|
29
|
+
//# sourceMappingURL=acp.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"acp.js","sourceRoot":"","sources":["../../../src/cli/commands/acp.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,IAAI,EAAE,MAAM,MAAM,CAAC;AAC5B,OAAO,EAAE,OAAO,EAAE,MAAM,IAAI,CAAC;AAC7B,OAAO,EAAE,SAAS,EAAE,MAAM,sBAAsB,CAAC;AACjD,OAAO,EAAE,aAAa,EAAE,MAAM,wBAAwB,CAAC;AACvD,OAAO,EAAE,QAAQ,EAAE,MAAM,yBAAyB,CAAC;AACnD,OAAO,EAAE,MAAM,EAAE,MAAM,uBAAuB,CAAC;AAC/C,OAAO,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AAEtD,MAAM,CAAC,MAAM,UAAU,GAAG,IAAI,OAAO,CAAC,KAAK,CAAC;KACzC,WAAW,CAAC,kDAAkD,CAAC;KAC/D,MAAM,CAAC,mBAAmB,EAAE,MAAM,EAAE,MAAM,CAAC;KAC3C,MAAM,CAAC,mBAAmB,EAAE,MAAM,EAAE,WAAW,CAAC;KAChD,MAAM,CAAC,aAAa,EAAE,oCAAoC,CAAC;KAC3D,MAAM,CAAC,KAAK,EAAE,OAAwD,EAAE,EAAE;IACzE,MAAM,GAAG,GAAG,IAAI,QAAQ,EAAE,EAAE,MAAM,GAAG,IAAI,MAAM,CAAC,KAAK,EAAE,MAAM,CAAC,EAAE,QAAQ,GAAG,IAAI,aAAa,CAAC,GAAG,CAAC,CAAC;IAClG,QAAQ,CAAC,aAAa,CAAC,IAAI,CAAC,OAAO,EAAE,EAAE,KAAK,EAAE,cAAc,EAAE,QAAQ,CAAC,CAAC,CAAC;IAEzE,IAAI,MAA+B,CAAC;IACpC,IAAI,OAAO,CAAC,MAAM,EAAE,CAAC;QACnB,MAAM,GAAG,IAAI,WAAW,CAAC,EAAE,QAAQ,EAAE,GAAG,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,cAAc,EAAE,IAAI,EAAE,CAAC,CAAC;IACzF,CAAC;IAED,MAAM,MAAM,GAAG,IAAI,SAAS,CAAC,EAAE,IAAI,EAAE,QAAQ,CAAC,OAAO,CAAC,IAAI,EAAE,EAAE,CAAC,EAAE,IAAI,EAAE,OAAO,CAAC,IAAI,EAAE,QAAQ,EAAE,GAAG,EAAE,MAAM,EAAE,MAAM,EAAE,CAAC,CAAC;IACtH,MAAM,MAAM,CAAC,KAAK,EAAE,CAAC;IACrB,OAAO,CAAC,GAAG,CAAC,KAAK,CAAC,KAAK,CAAC,wBAAwB,OAAO,CAAC,IAAI,IAAI,OAAO,CAAC,IAAI,EAAE,CAAC,CAAC,CAAC;IACjF,OAAO,CAAC,GAAG,CAAC,aAAa,MAAM,CAAC,CAAC,CAAC,KAAK,CAAC,KAAK,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,GAAG,CAAC,wBAAwB,CAAC,EAAE,CAAC,CAAC;IACpG,OAAO,CAAC,GAAG,CAAC,4EAA4E,CAAC,CAAC;IAC1F,OAAO,CAAC,EAAE,CAAC,QAAQ,EAAE,KAAK,IAAI,EAAE,GAAG,MAAM,MAAM,CAAC,IAAI,EAAE,CAAC,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;AAC9E,CAAC,CAAC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"agents.d.ts","sourceRoot":"","sources":["../../../src/cli/commands/agents.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAOpC,eAAO,MAAM,aAAa,SACgB,CAAC"}
|