logoalt Hacker News

I turned Markdown into a protocol for generative UI

38 pointsby FabianCarbonaratoday at 1:42 PM15 commentsview on HN

There's a lot of work happening around both generative UI and code execution for AI agents. I kept wondering: how do you bring them together into a fully featured architecture? I built a prototype:

- Markdown as protocol — one stream carrying text, executable code, and data

- Streaming execution — code fences execute statement by statement as they stream in

- A mount() primitive — the agent creates React UIs with full data flow between client, server, and LLM

Let me know what you think!


Comments

zeroqtoday at 5:40 PM

If you're still looking for a name let me suggest "hyper text".

It embodies the whole idea of having data, code and presentation at the same place.

If you're open for contributions I already have an idea for cascading styles system in mind.

show 3 replies
theturtletalkstoday at 6:11 PM

OpenUI and JSON-render are some other players in this space.

I’m building an agentic commerce chat that uses MCP-UI and want to start using these new implementations instead of MCP-UI but can’t wrap my head around how button on click and actions work? MCP-UI allows onClick events to work since you’re “hard coding” the UI from the get-go vs relying on AI generating undertemistic JSON and turning that into UI that might be different on every use.

show 1 reply
tantalortoday at 7:08 PM

The nice thing about standards is that you have so many to choose from

iusethemousetoday at 6:00 PM

There’s definitely a lot of merit to this idea, and the gifs in the article look impressive. My strong opinion is that there’s a lot more to (good) UIs than what an LLM will ever be able to bring (happy to be proven wrong in a few years…), but for utilitarian and on-the-fly UIs there’s definitely a lot of promise

show 1 reply
eightysixfourtoday at 5:38 PM

There seems to be a lot of movement in this direction, how do you feel about Markdown UI?

https://markdown-ui.com/

show 2 replies
wangmandertoday at 6:57 PM

Using markdown as the transport layer is clever because every LLM already speaks it fluently. You're not teaching the model a new format, you're just giving existing behavior a runtime.

show 1 reply