# axiom-studio/openseal architecture

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

- Interactive diagram: https://gitdiagram.com/axiom-studio/openseal
- Repository: https://github.com/axiom-studio/openseal

## Overview

OpenSeal is a durable kernel for autonomous Agents and Teams. Users submit prompts or events through the desktop, TUI, or API; the kernel turns work into objectives and durable Runs, executes bounded turns with governed Skills, and exposes progress, approvals, and artifacts. Teams, collaboration, evidence, outreach, and optional deterministic runbooks are additional product capabilities. The graph reflects README-documented behavior and sampled entry points; unsampled subsystem wiring is intentionally not inferred.

Main entry points: [`pkg/runtime/turn_coordinator.go`](https://github.com/axiom-studio/openseal/blob/develop/pkg/runtime/turn_coordinator.go) (Runs and turns), [`internal/server/server.go`](https://github.com/axiom-studio/openseal/blob/develop/internal/server/server.go) (Kernel API), [`pkg/executor/pipeline.go`](https://github.com/axiom-studio/openseal/blob/develop/pkg/executor/pipeline.go) (Execution engine), [`cmd/openseal/commands`](https://github.com/axiom-studio/openseal/tree/develop/cmd/openseal/commands) (CLI)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_clients["User clients"]
  node_desktop["Desktop app<br/>[App.tsx]"]
  node_tui["Terminal UI"]
  node_cli["CLI"]
end

subgraph group_api["API and authoring"]
  node_api["Kernel API<br/>[server.go]"]
  node_client["Go kernel client<br/>[kernel_client.go]"]
  node_authoring["Prompt authoring"]
end

subgraph group_kernel["Durable kernel"]
  node_engine["Kernel facade<br/>[openseal.go]"]
  node_runs["Runs and turns"]
  node_state[("Durable state<br/>[sqlite_store.go]")]
  node_artifacts[("Artifacts<br/>[artifact.go]")]
end

subgraph group_workforce["Workforce domain"]
  node_agents["Agents<br/>[definition.go]"]
  node_teams["Teams<br/>[definition.go]"]
  node_objectives["Objectives and projects"]
  node_collaboration["Requests and channels<br/>[collaboration.go]"]
  node_approvals["Approvals and activity"]
end

subgraph group_execution["Skills and execution"]
  node_skills["Skill lifecycle<br/>[activation.go]"]
  node_executor["Execution engine<br/>[pipeline.go]"]
  node_bindings["Capability bindings<br/>[types.go]"]
  node_runbooks["Optional runbooks<br/>[runbook.go]"]
end

subgraph group_integrations["Evidence and integrations"]
  node_evidence["Evidence and source"]
  node_outreach["Governed outreach<br/>[webhook_invoker.go]"]
end

node_user(("Operator"))
node_provider(("Model provider"))
node_skillservice{{"External Skill service"}}

node_user -->|"submits work"| node_desktop
node_user -->|"submits work"| node_tui
node_user -->|"runs command"| node_cli
node_desktop -->|"HTTP requests"| node_api
node_tui -->|"API requests"| node_api
node_cli -->|"invokes operations"| node_api
node_client -->|"HTTP requests"| node_api
node_api -->|"dispatches operations"| node_engine
node_api -->|"requests proposals"| node_authoring
node_authoring -.->|"generates proposals"| node_provider
node_engine -->|"coordinates work"| node_runs
node_runs -->|"persists runs"| node_state
node_runs -->|"runs deployments"| node_agents
node_runs -->|"runs teams"| node_teams
node_runs -->|"advances objectives"| node_objectives
node_runs -->|"activates skills"| node_skills
node_runs -->|"requests approval"| node_approvals
node_runs -->|"records artifacts"| node_artifacts
node_runs -->|"dispatches execution"| node_executor
node_executor -->|"resolves capabilities"| node_bindings
node_executor -.->|"executes remotely"| node_skillservice
node_teams -->|"coordinates work"| node_collaboration
node_approvals -->|"persists reviews"| node_state
node_artifacts -->|"associates evidence"| node_evidence
node_executor -.->|"invokes outreach"| node_outreach
node_cli -.->|"runs optionally"| node_runbooks

click node_desktop "https://github.com/axiom-studio/openseal/blob/develop/desktop/src/App.tsx"
click node_tui "https://github.com/axiom-studio/openseal/tree/develop/internal/tui"
click node_cli "https://github.com/axiom-studio/openseal/tree/develop/cmd/openseal/commands"
click node_api "https://github.com/axiom-studio/openseal/blob/develop/internal/server/server.go"
click node_client "https://github.com/axiom-studio/openseal/blob/develop/pkg/client/kernel_client.go"
click node_authoring "https://github.com/axiom-studio/openseal/tree/develop/pkg/authoring"
click node_engine "https://github.com/axiom-studio/openseal/blob/develop/pkg/openseal/openseal.go"
click node_runs "https://github.com/axiom-studio/openseal/blob/develop/pkg/runtime/turn_coordinator.go"
click node_state "https://github.com/axiom-studio/openseal/blob/develop/pkg/runtime/sqlite_store.go"
click node_artifacts "https://github.com/axiom-studio/openseal/blob/develop/pkg/runtime/artifact.go"
click node_agents "https://github.com/axiom-studio/openseal/blob/develop/pkg/agent/definition.go"
click node_teams "https://github.com/axiom-studio/openseal/blob/develop/pkg/team/definition.go"
click node_objectives "https://github.com/axiom-studio/openseal/blob/develop/pkg/runtime/objective_action.go"
click node_collaboration "https://github.com/axiom-studio/openseal/blob/develop/pkg/runtime/collaboration.go"
click node_approvals "https://github.com/axiom-studio/openseal/blob/develop/pkg/runtime/approval_coordinator.go"
click node_skills "https://github.com/axiom-studio/openseal/blob/develop/pkg/skill/activation.go"
click node_executor "https://github.com/axiom-studio/openseal/blob/develop/pkg/executor/pipeline.go"
click node_bindings "https://github.com/axiom-studio/openseal/blob/develop/pkg/capability/types.go"
click node_runbooks "https://github.com/axiom-studio/openseal/blob/develop/pkg/runbook/runbook.go"
click node_evidence "https://github.com/axiom-studio/openseal/blob/develop/pkg/runtime/evidence_snapshot.go"
click node_outreach "https://github.com/axiom-studio/openseal/blob/develop/pkg/outreach/webhook_invoker.go"

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_tui,node_cli toneBlue
class node_api,node_client,node_authoring toneAmber
class node_engine,node_runs,node_state,node_artifacts toneMint
class node_agents,node_teams,node_objectives,node_collaboration,node_approvals toneRose
class node_skills,node_executor,node_bindings,node_runbooks,node_user,node_provider,node_skillservice toneIndigo
class node_evidence,node_outreach toneTeal
```

## Components

### User clients

- [Desktop app](https://github.com/axiom-studio/openseal/blob/develop/desktop/src/App.tsx): `desktop/src/App.tsx`
- [Terminal UI](https://github.com/axiom-studio/openseal/tree/develop/internal/tui): `internal/tui`
- [CLI](https://github.com/axiom-studio/openseal/tree/develop/cmd/openseal/commands): `cmd/openseal/commands`

### API and authoring

- [Kernel API](https://github.com/axiom-studio/openseal/blob/develop/internal/server/server.go): `internal/server/server.go`
- [Go kernel client](https://github.com/axiom-studio/openseal/blob/develop/pkg/client/kernel_client.go): `pkg/client/kernel_client.go`
- [Prompt authoring](https://github.com/axiom-studio/openseal/tree/develop/pkg/authoring): `pkg/authoring`

### Durable kernel

- [Kernel facade](https://github.com/axiom-studio/openseal/blob/develop/pkg/openseal/openseal.go): `pkg/openseal/openseal.go`
- [Runs and turns](https://github.com/axiom-studio/openseal/blob/develop/pkg/runtime/turn_coordinator.go): `pkg/runtime/turn_coordinator.go`
- [Durable state](https://github.com/axiom-studio/openseal/blob/develop/pkg/runtime/sqlite_store.go): `pkg/runtime/sqlite_store.go`
- [Artifacts](https://github.com/axiom-studio/openseal/blob/develop/pkg/runtime/artifact.go): `pkg/runtime/artifact.go`

### Workforce domain

- [Agents](https://github.com/axiom-studio/openseal/blob/develop/pkg/agent/definition.go): `pkg/agent/definition.go`
- [Teams](https://github.com/axiom-studio/openseal/blob/develop/pkg/team/definition.go): `pkg/team/definition.go`
- [Objectives and projects](https://github.com/axiom-studio/openseal/blob/develop/pkg/runtime/objective_action.go): `pkg/runtime/objective_action.go`
- [Requests and channels](https://github.com/axiom-studio/openseal/blob/develop/pkg/runtime/collaboration.go): `pkg/runtime/collaboration.go`
- [Approvals and activity](https://github.com/axiom-studio/openseal/blob/develop/pkg/runtime/approval_coordinator.go): `pkg/runtime/approval_coordinator.go`

### Skills and execution

- [Skill lifecycle](https://github.com/axiom-studio/openseal/blob/develop/pkg/skill/activation.go): `pkg/skill/activation.go`
- [Execution engine](https://github.com/axiom-studio/openseal/blob/develop/pkg/executor/pipeline.go): `pkg/executor/pipeline.go`
- [Capability bindings](https://github.com/axiom-studio/openseal/blob/develop/pkg/capability/types.go): `pkg/capability/types.go`
- [Optional runbooks](https://github.com/axiom-studio/openseal/blob/develop/pkg/runbook/runbook.go): `pkg/runbook/runbook.go`

### Evidence and integrations

- [Evidence and source](https://github.com/axiom-studio/openseal/blob/develop/pkg/runtime/evidence_snapshot.go): `pkg/runtime/evidence_snapshot.go`
- [Governed outreach](https://github.com/axiom-studio/openseal/blob/develop/pkg/outreach/webhook_invoker.go): `pkg/outreach/webhook_invoker.go`

### Other components

- **Operator**
- **Model provider**
- **External Skill service**

## Connections

- Operator → Desktop app: submits work
- Operator → Terminal UI: submits work
- Operator → CLI: runs command
- Desktop app → Kernel API: HTTP requests
- Terminal UI → Kernel API: API requests
- CLI → Kernel API: invokes operations
- Go kernel client → Kernel API: HTTP requests
- Kernel API → Kernel facade: dispatches operations
- Kernel API → Prompt authoring: requests proposals
- Prompt authoring → Model provider: generates proposals
- Kernel facade → Runs and turns: coordinates work
- Runs and turns → Durable state: persists runs
- Runs and turns → Agents: runs deployments
- Runs and turns → Teams: runs teams
- Runs and turns → Objectives and projects: advances objectives
- Runs and turns → Skill lifecycle: activates skills
- Runs and turns → Approvals and activity: requests approval
- Runs and turns → Artifacts: records artifacts
- Runs and turns → Execution engine: dispatches execution
- Execution engine → Capability bindings: resolves capabilities
- Execution engine → External Skill service: executes remotely
- Teams → Requests and channels: coordinates work
- Approvals and activity → Durable state: persists reviews
- Artifacts → Evidence and source: associates evidence
- Execution engine → Governed outreach: invokes outreach
- CLI → Optional runbooks: runs optionally
