How tls11/seraphim works
Seraphim is a self-hosted autonomous developer agent. Operators curate issues on a kanban board; the API syncs tracker issues, selects the top To Do task, prepares a persistent Docker workspace, drives a resumable Claude Code session, and surfaces its live progress. Pull requests are detected and checked against repository review policy before completion or human review. The graph also shows settings, automation, Jira, and usage capabilities documented by the README or represented in the source index; unsampled implementation details are not inferred beyond those references.
Main entry points: orchestrator/mod.rs Agent and sync loops · queries.rs Database queries · http/mod.rs REST and SSE routes · webhooks.rs Issue webhooks
Components 27
API and state
- API server
api/src/main.rs - REST and SSE routes
api/src/http/mod.rs - Board endpoints
api/src/http/board.rs - Task endpoints
api/src/http/tasks.rs - Settings endpoints
api/src/http/settings.rs - Shared state and events
api/src/state.rs - Domain models
api/src/db/models.rs - Database queries
api/src/db/queries.rs - Runtime configuration
api/src/config.rs
Agent workflow
- Agent and sync loops
api/src/orchestrator/mod.rs - Prompt construction
api/src/orchestrator/prompt.rs - Workspace preparation
api/src/orchestrator/provision.rs - Agent event parsing
api/src/claude/events.rs - PR review policy
api/src/orchestrator/review.rs - Automation rules
api/src/automation/mod.rs
Trackers and integrations
- Issue webhooks
api/src/http/webhooks.rs - Claude OAuth and usage
api/src/claude/oauth.rs - GitHub operations
api/src/git/mod.rs - Jira client and mapping
api/src/jira/mod.rs
Operator interface
- Kanban and settings UI
frontend/src/routes/+page.svelte - Board search
frontend/src/lib/components/SearchBar.svelte
Other components
- Operator
- Postgres
- Docker workspace
- Claude service
- GitHub issues and PRs
- Jira service
Connections 35
- Operator → Kanban and settings UI: curates work
- Kanban and settings UI → REST and SSE routes: uses REST and SSE
- API server → REST and SSE routes: serves routes
api/src/main.rs - API server → Shared state and events: constructs shared state
api/src/main.rs - API server → Agent and sync loops: spawns loops
api/src/main.rs - REST and SSE routes → Board endpoints: registers routes
api/src/http/mod.rs - REST and SSE routes → Task endpoints: registers routes
api/src/http/mod.rs - REST and SSE routes → Settings endpoints: registers routes
api/src/http/mod.rs - Board endpoints → Database queries: reads and writes
- Task endpoints → Database queries: queries tasks
api/src/http/tasks.rs - Task endpoints → GitHub operations: uses GitHub operations
api/src/http/tasks.rs - Issue webhooks → Database queries: updates issue cache
api/src/http/webhooks.rs - Issue webhooks → GitHub operations: maps GitHub issues
api/src/http/webhooks.rs - Issue webhooks → Jira client and mapping: maps Jira events
api/src/http/webhooks.rs - GitHub issues and PRs → Issue webhooks: sends issue events
api/src/http/webhooks.rs - Jira service → Issue webhooks: sends issue events
api/src/http/webhooks.rs - Shared state and events → Database queries: queries persisted state
api/src/state.rs - Database queries → Postgres: reads and writes
- Domain models → Shared state and events: defines domain data
api/src/db/models.rs - Agent and sync loops → Database queries: selects and updates tasks
api/src/orchestrator/mod.rs - Agent and sync loops → Workspace preparation: prepares repository
api/src/orchestrator/mod.rs - Agent and sync loops → Prompt construction: builds agent prompt
api/src/orchestrator/mod.rs - Agent and sync loops → Agent event parsing: handles streamed events
- Workspace preparation → Docker workspace: prepares workspace
- Docker workspace → Claude service: runs resumed session
- Claude service → Kanban and settings UI: streams task output
- Agent and sync loops → GitHub operations: detects and reviews PRs
api/src/orchestrator/mod.rs - PR review policy → GitHub operations: applies review policy
- GitHub operations → GitHub issues and PRs: checks and merges PRs
api/src/git/mod.rs - Settings endpoints → Claude OAuth and usage: supports subscription login
- Claude OAuth and usage → Claude service: exchanges token and usage
api/src/claude/oauth.rs - Agent and sync loops → Automation rules: fires matching rules
api/src/orchestrator/mod.rs - Settings endpoints → Jira client and mapping: configures integration
- Board search → Kanban and settings UI: filters board tasks
frontend/src/lib/components/SearchBar.svelte - Kanban and settings UI → Operator: shows board and progress