Local-first orchestration for personal AI workflows.
Orchestro is a Python application that sits above model backends and agent CLIs and adds routing, persistence, memory retrieval, sessions, plans, tools, ratings, corrections, benchmark runs, scheduled tasks, MCP bridging, LSP integration, and exportable feedback data.
It is designed for an operator who wants a terminal-first daily-driver, not just a thin wrapper around one model endpoint.
Current state in this checkout:
- Full
pytestsuite is green. - The project has acceptance-style API and CLI workflow coverage.
- Live backend smoke tests exist for opt-in verification of external agent CLIs.
- A canary script exists for day-to-day environment checks and auto-routing/cooldown inspection.
Orchestro combines several layers:
- Backend abstraction: local OpenAI-compatible servers, Anthropic, subprocess backends, and agent CLIs such as
claude,codex,kilocode, andcursor-agent. - Routing:
autobackend selection, model-aware routing, and cooldown-based skipping of temporarily unavailable backends. - Execution strategies:
direct,tool-loop,reflect-retry,reflect-retry-once,self-consistency,critique-revise, andverified. - Persistent memory: runs, ratings, interactions, facts, corrections, postmortems, plans, sessions, scheduled tasks, and collections in SQLite.
- Tooling: shell commands, file reads, git inspection, tests, memory search, fact/correction proposals, and optional bridged MCP tools.
- Operator surfaces: CLI, shell mode, a full-screen TUI path, FastAPI service, benchmark runner, and a daily-driver canary script.
- Developer support: acceptance tests, live smoke tests, benchmark suites, and export paths for preference/training data.
For architecture and design intent, see Architecture, ADR: SQLite First, and Roadmap.
python -m venv .venv
. .venv/bin/activate
pip install -e .cp docs/global.md.example .orchestro/global.md
cp .env.example .envEdit .env only if you want live non-mock backends. The test-safe default is still the mock backend.
PYTHONPATH=src pytest -q
PYTHONPATH=src python scripts/orchestro_canary.py --backend mock --goal "Reply with canary ok." --jsonCLI:
orchestro ask "Summarize the repo" --backend auto
orchestro tui --backend auto
orchestro backends
orchestro runs --limit 5API:
orchestro serve --host 127.0.0.1 --port 8765
curl http://127.0.0.1:8765/health
curl http://127.0.0.1:8765/backendsFor a fuller setup flow, see Getting Started.
- Getting Started
- CLI Reference
- Shell Mode
- TUI Vision
- TUI Implementation Plan
- TUI Redesign Spec
- API Reference
- API Operations
- Deployment
- Troubleshooting
- Backends And Routing
- MCP
- LSP
- Plugins
- Collections
- Benchmarks
- Database Schema
- Database Schema SQL
- Instructions And Constitutions
- Trust And Security
- Examples
- Testing And Operations
- Architecture
- ADR: SQLite First
- ADR: Agent Loop Patterns
- Borrowed Patterns
- Roadmap
- Global Instructions Template
- CLI entrypoint:
orchestro - MCP server entrypoint:
orchestro-mcp - FastAPI service in
src/orchestro/api.py - Interactive shell in
src/orchestro/cli.py
- Asking and shell work:
ask,shell,backends - Run management:
runs,show,changes,run-summary,run-note,rate,rate-event - Sessions and plans:
sessions,session-*,plans,plan-* - Tools and integrations:
tools,tool-run,plugins,mcp-status,lsp-status - Memory and knowledge:
facts,corrections,interactions,search,semantic-search,collections - Benchmarks and exports:
bench*,benchmark-*,export-preferences,export-stats - Scheduling and operations:
schedule-*,approval-*,vector-status,index-*,queue-embeddings
See CLI Reference for the grouped command index.
- Health and status:
/health,/backends,/plugins,/mcp-status,/lsp-status - Runs:
/ask,/ask/stream,/runs,/runs/{run_id},/runs/{run_id}/events - Sessions and plans:
/sessions,/sessions/{id},/plans,/plans/{id} - Tools and memory:
/tools,/tools/run,/facts,/corrections,/search,/semantic-search - Operations:
/scheduled-tasks,/routing-stats,/index-jobs,/benchmark-runs
See API Reference and Examples.
src/orchestro/ Application code
tests/ Unit, integration, acceptance, and live smoke tests
docs/ Human docs, ADRs, architecture notes
benchmarks/ Benchmark suites
scripts/ Operational helpers and canaries
.orchestro/ Default local data directory
Key files:
src/orchestro/orchestrator.py: run lifecycle, routing, retries, tool execution, persistence gluesrc/orchestro/cli.py: terminal UI and command entrypointssrc/orchestro/api.py: FastAPI servicesrc/orchestro/db.py: SQLite persistence layersrc/orchestro/backend_profiles.py: backend registry, aliases, auto routing, cooldownsscripts/orchestro_canary.py: daily-driver canary
The major documentation gaps from the previous passes are now closed. Ongoing maintenance risks are tracked in docs/documentation-gaps.md.
If you are changing behavior, update the relevant focused doc rather than growing this README again.
Run ./scripts/security-scan-local.sh for local Semgrep CE and the Trivy scanners that fit this repository. The installed pre-commit hook runs Semgrep on staged source/config files only; Trivy runs on demand or in CI. See security-scanning.md. Use ./scripts/update-security-tools.sh to refresh local scanner data and the Trivy database.