The model-quality layer that makes local, quantized, and cheap models behave.
Recovers and executes malformed tool calls · vetoes bad completion drafts · catches fabricated data · self-calibrates token estimates. Plus the plumbing you'd otherwise rewrite: typed wire protocol · pluggable LLM runtime · embeddable Python sidecar · headless React chat UI. Pick any subset, skip the rest.
Docs · Storybook · Live demo · Examples · Releases · Discussions
79.0% on Terminal-Bench 2.1 with GLM-5.3-Flash — same band as Claude Code + Opus 4.8 (78.9%) and Codex CLI + GPT-5.5 (83.1%). Harbor hidden tests, 89-task catalog, three-run mean. Numbers and protocol.
Want to see it running before reading anything? Open the hosted live demo — the real Tier 5 agent shell UI running in your browser on mock data, no backend or API key required. Locally:
git clone … && pnpm install && pnpm agent-shell:webboots the same shell against your own model.
- Why Steerable
- Terminal-Bench 2.1
- Quickstart — pick your path (5 minutes)
- Architecture
- What's in the box
- Comparison
- Who's using it in production
- Project status & roadmap
- Documentation
- Community & support
- Contributing
- Acknowledgements
- License
Every agent SDK assumes the model emits clean, structured tool_calls. Local, quantized, and cheap models don't. Steerable is the model-quality layer that closes that gap — plus the plumbing layers you'd otherwise rewrite, each shippable on its own.
| The problem you've already solved twice | Steerable's answer |
|---|---|
"The model emitted a tool call as prose. Again." Local, quantized, and cheap models break the assumptions every SDK makes about structured tool_calls. |
The model-quality layer — the part no vendor SDK will build for you. pseudo.py recovers and executes malformed calls in three formats (MiniMax XML, DeepSeek <function=>, markdown); a before_completion veto answers accept/retry/narrate on a completion draft; grounding judges catch fabricated data; token estimates self-calibrate against observed usage. |
| "What shape is this SSE stream?" Every team invents their own envelope; FE and BE drift. | One JSON Schema → generated TypeScript types + Pydantic models, in lockstep release. content, tool_call, tool_result, error, done, budget_exhausted all standardised; conformance test suite verifies the two language SDKs stay byte-compatible. |
| Tool dispatch / budgets / retries / safety regex | agent-harness (Py): decide_tool_mode, consume_budget, next_retry_delay_ms, is_terminal_result, command-safety patterns. Pure functions, zero I/O coupling — drop into FastAPI / Celery / a notebook. 49 unit + golden tests. |
| LLM provider abstraction | agent-runtime (Py): one LLMProvider interface across four wire protocols — OpenAI-compatible chat/completions (Ollama, vLLM, DeepSeek, Groq, …), OpenAI Responses, Anthropic-native, Gemini-native — with a live gateway model catalog, per-vendor sampling presets, @tool decorator, ToolRouter, SSE-over-HTTP and stdio JSON-RPC transports. |
| Shipping LLMs in a desktop app without a network round-trip | steerable-sidecar: a portable, signed CPython binary that speaks JSON-RPC over stdio (36 methods). Bundle it into a Tauri app (@steerable/agent-shell-tauri), any other native shell, or your own host — macOS notarised, Windows code-signed, ~95 MB stripped on darwin-arm64 under a CI size budget. |
| Chat UI that doesn't look like 2003 | @steerable/agent-ui: 7 headless React components + 14 rich cards + 3 hooks + Tailwind preset. Every component has Storybook + a11y (axe) + visual-regression baselines locked in CI. |
Every layer is independently published. Use just the protocol types, just the UI, just the sidecar — there is no monolith to swallow.
A Flash-cost model on Steerable. Harbor hidden tests, 89-task catalog, three independent full runs: mean 79.0% (SD 3.4 points). The runs average 229.9M input tokens, down 15.4% from the superseded six-run baseline. Provider prices changed between measurement windows, so we do not publish a cross-date dollar conversion. Protocol and run list: docs/evals.md.
Same model · GLM-5.3-Flash — identical cheap model, same Harbor catalog-89 protocol:
| Agent | TB 2.1 | Input tokens / run | Notes |
|---|---|---|---|
| Steerable | 79.0% ±3.4 | 229.9M | this repo, 3× catalog-89 · +5.6 vs Pi |
| Claude Code | 83.1% | 299.2M | this repo, 1 catalog run |
| Pi | 73.4% ±2.2 | 138.9M | this repo, 3 catalog runs |
Z.AI's own Claude Code run of the same Flash model is 84.3% under a 6-hour timeout (Claude Code 2.1.207) — a different protocol; we wrap at 170 minutes.
uv add steerable-agent-protocol steerable-agent-harness steerable-agent-runtimefrom steerable_agent_runtime import ToolRouter, tool
from steerable_agent_protocol import ToolCall
router = ToolRouter()
@tool(router=router, description="Read a file by path")
async def read_file(path: str) -> dict:
return {"path": path, "content": open(path).read()}
result = await router.dispatch(ToolCall(id="c1", name="read_file", arguments={"path": "README.md"}))
# result.success, result.data, result.error — all typed.Full runnable: examples/py-minimal.
pnpm add @steerable/agent-protocol @steerable/agent-uiimport { ChatPanel, useChatStream } from '@steerable/agent-ui';
export function Chat() {
const { messages, send, isStreaming } = useChatStream({
endpoint: '/api/chats/123/send',
});
return <ChatPanel messages={messages} onSubmit={send} isStreaming={isStreaming} />;
}useChatStream parses every standard SSEEvent shape into typed messages — you don't write a parser, you don't argue about envelope format. See live components at the Storybook.
# Bundle the sidecar binary into resources/python-runtime/<platform>/
# (build script: packages/sidecar/build/build_sidecar.py)import { spawn } from 'node:child_process';
const proc = spawn(sidecarPath, [], { stdio: ['pipe', 'pipe', 'inherit'] });
proc.stdin.write(JSON.stringify({
jsonrpc: '2.0', id: 1, method: 'agent.chat.stream',
params: { messages: [{ role: 'user', content: 'hi' }] },
}) + '\n');
// SSE-over-JSON-RPC events stream back on stdout, one per line.TypeScript hosts can skip the subprocess plumbing with @steerable/agent-runtime (packages/agent-runtime/ts — source-consumed via link:, not on npm yet): it owns spawn, the lifecycle.ready handshake, health pings, bounded auto-restart, and graceful drain, and exposes the full CoreLoop-level API (chatStream / cancelChat / steerChat / session fork & branch tree / …). A Tauri product usually takes @steerable/agent-shell-tauri instead: the crate owns the native window and supervises the shell's Node host, which supervises the sidecar.
Full runnable: examples/sidecar-roundtrip. Real-world embedder: deeppath-agent.
The Tier 5 host shell runs standalone with neutral branding (no product, no packs), in the browser or from the command line:
pnpm install
pnpm agent-shell:web # builds shell + neutral web app, boots the headless server
# → http://127.0.0.1:4787 (Steerable Shell)npm install -g @steerable/agent-cli
steerable-cli login # pick a provider, paste a key, pick a model
steerable-cli run "summarize this repo"Two other install paths produce the same command: curl -fsSL https://steerableframework.com/install.sh | sh (installs Node too when missing) and brew install pathlyapp/steerable/steerable. See packaging.
login verifies the key with one model-list request before saving it. In scripts and CI, set the provider's environment variable instead and skip the prompt:
export DEEPSEEK_API_KEY=sk-...
steerable-cli run "summarize this repo"steerable-cli doctor lists every runtime and configuration check with the command that fixes a failure; steerable-cli tui opens the terminal interface (it needs Node 26.4.0 because of the renderer, while the other commands run on Node 22.19.0 and newer).
A product ships the desktop window through @steerable/agent-shell-tauri and its own thin src-tauri crate; the framework repo itself boots the same shell in the browser.
Both web and CLI are the production code path — the browser-dev host mock is dev-server-only and tree-shaken out of prod builds, so it never appears here.
Five tiers, strict no-upward-imports rule. Each tier is shippable on its own.
flowchart TB
subgraph T5[Tier 5 · Host Shell]
SH["<b>@steerable/agent-shell</b> (TS)<br/>Node host runtime + headless HTTP server · local-backend · storage · sidecar supervisor"]
SHT["<b>@steerable/agent-shell-tauri</b> (Rust)<br/>native window · menus · dialogs · updates · process containment"]
SHW["<b>@steerable/agent-shell-web</b> (TS)<br/>product-neutral renderer SPA source (React + Vite)"]
end
subgraph T4[Tier 4 · UI]
UI["<b>@steerable/agent-ui</b><br/>React hooks · headless components · Tailwind preset"]
end
subgraph T3[Tier 3 · Runtime & Sidecar]
RT["<b>steerable-agent-runtime</b> (Py)<br/>LLMProvider · ToolRouter · StorageAdapter · TransportAdapter"]
SC["<b>steerable-sidecar</b> (Py)<br/>portable CPython binary · JSON-RPC over stdio"]
end
subgraph T2[Tier 2 · Harness]
H["<b>steerable-agent-harness</b> (Py)<br/>policy · budget · retry · completion · tracing"]
HF["<b>@steerable/agent-harness</b> (TS)<br/>thin facade · conformance only"]
end
subgraph T1[Tier 1 · Protocol]
P["<b>(@)steerable(/)agent-protocol</b><br/>spec/*.schema.json → TS types + Pydantic models"]
end
SH --> UI
SH --> SC
SHT --> SH
SHW --> UI
UI --> P
RT --> H
SC --> RT
H --> P
HF -. conformance .-> H
classDef t1 fill:#e3f2fd,stroke:#1976d2
classDef t2 fill:#f3e5f5,stroke:#7b1fa2
classDef t3 fill:#e8f5e9,stroke:#388e3c
classDef t4 fill:#fff3e0,stroke:#f57c00
classDef t5 fill:#fce4ec,stroke:#c2185b
class P t1
class H,HF t2
class RT,SC t3
class UI t4
class SH,SHW,SHT t5
The rules:
- Tier N never imports Tier N+1. Adopting any layer means inheriting only the layers below it.
- TS↔Py for
agent-protocolis codegen, not parallel implementation —spec/*.schema.jsonis the single source of truth. - The public npm and Python sidecar packages release in framework lockstep. The private Rust bundle — the native CoreLoop wheel and egress proxy — has its own version and immutable
rust-vX.Y.ZRelease.rust-artifacts.lock.jsonpins the reviewed bundle manifest and exact native dependency; framework releases reuse that pin until an explicit artifact update. Rust crates remain unpublished on crates.io (publish = false). - Tier 5 is product-neutral: brand, telemetry endpoints, help links, and data-directory names are injected by the consuming product's assembly root (
setProductBrand/setProductConfig), enforced by theshell:neutralgate in CI.
Tier 1 — Protocol · @steerable/agent-protocol + steerable-agent-protocol
SSEEventenvelope (universal stream shape —content/tool_call/tool_result/error/done/budget_exhausted/ extensible)ToolCall,ToolResult— closed schemas, byte-stableChatMessage,ChatAgent— open schemas, extensible payloadsAgentSession,HarnessTrace,TraceSpan,TraceEvent— runtime introspectionSidecarRequest,SidecarResponse,SidecarError,SidecarNotification,SidecarHealth— JSON-RPC envelope for the sidecarCommandSafetyPattern— declarative regex/glob patterns for tool guardrails- Codegen:
pnpm gen(TS) +uv run python scripts/generate_py.py(Py); drift checker fails CI on hand edits
Tier 2 — Harness · steerable-agent-harness
- Policy:
decide_tool_mode(name)— classifies tools as read/write/network/etc. for downstream gating - Budget:
BudgetLimit,BudgetState,consume_budget(state, limit, tokens=, step=, tool_call=)— pure-function step accounting; emits the standardbudget_exhaustedevent when tripped - Retry:
RetryPolicy,next_retry_delay_ms(policy, attempt)— deterministic exponential-backoff with optional jitter - Completion:
is_terminal_result(result)— consistent loop-termination predicate - Tracing:
HarnessTracebuilder withTraceSpan/TraceEventrecorders - Safety patterns: command-safety regex/glob compiled from
spec/safety/CommandSafetyPattern.schema.json - 49 unit + golden snapshot tests; zero DB / HTTP coupling
Tier 3 — Runtime & Sidecar · steerable-agent-runtime + steerable-sidecar + steerable-egress-proxy
- CoreLoop — the production single-agent step loop, yielding a structured
LoopEventstream (15 kinds): pseudo tool-call recovery,before_completionveto, three default compaction paths plus one opt-in (micro_compact_interval_rounds) with both circuit breakers, soft-timeout wrap-up, duplicate-call dedup, per-tool timeouts - LLMProvider interface across four wire protocols: OpenAI-compatible chat/completions (Ollama, vLLM, llama.cpp server, DeepSeek, Groq, Together, …), OpenAI Responses (with
store: false+ encrypted-reasoning round-trips), Anthropic-native, Gemini-native — vendor divergences are data (PROVIDER_COMPAT_HOSTS+ per-model sampling presets) - Gateway model catalog — live
GET /modelsdiscovery (models.list, refreshable), bundled serving-provider catalog (catalog.describe), strictreasoning_efforthandling - ToolRouter +
@tooldecorator with JSON Schema auto-derived from Python type hints (explicitschema=always overrides); exposure tiers (direct/deferred/hidden) withtool_search - MCP client — stdio servers, deterministic
mcp__<server>__<tool>naming, per-server catalog caps, deferred-by-default exposure - Plugin lifecycle — entry-point + local-directory sources;
plugin.list/enable/disable/reloadwithout a sidecar restart - Subagents — named profiles with per-profile tool domains (fail-closed), models, and system prompts; opt-in orchestration pool (
agent_spawn/agent_send/agent_wait/ …) - Approval + sandbox executors — 8-variant approval algebra across request/session/durable scopes; per-exec Seatbelt confinement with enforcement returned as a value; bundled per-host egress allow-list proxy with ask-the-user widening
- StorageAdapter interface + InMemory + SQLAlchemy reference implementations
- TransportAdapter: FastAPI SSE + stdio JSON-RPC (sidecar), plus AG-UI and ACP peer transports
- Sidecar binary built from
python-build-standalone— boots in <1s, ~95 MB stripped on darwin-arm64, macOS notarised, Windows signed - Cross-platform build (
packages/sidecar/build/build_sidecar.py); aggressive stdlib pruning under a CI size budget
Tier 4 — UI · @steerable/agent-ui
- Components:
ChatPanel,MessageList,AgentSelector,ModelSelector(live/stale/offline catalog states),OrchestrationPlanCard,ToolCallRenderer,SSEStreamView— all headless / Tailwind-themable - Cards (
@steerable/agent-ui/cards): 14 rich message cards —QuizCard,CoverageReportCard,AnalysisDocumentCard,ResearchPlanCard,SuggestedRepliesCard,AskUserQuestionsCard,ThinkingProcessCard,PlanStepsCard,PlanSelectorCard,SearchSourcesCard,SummaryMessageCard,ActionSegmentCard,ToolExecutionCard,OrchestrationPlanCard - Hooks:
useChatStream,useAgentSession,useToolCallStatus+ chat-session state primitives (useChatSession,useChatComposer,useChatList,MockChatStreamTransport, …) - Tailwind preset — drop-in tokens (
bg-agent-canvas,rounded-agent-md, etc.) - Storybook — every component, every state, with axe a11y + Playwright visual-regression locked in CI
- 167 unit tests + 43 stories + 4 MDX docs
Tier 5 — Host Shell · @steerable/agent-shell + @steerable/agent-shell-tauri + @steerable/agent-shell-web + @steerable/pack-sdk
- Two hosts, one runtime: a Tauri desktop window (
@steerable/agent-shell-tauri, a Rust crate that supervises the Node host on a loopback port — native window, menus, dialogs, single-instance, process containment, updates) and a headless HTTP server (/api/v2/*, SSE) assembled from the sameHostRuntime - Local backend: chat/project/agent CRUD, CoreLoop streaming, skill loader (brand-placeholder rendering), subagent profiles, cross-turn background tasks with a panel UI, git-worktree isolation, session branch tree, usage/insights storage (SQLite via better-sqlite3)
- Sidecar supervision: boot, health, egress proxy, seatbelt/exec sandbox, reverse approval/ask-user bridges
- Connection diagnostics: LLM connection diagnosis panel, system/ambient proxy detection, and egress hints surfaced in settings — a misconfigured gateway fails with a remedy, not a hang
- Scenario-pack extension points (
pack-sdktypes): services, tools, migrations, skills, agent seeds, HTTP routes, CLI commands, packaging spec, and renderer contributions (routes, settings panels, chat slots, card renderers, brand/logo) — composed at build time by the product's assembly root - Renderer SPA source (
agent-shell-web): product-neutral React app consumed by product web entries via the@/alias +createProductViteConfigfactory - Packaging helpers:
scripts/prepare-sidecar.sh/prepare-framework-wheels.shbuild the embedded Python runtime for product installers - Neutrality gate:
pnpm --filter @steerable/agent-shell shell:neutralfails CI on any product hardcoding in shell sources or skill text - Command line (
@steerable/agent-cli):steerable-cliruns a turn or a terminal session in-process and shares the host database with the desktop app. Products supply their own command name. - 615 node-side unit tests + 220 renderer component tests
There is no "best agent framework" — there's the right one for your shape of problem.
| Steerable | LangChain (Py + JS) | Vercel AI SDK (TS) | OpenAI Assistants API | |
|---|---|---|---|---|
| One wire protocol shared by TS + Py (codegen-aligned) | ✅ | ❌ (TS only) | ||
| Pure-function harness (drop into any framework) | ✅ | n/a (SaaS) | ||
| Embeddable local-LLM sidecar (offline desktop) | ✅ | ❌ | ❌ | ❌ (cloud-only) |
| Headless, themable React chat components | ✅ | ❌ | ✅ | ❌ |
| Lockstep release across all layers | ✅ | n/a | n/a | n/a |
| Self-hosted, no vendor lock-in | ✅ | ✅ | ✅ | ❌ |
Reach for Steerable when you need typed cross-language contracts, plan to ship to desktop / on-prem / air-gapped, or want a UI library you can theme without !important wars.
Don't reach for Steerable when your agent lives entirely inside one Python process with no FE, you're happy with cloud-hosted Assistants, or you want a high-level prompt -> answer SDK with batteries included for every model — Steerable is closer to "Express for agents" than "Rails for agents".
For a comparison with agent-specific frameworks and products (Codex, DeepSeek Harness, LangGraph, OpenAI Agents SDK, Claude Agent SDK), see the docs comparison page.
- DeepPath — web (
@steerable/agent-protocol+@steerable/agent-ui), API (all 3 Py packages), desktop (Tauri shell + sidecar + UI). The framework was extracted from this codebase and is dogfooded back into it on every release; that repo assembles several branded builds from the same shell.
If you're using Steerable in production, send a PR adding your project here.
Current: 0.8.x series — public registries, lockstep tag-driven releases, native engine artifacts at 1.0.7. One consumer codebase (DeepPath) ships web, API and desktop from this framework, and assembles several branded desktop builds from the same shell.
| Phase | Status | What lands |
|---|---|---|
| 0.x consolidation | 🟢 in progress | Stable surface API, integration tests against downstream repos, downstream lockfile bumps semi-automated |
| 0.3+ Trusted Publishing | ✅ done | npm --provenance (sigstore) + PyPI Trusted Publishing over OIDC; cross-platform sidecar build/sign matrix in GHA |
| 0.4+ Sidecar slimming | ✅ done | install_only_stripped distro landed; darwin-arm64 bundle 94.7 MB (was ~700 MB class), CI budgets back at the 320 MB design target |
| 0.5–0.6 Architecture-review waves 0–4 | ✅ done | Append-only model-visible history, world-state diffing with cache_control emission, tool exposure tiers + tool_search, MCP client, approval algebra, per-exec sandbox, AG-UI/ACP peer transports, plugin lifecycle, gateway model catalog |
| 0.6.x–0.7 Rust CoreLoop + Tauri host | ✅ done | The loop and egress proxy became digest-pinned Rust artifacts adopted through one lock file; the desktop host moved from an Electron main process to @steerable/agent-shell-tauri, which supervises the same Node host; directConnection, diagnosable and reconnectable provider failures, continuation of failed or stopped turns, OTLP turn-outcome counters, approval policy rules and project binding |
| 1.0 | ⚪ gated on | One full minor cycle without breaking changes; spec freeze (additionalProperties semantics locked); shared 1.0.0 decision for protocol+harness pair |
Pre-1.0 contract: minor (0.X) is the breaking-change axis.
- Getting Started — full walkthrough, ~5 minutes
- Evals — Terminal-Bench 2.1 catalog-89 score of record (Steerable + GLM-5.3-Flash 79.0%) plus Harbor cheap-12 (
claude-code/codex/pi) - Specs — wire-level reference for every event/envelope shape
- Examples — 3 runnable end-to-end smoke tests:
py-minimal— protocol + harness + tool dispatchts-minimal— protocol + harness facadesidecar-roundtrip— spawn the sidecar binary and complete a JSON-RPC roundtrip
- Storybook — every UI component, live, with a11y + visual regression baselines
- CHANGELOG — release notes
- INTEGRATION-TESTING.md — how to develop framework + downstream consumer in lockstep
- RELEASING.md —
bump_to.sh X.Y.Z → tag → pushis the entire flow
- 💬 Questions / ideas / show & tell → GitHub Discussions
- 🐛 Bug reports / feature requests → GitHub Issues
- 🔒 Security disclosures → see
SECURITY.md(please email the maintainers privately first; do not open a public issue) - 📦 npm provenance → every
@steerable/*tarball ships sigstore attestations; verify withnpm audit signatures @steerable/agent-ui
Contributions are welcome — both small (typo fixes, examples) and structural (new LLM adapters, new sidecar transport).
git clone https://github.com/pathlyapp/steerable
cd steerable
pnpm install
uv sync --all-packages
pnpm gen # regenerate TS+Py types from spec/
pnpm test # ~1,000 TS tests (incl. Storybook stories)
uv run pytest # ~1,950 testsIf your change touches spec/, the codegen drift checker will fire in CI — re-run pnpm gen && uv run python scripts/generate_py.py and commit the regenerated files.
Working on Steerable alongside one of the consumer repos? See INTEGRATION-TESTING.md — covers the local toggle scripts (use_framework_local.sh / use_framework_npm.sh / use_framework_source.sh) that flip each consumer between published-registry mode and sibling-source mode.
Cutting a release? See RELEASING.md. Short version:
./scripts/release/bump_to.sh 0.3.0
git add -A && git commit -m "chore(release): v0.3.0"
git tag v0.3.0
git push origin develop v0.3.0 # CI lockstep-validates, creates Release, publishes to npm + PyPI + native wheelsAll commits must be DCO-signed (git commit -s); the DCO check runs on every PR.
Steerable stands on the work of:
- python-build-standalone — the portable CPython distribution that makes the sidecar possible (and the reason you can ship a single signed binary instead of asking users to install Python).
- Sigstore — npm tarball provenance attestations.
- uv — Python dependency resolution at C-speed; the entire Py workspace is built around it.
- release-please — used briefly for the early 0.x releases; replaced by tag-driven lockstep when the per-component versioning collided with our cross-language lockstep gate (lessons captured in
RELEASING.md). - The headless React component patterns popularised by Radix UI and Headless UI —
@steerable/agent-uifollows the same "logic in hooks, no markup opinions" split.
The source in this repository is licensed under the
Apache License 2.0. The separately built native CoreLoop wheel
and egress proxy pinned by rust-artifacts.lock.json are
source-unavailable binary artifacts licensed separately by their immutable
Release. The lock records the reviewed license identifier. See
NOTICE for distribution terms and third-party attributions.