npm i -g codemachine
CodeMachine is an open-source tool that orchestrates AI coding agents into repeatable, long-running workflows. ⚡️
Every time you use an AI coding agent, you're running a workflow. Fix a bug? You ask questions, reproduce, analyze, plan, implement, test. Build a feature? You research, design, code, review.
The workflow lives in your head. You guide the agent through it, step by step, session by session. But every time you start, you rebuild it from scratch. You re-explain the process. You remember to ask the right questions. You manage when to clear context, when to push forward, when to loop back.
CodeMachine lets you capture that workflow and run it again.
CodeMachine is an orchestration layer that runs AI coding CLIs through structured workflows. You define the workflow once, and CodeMachine handles execution, context passing, and agent coordination.
It uses the headless scripting mode that AI coding engines provide for automation (Claude Code, Codex, Cursor, and others). It spawns engines via CLI, passes the right arguments and flags, and controls agents through its infrastructure.
Build workflows from fully interactive to fully autonomous - and anything in between. Learn about orchestration patterns →
CM introduces innovative agent communication styles that have never existed for coding agents before - enabling you to build any complex workflow you can imagine. Start with the Ali Workflow Builder default workflow to create your first workflow interactively.
- Build Once, Run Forever: Define complex workflows once and execute them reliably on every project - stop rebuilding the same patterns manually.
- Multi-Agent Orchestration: Assign different agents to different tasks, enable them to communicate with each other, and collaborate on complex decisions.
- Parallel Execution: Run multiple agents simultaneously on different parts of your workflow for faster results.
- Long-Running Workflows: Execute workflows for hours or days - CodeMachine handles persistence so you don't have to babysit.
- Context Engineering: Centralize prompts, manage dynamic context, and control what each agent sees at each step.
Ready to build your first workflow? Get started →
Developers are already building with CodeMachine - reducing time and effort on complex, repetitive workflows.
Want to see what they're creating? Join us.
