How leonvanzyl/codeden works
CodeDen is a local-first coding-agent workspace with CLI and desktop launchers, a web UI, a local server, and a persistent runner. The main workflow is: a user sets up a project and starts a session; the server delegates work to an isolated agent session; runner events are stored and projected; the UI presents the transcript and workbench for review. The graph also preserves documented orchestration, inbox, GitHub, automation, and factory capabilities. Some feature wiring is unsampled, so those relationships rely on README statements rather than inspected implementation.
Main entry points: server.ts Local server · orchestration-service.ts Agent orchestration · session-service.ts Session lifecycle · client.ts Runner protocol
Components 21
User interfaces
- Web workspace
apps/web/src/router.tsx - CLI launcher
apps/cli/src/main.ts - Desktop app
apps/desktop/src/main/main.ts
Session runtime
- Local server
apps/server/src/server.ts - Project management
apps/server/src/services/projects/project-service.ts - Session lifecycle
apps/server/src/services/sessions/session-service.ts - Runner protocol
apps/server/src/runner/client.ts - Runner process
apps/runner/src/main.ts - Agent provider
packages/providers/src/claude/session.ts - Agent browser
apps/runner/src/browser/manager.ts
Events and state
- Event ingestion
apps/server/src/events/ingest.ts - Event store
apps/server/src/events/store.ts - SQLite database
apps/server/src/db/client.ts
Work coordination
- Agent orchestration
apps/server/src/services/orchestration/orchestration-service.ts - User inbox
apps/server/src/services/inbox-service.ts - Automations
apps/server/src/services/automations/automation-service.ts - Factory loop
apps/server/src/services/factory/factory-service.ts
Workbench and integrations
- GitHub services
apps/server/src/services/github/github-service.ts - Session workbench
apps/web/src/components/workbench/browser-panel.tsx
Other components
- User
- GitHub
Connections 24
- User → Web workspace: uses
- User → CLI launcher: starts
- User → Desktop app: uses
- Web workspace → Local server: requests
- CLI launcher → Local server: starts
apps/cli/src/main.ts - Desktop app → Local server: hosts
apps/desktop/src/main/main.ts - Local server → Project management: manages
- Local server → Session lifecycle: handles
- Session lifecycle → Runner protocol: delegates
apps/server/src/services/sessions/session-service.ts - Runner protocol → Runner process: connects
apps/server/src/runner/client.ts - Runner protocol → Event ingestion: submits
apps/server/src/runner/client.ts - Runner process → Agent provider: runs
- Runner process → Agent browser: provides
- Event ingestion → Event store: appends
apps/server/src/events/ingest.ts - Event store → SQLite database: persists
apps/server/src/events/store.ts - Local server → Agent orchestration: coordinates
- Agent orchestration → Session lifecycle: starts and steers
apps/server/src/services/orchestration/orchestration-service.ts - Agent orchestration → User inbox: reads
apps/server/src/services/orchestration/orchestration-service.ts - Local server → Automations: runs
- Factory loop → Session lifecycle: builds work
apps/server/src/services/factory/factory-service.ts - Factory loop → Agent orchestration: notifies
apps/server/src/services/factory/factory-service.ts - GitHub services → GitHub: syncs
- Session workbench → Local server: views session
- User → Session workbench: reviews work