# vishwajith-gs/data-kitchen architecture

> Architecture diagram of the GitHub repository vishwajith-gs/data-kitchen, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-09-28). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/vishwajith-gs/data-kitchen
- Repository: https://github.com/vishwajith-gs/data-kitchen

## Overview

Data Kitchen is a browser-only data-preparation studio: users load CSV or Parquet data, inspect its profile, configure a guided sequence of preparation steps, preview transformations, and export the result. React keeps wizard state on the main thread and sends database requests through a message-based client to a Web Worker running DuckDB-WASM. The worker owns ingestion, profiling, transformation execution, and export operations. The sampled code confirms key transformations; README features and unsampled UI modules are represented where the tree supports them, without asserting uncertain internal wiring.

Main entry points: [`data-prep-studio/src/components/WizardStudio.tsx`](https://github.com/vishwajith-gs/data-kitchen/blob/main/data-prep-studio/src/components/WizardStudio.tsx) (Wizard studio), [`data-prep-studio/src/worker/db-worker.ts`](https://github.com/vishwajith-gs/data-kitchen/blob/main/data-prep-studio/src/worker/db-worker.ts) (Database worker), [`data-prep-studio/src/lib/db-client.ts`](https://github.com/vishwajith-gs/data-kitchen/blob/main/data-prep-studio/src/lib/db-client.ts) (Database client), [`data-prep-studio/src/App.tsx`](https://github.com/vishwajith-gs/data-kitchen/blob/main/data-prep-studio/src/App.tsx) (Application shell)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_interface["Studio interface"]
  node_app["Application shell<br/>[App.tsx]"]
  node_studio["Wizard studio<br/>[WizardStudio.tsx]"]
  node_wizard_ui["Wizard steps"]
end

subgraph group_workflow["Preparation workflow"]
  node_wizard_state["Wizard state<br/>[WizardContext.tsx]"]
  node_step_components["Preparation steps"]
  node_pipeline["Recipe compiler<br/>[pipelineEngine.ts]"]
end

subgraph group_engine["Worker engine"]
  node_db_client["Database client<br/>[db-client.ts]"]
  node_worker["Database worker<br/>[db-worker.ts]"]
  node_duckdb[("In-browser DuckDB<br/>[db-worker.ts]")]
  node_profiler["Dataset profiler<br/>[profiler.ts]"]
  node_sql_compiler["SQL compiler<br/>[sql-compiler.ts]"]
end

subgraph group_results["Preview and export"]
  node_grid["Data preview<br/>[DataGrid.tsx]"]
  node_export_ui["Export panel<br/>[ExportPanel.tsx]"]
end

node_user(("Data user"))

node_user -->|"starts session"| node_app
node_app -->|"opens studio"| node_studio
node_studio -->|"renders steps"| node_wizard_ui
node_wizard_ui -->|"selects step"| node_step_components
node_step_components -->|"saves choices"| node_wizard_state
node_studio -->|"reads history"| node_wizard_state
node_studio -->|"requests operations"| node_db_client
node_studio -->|"compiles history"| node_pipeline
node_pipeline -->|"returns recipe"| node_studio
node_db_client -->|"posts requests"| node_worker
node_worker -->|"returns results"| node_db_client
node_worker -->|"runs SQL"| node_duckdb
node_worker -->|"profiles data"| node_profiler
node_worker -->|"compiles recipe"| node_sql_compiler
node_studio -->|"shows preview"| node_grid
node_user -->|"selects file"| node_studio
node_export_ui -->|"requests export"| node_db_client

click node_app "https://github.com/vishwajith-gs/data-kitchen/blob/main/data-prep-studio/src/App.tsx"
click node_studio "https://github.com/vishwajith-gs/data-kitchen/blob/main/data-prep-studio/src/components/WizardStudio.tsx"
click node_wizard_ui "https://github.com/vishwajith-gs/data-kitchen/blob/main/data-prep-studio/src/components/Wizard/WizardContainer.tsx"
click node_wizard_state "https://github.com/vishwajith-gs/data-kitchen/blob/main/data-prep-studio/src/context/WizardContext.tsx"
click node_step_components "https://github.com/vishwajith-gs/data-kitchen/blob/main/data-prep-studio/src/components/Wizard/Steps/AdditionalSteps.tsx"
click node_pipeline "https://github.com/vishwajith-gs/data-kitchen/blob/main/data-prep-studio/src/utils/pipelineEngine.ts"
click node_db_client "https://github.com/vishwajith-gs/data-kitchen/blob/main/data-prep-studio/src/lib/db-client.ts"
click node_worker "https://github.com/vishwajith-gs/data-kitchen/blob/main/data-prep-studio/src/worker/db-worker.ts"
click node_duckdb "https://github.com/vishwajith-gs/data-kitchen/blob/main/data-prep-studio/src/worker/db-worker.ts"
click node_profiler "https://github.com/vishwajith-gs/data-kitchen/blob/main/data-prep-studio/src/worker/profiler.ts"
click node_sql_compiler "https://github.com/vishwajith-gs/data-kitchen/blob/main/data-prep-studio/src/worker/sql-compiler.ts"
click node_grid "https://github.com/vishwajith-gs/data-kitchen/blob/main/data-prep-studio/src/components/DataGrid.tsx"
click node_export_ui "https://github.com/vishwajith-gs/data-kitchen/blob/main/data-prep-studio/src/components/ExportPanel.tsx"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_app,node_studio,node_wizard_ui,node_user toneBlue
class node_wizard_state,node_step_components,node_pipeline toneAmber
class node_db_client,node_worker,node_duckdb,node_profiler,node_sql_compiler toneMint
class node_grid,node_export_ui toneRose
```

## Components

### Studio interface

- [Application shell](https://github.com/vishwajith-gs/data-kitchen/blob/main/data-prep-studio/src/App.tsx): `data-prep-studio/src/App.tsx`
- [Wizard studio](https://github.com/vishwajith-gs/data-kitchen/blob/main/data-prep-studio/src/components/WizardStudio.tsx): `data-prep-studio/src/components/WizardStudio.tsx`
- [Wizard steps](https://github.com/vishwajith-gs/data-kitchen/blob/main/data-prep-studio/src/components/Wizard/WizardContainer.tsx): `data-prep-studio/src/components/Wizard/WizardContainer.tsx`

### Preparation workflow

- [Wizard state](https://github.com/vishwajith-gs/data-kitchen/blob/main/data-prep-studio/src/context/WizardContext.tsx): `data-prep-studio/src/context/WizardContext.tsx`
- [Preparation steps](https://github.com/vishwajith-gs/data-kitchen/blob/main/data-prep-studio/src/components/Wizard/Steps/AdditionalSteps.tsx): `data-prep-studio/src/components/Wizard/Steps/AdditionalSteps.tsx`
- [Recipe compiler](https://github.com/vishwajith-gs/data-kitchen/blob/main/data-prep-studio/src/utils/pipelineEngine.ts): `data-prep-studio/src/utils/pipelineEngine.ts`

### Worker engine

- [Database client](https://github.com/vishwajith-gs/data-kitchen/blob/main/data-prep-studio/src/lib/db-client.ts): `data-prep-studio/src/lib/db-client.ts`
- [Database worker](https://github.com/vishwajith-gs/data-kitchen/blob/main/data-prep-studio/src/worker/db-worker.ts): `data-prep-studio/src/worker/db-worker.ts`
- [In-browser DuckDB](https://github.com/vishwajith-gs/data-kitchen/blob/main/data-prep-studio/src/worker/db-worker.ts): `data-prep-studio/src/worker/db-worker.ts`
- [Dataset profiler](https://github.com/vishwajith-gs/data-kitchen/blob/main/data-prep-studio/src/worker/profiler.ts): `data-prep-studio/src/worker/profiler.ts`
- [SQL compiler](https://github.com/vishwajith-gs/data-kitchen/blob/main/data-prep-studio/src/worker/sql-compiler.ts): `data-prep-studio/src/worker/sql-compiler.ts`

### Preview and export

- [Data preview](https://github.com/vishwajith-gs/data-kitchen/blob/main/data-prep-studio/src/components/DataGrid.tsx): `data-prep-studio/src/components/DataGrid.tsx`
- [Export panel](https://github.com/vishwajith-gs/data-kitchen/blob/main/data-prep-studio/src/components/ExportPanel.tsx): `data-prep-studio/src/components/ExportPanel.tsx`

### Other components

- **Data user**

## Connections

- Data user → Application shell: starts session
- Application shell → Wizard studio: opens studio
- Wizard studio → Wizard steps: renders steps
- Wizard steps → Preparation steps: selects step
- Preparation steps → Wizard state: saves choices
- Wizard studio → Wizard state: reads history
- Wizard studio → Database client: requests operations
- Wizard studio → Recipe compiler: compiles history
- Recipe compiler → Wizard studio: returns recipe
- Database client → Database worker: posts requests
- Database worker → Database client: returns results
- Database worker → In-browser DuckDB: runs SQL
- Database worker → Dataset profiler: profiles data
- Database worker → SQL compiler: compiles recipe
- Wizard studio → Data preview: shows preview
- Data user → Wizard studio: selects file
- Export panel → Database client: requests export
