# aisland-sjl/dsh-worktable architecture

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

- Interactive diagram: https://gitdiagram.com/aisland-sjl/dsh-worktable
- Repository: https://github.com/aisland-sjl/dsh-worktable

## Overview

dsh-worktable is a Cordis plugin that adds a project drawer, dockable split workspaces, and a live control room to DeepSeek Harness. Users select or create a project, open its panes, and can bind it to a host conversation; window-task artifacts can then mount into a workspace window. The host plugin exposes filesystem, site, workspace, and terminal services. The README documents the major capabilities; sampled source supports the route and client details shown, while unsampled client behavior is represented only where documented.

Main entry points: [`01_content/src/client/index.tsx`](https://github.com/aisland-sjl/dsh-worktable/blob/main/01_content/src/client/index.tsx) (Client entry), [`01_content/src/client/split.tsx`](https://github.com/aisland-sjl/dsh-worktable/blob/main/01_content/src/client/split.tsx) (Workspace panes), [`01_content/src/index.ts`](https://github.com/aisland-sjl/dsh-worktable/blob/main/01_content/src/index.ts) (Terminal socket), [`01_content/src/client/updateCheck.ts`](https://github.com/aisland-sjl/dsh-worktable/blob/main/01_content/src/client/updateCheck.ts) (Update checker)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_client["Workbench client"]
  node_drawer["Project drawer<br/>[index.tsx]"]
  node_client["Client entry<br/>[index.tsx]"]
end

subgraph group_workspace["Workspace features"]
  node_workspace["Split workspace<br/>[split.tsx]"]
  node_panes["Workspace panes<br/>[split.tsx]"]
  node_control["Control room<br/>[index.tsx]"]
  node_windowtask["Window tasks<br/>[index.tsx]"]
  node_update["Update checker<br/>[updateCheck.ts]"]
end

subgraph group_host["Host services"]
  node_hostplugin["Host plugin<br/>[index.ts]"]
  node_api["Worktable routes<br/>[index.ts]"]
  node_terminal["Terminal socket<br/>[index.ts]"]
end

subgraph group_state["Runtime state"]
  node_storage[("Browser storage")]
  node_photo["Photo store<br/>[photoStore.ts]"]
end

node_user(("Workbench user"))
node_harness["Harness shell"]
node_filesystem["Project files"]
node_pty["PTY shell"]
node_sessionruntime["Session runtime"]
node_agent(("Harness agent"))

node_harness -->|"loads plugin"| node_hostplugin
node_harness -->|"injects client"| node_client
node_user -->|"selects projects"| node_drawer
node_drawer -->|"opens layout"| node_workspace
node_client -->|"renders drawer"| node_drawer
node_client -->|"renders room"| node_control
node_client -->|"mounts artifact"| node_windowtask
node_client -->|"subscribes snapshots"| node_sessionruntime
node_control -->|"reads snapshots"| node_sessionruntime
node_drawer -->|"opens sessions"| node_sessionruntime
node_workspace -->|"hosts panes"| node_panes
node_panes -->|"requests file services"| node_api
node_api -->|"reads and writes"| node_filesystem
node_panes -->|"opens terminal"| node_terminal
node_terminal -->|"spawns shell"| node_pty
node_terminal -->|"streams terminal data"| node_panes
node_windowtask -->|"fetches artifact"| node_api
node_agent -->|"writes task result"| node_filesystem
node_drawer -->|"persists projects"| node_storage
node_workspace -->|"persists layouts"| node_storage
node_client -->|"uses photo assets"| node_photo
node_client -->|"checks updates"| node_update
node_update -.->|"checks version"| node_harness

click node_drawer "https://github.com/aisland-sjl/dsh-worktable/blob/main/01_content/src/client/index.tsx"
click node_client "https://github.com/aisland-sjl/dsh-worktable/blob/main/01_content/src/client/index.tsx"
click node_workspace "https://github.com/aisland-sjl/dsh-worktable/blob/main/01_content/src/client/split.tsx"
click node_panes "https://github.com/aisland-sjl/dsh-worktable/blob/main/01_content/src/client/split.tsx"
click node_control "https://github.com/aisland-sjl/dsh-worktable/blob/main/01_content/src/client/index.tsx"
click node_windowtask "https://github.com/aisland-sjl/dsh-worktable/blob/main/01_content/src/client/index.tsx"
click node_hostplugin "https://github.com/aisland-sjl/dsh-worktable/blob/main/01_content/src/index.ts"
click node_api "https://github.com/aisland-sjl/dsh-worktable/blob/main/01_content/src/index.ts"
click node_terminal "https://github.com/aisland-sjl/dsh-worktable/blob/main/01_content/src/index.ts"
click node_update "https://github.com/aisland-sjl/dsh-worktable/blob/main/01_content/src/client/updateCheck.ts"
click node_photo "https://github.com/aisland-sjl/dsh-worktable/blob/main/01_content/src/client/photoStore.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_drawer,node_client,node_user toneBlue
class node_workspace,node_panes,node_control,node_windowtask,node_update toneAmber
class node_hostplugin,node_api,node_terminal toneMint
class node_storage,node_photo toneRose
class node_harness,node_filesystem,node_pty,node_sessionruntime,node_agent toneIndigo
```

## Components

### Workbench client

- [Project drawer](https://github.com/aisland-sjl/dsh-worktable/blob/main/01_content/src/client/index.tsx): `01_content/src/client/index.tsx`
- [Client entry](https://github.com/aisland-sjl/dsh-worktable/blob/main/01_content/src/client/index.tsx): `01_content/src/client/index.tsx`

### Workspace features

- [Split workspace](https://github.com/aisland-sjl/dsh-worktable/blob/main/01_content/src/client/split.tsx): `01_content/src/client/split.tsx`
- [Workspace panes](https://github.com/aisland-sjl/dsh-worktable/blob/main/01_content/src/client/split.tsx): `01_content/src/client/split.tsx`
- [Control room](https://github.com/aisland-sjl/dsh-worktable/blob/main/01_content/src/client/index.tsx): `01_content/src/client/index.tsx`
- [Window tasks](https://github.com/aisland-sjl/dsh-worktable/blob/main/01_content/src/client/index.tsx): `01_content/src/client/index.tsx`
- [Update checker](https://github.com/aisland-sjl/dsh-worktable/blob/main/01_content/src/client/updateCheck.ts): `01_content/src/client/updateCheck.ts`

### Host services

- [Host plugin](https://github.com/aisland-sjl/dsh-worktable/blob/main/01_content/src/index.ts): `01_content/src/index.ts`
- [Worktable routes](https://github.com/aisland-sjl/dsh-worktable/blob/main/01_content/src/index.ts): `01_content/src/index.ts`
- [Terminal socket](https://github.com/aisland-sjl/dsh-worktable/blob/main/01_content/src/index.ts): `01_content/src/index.ts`

### Runtime state

- **Browser storage**
- [Photo store](https://github.com/aisland-sjl/dsh-worktable/blob/main/01_content/src/client/photoStore.ts): `01_content/src/client/photoStore.ts`

### Other components

- **Workbench user**
- **Harness shell**
- **Project files**
- **PTY shell**
- **Session runtime**
- **Harness agent**

## Connections

- Harness shell → Host plugin: loads plugin
- Harness shell → Client entry: injects client
- Workbench user → Project drawer: selects projects
- Project drawer → Split workspace: opens layout
- Client entry → Project drawer: renders drawer
- Client entry → Control room: renders room
- Client entry → Window tasks: mounts artifact
- Client entry → Session runtime: subscribes snapshots
- Control room → Session runtime: reads snapshots
- Project drawer → Session runtime: opens sessions
- Split workspace → Workspace panes: hosts panes
- Workspace panes → Worktable routes: requests file services
- Worktable routes → Project files: reads and writes
- Workspace panes → Terminal socket: opens terminal
- Terminal socket → PTY shell: spawns shell
- Terminal socket → Workspace panes: streams terminal data
- Window tasks → Worktable routes: fetches artifact
- Harness agent → Project files: writes task result
- Project drawer → Browser storage: persists projects
- Split workspace → Browser storage: persists layouts
- Client entry → Photo store: uses photo assets
- Client entry → Update checker: checks updates
- Update checker → Harness shell: checks version
