Loading preview…
Loading preview…
Spreadsheet editor with AI chat for data analysis and manipulation. Edit tables through conversation.
Loading preview…
Requirements, wiring steps, and what this pattern adds to your project.
Pick how you want to pull this pattern in — then wire env vars and routes the same way.
Install from the preview toolbar
Copy the install command above and run it in your project — Pro patterns include a short-lived token.
Add environment variables to .env.local
OPENAI_API_KEY, UPSTASH_REDIS_REST_URL, UPSTASH_REDIS_REST_TOKEN
Point client fetches at your API routes
Replace preview `/view/.../api/...` paths with `/api/...` in the installed files.
Customize the agent and tool files
Adapt prompts, tools, and stop conditions for your product — Copy for AI in the toolbar helps seed that work.
Run your dev server and open the pattern route
Install dependencies if needed, then start the app and verify responses.
AI SDK APIs
streamTexttoolconvertToModelMessagesgenerateTextProviders
External services
app/page.tsxapp/layout.tsxapp/api/artifact-table/route.tscomponents/expandable-panel.tsxcomponents/panel-left-chat.tsxcomponents/chat-message-input.tsxcomponents/chat-message-list.tsxcomponents/intro-heading.tsxcomponents/panel-right-artifact.tsxcomponents/sheet-editor.tsxcomponents/table-artifact-loading.tsxcomponents/table-artifact.tsxcomponents/table-chat.tsxcomponents/table-artifact-mobile.tsxcomponents/table-artifact-context.tsxhooks/use-artifact-panel-state.tsxhooks/use-table-editor-artifact.tslib/ai/artifacts/table-editor.tslib/ai/context.tslib/ai/tools/index.tslib/ai/tools/table-editor.tslib/error-handler.tslib/ai/types.tslib/sheet-utils.tsREADME.mdnpm packages
8
Registry components
artifact-table/route.tsAPI route for the table artifact system. Uses runWithContext for AsyncLocalStorage-based context management. Implements hydrateContextFromMessages to restore previous table state. Configures streamText with tableEditor and addData tools.
tools/table-editor.tsMassive tool implementation containing addDataTool and tableEditorTool (handles create, add_column, filter_rows, sort_data, calculate, clean_data, edit_column, merge_data operations). Implements CSV parsing, column profiling, data transformations, and progressive artifact streaming.
artifacts/table-editor.tsDefines the TableEditorArtifact using the artifact() helper. Contains the comprehensive Zod schema for table editor state: title, stage, csvContent, summary, operations, version history.
ai/context.tsAsyncLocalStorage-based context management for the artifact system. Provides runWithContext, getContext, getWriter, and artifact data accessors.
lib/sheet-utils.tsCore spreadsheet utility library: CSV parsing with fallback, row normalization, Excel-style column reference resolution, filter predicate builder, value type coercion, and automatic column type detection.
Loading preview…
Early-bird pricing — limited time

Open on desktop for the interactive preview.
Spreadsheet editor with AI chat for data analysis and manipulation. Edit tables through conversation.