Bernstein 1.0 is up on PyPI today. It's an orchestrator for CLI coding agents - Claude Code, Codex, Gemini CLI, anything that talks over a terminal - with a plain-Python scheduler and a worktree per agent so they don't trample each other.
why
I started the project after a 47-hour weekend running twelve Claude Code sessions in parallel and watching them race for the same files. The full story is on my personal blog. The short version is that twelve agents with no coordination produce a merge horror show; twelve with worktrees and a scheduler produce a working codebase.
what's different
No LLM in the scheduling loop. The orchestrator is plain Python, the only model call decomposes the goal into tasks, the rest is a state machine. Predictable. Replayable from the audit log.
Eighteen adapters. Claude Code, Codex, Gemini CLI, OpenAI Agents SDK, Aider, Cursor, Amp, Kiro, Kilo, Qwen, Goose, and a few more. New adapters land in roughly 100 lines of Python. Agents are interchangeable workers, not pets.
Git worktree per agent. No conflicts during execution; the merge queue lands what passes the gates and rolls back what doesn't.
State in .sdd/ files. YAML and JSON, no database, no Redis. cat, grep, git all work on it.
Short-lived agents. Each one handles one to three tasks and exits. Fresh context, no token rot.
install
pip install bernstein
export ANTHROPIC_API_KEY=sk-...
bernstein run --goal "Add input validation to the user registration endpoint"For multi-stage projects there's a YAML plan format:
stages:
- name: validation
steps:
- goal: "Add Pydantic models for all API request bodies"
role: backend
- name: testing
depends_on: [validation]
steps:
- goal: "Write integration tests for all validation rules"
role: qabernstein run plans/api-hardening.yamlwhat's in 1.0
Tick-based orchestrator, task store with retry and a dead-letter queue, quality gates, cost tracking, HMAC-signed audit log, task server on :8052, a TUI. The full changelog has the rest. The getting started post walks the first run.
Cost-aware routing, cloud execution, MCP and A2A - all on the roadmap, all Apache 2.0, all in the open. Source: github.com/sipyourdrink-ltd/bernstein. The cost-aware routing post walks through the bandit that fell out of the routing roadmap; the v2.0 release closes the v1 -> v2 arc with the web GUI.