# bestagentkits/design-studio-ai architecture

> Architecture diagram of the GitHub repository bestagentkits/design-studio-ai, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-06). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/bestagentkits/design-studio-ai
- Repository: https://github.com/bestagentkits/design-studio-ai

## Overview

Design Studio AI is a collaborative, agent-accessible design workspace. The main flow is brief/template-driven authoring in the web studio, revision-checked project saves, preview and export or publication; agents can work on the same versioned documents through REST, MCP, and the CLI. The graph preserves the major documented editing, generation, community, export, and observability capabilities. Some subsystem paths and links are documented or indexed rather than excerpted; those connections cite the README or SOURCE INDEX, and unsampled implementation details are not inferred.

Main entry points: [`src/app/app.tsx`](https://github.com/bestagentkits/design-studio-ai/blob/main/src/app/app.tsx) (Studio workspace), [`server/projects.ts`](https://github.com/bestagentkits/design-studio-ai/blob/main/server/projects.ts) (Project service), [`src/app/editor.tsx`](https://github.com/bestagentkits/design-studio-ai/blob/main/src/app/editor.tsx) (Manual editor), [`src/app/api.ts`](https://github.com/bestagentkits/design-studio-ai/blob/main/src/app/api.ts) (Browser API client)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_workspace["Studio workspace"]
  node_studio["Studio workspace<br/>[app.tsx]"]
  node_editor["Manual editor<br/>[editor.tsx]"]
  node_api_client["Browser API client<br/>[api.ts]"]
end

subgraph group_document["Document authoring"]
  node_document_model["Document schema<br/>[schema.ts]"]
  node_scene_authoring["3D and scene authoring<br/>[scene-authoring.ts]"]
  node_painting["Painting workspace"]
  node_design_system["Design systems<br/>[design-systems.ts]"]
end

subgraph group_services["Server services"]
  node_project_api["Project service<br/>[projects.ts]"]
  node_document_store[("Stored documents")]
  node_providers["Generation providers<br/>[providers.ts]"]
  node_observability["Activity and traces<br/>[observability.ts]"]
  node_telemetry_store[("Telemetry store")]
end

subgraph group_sharing["Sharing and export"]
  node_exports["Export service<br/>[exports.ts]"]
  node_community["Community publication"]
  node_community_api["Community routes"]
  node_community_worker["Community jobs"]
  node_community_assets[("Community assets")]
  node_google_slides["Google Slides export<br/>[google-slides.ts]"]
end

subgraph group_access["Agent access"]
  node_mcp["MCP and REST access<br/>[mcp.ts]"]
  node_cli["DSA CLI<br/>[dsa.ts]"]
end

node_person(("Designer or agent"))
node_external_provider["Text, media and speech providers"]

node_person -->|"authors in"| node_studio
node_studio -->|"opens editor"| node_editor
node_studio -->|"requests"| node_api_client
node_api_client -->|"calls REST"| node_project_api
node_project_api -->|"validates"| node_document_model
node_project_api -->|"persists revisions"| node_document_store
node_editor -->|"edits documents"| node_document_model
node_studio -.->|"selects systems"| node_design_system
node_studio -.->|"authors scenes"| node_scene_authoring
node_studio -.->|"paints artwork"| node_painting
node_person -->|"uses agent access"| node_mcp
node_person -->|"runs commands"| node_cli
node_mcp -->|"shares project access"| node_project_api
node_cli -->|"calls REST"| node_project_api
node_studio -->|"requests generation"| node_providers
node_providers -->|"calls providers"| node_external_provider
node_person -->|"requests export"| node_exports
node_exports -.->|"supports Slides"| node_google_slides
node_person -->|"browses or publishes"| node_community_api
node_community_api -->|"routes publication"| node_community
node_community -->|"queues work"| node_community_worker
node_community_worker -->|"reads and writes assets"| node_community_assets
node_studio -.->|"reports activity"| node_observability
node_observability -->|"stores events"| node_telemetry_store

click node_studio "https://github.com/bestagentkits/design-studio-ai/blob/main/src/app/app.tsx"
click node_editor "https://github.com/bestagentkits/design-studio-ai/blob/main/src/app/editor.tsx"
click node_api_client "https://github.com/bestagentkits/design-studio-ai/blob/main/src/app/api.ts"
click node_project_api "https://github.com/bestagentkits/design-studio-ai/blob/main/server/projects.ts"
click node_document_store "https://github.com/bestagentkits/design-studio-ai/blob/main/server/stored-documents.ts"
click node_document_model "https://github.com/bestagentkits/design-studio-ai/blob/main/src/shared/schema.ts"
click node_scene_authoring "https://github.com/bestagentkits/design-studio-ai/blob/main/src/shared/scene-authoring.ts"
click node_painting "https://github.com/bestagentkits/design-studio-ai/blob/main/src/app/painting-workspace.tsx"
click node_design_system "https://github.com/bestagentkits/design-studio-ai/blob/main/server/design-systems.ts"
click node_providers "https://github.com/bestagentkits/design-studio-ai/blob/main/server/providers.ts"
click node_exports "https://github.com/bestagentkits/design-studio-ai/blob/main/server/exports.ts"
click node_community "https://github.com/bestagentkits/design-studio-ai/blob/main/server/community-publication.ts"
click node_community_api "https://github.com/bestagentkits/design-studio-ai/blob/main/server/community-routes.ts"
click node_community_worker "https://github.com/bestagentkits/design-studio-ai/blob/main/server/community-worker.ts"
click node_community_assets "https://github.com/bestagentkits/design-studio-ai/blob/main/server/community-assets.ts"
click node_observability "https://github.com/bestagentkits/design-studio-ai/blob/main/server/observability.ts"
click node_telemetry_store "https://github.com/bestagentkits/design-studio-ai/blob/main/server/observability-store.ts"
click node_mcp "https://github.com/bestagentkits/design-studio-ai/blob/main/server/mcp.ts"
click node_cli "https://github.com/bestagentkits/design-studio-ai/blob/main/packages/cli/src/dsa.ts"
click node_google_slides "https://github.com/bestagentkits/design-studio-ai/blob/main/server/google-slides.ts"

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_studio,node_editor,node_api_client toneBlue
class node_document_model,node_scene_authoring,node_painting,node_design_system toneAmber
class node_project_api,node_document_store,node_providers,node_observability,node_telemetry_store toneMint
class node_exports,node_community,node_community_api,node_community_worker,node_community_assets,node_google_slides toneRose
class node_mcp,node_cli,node_person,node_external_provider toneIndigo
```

## Components

### Studio workspace

- [Studio workspace](https://github.com/bestagentkits/design-studio-ai/blob/main/src/app/app.tsx): `src/app/app.tsx`
- [Manual editor](https://github.com/bestagentkits/design-studio-ai/blob/main/src/app/editor.tsx): `src/app/editor.tsx`
- [Browser API client](https://github.com/bestagentkits/design-studio-ai/blob/main/src/app/api.ts): `src/app/api.ts`

### Document authoring

- [Document schema](https://github.com/bestagentkits/design-studio-ai/blob/main/src/shared/schema.ts): `src/shared/schema.ts`
- [3D and scene authoring](https://github.com/bestagentkits/design-studio-ai/blob/main/src/shared/scene-authoring.ts): `src/shared/scene-authoring.ts`
- [Painting workspace](https://github.com/bestagentkits/design-studio-ai/blob/main/src/app/painting-workspace.tsx): `src/app/painting-workspace.tsx`
- [Design systems](https://github.com/bestagentkits/design-studio-ai/blob/main/server/design-systems.ts): `server/design-systems.ts`

### Server services

- [Project service](https://github.com/bestagentkits/design-studio-ai/blob/main/server/projects.ts): `server/projects.ts`
- [Stored documents](https://github.com/bestagentkits/design-studio-ai/blob/main/server/stored-documents.ts): `server/stored-documents.ts`
- [Generation providers](https://github.com/bestagentkits/design-studio-ai/blob/main/server/providers.ts): `server/providers.ts`
- [Activity and traces](https://github.com/bestagentkits/design-studio-ai/blob/main/server/observability.ts): `server/observability.ts`
- [Telemetry store](https://github.com/bestagentkits/design-studio-ai/blob/main/server/observability-store.ts): `server/observability-store.ts`

### Sharing and export

- [Export service](https://github.com/bestagentkits/design-studio-ai/blob/main/server/exports.ts): `server/exports.ts`
- [Community publication](https://github.com/bestagentkits/design-studio-ai/blob/main/server/community-publication.ts): `server/community-publication.ts`
- [Community routes](https://github.com/bestagentkits/design-studio-ai/blob/main/server/community-routes.ts): `server/community-routes.ts`
- [Community jobs](https://github.com/bestagentkits/design-studio-ai/blob/main/server/community-worker.ts): `server/community-worker.ts`
- [Community assets](https://github.com/bestagentkits/design-studio-ai/blob/main/server/community-assets.ts): `server/community-assets.ts`
- [Google Slides export](https://github.com/bestagentkits/design-studio-ai/blob/main/server/google-slides.ts): `server/google-slides.ts`

### Agent access

- [MCP and REST access](https://github.com/bestagentkits/design-studio-ai/blob/main/server/mcp.ts): `server/mcp.ts`
- [DSA CLI](https://github.com/bestagentkits/design-studio-ai/blob/main/packages/cli/src/dsa.ts): `packages/cli/src/dsa.ts`

### Other components

- **Designer or agent**
- **Text, media and speech providers**

## Connections

- Designer or agent → Studio workspace: authors in
- Studio workspace → Manual editor: opens editor (evidence: `src/app/app.tsx`)
- Studio workspace → Browser API client: requests (evidence: `src/app/app.tsx`)
- Browser API client → Project service: calls REST
- Project service → Document schema: validates (evidence: `server/projects.ts`)
- Project service → Stored documents: persists revisions (evidence: `server/projects.ts`)
- Manual editor → Document schema: edits documents (evidence: `src/app/app.tsx`)
- Studio workspace → Design systems: selects systems
- Studio workspace → 3D and scene authoring: authors scenes
- Studio workspace → Painting workspace: paints artwork
- Designer or agent → MCP and REST access: uses agent access
- Designer or agent → DSA CLI: runs commands
- MCP and REST access → Project service: shares project access
- DSA CLI → Project service: calls REST
- Studio workspace → Generation providers: requests generation
- Generation providers → Text, media and speech providers: calls providers
- Designer or agent → Export service: requests export
- Export service → Google Slides export: supports Slides
- Designer or agent → Community routes: browses or publishes
- Community routes → Community publication: routes publication (evidence: `server/community-routes.ts`)
- Community publication → Community jobs: queues work (evidence: `server/community-publication.ts`)
- Community jobs → Community assets: reads and writes assets (evidence: `server/community-worker.ts`)
- Studio workspace → Activity and traces: reports activity
- Activity and traces → Telemetry store: stores events (evidence: `server/observability-routes.ts`)
