Providers
Built-in descriptors, your own, and how services merge.
Built-in descriptors
@rivus/agent-kit/providers exports Provider and builtinProviders. It runs anywhere.
builtinProviders exposes each Agent's identity, discovery, install, sessions, usage and acp services when supported. Select a descriptor by id, then check the optional service before use. The ordinary entries share these service objects.
Hook dialects and catalog
Hook commands keep using builtinHookDialects from /harness/events. That isolated build imports nothing and owns separate hook objects. It does not take the provider list.
/catalog retains AgentKitError and isAgentKitError so callers can recognize errors from shell functions.
Which services exist for each built-in Agent is the generated table on Supported Agents. Today's built-in Agents are examples. The table lists them.
Adding your own
Routed functions accept providers?: readonly Provider[]. The type and builtinProviders come from @rivus/agent-kit/providers.
Descriptors merge over built-ins by id and service. { id: "codex", hooks: dialect } changes only Codex hooks. Omitted services and other Agents remain available. The old adapters, dialects, recipes and profiles options are removed.
A custom identity supplies aliases and a fallback home rule. Conflicting aliases, or an identity whose id differs from its descriptor, are rejected.
To display an Agent name, find builtinProviders.find((provider) => provider.id === id)?.identity?.displayName.
To customize discovery, select its discovery recipe and pass providers: [{ id, discovery: { ...recipe, auth: {} } }].
Option and result types without named consumers remain in signatures. Derive them with Parameters or ReturnType, and with Effect's success and error types for Effect operations.
To read another Agent, pass providers: [{ id: "my-agent", sessions: adapter }] and check it with sessionAdapterConformance from /testing. An adapter's event builder that is generic over the kind takes its payload as TranscriptEventPayloads[K] (exported from /transcript) and returns a TranscriptEventOf<K>. The suites are on Testing your adapters.