Asking an agent to draw a diagram is one of the most natural things a DSH user does: the model emits a ```mermaid fenced block, and the chat surface should render it as a picture. As of 2026-09-17, the official build does not, and the community has not done it well either.
The demand
- Official Discussion #610 (16 upvotes, 2026-08-14): “Mermaid rendering, please — Codex supports it.” It is not one thread: #1065, #1135, #2711 and #3346 are the same request opened again, and #6502 (2026-09-13) calls itself “the 4th request” in its title. The same need opened six separate times is the strongest demand signal there is.
The gap
In the indexed layer (11,838 repositories, 2026-09-16 snapshot), only three names are even adjacent: MrmoLabs/dsh-mermaid (11★), zerob13/dsh-better-markdown (20★, mermaid as a side feature) and omdsh-dev/dsh-genui (439★, a heavy GenUI approach whose goal is agent-generated React interfaces, not lightweight rendering). For a user who just wants the diagram to show up, there is effectively no supply.
Proposed shape
A client-UI plugin: intercept ```mermaid fences in the message rendering pipeline, replace them with rendered SVG/Canvas, keep a “view source” toggle.
Implementation notes
- Register into the Web Client’s message-rendering extension point; the official docs docs/subsystems/slots.md and web-client.md are the entry points.
- Load mermaid.js via dynamic import on first use — never in the first-screen bundle. This is a performance red line and something reviewers check.
- On render failure, degrade to the original code block with the parse error location; never let one bad diagram blank a whole session.
The MVP
Mermaid syntax only, following the interface’s light/dark theme. One weekend.
Risks
Rendering untrusted mermaid has an XSS history: strict security mode and sandboxed output are non-negotiable, and a listing review will look at exactly this.
FAQ
Why hasn’t the official team built it?
Judging by the Discussions, official effort is on the core loop and stability; rendering features are deliberately left to the plugin ecosystem — which is what the ecosystem is for.
How is this different from dsh-genui?
GenUI wants the agent to generate entire interactive interfaces; the demand here is only “render the fenced block as a diagram” — lightweight, predictable, and covering 95% of daily needs. The two do not conflict.