The DialogAdapter protocol
Defined inunpod.adapters.base. Runtime-checkable - any object with these
three methods passes isinstance(obj, DialogAdapter); no base class required.
Auto-wrapping
Thectx.session.dialog_machine setter accepts, in order:
- A superdialog
DialogMachineorLLMAgent- wrapped in aSuperDialogAdapterautomatically. - Any object satisfying the
DialogAdapterprotocol - used as-is. - Anything else - raises
TypeError.
Bundled adapters
All importable fromunpod.adapters:
AnthropicAdapter, DialogAdapter, HTTPAdapter, LangChainAdapter,
MCPAdapter, OpenAIAdapter, SuperDialogAdapter.
Constructor signatures
Streaming behavior
assist() semantics
SuperDialogAdapter extras
Beyond the protocol,SuperDialogAdapter exposes the wrapped agent’s controls:
is_complete and state work on both engines; on the Playbook engine state
returns {"checkpoint": ..., "slots": ..., "ended": ...}. switch_flow applies
only to the legacy graph engine (a DialogMachine built from a FlowSet).
See SuperDialog for the agent itself.