Overview
Fracta supports multiple LLM runtime implementations. A runtime is an adapter between fracta’s orchestrator and a specific LLM CLI or API. Runtimes declare their capabilities and fracta routes accordingly. Claude parity is not required. For configuring existing runtimes (Claude, Codex, OpenCode), see runtime-configuration.md.Capability Tiers
A Batch-only host is production-valid. The system degrades gracefully for missing capabilities.
Steps
1. Implement host.Host
Create internal/host/<name>/ with a struct implementing host.Host:
2. Register the runtime
Incmd/helpers.go buildRuntimeRegistry():
3. Add runtime config to fracta.yaml
4. Spawn with the runtime
What fracta handles automatically
- Host resolution from
host_typeparameter or config default - Model resolution from host-specific
model_tiers - Capability enforcement (stream/resume/AgentMCP checked before side effects)
- Host env injection for local and K8s backends
- Workspace creation and cleanup
What the host adapter handles
- CLI command construction (
BuildBatchCommand) - Output parsing (
ParseBatchOutput) - Workspace file artifacts (
WriteWorkspace— can be no-op) - Streaming protocol (
StartStream— can returnErrStreamNotSupported) - Bootstrap file/prompt (
Bootstrap—FileNamecan be empty)
Incremental shipping
A host can ship in stages:- Batch-only (Tier 1) — implement
BuildBatchCommand+ParseBatchOutput - Add streaming (Tier 2) — implement
StartStream - Add resume + agent-mode (Tier 3) — add
ResumeToken+AgentMCPcapabilities

