Plugins
The catalog of providers and transports, and how they plug in.
The core is small and vendor-free: it defines interfaces
(models,
transport, telemetry, kv) and nothing else.
Plugins are separate packages under plugins/ that implement those
interfaces — so importing the core never pulls an HTTP client or a media stack,
and you add exactly the providers you use.
How plugins plug in
-
Model providers self-register with the
modelspecregistry in theirinit, so a blank import makes their"provider/model"specs resolve — thedatabase/sqldriver pattern:import _ "github.com/webdeveloperben/agents-go/plugins/openai" // now agents.Config{LLM: "openai/gpt-4o"} resolves -
Transports are constructed and bound to a session (via
Startor aBinding); observability/infra plugins are constructed and handed to the session (Config.Telemetry) or the coordinator (kv.Store).
The registry holds factory functions, not credentials — API keys come from each provider's environment variable (or an explicit option) at construction.
Catalog
Models
OpenAI
LLM · STT · TTS. Specs: openai/… (alias gpt/…).
Anthropic
LLM. Specs: anthropic/… (alias claude/…).
Fake (testing)
LLM/STT/TTS/VAD test doubles. Specs: fake/…. No cloud accounts.
Transports
LiveKit
WebRTC room transport (roomio) + the LiveKit dispatch source.
Twilio
Telephony media stream + voice webhook.
Observability & infra
OpenTelemetry
Export spans and metrics (Prometheus / OTLP).
Redis (rediskv)
Coordinator kv.Store backend for shared cluster state.
Adding your own
Every plugin follows the same small contract. To add a provider, see Writing a plugin.