# yejiming/dsh-ppt architecture

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

- Interactive diagram: https://gitdiagram.com/yejiming/dsh-ppt
- Repository: https://github.com/yejiming/dsh-ppt

## Overview

DSH PPT is a local AI-assisted presentation-generation plugin: a user request is handled through the DSH runtime and tools, then becomes an editable PPTX with supporting assets and preview/quality outputs. The README documents the main product capabilities; the source index identifies runtime and tool dependencies, but several implementation files were not excerpted, so only documented or indexed relationships are shown.

Main entry points: [`src/tools.ts`](https://github.com/yejiming/dsh-ppt/blob/main/src/tools.ts) (PPT tools), [`src/runtime.ts`](https://github.com/yejiming/dsh-ppt/blob/main/src/runtime.ts) (Workflow runtime), [`src/pptx.ts`](https://github.com/yejiming/dsh-ppt/blob/main/src/pptx.ts) (Editable PPTX), [`src/ppt-image.ts`](https://github.com/yejiming/dsh-ppt/blob/main/src/ppt-image.ts) (PPTX rendering)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_entry["Plugin entry"]
  node_plugin["Plugin registration<br/>[index.ts]"]
  node_tools["PPT tools<br/>[tools.ts]"]
  node_runtime["Workflow runtime<br/>[runtime.ts]"]
end

subgraph group_authoring["Deck authoring"]
  node_outline["Outline generation<br/>[outline.ts]"]
  node_direction["Art direction<br/>[art-direction.ts]"]
  node_images["Image search<br/>[image-search.ts]"]
  node_assets["Artifact manifest<br/>[artifacts.ts]"]
  node_html["Slide HTML<br/>[html.ts]"]
  node_fonts["Font handling<br/>[fonts.ts]"]
  node_pptx["Editable PPTX<br/>[pptx.ts]"]
end

subgraph group_render["Rendering and review"]
  node_browser["Browser runtime<br/>[browser.ts]"]
  node_pptimage["PPTX rendering<br/>[ppt-image.ts]"]
  node_office["Office renderer"]
  node_quality["Visual quality review<br/>[quality.ts]"]
end

subgraph group_foundation["Runtime foundations"]
  node_diagnostics["Diagnostics<br/>[diagnostics.ts]"]
  node_session["Session resources"]
  node_python["Python integration<br/>[python.ts]"]
  node_paths["Workspace paths<br/>[paths.ts]"]
  node_platform["Platform detection<br/>[platform.ts]"]
  node_errors["Error handling<br/>[errors.ts]"]
end

node_user(("Presentation requester"))
node_dsh["DSH runtime"]
node_output["PPTX and previews"]

node_user -->|"requests deck"| node_dsh
node_dsh -->|"loads plugin"| node_plugin
node_plugin -->|"registers tools"| node_tools
node_plugin -->|"configures runtime"| node_runtime
node_tools -->|"offers outline tools"| node_outline
node_tools -->|"offers design tools"| node_direction
node_tools -->|"offers image search"| node_images
node_images -->|"records image sources"| node_assets
node_tools -->|"offers HTML creation"| node_html
node_html -->|"uses art direction"| node_direction
node_html -->|"uses font handling"| node_fonts
node_tools -->|"offers PPTX creation"| node_pptx
node_pptx -->|"validates slide HTML"| node_html
node_pptx -->|"validates outline"| node_outline
node_pptx -->|"rasterizes elements"| node_browser
node_runtime -->|"invokes image search"| node_images
node_runtime -->|"invokes rendering"| node_pptimage
node_runtime -->|"invokes quality review"| node_quality
node_runtime -->|"uses browser runtime"| node_browser
node_runtime -->|"uses Python integration"| node_python
node_pptimage -->|"renders through"| node_office
node_quality -->|"checks PPTX"| node_pptx
node_quality -->|"compares previews"| node_pptimage
node_runtime -->|"uses diagnostics"| node_diagnostics
node_runtime -->|"manages sessions"| node_session
node_tools -->|"uses session resources"| node_session
node_pptx -->|"writes deck"| node_output
node_pptimage -->|"writes previews"| node_output
node_quality -->|"writes review report"| node_output
node_tools -->|"uses workspace paths"| node_paths
node_pptimage -->|"selects render backend"| node_platform
node_tools -->|"uses typed errors"| node_errors

click node_plugin "https://github.com/yejiming/dsh-ppt/blob/main/src/index.ts"
click node_tools "https://github.com/yejiming/dsh-ppt/blob/main/src/tools.ts"
click node_runtime "https://github.com/yejiming/dsh-ppt/blob/main/src/runtime.ts"
click node_outline "https://github.com/yejiming/dsh-ppt/blob/main/src/outline.ts"
click node_direction "https://github.com/yejiming/dsh-ppt/blob/main/src/art-direction.ts"
click node_images "https://github.com/yejiming/dsh-ppt/blob/main/src/image-search.ts"
click node_assets "https://github.com/yejiming/dsh-ppt/blob/main/src/artifacts.ts"
click node_html "https://github.com/yejiming/dsh-ppt/blob/main/src/html.ts"
click node_fonts "https://github.com/yejiming/dsh-ppt/blob/main/src/fonts.ts"
click node_pptx "https://github.com/yejiming/dsh-ppt/blob/main/src/pptx.ts"
click node_browser "https://github.com/yejiming/dsh-ppt/blob/main/src/browser.ts"
click node_pptimage "https://github.com/yejiming/dsh-ppt/blob/main/src/ppt-image.ts"
click node_quality "https://github.com/yejiming/dsh-ppt/blob/main/src/quality.ts"
click node_diagnostics "https://github.com/yejiming/dsh-ppt/blob/main/src/diagnostics.ts"
click node_session "https://github.com/yejiming/dsh-ppt/blob/main/src/session-resources.ts"
click node_python "https://github.com/yejiming/dsh-ppt/blob/main/src/python.ts"
click node_paths "https://github.com/yejiming/dsh-ppt/blob/main/src/paths.ts"
click node_platform "https://github.com/yejiming/dsh-ppt/blob/main/src/platform.ts"
click node_errors "https://github.com/yejiming/dsh-ppt/blob/main/src/errors.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_plugin,node_tools,node_runtime,node_output toneBlue
class node_outline,node_direction,node_images,node_assets,node_html,node_fonts,node_pptx toneAmber
class node_browser,node_pptimage,node_office,node_quality,node_user toneMint
class node_diagnostics,node_session,node_python,node_paths,node_platform,node_errors toneRose
class node_dsh toneIndigo
```

## Components

### Plugin entry

- [Plugin registration](https://github.com/yejiming/dsh-ppt/blob/main/src/index.ts): `src/index.ts`
- [PPT tools](https://github.com/yejiming/dsh-ppt/blob/main/src/tools.ts): `src/tools.ts`
- [Workflow runtime](https://github.com/yejiming/dsh-ppt/blob/main/src/runtime.ts): `src/runtime.ts`

### Deck authoring

- [Outline generation](https://github.com/yejiming/dsh-ppt/blob/main/src/outline.ts): `src/outline.ts`
- [Art direction](https://github.com/yejiming/dsh-ppt/blob/main/src/art-direction.ts): `src/art-direction.ts`
- [Image search](https://github.com/yejiming/dsh-ppt/blob/main/src/image-search.ts): `src/image-search.ts`
- [Artifact manifest](https://github.com/yejiming/dsh-ppt/blob/main/src/artifacts.ts): `src/artifacts.ts`
- [Slide HTML](https://github.com/yejiming/dsh-ppt/blob/main/src/html.ts): `src/html.ts`
- [Font handling](https://github.com/yejiming/dsh-ppt/blob/main/src/fonts.ts): `src/fonts.ts`
- [Editable PPTX](https://github.com/yejiming/dsh-ppt/blob/main/src/pptx.ts): `src/pptx.ts`

### Rendering and review

- [Browser runtime](https://github.com/yejiming/dsh-ppt/blob/main/src/browser.ts): `src/browser.ts`
- [PPTX rendering](https://github.com/yejiming/dsh-ppt/blob/main/src/ppt-image.ts): `src/ppt-image.ts`
- **Office renderer**
- [Visual quality review](https://github.com/yejiming/dsh-ppt/blob/main/src/quality.ts): `src/quality.ts`

### Runtime foundations

- [Diagnostics](https://github.com/yejiming/dsh-ppt/blob/main/src/diagnostics.ts): `src/diagnostics.ts`
- [Session resources](https://github.com/yejiming/dsh-ppt/blob/main/src/session-resources.ts): `src/session-resources.ts`
- [Python integration](https://github.com/yejiming/dsh-ppt/blob/main/src/python.ts): `src/python.ts`
- [Workspace paths](https://github.com/yejiming/dsh-ppt/blob/main/src/paths.ts): `src/paths.ts`
- [Platform detection](https://github.com/yejiming/dsh-ppt/blob/main/src/platform.ts): `src/platform.ts`
- [Error handling](https://github.com/yejiming/dsh-ppt/blob/main/src/errors.ts): `src/errors.ts`

### Other components

- **Presentation requester**
- **DSH runtime**
- **PPTX and previews**

## Connections

- Presentation requester → DSH runtime: requests deck (evidence: `README.md`)
- DSH runtime → Plugin registration: loads plugin (evidence: `README.md`)
- Plugin registration → PPT tools: registers tools (evidence: `src/index.ts`)
- Plugin registration → Workflow runtime: configures runtime (evidence: `src/index.ts`)
- PPT tools → Outline generation: offers outline tools (evidence: `src/tools.ts`)
- PPT tools → Art direction: offers design tools (evidence: `src/tools.ts`)
- PPT tools → Image search: offers image search (evidence: `src/tools.ts`)
- Image search → Artifact manifest: records image sources (evidence: `src/image-search.ts`)
- PPT tools → Slide HTML: offers HTML creation (evidence: `src/tools.ts`)
- Slide HTML → Art direction: uses art direction (evidence: `src/html.ts`)
- Slide HTML → Font handling: uses font handling (evidence: `src/html.ts`)
- PPT tools → Editable PPTX: offers PPTX creation (evidence: `src/tools.ts`)
- Editable PPTX → Slide HTML: validates slide HTML (evidence: `src/pptx.ts`)
- Editable PPTX → Outline generation: validates outline (evidence: `src/pptx.ts`)
- Editable PPTX → Browser runtime: rasterizes elements (evidence: `src/pptx.ts`)
- Workflow runtime → Image search: invokes image search (evidence: `src/runtime.ts`)
- Workflow runtime → PPTX rendering: invokes rendering (evidence: `src/runtime.ts`)
- Workflow runtime → Visual quality review: invokes quality review (evidence: `src/runtime.ts`)
- Workflow runtime → Browser runtime: uses browser runtime (evidence: `src/runtime.ts`)
- Workflow runtime → Python integration: uses Python integration (evidence: `src/runtime.ts`)
- PPTX rendering → Office renderer: renders through (evidence: `README.md`)
- Visual quality review → Editable PPTX: checks PPTX (evidence: `src/quality.ts`)
- Visual quality review → PPTX rendering: compares previews (evidence: `src/quality.ts`)
- Workflow runtime → Diagnostics: uses diagnostics (evidence: `src/runtime.ts`)
- Workflow runtime → Session resources: manages sessions (evidence: `src/runtime.ts`)
- PPT tools → Session resources: uses session resources (evidence: `src/tools.ts`)
- Editable PPTX → PPTX and previews: writes deck (evidence: `README.md`)
- PPTX rendering → PPTX and previews: writes previews (evidence: `README.md`)
- Visual quality review → PPTX and previews: writes review report (evidence: `README.md`)
- PPT tools → Workspace paths: uses workspace paths (evidence: `src/tools.ts`)
- PPTX rendering → Platform detection: selects render backend (evidence: `src/ppt-image.ts`)
- PPT tools → Error handling: uses typed errors (evidence: `src/tools.ts`)
