Fast, concise, LLM-first Generative UI language.

Gen-UI-Lang is a compact, LLM-friendly language for describing UIs in a few readable lines. Write one UI expression and render it to HTML, React JSX, Gradio, or other targets — ideal for rapid prototyping and LLM-driven UI generation.

Tip: If Gen-UI-Lang helps you prototype faster, starring the repo is the quickest way to support it.

Elevator pitch (one expression → many targets)
genui(
  row(
    text("Sales Overview"),
    btn("Load", on_load=lambda: get_graph(2001, 2002))
  ),
  chart(type="line", data="sales_q4")
)

Compact syntax means fewer tokens, more predictable generations, and quicker iteration.

Code → UI preview instantly

Gen-UI-Lang sits in the sweet spot: human-readable, but structured enough to transform programmatically. That makes it especially effective for prototypes, demos, and LLM-driven generative UI workflows.

Think of it as an AST built from Node factories (like row, text, btn) that can be rendered to multiple targets.
Gen-UI-Lang workflow animation

Demo

A quick look at the author-once, render-everywhere experience.

Gen-UI-Lang demo animation

Why use Gen-UI-Lang?

If you’ve ever felt that HTML/JSX is too verbose for prototyping — or that LLM output gets noisy — this is built for you.

LLM-first design

Concise, predictable syntax helps models generate reliably with fewer tokens and less drift.

Multi-target output

Author once, render to HTML previews, React components, Gradio demos, and more.

Consistent cross-target language

Use the same snippet across frameworks to cut duplication and reduce cognitive load.

Quickstart

The full setup and runnable examples live in the GitHub README. Use it when you want to install, run the demo servers, or wire up an LLM.

Go to Quickstart

Open the README’s Quickstart section for the latest commands and environment notes.

Design notes & extensibility

The core idea stays small on purpose: represent UI as nodes, then write renderers for the outputs you care about.

Minimal syntax

Factory functions map directly to components (genui, row, col, card, text, btn, input, table, chart).

Extensible core

Add nodes or renderers without rewriting your UI definitions.

LLM integration

Helpers make it easy to ask an LLM to return Gen-UI-Lang snippets when available.

Make your prototypes feel instant

If Gen-UI-Lang saves you time, star the repo — it helps others find it.