Thoughtflow
Thoughtflow lets you see inside your delegate’s thinking. After any conversation turn, you can open a visual map showing exactly how your delegate handled your request — no guesswork, no black box.

What it shows
Each diagram traces one complete response from start to finish:
- What you sent — the message your delegate received
- Which AI model was called — and when
- Which tools were used — for example, a web search or a calendar lookup
- What those tools returned — the actual data the delegate worked with
- How it reached its answer — including any time it escalated to a more powerful reasoning mode
Why it’s useful
When your delegate does something unexpected — or surprisingly good — Thoughtflow lets you understand exactly why. You can see which tool surfaced a piece of information, whether a search returned useful results, or why a response took the path it did.
How to use it
- Have a conversation with your delegate as normal.
- Open
/thoughtflow/viewerin your browser. - You’ll see a list of recent runs, newest first.
- Click any entry to open its diagram.
Each diagram is interactive — you can zoom and pan to explore the full flow.
Technical details
- Artifacts are written to
runtime-data/thoughtflow/as.d2source files plus rendered output. - Diagrams are generated in D2 format.
Viewer endpoints:
| Path | Purpose |
|---|---|
/thoughtflow/viewer |
Index of all runs |
/thoughtflow/viewer/:id |
View one run |
/thoughtflow/raw/:id.d2 |
Raw D2 source |
/thoughtflow/:id.:ext |
Rendered artifact (e.g. .svg, .png) |
Reference example diagrams (included in the repo):
detail-run1-llm.d2— a basic LLM calldetail-run2-weathercall.d2— a tool call sequencedetail-run3-memwrite.d2— a memory write
Debugging: set LEDGER_DEBUG=1 for extra structured logging from the event ledger that backs Thoughtflow.
See also: Operations → Logging.