
Stars and Flakes
A conversational data modelling assistant — describe your business in plain language and an AI interviews you the way an experienced data modeller would, drawing a star schema on a live canvas as the conversation unfolds and finishing with deployable SQL for SQL Server, SparkSQL, or Fabric Warehouse.
Problem Solved
Dimensional modelling workshops are expensive. Getting from "tell me about your business" to a reviewed star schema normally takes a data modeller several sessions with business stakeholders, a whiteboard, and a lot of follow-up emails — and the resulting diagrams go stale the moment the workshop ends.
Stars and Flakes turns that workshop into a conversation with an AI. A business owner describes what they do in plain language — "I run an online bookstore" — and the assistant interviews them the way an experienced data modeller would: identifying actors, resources, and events, pinning targeted questions to each entity, and confirming assumptions before committing to structure. While the conversation flows on the left, the data model is drawn and continuously updated on a canvas on the right. By the end of the session the user has a reviewed star schema and the DDL to create it — no modeller in the room.
Key Features
Guided Five-Phase Interview
A structured survey — Discovery, Interview, Review, Schema, and Refinement — shown as a progress stepper above the chat. In Discovery the assistant learns the business narrative; in Interview it generates targeted attribute, relationship, and classification questions per entity, surfaced both as badges on the canvas and in a dedicated Questions panel. It only advances to schema design once the domain picture is confirmed.
Live Dual-Pane Canvas
Every AI response can carry structured model commands that mutate the canvas in real time — entities appear as they're mentioned, relationships form as questions are answered, and the domain model transforms into fact and dimension tables when the schema phase begins. The canvas is fully editable by hand, and an "Enhance with AI" action asks the assistant to review the whole schema and suggest additional columns.
Domain Model to Star Schema Transformation
Two synchronized representations: a business-friendly domain model (actors, resources, events, classifications) and a physical schema. At the schema phase the domain model is automatically transformed into a Kimball-style star schema — events become fact tables, actors and resources become dimensions, with surrogate keys and foreign keys generated. A toggle re-transforms the canvas between dimensional and domain-oriented schemas instantly.
One-Click SQL Generation
The finished schema exports to ready-to-run DDL in three dialects — SQL Server, SparkSQL, and Fabric Warehouse — with idempotent IF NOT EXISTS guards, typed columns, primary key constraints, and foreign key relationships. Copy to clipboard or download a .sql file directly.
Privacy-First by Design
A persistent banner warns users not to share confidential or sensitive information, and the assistant's own introduction reinforces that it wants the patterns of the business, not real data. Sessions live in the browser's localStorage by default, with optional named save/load to cloud storage, and the whole app sits behind a login gate.
Architecture
Architecture Overview
A single Next.js App Router application deployed on Vercel. The interesting work happens in the contract between the AI and the canvas: the system prompt instructs the model to emit <model_commands> tags containing JSON commands alongside its conversational reply. The API route streams the response over Server-Sent Events, separating text deltas from command payloads, so the chat bubble and the canvas update from the same response without blocking each other.
- Frontend: Next.js App Router with React 19 and Tailwind CSS; the canvas is React Flow with dagre auto-layout
- AI layer: provider-agnostic factory supporting both the Claude API (Anthropic SDK) and OpenAI, selected by environment config
- Streaming: a Server-Sent Events endpoint emitting text_delta, commands, and done chunks
- Model engine: a discriminated-union command set (add/rename/remove tables, columns, relationships) applied through a subscription-based model store decoupled from React
- Persistence: localStorage for the working session, JSON export/import, and cloud save/load via Vercel Blob
Key Decisions
Commands, not code
The AI never writes to the canvas directly — it emits declarative JSON commands validated against a discriminated union of allowed operations. A malformed or hallucinated command is rejected by the engine rather than corrupting the model, and every mutation is replayable, which is what makes session export/import and the undo-friendly store trivial.
Two models, one source of truth
Keeping a business-facing domain model separate from the physical schema doubles the bookkeeping — structural edits on the schema canvas reverse-sync into the domain model — but it means the interview happens in the business's language (customers, orders, shipments) while the output speaks the warehouse's language (fact_order, dim_customer). Users review something they understand; engineers receive something they can deploy.
Local-first persistence
Sessions persist to localStorage on every change, with cloud storage as an explicit opt-in rather than a default. For a tool that encourages people to describe their business processes, keeping data on the user's machine until they choose otherwise is the right privacy posture — and it makes the app fully usable with zero backend state.
Screenshots





Interested in something similar?
We scope, design, and ship data and AI tools that solve the problems your team actually has.
Let's Talk