# soundwave-machine-learning/smlstarnet architecture

> Architecture diagram of the GitHub repository soundwave-machine-learning/smlstarnet, 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/soundwave-machine-learning/smlstarnet
- Repository: https://github.com/soundwave-machine-learning/smlstarnet

## Overview

StarNet is a local-first desktop harness for creating AI-agent teams and running real work through them. The principal flow is: a person gives the station work; the frontend can route it through a spatial belt plan to an agent; the local sidecar runs the agent with model and tool access; completed files appear in the OUTBOX, while runtime state is projected in the station UI. The README documents these boundaries and capabilities, but the supplied source excerpts do not include the sidecar entry point or most frontend wiring, so uncertain call-level links are omitted.

Main entry points: [`sidecar`](https://github.com/soundwave-machine-learning/smlstarnet/tree/feat/harness-backend/sidecar) (Local sidecar), [`src-tauri/src/main.rs`](https://github.com/soundwave-machine-learning/smlstarnet/blob/feat/harness-backend/src-tauri/src/main.rs) (Desktop shell), [`frontend/app/workhub.js`](https://github.com/soundwave-machine-learning/smlstarnet/blob/feat/harness-backend/frontend/app/workhub.js) (Work interface), [`frontend/app/app.js`](https://github.com/soundwave-machine-learning/smlstarnet/blob/feat/harness-backend/frontend/app/app.js) (Station app)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_station["Station UI"]
  node_desktop["Desktop shell<br/>[main.rs]"]
  node_app["Station app<br/>[app.js]"]
  node_world["Station world<br/>[world.js]"]
  node_workui["Work interface<br/>[workhub.js]"]
  node_outbox["Deliverables<br/>[deliverables.js]"]
end

subgraph group_work["Work orchestration"]
  node_routing["Belt routing plan<br/>[pipeline.js]"]
  node_agentsetup["Agent setup<br/>[onboarding.js]"]
  node_recipes["Recipes and skills<br/>[recipes.js]"]
  node_schedules["Scheduled work<br/>[autojobs.js]"]
  node_briefs["Task briefs<br/>[intake.js]"]
end

subgraph group_runtime["Agent runtime"]
  node_sidecar["Local sidecar"]
  node_providers["Model providers"]
  node_tools["Agent tools"]
  node_mcp["MCP connectors<br/>[manager.js]"]
  node_channels["Message channels<br/>[channels.js]"]
  node_voice["Voice interaction<br/>[voice.js]"]
end

subgraph group_state["State and integrations"]
  node_persistence[("Local persistence<br/>[save.js]")]
  node_ledgers[("Run and spend ledgers<br/>[recledger.js]")]
  node_stationstate["Station projection<br/>[worldrenderer.js]"]
end

node_person(("Station user"))
node_modelservice["Model services"]
node_externalchannels["Chat services"]
node_localtools["Local and network tools"]

node_person -->|"opens"| node_desktop
node_desktop -->|"starts"| node_sidecar
node_desktop -->|"opens webview"| node_app
node_person -->|"uses"| node_app
node_app -->|"presents work"| node_workui
node_workui -->|"captures task"| node_briefs
node_workui -->|"configures routes"| node_routing
node_agentsetup -->|"configures agents"| node_sidecar
node_recipes -->|"launches work"| node_sidecar
node_schedules -->|"schedules runs"| node_sidecar
node_sidecar -->|"resolves target"| node_routing
node_sidecar -->|"requests inference"| node_providers
node_providers -->|"calls models"| node_modelservice
node_sidecar -->|"dispatches tools"| node_tools
node_tools -->|"operates through"| node_localtools
node_sidecar -.->|"uses connectors"| node_mcp
node_mcp -.->|"exposes tools"| node_localtools
node_person -.->|"messages remotely"| node_channels
node_channels -.->|"delivers messages"| node_sidecar
node_person -->|"dictates"| node_voice
node_sidecar -->|"persists state"| node_persistence
node_sidecar -->|"records runs and spend"| node_ledgers
node_sidecar -->|"publishes deliverables"| node_outbox
node_sidecar -->|"emits runtime state"| node_stationstate
node_stationstate -->|"projects state"| node_world
node_outbox -->|"offers files"| node_person

click node_desktop "https://github.com/soundwave-machine-learning/smlstarnet/blob/feat/harness-backend/src-tauri/src/main.rs"
click node_app "https://github.com/soundwave-machine-learning/smlstarnet/blob/feat/harness-backend/frontend/app/app.js"
click node_world "https://github.com/soundwave-machine-learning/smlstarnet/blob/feat/harness-backend/frontend/app/world.js"
click node_workui "https://github.com/soundwave-machine-learning/smlstarnet/blob/feat/harness-backend/frontend/app/workhub.js"
click node_outbox "https://github.com/soundwave-machine-learning/smlstarnet/blob/feat/harness-backend/frontend/app/deliverables.js"
click node_routing "https://github.com/soundwave-machine-learning/smlstarnet/blob/feat/harness-backend/frontend/app/pipeline.js"
click node_agentsetup "https://github.com/soundwave-machine-learning/smlstarnet/blob/feat/harness-backend/frontend/app/onboarding.js"
click node_recipes "https://github.com/soundwave-machine-learning/smlstarnet/blob/feat/harness-backend/frontend/app/recipes.js"
click node_schedules "https://github.com/soundwave-machine-learning/smlstarnet/blob/feat/harness-backend/frontend/app/autojobs.js"
click node_briefs "https://github.com/soundwave-machine-learning/smlstarnet/blob/feat/harness-backend/frontend/app/intake.js"
click node_sidecar "https://github.com/soundwave-machine-learning/smlstarnet/tree/feat/harness-backend/sidecar"
click node_providers "https://github.com/soundwave-machine-learning/smlstarnet/tree/feat/harness-backend/sidecar"
click node_tools "https://github.com/soundwave-machine-learning/smlstarnet/tree/feat/harness-backend/sidecar"
click node_mcp "https://github.com/soundwave-machine-learning/smlstarnet/blob/feat/harness-backend/sidecar/mcp/manager.js"
click node_channels "https://github.com/soundwave-machine-learning/smlstarnet/blob/feat/harness-backend/frontend/app/channels.js"
click node_voice "https://github.com/soundwave-machine-learning/smlstarnet/blob/feat/harness-backend/frontend/app/voice.js"
click node_persistence "https://github.com/soundwave-machine-learning/smlstarnet/blob/feat/harness-backend/frontend/app/save.js"
click node_ledgers "https://github.com/soundwave-machine-learning/smlstarnet/blob/feat/harness-backend/frontend/app/recledger.js"
click node_stationstate "https://github.com/soundwave-machine-learning/smlstarnet/blob/feat/harness-backend/frontend/app/worldrenderer.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_desktop,node_app,node_world,node_workui,node_outbox,node_person toneBlue
class node_routing,node_agentsetup,node_recipes,node_schedules,node_briefs toneAmber
class node_sidecar,node_providers,node_tools,node_mcp,node_channels,node_voice toneMint
class node_persistence,node_ledgers,node_stationstate toneRose
class node_modelservice,node_externalchannels,node_localtools toneIndigo
```

## Components

### Station UI

- [Desktop shell](https://github.com/soundwave-machine-learning/smlstarnet/blob/feat/harness-backend/src-tauri/src/main.rs): `src-tauri/src/main.rs`
- [Station app](https://github.com/soundwave-machine-learning/smlstarnet/blob/feat/harness-backend/frontend/app/app.js): `frontend/app/app.js`
- [Station world](https://github.com/soundwave-machine-learning/smlstarnet/blob/feat/harness-backend/frontend/app/world.js): `frontend/app/world.js`
- [Work interface](https://github.com/soundwave-machine-learning/smlstarnet/blob/feat/harness-backend/frontend/app/workhub.js): `frontend/app/workhub.js`
- [Deliverables](https://github.com/soundwave-machine-learning/smlstarnet/blob/feat/harness-backend/frontend/app/deliverables.js): `frontend/app/deliverables.js`

### Work orchestration

- [Belt routing plan](https://github.com/soundwave-machine-learning/smlstarnet/blob/feat/harness-backend/frontend/app/pipeline.js): `frontend/app/pipeline.js`
- [Agent setup](https://github.com/soundwave-machine-learning/smlstarnet/blob/feat/harness-backend/frontend/app/onboarding.js): `frontend/app/onboarding.js`
- [Recipes and skills](https://github.com/soundwave-machine-learning/smlstarnet/blob/feat/harness-backend/frontend/app/recipes.js): `frontend/app/recipes.js`
- [Scheduled work](https://github.com/soundwave-machine-learning/smlstarnet/blob/feat/harness-backend/frontend/app/autojobs.js): `frontend/app/autojobs.js`
- [Task briefs](https://github.com/soundwave-machine-learning/smlstarnet/blob/feat/harness-backend/frontend/app/intake.js): `frontend/app/intake.js`

### Agent runtime

- [Local sidecar](https://github.com/soundwave-machine-learning/smlstarnet/tree/feat/harness-backend/sidecar): `sidecar`
- [Model providers](https://github.com/soundwave-machine-learning/smlstarnet/tree/feat/harness-backend/sidecar): `sidecar`
- [Agent tools](https://github.com/soundwave-machine-learning/smlstarnet/tree/feat/harness-backend/sidecar): `sidecar`
- [MCP connectors](https://github.com/soundwave-machine-learning/smlstarnet/blob/feat/harness-backend/sidecar/mcp/manager.js): `sidecar/mcp/manager.js`
- [Message channels](https://github.com/soundwave-machine-learning/smlstarnet/blob/feat/harness-backend/frontend/app/channels.js): `frontend/app/channels.js`
- [Voice interaction](https://github.com/soundwave-machine-learning/smlstarnet/blob/feat/harness-backend/frontend/app/voice.js): `frontend/app/voice.js`

### State and integrations

- [Local persistence](https://github.com/soundwave-machine-learning/smlstarnet/blob/feat/harness-backend/frontend/app/save.js): `frontend/app/save.js`
- [Run and spend ledgers](https://github.com/soundwave-machine-learning/smlstarnet/blob/feat/harness-backend/frontend/app/recledger.js): `frontend/app/recledger.js`
- [Station projection](https://github.com/soundwave-machine-learning/smlstarnet/blob/feat/harness-backend/frontend/app/worldrenderer.js): `frontend/app/worldrenderer.js`

### Other components

- **Station user**
- **Model services**
- **Chat services**
- **Local and network tools**

## Connections

- Station user → Desktop shell: opens
- Desktop shell → Local sidecar: starts
- Desktop shell → Station app: opens webview
- Station user → Station app: uses
- Station app → Work interface: presents work
- Work interface → Task briefs: captures task
- Work interface → Belt routing plan: configures routes
- Agent setup → Local sidecar: configures agents
- Recipes and skills → Local sidecar: launches work
- Scheduled work → Local sidecar: schedules runs
- Local sidecar → Belt routing plan: resolves target
- Local sidecar → Model providers: requests inference
- Model providers → Model services: calls models
- Local sidecar → Agent tools: dispatches tools
- Agent tools → Local and network tools: operates through
- Local sidecar → MCP connectors: uses connectors
- MCP connectors → Local and network tools: exposes tools
- Station user → Message channels: messages remotely
- Message channels → Local sidecar: delivers messages
- Station user → Voice interaction: dictates
- Local sidecar → Local persistence: persists state
- Local sidecar → Run and spend ledgers: records runs and spend
- Local sidecar → Deliverables: publishes deliverables
- Local sidecar → Station projection: emits runtime state
- Station projection → Station world: projects state
- Deliverables → Station user: offers files
