Expand description
Provider components for pluggable LLM backends.
A provider is split into narrow capabilities: configured state,
request transport, failure classification, and model policy.
ProviderHandle owns those components and is the executable handle
installed by the host for a running session.
ProviderSpec is only a host/config-file data shape. Runtime
persistence records provider identity separately and never rebuilds a
ProviderHandle from disk.
Structs§
- Default
Provider Failure Classifier - Empty
Provider Resolver - LlmTimeouts
- MapProvider
Resolver - Provider
Binding - Provider
Components - Component bundle returned by provider factories.
- Provider
Handle - Owning handle to provider components. This is an executable transport handle supplied by the host, not a persistence format.
- Provider
Options - Provider
Rate Limit Permit - Provider
Rate Limit Policy - Provider
Rate Limiter - Provider
Reliability - Provider
Retry Policy - Provider
Spec - Serialised form of a provider’s host-owned configuration. Runtime persistence stores only provider ids; this type is for app/user config files that need credentials.
- Resolved
Generation Policy - Single
Provider Resolver - Static
Model Policy - Unconfigured
Provider - Placeholder provider used when
SessionPolicy::default()is constructed without an explicit provider. Every transport-level method errors; calling code MUST replace this before executing a turn. It exists solely so..Default::default()shorthand keeps working in host code that always overrides the provider field.
Enums§
- Cache
Retention - Prompt-cache lifetime hint. Providers translate this into their own
wire dialect (Anthropic
cache_controlTTL, OpenRouter-Claudecache_controlmarkers via Chat Completions, OpenAI Responsesprompt_cache_key/prompt_cache_retention). Providers without a cache-control concept (Google, Codex) read the value but emit nothing for it. - Provider
Resolution Error - Request
Timeout
Constants§
Traits§
- Provider
- A configured LLM backend: its identity, host-config serialization, its generation options, and the request transport.
- Provider
Factory - Provider
Failure Classifier - Provider
Model Policy - Runtime
Provider Resolver