# valenxi0/nano architecture

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

- Interactive diagram: https://gitdiagram.com/valenxi0/nano
- Repository: https://github.com/valenxi0/nano

## Overview

Nano is a native macOS menu-bar/island app: users interact with the island and dashboard, enable modules in settings, then receive live system or agent activity and use features such as dictation or task capture. Its main domain stages are island presentation, event/module services, and optional feature workflows; settings and local stores provide a useful internal layer. The README documents capabilities not represented by sampled source. Connections for those unsampled features are omitted or marked unverified rather than inferred from filenames.

Main entry points: [`Nano/Core/VoiceDictation/VoiceDictationController.swift`](https://github.com/valenxi0/nano/blob/main/Nano/Core/VoiceDictation/VoiceDictationController.swift) (Quill controller), [`Nano/Views/ConnectedModuleViews.swift`](https://github.com/valenxi0/nano/blob/main/Nano/Views/ConnectedModuleViews.swift) (Connected modules), [`Nano/Views/IslandRootView.swift`](https://github.com/valenxi0/nano/blob/main/Nano/Views/IslandRootView.swift) (Island dashboard), [`Nano/Window/IslandPanel.swift`](https://github.com/valenxi0/nano/blob/main/Nano/Window/IslandPanel.swift) (Island window)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_shell["Island and dashboard"]
  node_app["App lifecycle"]
  node_panel["Island window<br/>[IslandPanel.swift]"]
  node_rootview["Island dashboard"]
  node_widgets["Dashboard widgets"]
  node_moduleviews["Connected modules"]
end

subgraph group_agents["Coding agents"]
  node_agents["Agent activity"]
  node_agentroutes["Agent routes<br/>[AgentRoutes.swift]"]
  node_agentbridge["Agent hooks"]
  node_agentusage[("Usage tracking<br/>[TokenLedger.swift]")]
  node_agentjump["Session jumping"]
end

subgraph group_voice["Voice and Sketch"]
  node_dictation["Quill controller"]
  node_audio["Audio capture"]
  node_engines["Speech engines"]
  node_textpipe["Transcript pipeline"]
  node_models[("Speech model store")]
end

subgraph group_productivity["Productivity modules"]
  node_cue[("Cue list<br/>[CueStore.swift]")]
  node_cuesync["Cue synchronization"]
  node_taskdest["Task destinations"]
  node_mixer["Per-app mixer<br/>[MixerEngine.swift]"]
  node_tray[("File tray<br/>[TrayStore.swift]")]
  node_calendarweather["Calendar and weather"]
  node_focus[("Focus timer")]
end

subgraph group_platform["Settings and services"]
  node_settings[("Settings<br/>[NanoSettings.swift]")]
  node_notifications["Notification routing"]
  node_systemevents["System event monitor"]
  node_media["Media and device cards"]
end

node_user(("Mac user"))
node_externalapps["Task apps"]
node_localmodels["Local speech runtimes"]

node_user -->|"opens"| node_panel
node_panel -->|"hosts"| node_rootview
node_rootview -->|"shows"| node_widgets
node_rootview -->|"shows"| node_moduleviews
node_app -->|"configures"| node_settings
node_moduleviews -->|"reads status"| node_agents
node_moduleviews -->|"reads usage"| node_agentusage
node_agentbridge -.->|"uses routes"| node_agentroutes
node_dictation -->|"records"| node_audio
node_dictation -->|"selects engine"| node_engines
node_dictation -->|"cleans transcript"| node_textpipe
node_dictation -->|"loads models"| node_models
node_engines -.->|"runs locally"| node_localmodels
node_user -->|"dictates"| node_dictation
node_cue -->|"syncs changes"| node_cuesync
node_cuesync -->|"syncs tasks"| node_taskdest
node_taskdest -.->|"connects apps"| node_externalapps
node_user -->|"captures tasks"| node_cue
node_user -->|"adjusts volume"| node_mixer
node_user -->|"drops files"| node_tray
node_user -->|"views context"| node_calendarweather
node_user -->|"starts timer"| node_focus
node_systemevents -.->|"routes events"| node_notifications
node_user -->|"controls devices"| node_media
node_settings -.->|"enables modules"| node_moduleviews

click node_app "https://github.com/valenxi0/nano/blob/main/Nano/App/NanoAppDelegate.swift"
click node_panel "https://github.com/valenxi0/nano/blob/main/Nano/Window/IslandPanel.swift"
click node_rootview "https://github.com/valenxi0/nano/blob/main/Nano/Views/IslandRootView.swift"
click node_widgets "https://github.com/valenxi0/nano/blob/main/Nano/Views/DashboardWidgetViews.swift"
click node_settings "https://github.com/valenxi0/nano/blob/main/Nano/Core/NanoSettings.swift"
click node_moduleviews "https://github.com/valenxi0/nano/blob/main/Nano/Views/ConnectedModuleViews.swift"
click node_agents "https://github.com/valenxi0/nano/blob/main/Nano/Core/AgentStatusService.swift"
click node_agentroutes "https://github.com/valenxi0/nano/blob/main/Nano/Core/AgentRoutes.swift"
click node_agentbridge "https://github.com/valenxi0/nano/blob/main/Nano/Core/AgentHookBridge.swift"
click node_agentusage "https://github.com/valenxi0/nano/blob/main/Nano/Core/TokenLedger.swift"
click node_agentjump "https://github.com/valenxi0/nano/blob/main/Nano/Core/AgentSessionJump.swift"
click node_dictation "https://github.com/valenxi0/nano/blob/main/Nano/Core/VoiceDictation/VoiceDictationController.swift"
click node_audio "https://github.com/valenxi0/nano/blob/main/Nano/Core/VoiceDictation/VoiceDictationAudioRecorder.swift"
click node_engines "https://github.com/valenxi0/nano/blob/main/Nano/Core/VoiceDictation/VoiceDictationEngines.swift"
click node_textpipe "https://github.com/valenxi0/nano/blob/main/Nano/Core/VoiceDictation/VoiceDictationTextPipeline.swift"
click node_models "https://github.com/valenxi0/nano/blob/main/Nano/Core/VoiceDictation/VoiceDictationModelStore.swift"
click node_cue "https://github.com/valenxi0/nano/blob/main/Nano/Core/CueStore.swift"
click node_cuesync "https://github.com/valenxi0/nano/blob/main/Nano/Core/CueSyncEngine.swift"
click node_taskdest "https://github.com/valenxi0/nano/blob/main/Nano/Core/TaskDestination.swift"
click node_mixer "https://github.com/valenxi0/nano/blob/main/Nano/Core/MixerEngine.swift"
click node_tray "https://github.com/valenxi0/nano/blob/main/Nano/Core/TrayStore.swift"
click node_calendarweather "https://github.com/valenxi0/nano/blob/main/Nano/Core/CalendarWeatherServices.swift"
click node_focus "https://github.com/valenxi0/nano/blob/main/Nano/Core/FocusTimerStore.swift"
click node_notifications "https://github.com/valenxi0/nano/blob/main/Nano/Core/NotificationRouter.swift"
click node_systemevents "https://github.com/valenxi0/nano/blob/main/Nano/Core/SystemEventMonitor.swift"
click node_media "https://github.com/valenxi0/nano/blob/main/Nano/Core/MediaSystemServices.swift"

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_app,node_panel,node_rootview,node_widgets,node_moduleviews,node_user toneBlue
class node_agents,node_agentroutes,node_agentbridge,node_agentusage,node_agentjump toneAmber
class node_dictation,node_audio,node_engines,node_textpipe,node_models toneMint
class node_cue,node_cuesync,node_taskdest,node_mixer,node_tray,node_calendarweather,node_focus,node_externalapps toneRose
class node_settings,node_notifications,node_systemevents,node_media,node_localmodels toneIndigo
```

## Components

### Island and dashboard

- [App lifecycle](https://github.com/valenxi0/nano/blob/main/Nano/App/NanoAppDelegate.swift): `Nano/App/NanoAppDelegate.swift`
- [Island window](https://github.com/valenxi0/nano/blob/main/Nano/Window/IslandPanel.swift): `Nano/Window/IslandPanel.swift`
- [Island dashboard](https://github.com/valenxi0/nano/blob/main/Nano/Views/IslandRootView.swift): `Nano/Views/IslandRootView.swift`
- [Dashboard widgets](https://github.com/valenxi0/nano/blob/main/Nano/Views/DashboardWidgetViews.swift): `Nano/Views/DashboardWidgetViews.swift`
- [Connected modules](https://github.com/valenxi0/nano/blob/main/Nano/Views/ConnectedModuleViews.swift): `Nano/Views/ConnectedModuleViews.swift`

### Coding agents

- [Agent activity](https://github.com/valenxi0/nano/blob/main/Nano/Core/AgentStatusService.swift): `Nano/Core/AgentStatusService.swift`
- [Agent routes](https://github.com/valenxi0/nano/blob/main/Nano/Core/AgentRoutes.swift): `Nano/Core/AgentRoutes.swift`
- [Agent hooks](https://github.com/valenxi0/nano/blob/main/Nano/Core/AgentHookBridge.swift): `Nano/Core/AgentHookBridge.swift`
- [Usage tracking](https://github.com/valenxi0/nano/blob/main/Nano/Core/TokenLedger.swift): `Nano/Core/TokenLedger.swift`
- [Session jumping](https://github.com/valenxi0/nano/blob/main/Nano/Core/AgentSessionJump.swift): `Nano/Core/AgentSessionJump.swift`

### Voice and Sketch

- [Quill controller](https://github.com/valenxi0/nano/blob/main/Nano/Core/VoiceDictation/VoiceDictationController.swift): `Nano/Core/VoiceDictation/VoiceDictationController.swift`
- [Audio capture](https://github.com/valenxi0/nano/blob/main/Nano/Core/VoiceDictation/VoiceDictationAudioRecorder.swift): `Nano/Core/VoiceDictation/VoiceDictationAudioRecorder.swift`
- [Speech engines](https://github.com/valenxi0/nano/blob/main/Nano/Core/VoiceDictation/VoiceDictationEngines.swift): `Nano/Core/VoiceDictation/VoiceDictationEngines.swift`
- [Transcript pipeline](https://github.com/valenxi0/nano/blob/main/Nano/Core/VoiceDictation/VoiceDictationTextPipeline.swift): `Nano/Core/VoiceDictation/VoiceDictationTextPipeline.swift`
- [Speech model store](https://github.com/valenxi0/nano/blob/main/Nano/Core/VoiceDictation/VoiceDictationModelStore.swift): `Nano/Core/VoiceDictation/VoiceDictationModelStore.swift`

### Productivity modules

- [Cue list](https://github.com/valenxi0/nano/blob/main/Nano/Core/CueStore.swift): `Nano/Core/CueStore.swift`
- [Cue synchronization](https://github.com/valenxi0/nano/blob/main/Nano/Core/CueSyncEngine.swift): `Nano/Core/CueSyncEngine.swift`
- [Task destinations](https://github.com/valenxi0/nano/blob/main/Nano/Core/TaskDestination.swift): `Nano/Core/TaskDestination.swift`
- [Per-app mixer](https://github.com/valenxi0/nano/blob/main/Nano/Core/MixerEngine.swift): `Nano/Core/MixerEngine.swift`
- [File tray](https://github.com/valenxi0/nano/blob/main/Nano/Core/TrayStore.swift): `Nano/Core/TrayStore.swift`
- [Calendar and weather](https://github.com/valenxi0/nano/blob/main/Nano/Core/CalendarWeatherServices.swift): `Nano/Core/CalendarWeatherServices.swift`
- [Focus timer](https://github.com/valenxi0/nano/blob/main/Nano/Core/FocusTimerStore.swift): `Nano/Core/FocusTimerStore.swift`

### Settings and services

- [Settings](https://github.com/valenxi0/nano/blob/main/Nano/Core/NanoSettings.swift): `Nano/Core/NanoSettings.swift`
- [Notification routing](https://github.com/valenxi0/nano/blob/main/Nano/Core/NotificationRouter.swift): `Nano/Core/NotificationRouter.swift`
- [System event monitor](https://github.com/valenxi0/nano/blob/main/Nano/Core/SystemEventMonitor.swift): `Nano/Core/SystemEventMonitor.swift`
- [Media and device cards](https://github.com/valenxi0/nano/blob/main/Nano/Core/MediaSystemServices.swift): `Nano/Core/MediaSystemServices.swift`

### Other components

- **Mac user**
- **Task apps**
- **Local speech runtimes**

## Connections

- Mac user → Island window: opens (evidence: `README.md`)
- Island window → Island dashboard: hosts (evidence: `Nano/Window/IslandPanel.swift`)
- Island dashboard → Dashboard widgets: shows (evidence: `README.md`)
- Island dashboard → Connected modules: shows (evidence: `Nano/Views/ConnectedModuleViews.swift`)
- App lifecycle → Settings: configures (evidence: `Nano/App/NanoAppDelegate.swift`)
- Connected modules → Agent activity: reads status (evidence: `Nano/Views/ConnectedModuleViews.swift`)
- Connected modules → Usage tracking: reads usage (evidence: `Nano/Views/ConnectedModuleViews.swift`)
- Agent hooks → Agent routes: uses routes (evidence: `Nano/Core/AgentHookBridge.swift`)
- Quill controller → Audio capture: records (evidence: `Nano/Core/VoiceDictation/VoiceDictationController.swift`)
- Quill controller → Speech engines: selects engine (evidence: `Nano/Core/VoiceDictation/VoiceDictationEngines.swift`)
- Quill controller → Transcript pipeline: cleans transcript (evidence: `Nano/Core/VoiceDictation/VoiceDictationController.swift`)
- Quill controller → Speech model store: loads models (evidence: `Nano/Core/VoiceDictation/VoiceDictationController.swift`)
- Speech engines → Local speech runtimes: runs locally
- Mac user → Quill controller: dictates (evidence: `README.md`)
- Cue list → Cue synchronization: syncs changes (evidence: `Nano/Core/CueSyncEngine.swift`)
- Cue synchronization → Task destinations: syncs tasks (evidence: `Nano/Core/CueSyncEngine.swift`)
- Task destinations → Task apps: connects apps (evidence: `README.md`)
- Mac user → Cue list: captures tasks (evidence: `README.md`)
- Mac user → Per-app mixer: adjusts volume (evidence: `README.md`)
- Mac user → File tray: drops files (evidence: `README.md`)
- Mac user → Calendar and weather: views context (evidence: `README.md`)
- Mac user → Focus timer: starts timer (evidence: `README.md`)
- System event monitor → Notification routing: routes events
- Mac user → Media and device cards: controls devices (evidence: `README.md`)
- Settings → Connected modules: enables modules (evidence: `Nano/Views/ConnectedModuleViews.swift`)
