Bernstein
Multi-agent orchestration MCP server. Start parallel agent runs, manage task queues, track costs, and verify quality gates across 20+ CLI coding agents.
Orchestrate any AI coding agent. Any model. One command.
Documentation · Getting Started · Glossary · Limitations
Wall of fame
"lol, good luck, keep vibecoding shit that you have no idea about xD" — PeaceFirePL, Reddit
Bernstein takes a goal, breaks it into tasks, assigns them to AI coding agents running in parallel, verifies the output, and merges the results. You come back to working code, passing tests, and a clean git history.
No framework to learn. No vendor lock-in. Agents are interchangeable workers — swap any agent, any model, any provider. The orchestrator itself is deterministic Python code. Zero LLM tokens on scheduling.
pip install bernstein
bernstein -g "Add JWT auth with refresh tokens, tests, and API docs"
Also available via pipx, uv tool install, brew, dnf copr, and npx bernstein-orchestrator. See install options.
Supported agents
Bernstein auto-discovers installed CLI agents. Mix them in the same run — cheap local models for boilerplate, heavy cloud models for architecture.
| Agent | Models | Install |
|---|---|---|
| Claude Code | opus 4.6, sonnet 4.6, haiku 4.5 | npm install -g @anthropic-ai/claude-code |
| Codex CLI | gpt-5.4, gpt-5.4-mini | npm install -g @openai/codex |
| Gemini CLI | gemini-3.1-pro, gemini-3-flash | npm install -g @google/gemini-cli |
| Cursor | sonnet 4.6, opus 4.6, gpt-5.4 | Cursor app |
| Aider | Any OpenAI/Anthropic-compatible | pip install aider-chat |
| Ollama + Aider | Local models (offline) | brew install ollama |
| Cloudflare Agents | Workers AI models | bernstein cloud init |
| Codex on Cloudflare | gpt-5.4 via CF gateway | bernstein cloud init |
| Amp, Cody, Continue.dev, Goose, IaC (Terraform/Pulumi), Kilo, Kiro, OpenCode, Qwen, Roo Code, Tabby | Various | See docs |
| Generic | Any CLI with --prompt | Built-in |
Any adapter also works as the internal scheduler LLM — run the entire stack without any specific provider:
internal_llm_provider: gemini # or qwen, ollama, codex, goose, ...
internal_llm_model: gemini-3.1-pro-preview
[!TIP] Run
bernstein --headlessfor CI pipelines — no TUI, structured JSON output, non-zero exit on failure.
Quick start
cd your-project
bernstein init # creates .sdd/ workspace + bernstein.yaml
bernstein -g "Add rate limiting" # agents spawn, work in parallel, verify, exit
bernstein live # watch progress in the TUI dashboard
bernstein stop # graceful shutdown with drain
For multi-stage projects, define a YAML plan:
bernstein run plan.yaml # skips LLM planning, goes straight to execution
bernstein run --dry-run plan.yaml # preview tasks and estimated cost
How it works
- Decompose — the manager breaks your goal into tasks with roles, owned files, and completion signals
- Spawn — agents start in isolated git worktrees, one per task. Main branch stays clean.
- Verify — the janitor checks concrete signals: tests pass, files exist, lint clean, types correct
- Merge — verified work lands in main. Failed tasks get retried or routed to a different model.
The orchestrator is a Python scheduler, not an LLM. Scheduling decisions are deterministic, auditable, and reproducible.
Cloud execution (Cloudflare)
Bernstein can run agents on Cloudflare Workers instead of locally. The bernstein cloud CLI handles deployment and lifecycle.
- Workers — agent execution on Cloudflare's edge, with Durable Workflows for multi-step tasks and automatic retry
- V8 sandbox isolation — each agent runs in its own isolate, no container overhead
- R2 workspace sync — local worktree state syncs to R2 object storage so cloud agents see the same files
- Workers AI — use Cloudflare-hosted models as the LLM provider (no external API keys required)
- D1 analytics — task metrics and cost data stored in D1 for querying
- Vectorize — semantic cache backed by Cloudflare's vector database
- Browser rendering — headless Chrome on Workers for agents that need to inspect web output
- MCP remote transport — expose or consume MCP servers over Cloudflare's network
bernstein cloud init # scaffold wrangler.toml + bindings
bernstein cloud deploy # push agent workers
bernstein cloud run plan.yaml # execute a plan on Cloudflare
Capabilities
Core orchestration — parallel execution, git worktree isolation, janitor verification, quality gates (lint + types + PII scan), cross-model code review, circuit breaker for misbehaving agents, token growth monitoring with auto-intervention.
Intelligence — contextual bandit router learns optimal model/effort pairs over time. Knowledge graph for codebase impact analysis. Semantic caching saves tokens on repeated patterns. Cost anomaly detection with Z-score flagging.
Enterprise — HMAC-chained tamper-evident audit logs. Policy limits with fail-open defaults and multi-tenant isolation. PII output gating. OAuth 2.0 PKCE. SSO/SAML/OIDC auth. WAL crash recovery — no silent data loss.
Observability — Prometheus /metrics, OTel exporter presets, Grafana dashboards. Per-model cost tracking (bernstein cost). Terminal TUI and web dashboard. Agent process visibility in ps.
Ecosystem — MCP server mode, A2A protocol support, GitHub App integration, pluggy-based plugin system, multi-repo workspaces, cluster mode for distributed execution, self-evolution via --evolve.
Full feature matrix: FEATURE_MATRIX.md
How it compares
| Feature | Bernstein | CrewAI | AutoGen | LangGraph |
|---|---|---|---|---|
| Orchestrator | Deterministic code | LLM-driven | LLM-driven | Graph + LLM |
| Works with | Any CLI agent (20 adapters) | Python SDK classes | Python agents | LangChain nodes |
| Git isolation | Worktrees per agent | No | No | No |
| Verification | Janitor + quality gates | No | No | Conditional edges |
| Cost tracking | Built-in | No | No | No |
| State model | File-based (.sdd/) | In-memory | In-memory | Checkpointer |
| Self-evolution | Built-in | No | No | No |
| Declarative plans (YAML) | Yes | Partial | No | Yes |
| Model routing per task | Yes | No | No | Manual |
| MCP support | Yes | No | No | No |
| Agent-to-agent chat | No | Yes | Yes | No |
| Web UI | No | Yes | Yes | Partial |
| Cloud hosted option | Yes (Cloudflare) | Yes | No | Yes |
| Built-in RAG/retrieval | No | Yes | Yes | Yes |
Last verified: 2026-04-14. See full comparison pages for detailed feature matrices.
Monitoring
bernstein live # TUI dashboard
bernstein dashboard # web dashboard
bernstein status # task summary
bernstein ps # running agents
bernstein cost # spend by model/task
bernstein doctor # pre-flight checks
bernstein recap # post-run summary
bernstein trace <ID> # agent decision trace
bernstein run-changelog --hours 48 # changelog from agent-produced diffs
bernstein explain <cmd> # detailed help with examples
bernstein dry-run # preview tasks without executing
bernstein dep-impact # API breakage + downstream caller impact
bernstein aliases # show command shortcuts
bernstein config-path # show config file locations
bernstein init-wizard # interactive project setup
bernstein debug-bundle # collect logs, config, and state for bug reports
bernstein fingerprint build --corpus-dir ~/oss-corpus # build local similarity index
bernstein fingerprint check src/foo.py # check generated code against the index
Install
| Method | Command |
|---|---|
| pip | pip install bernstein |
| pipx | pipx install bernstein |
| uv | uv tool install bernstein |
| Homebrew | brew tap chernistry/bernstein && brew install bernstein |
| Fedora / RHEL | sudo dnf copr enable alexchernysh/bernstein && sudo dnf install bernstein |
| npm (wrapper) | npx bernstein-orchestrator |
Editor extensions: VS Marketplace · Open VSX
Contributing
PRs welcome. See CONTRIBUTING.md for setup and code style.
Support
If Bernstein saves you time: GitHub Sponsors · Open Collective
License
"To achieve great things, two things are needed: a plan and not quite enough time." — Leonard Bernstein
संबंधित सर्वर
Scout Monitoring MCP
प्रायोजकPut performance and error data directly in the hands of your AI assistant.
Alpha Vantage MCP Server
प्रायोजकAccess financial market data: realtime & historical stock, ETF, options, forex, crypto, commodities, fundamentals, technical indicators, & more
MCP Devkit
A persistent development partner that prevents context drift and maintains project memory across all development sessions.
clj-kondo-MCP
Clojure linter
Next.js MCP Server
A Next.js-based MCP server with OAuth 2.1 authentication support using Google as the default provider. Requires a PostgreSQL database and optionally Redis for SSE transport.
NetRecon MCP
Network reconnaissance and security scanning with port scanning, DNS analysis, and vulnerability assessment
Remote MCP Server (Authless)
An example of a remote MCP server without authentication, deployable on Cloudflare Workers.
Rossum MCP & Agent
MCP server and AI agent toolkit for intelligent document processing with Rossum.
Swagger MCP
Scrapes Swagger UI to dynamically generate MCP tools at runtime using LLMs.
xcsimctl
Manage Xcode simulators.
DomScan MCP
DomScan MCP Domain Intelligence Suite
Image Generation
Generate images from text prompts using the Together AI API.