promptable-ux
Skill3 starsChanged 7 days agoMITView on GitHub
**WORKFLOW SKILL** - Shared promptable UX plus two concepts: a hidden side or bottom panel, and a prompt-first layout.
- Reads credentials
In this repository6 other files it gives its agents.
- AGENTS.mdAGENTS.md
- agentic-uxSkill
- observability-and-envSkill
- reference-tech-stackSkill
- repository-architectureSkill
- tanstack-promptable-fullstack-app-templateSkill
The file
We split this skill into the rules it gives an agent
12 rules. About 0 are common, 11 are distinctive, and 1 is very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈11
Distinctive · estimate
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 72
Read Shared UX. It applies to both concepts.
- Distinctive: line 73
Read Choose a concept. This template's reference app already declares Promptable UI (side).
- Distinctive: line 75
Run the UX checklist before a UI change.
- Distinctive: line 76
Keep routes, tools, and loaders on the architecture skill.
- Distinctive: line 101
Direct access too: Every area the prompt can open also has a visible control, so the app works before the model replies.
- Distinctive: line 107
Both color schemes: Every prompt surface and domain view works in light and dark, using theme tokens.
- Distinctive: line 126
Use a side panel on wider viewports or a bottom panel.
- Distinctive: line 127
Do not dock the prompt as a permanent column.
- Distinctive: line 150
Do not stack the rest of the application dashboard beneath the prompt input on the landing surface.
- Distinctive: line 152
Do not add a side drawer when in prompt-first mode.
- Distinctive: line 153
When AI is not configured, render the standard overview page gracefully.
- Very specific: line 198
After UX-contract changes: update this SKILL.md, run pnpm skills:check and pnpm skills:waza, and follow AGENTS.md §15 when the reference …
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Companion skills (install if missing)
This template publishes multiple skills. If only this skill is installed, add companions before related work:
tanstack-promptable-fullstack-app-template(parent) — Architecture contract: schema layers, loader-first routes, AI tools, and server boundaries. Install for every TanStack app; this skill only places the prompt.npx skills add carlosvin/tanstack-fullstack-ai-template --skill tanstack-promptable-fullstack-app-templatereference-tech-stack(companion) — Opinionated packages for this template, including the UI kit. Install when matching the demo app's widgets.npx skills add carlosvin/tanstack-fullstack-ai-template --skill reference-tech-stackobservability-and-env(companion) — Env parse, logger factories, and error-tracking bootstrap. Install when prompt work also touchesshellSession, logging, orprocess.env.npx skills add carlosvin/tanstack-fullstack-ai-template --skill observability-and-envagentic-ux(companion) — Fully agentic tool-only shell. Mantine views are declarative A2UI surfaces. Install when the deployment has no domain screens.npx skills add carlosvin/tanstack-fullstack-ai-template --skill agentic-ux
Discover all skills: npx skills add carlosvin/tanstack-fullstack-ai-template --list
Promptable UX
Purpose: One UX contract for promptable apps. Shared rules apply to every app. Two concepts differ only in where the prompt sits and what the user sees first.
Parent skill:
tanstack-promptable-fullstack-app-template— tools, loaders, URL-as-state,getAIAvailability(), boundedchat(). Do not restate that contract here.Kit recipes for this template: AGENTS.md §3 and §8, and companion
reference-tech-stack. Widget names below are the reference app. Another kit keeps the concept and swaps the widget.
Skill routing
| Task | Load |
| Which prompt concept, side panel chat, prompt bar, mobile first, assistant markdown, app navigation UX | This skill |
| Fully agentic shell, no domain screens | agentic-ux |
| Schemas, routes, AI tools, server boundaries, availability gate | tanstack-promptable-fullstack-app-template |
| Which UI library or markdown package this template uses | reference-tech-stack |
| Widget snippets and file paths in this repo | AGENTS.md §3 and §8 |
| Env, logging, error tracking | observability-and-env (do not load this skill for that) |
How to use this skill
- Read Shared UX. It applies to both concepts.
- Read Choose a concept. This template's reference app already declares Promptable UI (side). When it is not clear which user experience to implement, ask which of the three (side, prompt-first, or agentic) and wait. Record the choice so reviewers know which checklist applied.
- Implement only the chosen concept. Do not ship both prompt surfaces.
- Run the UX checklist before a UI change.
- Keep routes, tools, and loaders on the architecture skill. This skill changes composition, not the data model.
Choose a concept
| Promptable UI (side) | Prompt-first | |
| What the user sees first | The domain screen (dashboard, list, detail) | The conversation stage (hero or thread) |
| Prompt visibility | Hidden until the user opens it | Always on screen. It is the entry point |
| Panel | Side drawer, or a bottom panel. May cover a narrow viewport | Not a panel. Bottom-pinned composer (AppShell.Footer) |
| How areas are reached | App navigation, plus the prompt once opened | The prompt, markdown links, navigate, and dedicated drill-down routes |
| Best for | Data-dense apps where browsing is primary and the prompt assists | A conversation-first landing the user drills into from the prompt |
| This template | Default (PROMPT_CONCEPT=side or unset) | Second Netlify site with PROMPT_CONCEPT=prompt-first |
One concept per app. A hidden drawer plus a second always-visible prompt is a mixed concept. Do not build it.
Ask the developer which user experience to implement when it is not clear. The three experiences are Promptable UI (side) and Prompt-first in this skill, and the fully agentic shell in companion agentic-ux. Ask which of the three and wait. Do not pick one. Do not silently switch an app that already declares a concept. This template's default site stays Promptable UI (side) (PROMPT_CONCEPT=side or unset). A second site uses PROMPT_CONCEPT=prompt-first. A third site uses PROMPT_CONCEPT=agentic. Do not change those env values from this question.
Shared UX
These rules apply to both concepts. The prompt stack does not change between them.
- Promptable when configured. Mount the prompt only when
getAIAvailability()is true (architecture Core Contract #12). No disabled placeholder. When AI is off, the rest of the page stays; the prompt is absent. - One prompt stack. Both concepts use the same
/api/chatstream,buildSystemPrompt(base prompt, navigation manifest, current user, browser context),browserContext,navigateandinvalidateRouter, andmaxIterations(N). Only the chrome moves. - One prompt surface, state at the root. Conversation state mounts on the root layout so it survives route changes. Closing a panel or scrolling must not wipe the thread.
- Real routes, same loaders. Sections and views are router routes. Overview cards and drill-down pages call the same server functions as the rest of the app. No parallel data path for the prompt. The prompt presents or switches views with
navigateand markdown links. It does not invent a screen that is missing from the navigation manifest. New capabilities still follow the architecture implementation flow: schema, repository, server function, tool, route. - Direct access too. Every area the prompt can open also has a visible control, so the app works before the model replies.
- URL and prompt describe the same recoverable view. Filters, tabs, selections, bulk action status, and modal routes come from the URL path or validated search. Side-chat open state is transient chrome and starts closed. Discrete controls may navigate immediately. Debounce free-text search. Do not hide recoverable page state in
useStateor copy route state into it withuseEffect. - App navigation UX. Route and help context in the prompt comes from router introspection (
routesById, route descriptions,.describe()on search fields), not a hand-maintained map. A new user-facing route is missing until it is in that manifest. Dynamic segments need a current-location rule so "this task" resolves to the id on screen. - Mobile first (default). Progressive enhancement from small viewports up: a usable layout at the narrowest width, then richer layout as the viewport grows. This is the layout stance, not a widget. Ask the developer before leaving mobile first (desktop-first, a specialized layout). Do not silently switch. Both concepts stay mobile first. Kit tokens for this template live in AGENTS.md §3 and
reference-tech-stack. - Assistant markdown. Render assistant messages as Markdown, including GFM: lists, tables, fenced and inline code, and links. Internal paths such as
[Tasks](/tasks)stay client-navigable through the projectLink(search: true,preload="intent"). Do not flatten assistant output to plain text. The renderer package is project-specific (this repo: AGENTS.md §8). - Prompt behavior. Show tool activity as short status labels, a thinking state while the model runs, and errors in an alert. Enter sends; Shift+Enter inserts a newline. Offer stop while generating, and clear once messages exist. Suggested prompts may come from the single help document (
docs/help.md), which can also back the help route and a help tool. Filter choices and the prompt offer distinct values from the data, not a hardcoded list. - Both color schemes. Every prompt surface and domain view works in light and dark, using theme tokens. Keep one icon library.
- Auth stays on the server. Hiding a button is not a guard. Mutations stay behind the auth ticket. Chat affordances follow
aiAvailable.
Common failure modes
- Desktop-first without asking. Designing a wide layout and only later squeezing it onto a small screen.
- Mixed concepts. An always-visible prompt and a hidden drawer in the same shell.
- Chat-only views. A section that exists only as markdown in the thread, with no route.
- A second data path. Overview widgets that fetch beside the route loaders.
- Dashboard stacked under prompt. Dumping the entire traditional dashboard/table directly below a mid-page prompt input instead of giving the agentic conversation the main surface with bottom-pinned composer.
- Plain-text replies. Stripping tables, code, and internal links from assistant messages.
- Disabled prompt. Rendering a greyed-out chat when AI is not configured. Omit the prompt instead.
Promptable UI (side)
The domain UI is the product. The prompt is always reachable and hidden until the user asks for it. Use this when browsing, filtering, and detail pages are primary and the prompt assists what is already on screen. Extending this template as-is uses this concept.
- The primary surface is the current route: overview, list, or detail.
- The prompt starts closed. A persistent control on every screen opens it, including when navigation collapses on a narrow header.
- Use a side panel on wider viewports or a bottom panel. On the narrowest viewport the panel may cover the screen. Closing it returns to the same route and keeps the thread.
- Do not dock the prompt as a permanent column. A column that is always there is the prompt-first concept.
- Opening the prompt must not navigate away or drop URL search state.
- An internal link in an assistant message navigates without closing the panel or clearing the thread.
Reference app (this template): AppLayout mounts ChatDrawer closed. Header opens it (aria-label="Open AI chat"). The panel is a right-side drawer and becomes full viewport below the sm breakpoint. It is not an AppShell.Aside. Match that recipe when extending this repo. File paths and markdown CSS: AGENTS.md §3 and §8.
Prompt-first
The prompt is the primary agentic entry point. In modern agentic UX, the conversation is front and center with the composer pinned at the bottom, not stacked above a traditional cluttered dashboard. Application areas and drill-down views are accessed seamlessly through the conversation (assistant links, navigate client tools) or dedicated route navigation.
Layout and hierarchy:
- App bar — identity, current location, and navigation. Keep it clean and minimal.
- Conversation stage (main) — the agentic interaction surface. When empty, renders a clean hero state with welcome text and suggested starter prompt chips. As conversation progresses, it displays a scrollable message thread with rich Markdown, tables, and internal route links.
- Bottom-pinned composer (footer) — the prompt input is pinned at the bottom of the viewport (e.g.
AppShell.Footer), always accessible regardless of scroll position or thread length. Includes autosizing text input, send/stop button, and quick-action chips. - Dedicated drill-down surfaces — task lists, detail views, and forms live on their dedicated routes (
/tasks,/tasks/$taskId). When navigated, the user inspects or manipulates focused domain data with the prompt composer remaining pinned at the bottom (or accessible) for context-aware commands. - No stacked dashboard below prompt — do NOT render the entire app/dashboard directly below the prompt bar on the home surface. That creates visual confusion and undermines the agentic experience. When AI is not configured, fallback gracefully to the standard overview dashboard.
Rules that differ from the side concept:
- The prompt is present on first paint. Do not hide it behind a drawer or modal button.
- The prompt input is pinned to the bottom of the viewport, matching standard agentic UX patterns (ChatGPT, Claude, Cursor).
- The thread scrolls freely in the main viewport area; the composer stays docked at the bottom.
- Do not stack the rest of the application dashboard beneath the prompt input on the landing surface.
- Drill-down routes (
/tasks, etc.) remain full-fledged routes with shared loaders and navigation. - Do not add a side drawer when in prompt-first mode. One chat shell.
- When AI is not configured, render the standard overview page gracefully.
This template implements prompt-first when PROMPT_CONCEPT=prompt-first (see shellSession.promptConcept, PromptBar, shared PromptChatProvider). Wire the prompt composer and thread to the same /api/chat endpoint and client tools as the side drawer.
Minimal file shape (adapt to the project)
PromptChatProvider/ shared hook: manages chat thread state and opened A2UI detail views across route changes (clear both together).PromptBar/ChatComposer: bottom-pinned input bar (typically inAppShell.Footer) with autosizing input, submit/stop, and suggestion chips.ChatThread/PromptThread: full-height scrollable message thread with empty-state hero and suggestion chips.- One chat shell per app: no
Drawerfor chat in apps that commit to prompt-first. If a migration needs both temporarily, say so explicitly and remove the drawer before calling the migration done.
Switching & coexistence: extending the agentic chat core across side and prompt-first
The two route-based concepts (prompt-first and side) are extensions of the fully agentic dynamic chat component (companion agentic-ux). Every AI chat panel in the codebase renders dynamic A2UI surfaces (AgenticA2uiSurface) alongside assistant markdown:
- Shared dynamic chat rendering (
src/components/AgenticShell/AgenticThread.tsx,src/components/PromptChat/ChatThread.tsx):ChatThreadreusesAgenticMessageItemsfromAgenticThread, soshowTasksViewandshowTaskViewrender interactive cards, tables, kanban lanes, timelines, and single-click detail views inside bothChatDrawer(side) andPromptFirstLanding(prompt-first). - Shared route-aware chat context (
src/components/PromptChat/PromptChatContext.tsx): Bothsideandprompt-firstmountPromptChatProvideronce inAppLayoutwhenaiAvailableis true. It ownsuseInlineDetailViews(so opened details survive prompt-first remounts), router-awarebrowserContextcapture, and clientnavigate/invalidateRoutertools. - Shared composer & presentation (
src/components/PromptChat/):ChatComposer(usingfriendlyChatError),ChatThread,MessageBubble,MarkdownLink,toolLabels, andPromptChat.module.cssare reused unchanged by both route-based shells. - Concept-specific chrome only:
sidemountsChatDrawer(ChatThread+ChatComposerinside a rightDrawer) and opens it fromHeader.prompt-firstmountsPromptBarinAppShell.Footer(ChatComposerwithonAfterSubmitnavigating to/when on a drill-down route) and rendersPromptFirstLanding(PromptFirstHerowhenmessages.length === 0,ChatThreadonce the conversation starts) on/.
UX checklist
- Concept chosen with the developer. When it is not clear which user experience to implement, ask which of the three (side, prompt-first, or agentic) and wait. This repo's sites keep their declared
PROMPT_CONCEPT. getAIAvailability()gates the prompt. No disabled placeholder.- Chat state lives on the layout and survives navigation.
- Assistant output is GFM markdown. Internal links use the project
Link. - Navigation manifest covers every user-facing route, including "this item" on dynamic routes.
- Filters and tabs use
validateSearchandloaderDeps. Free-text search is debounced. - Overview and drill-down read the same loaders. No second fetch path.
- Narrow layout and both color schemes checked.
- Mutations stay server-guarded.
invalidateRouterruns after writes.
What stays on other skills
| Concern | Where it lives |
getAIAvailability() gate, tool coverage, agent loop | Architecture Core Contract #11–#13 |
| Routes, loaders, URL search, debounced search | Architecture Core Contract #7–#8 and Special Patterns |
| Markdown package and CSS for this repo | AGENTS.md §8; reference-tech-stack |
| Breakpoint props for this repo | AGENTS.md §3; reference-tech-stack |
Verification
After UX-contract changes: update this SKILL.md, run pnpm skills:check and pnpm skills:waza, and follow AGENTS.md §15 when the reference shell changes.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

