First public release of agent-sequencer — an MCP skill + server that lets a Python script drive an AI agent (Claude Code) through strictly-defined workflows and long-running tasks.
Workflow branching, aggregation, and termination logic stay in code (a Python generator), and per-step execution is delegated to the AI agent. Because the guardrails live in code instead of prompts, the system stays stable as conversation context degrades over long-running tasks.
Highlights
- Author your own sequencer program in Python. Each
yield Instruction(...)is one step that declares an instruction text plus a JSON Schema for the response. The AI agent executes the instruction with its own tools (Bash / Edit / Skill / ...) and returns the result as JSON. - MCP toolset for driving from Claude Code.
sequencer_list_programs,sequencer_start,sequencer_current,sequencer_next,sequencer_resume,sequencer_close,sequencer_list. - Deterministic replay. Every event is appended to a JSONL log; after a server restart, an interrupt, or a context compaction, an instance is fully recoverable by re-running the program from the start and re-injecting the recorded inputs.
- Schema-validated step responses with automatic retry on violation.
- Hot reload during development via
--watch(picks up changes toprograms/*.pywith a 2-second throttle). - Bundled programs:
hello— minimal sample / smoke test.review-rounds— three specialist agents (python-sensei / sequencer-sensei / prompt-sensei) review → fix → verify in parallel for up to N rounds. Usable as a self-review helper for your own sequencer programs and as a portable sample implementation.
- Distribution as a Claude Code plugin (git-based).
Installation
Install as a Claude Code plugin (recommended):
```text
/plugin marketplace add OPENSPHERE-Inc/agent-sequencer
/plugin install agent-sequencer@agent-sequencer
```
Or clone and run as a developer:
```bash
git clone https://github.com/OPENSPHERE-Inc/agent-sequencer.git
cd agent-sequencer
uv sync
uv run agent-sequencer --help
```
Prerequisites: uv and Python ≥ 3.11.
See README.md for details.
Limitations (v1)
ParallelInstructions(in-program fan-out declarations) is not yet implemented.- HTTP/SSE transport (sharing across multiple Claude Code sessions) is not yet implemented.
- Program sandboxing (stronger trust boundary) is not yet implemented.
- Execution of TypeScript / Lua programs is not yet implemented.
- PyPI publishing is not yet supported; only git-based distribution is available at this time.
License
MIT License © 2026 OPENSPHERE Inc.