Three UI Experiences for Promptable Apps

Three UI Experiences for Promptable Apps

Building AI-promptable full-stack apps fixed the contract under the screen: every external service sits behind an interface, schemas cross boundaries with Schema.parse(), and the UI and the assistant call the same server functions. That contract still leaves a product decision open. What does a person see on first paint, and where does the prompt live?

The template answers with three UI experiences on two UX Agent Skills:

  • Side panel — PROMPT_CONCEPT=side (or unset), chrome skill promptable-ux. First paint is the domain screen; the prompt starts closed.
  • Prompt-first — PROMPT_CONCEPT=prompt-first, chrome skill promptable-ux. First paint is the conversation; drill-down lands on real routes.
  • Agentic shell — PROMPT_CONCEPT=agentic, chrome skill agentic-ux. First paint is the prompt; there are no domain screens beside it.

Ownership is layered, not mutually exclusive: agentic-ux owns the A2UI chat host (AgenticMessageItems, view tools, allowlisted catalog). promptable-ux owns route-based chrome (drawer vs bottom composer, navigation manifest, User Menu destinations). Side and prompt-first mount that same chat core inside their chrome. Touching chat surfaces on a route-based app means loading both skills.

One codebase builds all three. Each Netlify site sets one PROMPT_CONCEPT. A new app that has not chosen yet should be asked which of the three to build; scaffolding waits.

Three wireframes: a task list with chat closed behind an Open AI control, a prompt-first page with a pinned composer and a route link, and an agentic shell whose cards come from a tool result.

The server functions underneath do not change when the shell does.

What every shell inherits

The UX skills are companions of tanstack-promptable-fullstack-app-template. They place the prompt and compose the chat surface. Schemas, loaders, authorization, and the agent loop stay on the architecture skill.

Architecture diagram: side panel, prompt-first, and agentic shell all enter one chat endpoint. Auth and TraceabilityContext sit on the shared stack. Route-based shells may navigate. The agentic shell re-renders from the tool result.

Chrome is a site setting. The prompt stack, the auth ticket, and the server functions are shared.

  1. AI gate. Mount the prompt only when getAIAvailability() is true. No greyed-out composer. Route-based apps stay usable without it; agentic shows an empty configuration state.
  2. One prompt stack. /api/chat, system prompt (including a navigation manifest where routes exist), browserContext, and agentLoopStrategy: maxIterations(N). Thread state lives on the root layout.
  3. One chat core. View tools (showTasksView, showTaskView) register for every mode. Replies are Markdown (GFM) plus allowlisted A2UI when a view tool returns data. Side and prompt-first add navigate and invalidateRouter; agentic does not.
  4. Server auth. Hiding a button is presentation. Mutations use the access ticket and TraceabilityContext.
  5. User Menu. Avatar or initials opens account-only Settings. Side and prompt-first use /settings. Agentic opens an in-shell modal — not a domain route.

Route-based experiences build the navigation manifest from the router. A new screen is missing from the assistant until it is listed. Filters stay in validated search params; overview and detail share loaders. Agentic drops the manifest and path/search from browserContext; after a write it re-renders from the tool result.

Side panel

Use when browsing, filtering, and detail pages are the job. Operational consoles and admin tools belong here. Extending this template as-is uses PROMPT_CONCEPT=side.

The current route is the product. The prompt starts closed; a persistent control opens it (aria-label="Open AI chat" in the reference app). Wide viewports use a side drawer; the narrowest may cover the screen. Opening it must keep URL search state. An always-visible prompt column is the prompt-first concept — ship one surface.

In the reference app, AppLayout mounts ChatDrawer closed; Header opens it and hosts the User Menu. The panel is not an AppShell.Aside. Inside the drawer runs the shared chat core: Markdown, tool-status labels, and A2UI when a view tool fires. Every area the prompt can open also has a visible control.

Prompt-first

Use when the job starts as a question and the screen is the evidence. The composer is on screen at first paint, pinned to the bottom of the viewport.

  1. App bar — identity, location, User Menu.
  2. Conversation stage — hero or thread (Markdown, route links, same A2UI surfaces).
  3. Bottom-pinned composer — typically AppShell.Footer.
  4. Drill-down routes — /tasks, /tasks/$taskId, same loaders as the rest of the app.

Do not stack the full dashboard under the composer. When AI is off, the ordinary overview stands alone. PromptChatProvider keeps the thread and opened A2UI details across navigation; do not also mount ChatDrawer.

The enterprise property: a filtered list still has a URL. Thread links, bookmarks, and audits land on the same route.

Agentic shell

Use when the conversation is the product and a parallel information architecture would only duplicate the tools. Shareable filtered URLs and in-app navigation go away — pick this when that cost is acceptable.

The shell is identity plus User Menu, a centered column, and a bottom-pinned composer. Starters ask for views, not dashboards. A list answer is one short sentence plus the view. "My tasks" means every task; a demo visitor identity is not an assignee filter. Route-shaped markdown links become follow-up prompts — this shell has no pages.

The model returns data, not markup. There is no iframe guest document and no dangerouslySetInnerHTML from tool output.

A data-only tool result becomes an allowlisted A2UI surface in the host. Unknown component types draw nothing. The host never injects raw HTML.

Closed catalog only. Side and prompt-first mount the same host inside their chrome; they are not a second renderer.

presentation selects cards (default), table, kanban, timeline, or chart. The host maps allowlisted A2UI nodes onto Mantine 9 (useA2uiProcessor + Surface); unknown types draw nothing. This template keeps @a2ui-bridge/core and @a2ui-bridge/react and maps the catalog in-host rather than pulling @a2ui-bridge/react-mantine (Mantine 8 peers).

Host actions: open-task opens detail without another model turn; back-to-list is a prompt; toggle-select / mark-selected become a bulk-status prompt; unknown names are ignored. Validate payloads with acceptA2uiMessages, seal component ids, and keep writes on the auth ticket.

How an agent is supposed to choose

npx skills add carlosvin/tanstack-fullstack-ai-template --skill tanstack-promptable-fullstack-app-template
# Route-based (side / prompt-first): chrome + A2UI host
npx skills add carlosvin/tanstack-fullstack-ai-template --skill promptable-ux
npx skills add carlosvin/tanstack-fullstack-ai-template --skill agentic-ux
# Tool-only shell: agentic-ux is enough for chrome; add promptable-ux only when comparing concepts
The workLoad
Drawer, prompt bar, navigation manifest, User Menu destinationspromptable-ux
A2UI catalog / host, view presentations, agentic shellagentic-ux
Schemas, routes, tools, server boundariesarchitecture skill (previous post)
Packages / file pathsreference-tech-stack, AGENTS.md

Pressure checks (pnpm skills:waza): do not silently switch PROMPT_CONCEPT; ask when the experience is unclear; keep Markdown and A2UI (no plain-text flattening); do not grow domain routes beside an agentic shell.

A portfolio rule

  1. Name the primary actor and the first thing they must see: a queue, a question, or a conversation.
  2. Set PROMPT_CONCEPT and record it with the architecture decision.
  3. Install the architecture skill plus the UX skill(s) for that choice (see above).
  4. Keep schema, repository, and authorization on the architecture skill. UX skills change composition only.

Three Netlify sites from this repository are the reference: same build, three declared experiences. New domain work still follows schema → repository → server function → tool → route, plus a view tool and A2UI builder when the chat must show it. The declared shell decides whether that surface is a navigable page, a prompt drill-down, or a tool-rendered view.

Conclusion

Pick the shell for the first paint. Keep one PROMPT_CONCEPT per site. Reuse the same server functions and the same A2UI host underneath.


Built with TanStack Start, Mantine, TanStack AI, and Agent Skills from the promptable fullstack template.