Skip to main content

Install

The CLI is included when you install SuperDialog:
The default commands operate on playbooks and run on the Playbook engine. The flow sub-tree (and --mode flow) is the legacy graph path.

superdialog generate

The default creation path. Bootstrap a validated simple-format playbook from a plain-language prompt.
The output is parsed and compiled before it’s written, so anything generate produces is loadable. When to use: start every new agent here, then refine the YAML by hand.

superdialog chat

Interactive terminal chat. No infrastructure, no Unpod account, no phone number. Runs on the Playbook engine; defaults to ./playbook.yaml, then ./flow.json - any format is auto-detected.
The per-turn status line names the live checkpoint, so you can watch outcomes advance. When to use: during playbook (or legacy flow) design, prompt tuning, and eval-dataset collection - before any voice infrastructure is involved. The CLI reads OPENAI_API_KEY / ANTHROPIC_API_KEY from your environment.

The build loop

1

Generate

superdialog generate a playbook from a plain-language prompt.
2

Chat

Full end-to-end dialog in the terminal - same logic, same LLM calls, same tool execution, nothing but Python.
3

Iterate

Refine the prose, slots, and advance rules. Repeat.
4

Embed

Only once it behaves correctly, wire it into LiveKit, PipeCat, a FastAPI endpoint, or Unpod Voice Infra.

Which engine am I on?

The status line tells you: A bare --flow x.json shows the checkpoint form - flow JSON is compiled onto the Playbook engine.

REPL loop in Python

For more control - custom tools, a split Talker/Director, or to inspect the event log:
Inspect the event log. Drop to PlaybookAgent and agent.event_log.to_jsonl() is the audit artifact - every utterance, slot write, advance, and tool call, replayable offline:
Legacy graph engine in code. Construct DialogMachine(Flow.load("kyc.json"), llm=..., engine="flow", traversal_dir="./traversal_history") and drive the same loop - see Traversal history.

superdialog optimize

Reflective prose optimizer: paired persona evals score targeted, prose-only edits and emit improved YAML in your source format.
It generates persona suites, runs paired evals (before/after), makes prose-only edits to guidance / say, and writes back improved YAML. When to use: to close the run → eval → improve loop without hand-tuning prompts.

superdialog playbook

Migration and direct playbook operations.
When to use: migrating an existing flow graph to a playbook, or running a playbook explicitly.

superdialog eval

A subcommand group: the playbook-vs-vanilla A/B harness plus the legacy single-session audit. Full guide: A/B Evals.
eval run takes --modes, --agent-model, --director-model, --talker-model, --judge-model, --user-model, --metrics, and --repeats - see the A/B Evals guide. (For playbook persona evals from Python, see run_eval in the API Reference.)

superdialog benchmark

A separate RAGAS + deterministic harness: replays a dataset’s user turns at one or more models and scores raw LLM vs with-SuperDialog against ground truth in one big table.
benchmark uses the RAGAS 0.2.x line (the benchmark extra), while the A/B eval harness uses RAGAS 0.4.3 (the ragas extra). They cannot co-install - see A/B Evals → RAGAS.

Legacy: flow graphs

The flow sub-tree authors and inspects flow graphs. These still work; superdialog generate writes a playbook instead.
By default a flow JSON runs compiled onto the Playbook engine - --mode flow opts into the original graph runtime. See Flows (legacy).

Traversal history (graph engine)

Any command running the legacy graph engine supports --traversal-dir. When set, a timestamped JSON file is written per completed session capturing every node visited, every turn, and all collected slot values:
Use these files to build eval corpora, debug flow paths, and audit conversations. On the Playbook engine, the equivalent artifact is the event log (agent.event_log.to_jsonl()).