Pages already gives you a visual editor with 18+ block types, data sources, actions, and theming. But starting from a blank page and wiring everything together still takes time — especially when you have a clear idea of what you want but don't want to configure each block manually.
That's what AI-powered page assembly is for.
Two Flows, One Goal
Flow 1: New Pages with AI
From the Pages list, click Guided Assembly and choose AI mode. Select the collections you want to build pages for, describe your goal in plain language, and let the AI generate a set of page proposals.
The AI has full context about your workspace — it knows your collections and their fields, triggers, compute functions, orchestrations, smart queries, and existing pages. So when you say "a customer management dashboard with an approval workflow," it generates pages that reference your real artifacts, not placeholder data.
Each proposal shows the page name, type (list, detail, form, or dashboard), and a brief rationale. You can accept individual proposals, and each accepted page is created as a draft ready for editing and publishing.
Iterative refinement is built in. After reviewing proposals, you can enter follow-up instructions like "add a kanban board grouped by status" or "include a related orders table on the detail page." The AI remembers what it already generated and what you accepted, so it builds on previous context instead of starting over.
Flow 2: Improve This Page
Already have a page? Open the editor and switch to the AI tab. Describe what you want to change — "add a chart showing orders by month" or "replace the table with a kanban view" — and the AI returns a modified definition with a summary of changes.
You get a preview showing before/after metrics (section count, block count) and can expand the full definition diff. Accept or discard as a single atomic operation.
Under the Hood
Workspace-Aware Prompts
The AI doesn't generate in a vacuum. Every generation request includes:
- Selected collections with full field definitions
- All triggers (event-driven, HTTP, scheduled) with their metadata
- Compute functions and orchestrations available for actions
- Smart queries that blocks can reference as data sources
- Existing pages (to avoid duplicate slugs and enable cross-page navigation)
This means the AI can generate a page with a button that invokes a real HTTP trigger, a data table backed by an actual collection, and navigation actions that link to existing pages — all without hallucinating references.
Validation and Auto-Fix
Every AI-generated definition goes through a semantic validator that:
- Verifies all data source references point to real collections or smart queries
- Checks that field references exist on their collections
- Validates trigger, orchestration, and page references in actions
- Auto-fixes common issues: injects missing `recordSlug` into data sources, adds `data.` prefixes to sort/filter fields, and regenerates all UUIDs
If validation fails, the system retries up to 3 times — appending the specific errors to the prompt so the AI can self-correct. Partial success is accepted: valid proposals are returned while invalid ones are discarded with error details.
Generation Logging
Every generation is logged with:
- Input: user goals, selected collections, mode (new vs. improve)
- Output: proposal count, discarded count, retry attempts
- Debugging: full system prompt, user prompt, and raw AI response
- User actions: which proposals were accepted (tracked via accept rate)
This gives you full observability into what the AI generated, why it generated it, and how often users found the output useful.
When to Use It
- Bootstrapping a new app: Select your collections, describe the app, and get a full set of CRUD pages in seconds
- Adding a dashboard: Describe the metrics and charts you need and let the AI figure out the block configuration
- Iterating on layout: Instead of manually reconfiguring blocks, describe what you want changed and accept the diff
AI page assembly is available now for workspaces with AI features enabled.