# tutur3u/platform architecture

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

- Interactive diagram: https://gitdiagram.com/tutur3u/platform
- Repository: https://github.com/tutur3u/platform

## Overview

Tuturuuu is a multi-product workspace: users enter through the Apps launcher or the central Platform, then use separate products for work and life. The README describes shared account sessions and shared packages, while the source index identifies representative API, storage, workflow, habits, education, and SDK layers. The graph preserves those documented product boundaries and sampled core modules; it does not infer calls between unsampled applications or claim a single end-to-end runtime pipeline.

Main entry points: [`apps/api/src/pipeline.ts`](https://github.com/tutur3u/platform/blob/main/apps/api/src/pipeline.ts) (Request pipeline), [`apps/web`](https://github.com/tutur3u/platform/tree/main/apps/web) (Platform app), [`apps/hive/src/lib/hive/workflow-engine.ts`](https://github.com/tutur3u/platform/blob/main/apps/hive/src/lib/hive/workflow-engine.ts) (Hive workflows), [`apps/apps/src/lib/apps-registry.ts`](https://github.com/tutur3u/platform/blob/main/apps/apps/src/lib/apps-registry.ts) (Apps launcher)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_entry["Entry points"]
  node_launcher["Apps launcher<br/>[apps-registry.ts]"]
  node_platform["Platform app"]
end

subgraph group_products["Workspace products"]
  node_satellites["Product apps"]
  node_mobile["Mobile client"]
end

subgraph group_services["Shared services"]
  node_api["API service<br/>[worker.ts]"]
  node_api_pipeline["Request pipeline<br/>[pipeline.ts]"]
  node_api_authorization["Authorization<br/>[authorization.ts]"]
  node_api_contracts["API contracts<br/>[contracts.ts]"]
  node_api_registry["Route registry<br/>[registry.ts]"]
  node_storage_provider[("Workspace storage")]
end

subgraph group_domains["Product domains"]
  node_habits["Habit tracking<br/>[page-client.tsx]"]
  node_tracker_parts["Tracker views<br/>[tracker-card.tsx]"]
  node_tracker_shared["Tracker helpers<br/>[tracker-shared.tsx]"]
  node_teach_modules["Teaching courses"]
  node_course_card["Course cards"]
  node_hive_workflows["Hive workflows<br/>[workflow-engine.ts]"]
  node_workflow_types["Workflow types<br/>[workflow-types.ts]"]
  node_world_patch["World patching"]
end

subgraph group_libraries["Shared libraries"]
  node_internal_api["Internal API client<br/>[client.ts]"]
  node_sdk["Platform SDK<br/>[epm.ts]"]
  node_sdk_storage["Storage SDK<br/>[storage.ts]"]
  node_task_queries["Task queries"]
end

node_user(("Workspace user"))

node_user -->|"opens products"| node_launcher
node_launcher -->|"launches products"| node_satellites
node_user -->|"uses workspace"| node_platform
node_platform -->|"shares account session"| node_satellites
node_mobile -.->|"workspace client"| node_platform
node_api_pipeline -->|"enforces access"| node_api_authorization
node_api_pipeline -->|"uses definitions"| node_api_contracts
node_api_pipeline -->|"dispatches routes"| node_api_registry
node_api_pipeline -.->|"serves requests"| node_api
node_habits -->|"renders trackers"| node_tracker_parts
node_tracker_parts -->|"uses helpers"| node_tracker_shared
node_teach_modules -->|"renders courses"| node_course_card
node_hive_workflows -->|"uses types"| node_workflow_types
node_hive_workflows -->|"applies patches"| node_world_patch
node_sdk -.->|"exposes storage"| node_sdk_storage
node_internal_api -.->|"serves task requests"| node_task_queries
node_platform -.->|"uses shared storage"| node_storage_provider

click node_launcher "https://github.com/tutur3u/platform/blob/main/apps/apps/src/lib/apps-registry.ts"
click node_platform "https://github.com/tutur3u/platform/tree/main/apps/web"
click node_satellites "https://github.com/tutur3u/platform/tree/main/apps"
click node_mobile "https://github.com/tutur3u/platform/tree/main/apps/mobile"
click node_api "https://github.com/tutur3u/platform/blob/main/apps/api/src/worker.ts"
click node_api_pipeline "https://github.com/tutur3u/platform/blob/main/apps/api/src/pipeline.ts"
click node_api_authorization "https://github.com/tutur3u/platform/blob/main/apps/api/src/authorization.ts"
click node_api_contracts "https://github.com/tutur3u/platform/blob/main/apps/api/src/contracts.ts"
click node_api_registry "https://github.com/tutur3u/platform/blob/main/apps/api/src/registry.ts"
click node_storage_provider "https://github.com/tutur3u/platform/blob/main/packages/storage-core/src/lib/workspace-storage-provider.ts"
click node_habits "https://github.com/tutur3u/platform/blob/main/apps/tanstack-web/src/components/habits/page-client.tsx"
click node_tracker_parts "https://github.com/tutur3u/platform/blob/main/apps/tanstack-web/src/components/habits/tracker-card.tsx"
click node_tracker_shared "https://github.com/tutur3u/platform/blob/main/apps/tanstack-web/src/components/habits/tracker-shared.tsx"
click node_teach_modules "https://github.com/tutur3u/platform/blob/main/apps/teach/src/components/modules/modules-page-client.tsx"
click node_course_card "https://github.com/tutur3u/platform/blob/main/apps/teach/src/components/modules/course-group-card.tsx"
click node_hive_workflows "https://github.com/tutur3u/platform/blob/main/apps/hive/src/lib/hive/workflow-engine.ts"
click node_workflow_types "https://github.com/tutur3u/platform/blob/main/apps/hive/src/lib/hive/workflow-types.ts"
click node_world_patch "https://github.com/tutur3u/platform/blob/main/apps/hive/src/lib/hive/workflow-world-patch.ts"
click node_internal_api "https://github.com/tutur3u/platform/blob/main/packages/internal-api/src/client.ts"
click node_sdk "https://github.com/tutur3u/platform/blob/main/packages/sdk/src/epm.ts"
click node_sdk_storage "https://github.com/tutur3u/platform/blob/main/packages/sdk/src/storage.ts"
click node_task_queries "https://github.com/tutur3u/platform/blob/main/packages/tasks-ui/src/tu-do/my-tasks/use-my-tasks-query.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_launcher,node_platform,node_user toneBlue
class node_satellites,node_mobile toneAmber
class node_api,node_api_pipeline,node_api_authorization,node_api_contracts,node_api_registry,node_storage_provider toneMint
class node_habits,node_tracker_parts,node_tracker_shared,node_teach_modules,node_course_card,node_hive_workflows,node_workflow_types,node_world_patch toneRose
class node_internal_api,node_sdk,node_sdk_storage,node_task_queries toneIndigo
```

## Components

### Entry points

- [Apps launcher](https://github.com/tutur3u/platform/blob/main/apps/apps/src/lib/apps-registry.ts): `apps/apps/src/lib/apps-registry.ts`
- [Platform app](https://github.com/tutur3u/platform/tree/main/apps/web): `apps/web`

### Workspace products

- [Product apps](https://github.com/tutur3u/platform/tree/main/apps): `apps`
- [Mobile client](https://github.com/tutur3u/platform/tree/main/apps/mobile): `apps/mobile`

### Shared services

- [API service](https://github.com/tutur3u/platform/blob/main/apps/api/src/worker.ts): `apps/api/src/worker.ts`
- [Request pipeline](https://github.com/tutur3u/platform/blob/main/apps/api/src/pipeline.ts): `apps/api/src/pipeline.ts`
- [Authorization](https://github.com/tutur3u/platform/blob/main/apps/api/src/authorization.ts): `apps/api/src/authorization.ts`
- [API contracts](https://github.com/tutur3u/platform/blob/main/apps/api/src/contracts.ts): `apps/api/src/contracts.ts`
- [Route registry](https://github.com/tutur3u/platform/blob/main/apps/api/src/registry.ts): `apps/api/src/registry.ts`
- [Workspace storage](https://github.com/tutur3u/platform/blob/main/packages/storage-core/src/lib/workspace-storage-provider.ts): `packages/storage-core/src/lib/workspace-storage-provider.ts`

### Product domains

- [Habit tracking](https://github.com/tutur3u/platform/blob/main/apps/tanstack-web/src/components/habits/page-client.tsx): `apps/tanstack-web/src/components/habits/page-client.tsx`
- [Tracker views](https://github.com/tutur3u/platform/blob/main/apps/tanstack-web/src/components/habits/tracker-card.tsx): `apps/tanstack-web/src/components/habits/tracker-card.tsx`
- [Tracker helpers](https://github.com/tutur3u/platform/blob/main/apps/tanstack-web/src/components/habits/tracker-shared.tsx): `apps/tanstack-web/src/components/habits/tracker-shared.tsx`
- [Teaching courses](https://github.com/tutur3u/platform/blob/main/apps/teach/src/components/modules/modules-page-client.tsx): `apps/teach/src/components/modules/modules-page-client.tsx`
- [Course cards](https://github.com/tutur3u/platform/blob/main/apps/teach/src/components/modules/course-group-card.tsx): `apps/teach/src/components/modules/course-group-card.tsx`
- [Hive workflows](https://github.com/tutur3u/platform/blob/main/apps/hive/src/lib/hive/workflow-engine.ts): `apps/hive/src/lib/hive/workflow-engine.ts`
- [Workflow types](https://github.com/tutur3u/platform/blob/main/apps/hive/src/lib/hive/workflow-types.ts): `apps/hive/src/lib/hive/workflow-types.ts`
- [World patching](https://github.com/tutur3u/platform/blob/main/apps/hive/src/lib/hive/workflow-world-patch.ts): `apps/hive/src/lib/hive/workflow-world-patch.ts`

### Shared libraries

- [Internal API client](https://github.com/tutur3u/platform/blob/main/packages/internal-api/src/client.ts): `packages/internal-api/src/client.ts`
- [Platform SDK](https://github.com/tutur3u/platform/blob/main/packages/sdk/src/epm.ts): `packages/sdk/src/epm.ts`
- [Storage SDK](https://github.com/tutur3u/platform/blob/main/packages/sdk/src/storage.ts): `packages/sdk/src/storage.ts`
- [Task queries](https://github.com/tutur3u/platform/blob/main/packages/tasks-ui/src/tu-do/my-tasks/use-my-tasks-query.ts): `packages/tasks-ui/src/tu-do/my-tasks/use-my-tasks-query.ts`

### Other components

- **Workspace user**

## Connections

- Workspace user → Apps launcher: opens products
- Apps launcher → Product apps: launches products
- Workspace user → Platform app: uses workspace
- Platform app → Product apps: shares account session
- Mobile client → Platform app: workspace client
- Request pipeline → Authorization: enforces access (evidence: `apps/api/src/pipeline.ts`)
- Request pipeline → API contracts: uses definitions (evidence: `apps/api/src/pipeline.ts`)
- Request pipeline → Route registry: dispatches routes (evidence: `apps/api/src/pipeline.ts`)
- Request pipeline → API service: serves requests
- Habit tracking → Tracker views: renders trackers (evidence: `apps/tanstack-web/src/components/habits/page-client.tsx`)
- Tracker views → Tracker helpers: uses helpers (evidence: `apps/tanstack-web/src/components/habits/tracker-card.tsx`)
- Teaching courses → Course cards: renders courses (evidence: `apps/teach/src/components/modules/modules-page-client.tsx`)
- Hive workflows → Workflow types: uses types (evidence: `apps/hive/src/lib/hive/workflow-engine.ts`)
- Hive workflows → World patching: applies patches (evidence: `apps/hive/src/lib/hive/workflow-engine.ts`)
- Platform SDK → Storage SDK: exposes storage (evidence: `packages/sdk/src/storage.ts`)
- Internal API client → Task queries: serves task requests
- Platform app → Workspace storage: uses shared storage
