Expand description
Model providers.
A provider translates CompletionRequest onto some wire protocol and
translates the reply back into CompletionResponse. Everything above this
layer — the agent loop, tools, sessions — is provider-agnostic.
Modules§
- anthropic
- Anthropic Messages API (
POST /v1/messages). - openai
- OpenAI-compatible
/v1/chat/completions. - preflight
- One request to a local server, asking it what it is actually serving.
- retry
- Provider failure classification, and the retry policy over it.
Structs§
- Failover
- Tries the primary, and on a transient exhaustion tries each fallback in order — turn-local, so the next call starts from the primary again.
Enums§
- Stream
Event - Incremental output, emitted only when a sink is supplied.
Traits§
Functions§
- build
- Build a provider from a config entry.