A developer known as Michaelliv has reverse-engineered Claude.ai's proprietary generative UI system and rebuilt it as a plugin for Pi, the open-source coding agent created by Mario Zechner. Published on GitHub, the project replicates the two internal tool calls — `show_widget` and `read_me` — that power Claude.ai's live widget rendering, allowing Pi to stream interactive HTML visualizations directly into a native macOS window. The extraction required no security breach; everything came through a feature available to any Claude subscriber.
When users trigger Claude's generative UI, the `read_me` tool fetches Anthropic's internal design guidelines and returns them as part of the tool call payload — a payload that is fully preserved when a conversation is exported as JSON through Claude.ai's account settings. By systematically triggering each guideline module (`interactive`, `chart`, `mockup`, `art`, and `diagram`) and exporting the results, Michaelliv assembled 72KB of Anthropic production rules covering typography, streaming-safe CSS, Chart.js configuration, SVG diagram engineering, and more. Four of the five modules were extracted in full; the fifth was only partially recovered. These guidelines now ship with the Pi extension as `guidelines.ts`.
Streaming LLM output is intercepted at Pi's event layer (`toolcall_start`, `toolcall_delta`, `toolcall_end`) and piped into a native macOS WKWebView window via Glimpse — a lightweight Swift micro-UI library that opens a WebView in under 50ms with no Electron dependency. The morphdom DOM-diffing library patches only changed nodes as tokens arrive, with new elements fading in over 0.3 seconds. A 150ms debounce batches rapid token updates, and JavaScript libraries like Chart.js and D3 are deferred until `toolcall_end` to prevent partial-execution errors.
Glimpse's bidirectional JSON Lines bridge takes the system beyond passive rendering: widgets can send data back to the agent via `window.glimpse.send()`, making them genuinely interactive — charts that respond to input, sliders that adjust parameters in real time — rather than rendered previews.
The project points to a specific blind spot in how AI products handle tool-call data. Anthropic never published its generative UI design system, but it ships the rules implicitly with every widget-enabled conversation, and the export feature preserves them verbatim. The payload was always user-accessible; it just hadn't been examined. It's an oversight that almost certainly applies to other products built on the same pattern.