SWARM-OpenClaw Bridge¶
Run SWARM as a production service with OpenClaw integration.
Overview¶
OpenClaw provides secure multi-agent orchestration. SWARM-OpenClaw enables:
- REST API for scenario execution
- Job queue for async simulation runs
- Skill integration for OpenClaw workflows
Installation¶
Quick Start¶
Start the Service¶
Run a Scenario¶
curl -X POST http://localhost:8000/runs \
-H "Content-Type: application/json" \
-d '{"scenario": "baseline", "seed": 42}'
Get Results¶
API Reference¶
POST /runs¶
Create a new simulation run.
Request:
Response:
GET /runs/{job_id}¶
Get run status.
Response:
GET /runs/{job_id}/metrics¶
Get run metrics.
Response:
OpenClaw Skill¶
Use SWARM from OpenClaw workflows:
from openclaw import Skill
swarm_skill = Skill("swarm")
# Run scenario
result = await swarm_skill.run_scenario(
scenario="baseline",
seed=42
)
# Get metrics
metrics = await swarm_skill.get_metrics(result.job_id)
Docker Deployment¶
FROM python:3.11-slim
RUN pip install swarm-openclaw
EXPOSE 8000
CMD ["swarm-service", "start", "--host", "0.0.0.0"]
Status¶
In Development - Service layer functional, OpenClaw skill in progress.