# ges233/equinoxeditor architecture

> Architecture diagram of the GitHub repository ges233/equinoxeditor, 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/ges233/equinoxeditor
- Repository: https://github.com/ges233/equinoxeditor

## Overview

Equinox is a singing-synthesis editor built around the Neume kernel. The main workflow is editing a project, checking and resolving interventions, then analyzing and rendering vocal tracks through a selected runtime; rendered tracks can be mixed into output. Coconut owns editing state and serialization, Neume supplies editor/runtime contracts and shared render semantics, and the DiffSinger adapter supplies voicebank analysis and synthesis. The web and Neumu layers provide interaction and project sessions. Some integration calls are not shown in the excerpts, so those links are marked unverified rather than asserted.

Main entry points: [`apps/neume_opu_ds/priv/diffsinger/worker.py`](https://github.com/ges233/equinoxeditor/blob/master/apps/neume_opu_ds/priv/diffsinger/worker.py) (Python worker), [`apps/neume_opu_ds/lib/neume_opu_ds/pipeline.ex`](https://github.com/ges233/equinoxeditor/blob/master/apps/neume_opu_ds/lib/neume_opu_ds/pipeline.ex) (DiffSinger pipeline), [`apps/neume/lib/neume/editor.ex`](https://github.com/ges233/equinoxeditor/blob/master/apps/neume/lib/neume/editor.ex) (Editor), [`apps/coconut/lib/coconut.ex`](https://github.com/ges233/equinoxeditor/blob/master/apps/coconut/lib/coconut.ex) (Edit state)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_editing["Editing core"]
  node_coconut["Edit state<br/>[coconut.ex]"]
  node_workspace["Workspace<br/>[workspace.ex]"]
  node_history["Edit history<br/>[history.ex]"]
  node_operations["Note operations"]
  node_score["Score model<br/>[note.ex]"]
  node_pickle["Serialization<br/>[command.ex]"]
  node_resolve["Render resolve<br/>[resolve.ex]"]
  node_engine["Engine dispatch<br/>[engine.ex]"]
end

subgraph group_kernel["Neume kernel"]
  node_editor["Editor<br/>[editor.ex]"]
  node_pins["Pin semantics<br/>[context.ex]"]
  node_output["Output intervention<br/>[output_pipeline.ex]"]
  node_mix["Track mixing<br/>[mix_pipeline.ex]"]
  node_mock["Mock renderer<br/>[mock_pipeline.ex]"]
end

subgraph group_runtime["DiffSinger runtime"]
  node_adapter["Coconut-Oi adapter<br/>[orchid_adapter.ex]"]
  node_ds_pipeline["DiffSinger pipeline<br/>[pipeline.ex]"]
  node_voicebank["Voicebank manifest<br/>[manifest.ex]"]
  node_worker["Python worker<br/>[worker.py]"]
  node_g2p["G2P<br/>[g2p.py]"]
  node_alignment["Phoneme alignment<br/>[alignment.py]"]
  node_openvino["OpenVINO session"]
end

subgraph group_sessions["Project sessions"]
  node_project_server["Project server<br/>[project_server.ex]"]
  node_snapshot["Project snapshot"]
  node_artifact_store[("Artifact store<br/>[artifact_store.ex]")]
end

subgraph group_web["Web interface"]
  node_project_channel["Project channel<br/>[project_channel.ex]"]
  node_board["Editor board<br/>[main.js]"]
end

node_user(("Editor user"))

node_user -.->|"edits project"| node_project_channel
node_project_channel -.->|"project commands"| node_project_server
node_project_server -.->|"uses snapshots"| node_snapshot
node_editor -.->|"uses edit model"| node_coconut
node_coconut -.->|"owns state"| node_workspace
node_workspace -.->|"tracks edits"| node_history
node_workspace -.->|"applies edits"| node_operations
node_operations -.->|"changes notes"| node_score
node_coconut -.->|"serializes state"| node_pickle
node_editor -.->|"uses pin contracts"| node_pins
node_editor -.->|"checks interventions"| node_resolve
node_resolve -.->|"dispatches render"| node_engine
node_engine -.->|"selects runtime"| node_ds_pipeline
node_engine -.->|"selects mock"| node_mock
node_adapter -.->|"adapts intervention"| node_ds_pipeline
node_ds_pipeline -.->|"loads manifest"| node_voicebank
node_ds_pipeline -.->|"executes synthesis"| node_worker
node_worker -->|"uses G2P"| node_g2p
node_worker -->|"uses alignment"| node_alignment
node_worker -->|"uses session"| node_openvino
node_output -->|"applies pins"| node_pins
node_mix -.->|"stores output"| node_artifact_store
node_project_server -.->|"stores artifacts"| node_artifact_store
node_project_channel -.->|"updates interface"| node_board
node_board -.->|"shows edits"| node_user

click node_editor "https://github.com/ges233/equinoxeditor/blob/master/apps/neume/lib/neume/editor.ex"
click node_coconut "https://github.com/ges233/equinoxeditor/blob/master/apps/coconut/lib/coconut.ex"
click node_workspace "https://github.com/ges233/equinoxeditor/blob/master/apps/coconut/lib/coconut/edit/workspace.ex"
click node_history "https://github.com/ges233/equinoxeditor/blob/master/apps/coconut/lib/coconut/edit/history.ex"
click node_operations "https://github.com/ges233/equinoxeditor/tree/master/apps/coconut/lib/coconut/edit/operations"
click node_score "https://github.com/ges233/equinoxeditor/blob/master/apps/coconut/lib/coconut/score/note.ex"
click node_pickle "https://github.com/ges233/equinoxeditor/blob/master/apps/coconut/lib/coconut/pickle/command.ex"
click node_resolve "https://github.com/ges233/equinoxeditor/blob/master/apps/coconut/lib/coconut/render/resolve.ex"
click node_engine "https://github.com/ges233/equinoxeditor/blob/master/apps/coconut/lib/coconut/render/engine.ex"
click node_pins "https://github.com/ges233/equinoxeditor/blob/master/apps/neume/lib/neume/pin/context.ex"
click node_output "https://github.com/ges233/equinoxeditor/blob/master/apps/neume/lib/neume/output_pipeline.ex"
click node_mix "https://github.com/ges233/equinoxeditor/blob/master/apps/neume/lib/neume/mix_pipeline.ex"
click node_mock "https://github.com/ges233/equinoxeditor/blob/master/apps/neume/lib/neume/engine/mock_pipeline.ex"
click node_adapter "https://github.com/ges233/equinoxeditor/blob/master/apps/coconut_oi/lib/coconut_oi/orchid_adapter.ex"
click node_ds_pipeline "https://github.com/ges233/equinoxeditor/blob/master/apps/neume_opu_ds/lib/neume_opu_ds/pipeline.ex"
click node_voicebank "https://github.com/ges233/equinoxeditor/blob/master/apps/neume_opu_ds/lib/neume_opu_ds/voicebank/manifest.ex"
click node_worker "https://github.com/ges233/equinoxeditor/blob/master/apps/neume_opu_ds/priv/diffsinger/worker.py"
click node_g2p "https://github.com/ges233/equinoxeditor/blob/master/apps/neume_opu_ds/priv/diffsinger/g2p.py"
click node_alignment "https://github.com/ges233/equinoxeditor/blob/master/apps/neume_opu_ds/priv/diffsinger/alignment.py"
click node_openvino "https://github.com/ges233/equinoxeditor/blob/master/apps/neume_opu_ds/priv/diffsinger/openvino_session.py"
click node_project_server "https://github.com/ges233/equinoxeditor/blob/master/apps/neumu/lib/neumu/project_server.ex"
click node_snapshot "https://github.com/ges233/equinoxeditor/blob/master/apps/neumu/lib/neumu/project_snapshot.ex"
click node_artifact_store "https://github.com/ges233/equinoxeditor/blob/master/apps/neumu/lib/neumu/artifact_store.ex"
click node_project_channel "https://github.com/ges233/equinoxeditor/blob/master/apps/equinox_web/lib/equinox_web/project_channel.ex"
click node_board "https://github.com/ges233/equinoxeditor/blob/master/apps/neume_lab/lib/neume_lab/board/main.js"

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_coconut,node_workspace,node_history,node_operations,node_score,node_pickle,node_resolve,node_engine,node_user toneBlue
class node_editor,node_pins,node_output,node_mix,node_mock toneAmber
class node_adapter,node_ds_pipeline,node_voicebank,node_worker,node_g2p,node_alignment,node_openvino toneMint
class node_project_server,node_snapshot,node_artifact_store toneRose
class node_project_channel,node_board toneIndigo
```

## Components

### Editing core

- [Edit state](https://github.com/ges233/equinoxeditor/blob/master/apps/coconut/lib/coconut.ex): `apps/coconut/lib/coconut.ex`
- [Workspace](https://github.com/ges233/equinoxeditor/blob/master/apps/coconut/lib/coconut/edit/workspace.ex): `apps/coconut/lib/coconut/edit/workspace.ex`
- [Edit history](https://github.com/ges233/equinoxeditor/blob/master/apps/coconut/lib/coconut/edit/history.ex): `apps/coconut/lib/coconut/edit/history.ex`
- [Note operations](https://github.com/ges233/equinoxeditor/tree/master/apps/coconut/lib/coconut/edit/operations): `apps/coconut/lib/coconut/edit/operations`
- [Score model](https://github.com/ges233/equinoxeditor/blob/master/apps/coconut/lib/coconut/score/note.ex): `apps/coconut/lib/coconut/score/note.ex`
- [Serialization](https://github.com/ges233/equinoxeditor/blob/master/apps/coconut/lib/coconut/pickle/command.ex): `apps/coconut/lib/coconut/pickle/command.ex`
- [Render resolve](https://github.com/ges233/equinoxeditor/blob/master/apps/coconut/lib/coconut/render/resolve.ex): `apps/coconut/lib/coconut/render/resolve.ex`
- [Engine dispatch](https://github.com/ges233/equinoxeditor/blob/master/apps/coconut/lib/coconut/render/engine.ex): `apps/coconut/lib/coconut/render/engine.ex`

### Neume kernel

- [Editor](https://github.com/ges233/equinoxeditor/blob/master/apps/neume/lib/neume/editor.ex): `apps/neume/lib/neume/editor.ex`
- [Pin semantics](https://github.com/ges233/equinoxeditor/blob/master/apps/neume/lib/neume/pin/context.ex): `apps/neume/lib/neume/pin/context.ex`
- [Output intervention](https://github.com/ges233/equinoxeditor/blob/master/apps/neume/lib/neume/output_pipeline.ex): `apps/neume/lib/neume/output_pipeline.ex`
- [Track mixing](https://github.com/ges233/equinoxeditor/blob/master/apps/neume/lib/neume/mix_pipeline.ex): `apps/neume/lib/neume/mix_pipeline.ex`
- [Mock renderer](https://github.com/ges233/equinoxeditor/blob/master/apps/neume/lib/neume/engine/mock_pipeline.ex): `apps/neume/lib/neume/engine/mock_pipeline.ex`

### DiffSinger runtime

- [Coconut-Oi adapter](https://github.com/ges233/equinoxeditor/blob/master/apps/coconut_oi/lib/coconut_oi/orchid_adapter.ex): `apps/coconut_oi/lib/coconut_oi/orchid_adapter.ex`
- [DiffSinger pipeline](https://github.com/ges233/equinoxeditor/blob/master/apps/neume_opu_ds/lib/neume_opu_ds/pipeline.ex): `apps/neume_opu_ds/lib/neume_opu_ds/pipeline.ex`
- [Voicebank manifest](https://github.com/ges233/equinoxeditor/blob/master/apps/neume_opu_ds/lib/neume_opu_ds/voicebank/manifest.ex): `apps/neume_opu_ds/lib/neume_opu_ds/voicebank/manifest.ex`
- [Python worker](https://github.com/ges233/equinoxeditor/blob/master/apps/neume_opu_ds/priv/diffsinger/worker.py): `apps/neume_opu_ds/priv/diffsinger/worker.py`
- [G2P](https://github.com/ges233/equinoxeditor/blob/master/apps/neume_opu_ds/priv/diffsinger/g2p.py): `apps/neume_opu_ds/priv/diffsinger/g2p.py`
- [Phoneme alignment](https://github.com/ges233/equinoxeditor/blob/master/apps/neume_opu_ds/priv/diffsinger/alignment.py): `apps/neume_opu_ds/priv/diffsinger/alignment.py`
- [OpenVINO session](https://github.com/ges233/equinoxeditor/blob/master/apps/neume_opu_ds/priv/diffsinger/openvino_session.py): `apps/neume_opu_ds/priv/diffsinger/openvino_session.py`

### Project sessions

- [Project server](https://github.com/ges233/equinoxeditor/blob/master/apps/neumu/lib/neumu/project_server.ex): `apps/neumu/lib/neumu/project_server.ex`
- [Project snapshot](https://github.com/ges233/equinoxeditor/blob/master/apps/neumu/lib/neumu/project_snapshot.ex): `apps/neumu/lib/neumu/project_snapshot.ex`
- [Artifact store](https://github.com/ges233/equinoxeditor/blob/master/apps/neumu/lib/neumu/artifact_store.ex): `apps/neumu/lib/neumu/artifact_store.ex`

### Web interface

- [Project channel](https://github.com/ges233/equinoxeditor/blob/master/apps/equinox_web/lib/equinox_web/project_channel.ex): `apps/equinox_web/lib/equinox_web/project_channel.ex`
- [Editor board](https://github.com/ges233/equinoxeditor/blob/master/apps/neume_lab/lib/neume_lab/board/main.js): `apps/neume_lab/lib/neume_lab/board/main.js`

### Other components

- **Editor user**

## Connections

- Editor user → Project channel: edits project
- Project channel → Project server: project commands
- Project server → Project snapshot: uses snapshots
- Editor → Edit state: uses edit model
- Edit state → Workspace: owns state
- Workspace → Edit history: tracks edits
- Workspace → Note operations: applies edits
- Note operations → Score model: changes notes
- Edit state → Serialization: serializes state
- Editor → Pin semantics: uses pin contracts
- Editor → Render resolve: checks interventions
- Render resolve → Engine dispatch: dispatches render (evidence: `apps/coconut/lib/coconut/render/engine.ex`)
- Engine dispatch → DiffSinger pipeline: selects runtime
- Engine dispatch → Mock renderer: selects mock
- Coconut-Oi adapter → DiffSinger pipeline: adapts intervention
- DiffSinger pipeline → Voicebank manifest: loads manifest
- DiffSinger pipeline → Python worker: executes synthesis
- Python worker → G2P: uses G2P (evidence: `apps/neume_opu_ds/priv/diffsinger/worker.py`)
- Python worker → Phoneme alignment: uses alignment (evidence: `apps/neume_opu_ds/priv/diffsinger/worker.py`)
- Python worker → OpenVINO session: uses session (evidence: `apps/neume_opu_ds/priv/diffsinger/worker.py`)
- Output intervention → Pin semantics: applies pins (evidence: `apps/neume/lib/neume/output_pipeline.ex`)
- Track mixing → Artifact store: stores output
- Project server → Artifact store: stores artifacts
- Project channel → Editor board: updates interface
- Editor board → Editor user: shows edits
