• Hacker News
  • new|
  • comments|
  • show|
  • ask|
  • jobs|
  • tantalor 20 minutes

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

  • 1 hours

  • theturtletalks 1 hours

    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.

    FabianCarbonara 1 hours

    In my approach, callbacks are first-class. The agent defines server-side functions and passes them to the UI:

      const onRefresh = async () => {
        data.loading = true;
        data.messages = await loadMessages();
        data.loading = false;
      };
    
      mount({
        data,
        callbacks: { onRefresh },
        ui: ({ data, callbacks }) => (
          <Button onClick={callbacks.onRefresh}>Refresh</Button>
        )
      });
    
    When the user clicks the button, it invokes the server-side function. The callback fetches fresh data, updates state via reactive proxies, and the UI reflects it — all without triggering a new LLM turn.

    So the UI is generated dynamically by the LLM, but the interactions are real server-side code, not just display. Forms work the same way — "await form.result" pauses execution until the user submits.

    The article has a full walkthrough of the four data flow patterns (forms, live updates, streaming data, callbacks) with demos.

  • 5 hours

  • eightysixfour 1 hours

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

    https://markdown-ui.com/

    FabianCarbonara 1 hours

    Markdown UI and my approach share the "markdown as the medium" insight, but they're fundamentally different bets:

    Markdown UI is declarative — you embed predefined widget types in markdown. The LLM picks from a catalog. It's clean and safe, but limited to what the catalog supports.

    My approach is code-based — the LLM writes executable TypeScript in markdown code fences, which runs on the server and can render any React UI. It also has server-side state, so the UI can do forms, callbacks, and streaming data — not just display widgets.

    threatofrain 1 hours

    I'd much prefer MDX.

  • wangmander 31 minutes

    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.

    Retr0id 21 minutes

    What's the going rate these days for decade-old HN accounts to repurpose as AI spambots?

  • iusethemouse 1 hours

    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

    FabianCarbonara 1 hours

    [dead]

  • zeroq 1 hours

    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.

    noman-land 9 minutes

    If HTML happened again except this time it was markdown, maybe more non-nerds would be able to use it? XML just looks gnarly.

    FabianCarbonara 58 minutes

    Ha, history does rhyme ;) Happy if you reach out via mail!

    heckintime 19 minutes

    I think he's talking about CSS

    altruios 1 hours

    Every turn of the wheel someone wants to make a new one.

    Maybe one day someone will invent a rounder wheel.

    doublerabbit 1 minutes

    Personally I think we should move to Heptagons. They're round enough. The wheel is a little bit par-se.