BERNSTEIN(1)

NAME

bernsteinDeclarative Agent Orchestration. Ship while you sleep.

SYNOPSIS

$npm install -g bernstein-orchestrator

INFO

80 stars
10 forks
0 views
Python

DESCRIPTION

Declarative Agent Orchestration. Ship while you sleep.

README

Bernstein

Orchestrate any AI coding agent. Any model. One command.

Bernstein TUI — live task dashboard

CI codecov PyPI npm VS Marketplace Python 3.12+ License MCP Compatible A2A Compatible

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.

AgentModelsInstall
Claude Codeopus 4.6, sonnet 4.6, haiku 4.5npm install -g @anthropic-ai/claude-code
Codex CLIgpt-5.4, o3, o4-mininpm install -g @openai/codex
Gemini CLIgemini-3-pro, 3-flashnpm install -g @google/gemini-cli
Cursorsonnet 4.6, opus 4.6, gpt-5.4Cursor app
AiderAny OpenAI/Anthropic-compatiblepip install aider-chat
Ollama + AiderLocal models (offline)brew install ollama
Amp, Cody, Continue.dev, Goose, Kilo, Kiro, OpenCode, Qwen, Roo Code, TabbyVariousSee docs
GenericAny CLI with --promptBuilt-in

[!TIP] Run bernstein --headless for 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

  1. Decompose — the manager breaks your goal into tasks with roles, owned files, and completion signals
  2. Spawn — agents start in isolated git worktrees, one per task. Main branch stays clean.
  3. Verify — the janitor checks concrete signals: tests pass, files exist, lint clean, types correct
  4. 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.

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

FeatureBernsteinCrewAIAutoGenLangGraph
OrchestratorDeterministic codeLLM-drivenLLM-drivenGraph + LLM
Works withAny CLI agent (18+)Python SDK classesPython agentsLangChain nodes
Git isolationWorktrees per agentNoNoNo
VerificationJanitor + quality gatesNoNoConditional edges
Cost trackingBuilt-inNoNoNo
State modelFile-based (.sdd/)In-memoryIn-memoryCheckpointer
Self-evolutionBuilt-inNoNoNo
Declarative plans (YAML)YesPartialNoYes
Model routing per taskYesNoNoManual
MCP supportYesNoNoNo
Agent-to-agent chatNoYesYesNo
Web UINoYesYesPartial
Cloud hosted optionNoYesNoYes
Built-in RAG/retrievalNoYesYesYes

Last verified: 2026-04-07. 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 explain <cmd>  # detailed help with examples
bernstein dry-run    # preview tasks without executing
bernstein aliases    # show command shortcuts
bernstein config-path    # show config file locations
bernstein init-wizard    # interactive project setup

Install

MethodCommand
pippip install bernstein
pipxpipx install bernstein
uvuv tool install bernstein
Homebrewbrew tap chernistry/bernstein && brew install bernstein
Fedora / RHELsudo 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

Apache License 2.0


"To achieve great things, two things are needed: a plan and not quite enough time." — Leonard Bernstein

clihub4/8/2026BERNSTEIN(1)