How peakflo/20x works
20x is a local-first Electron task manager that routes work from a desktop or paired mobile client to coding agents. The main workflow is task intake and selection, agent execution in an isolated repository workspace, live review and approval, then task/result updates and feedback. The README also documents task-source integrations, skills, MCP tools, artifacts, voice, and heartbeat monitoring. The graph follows documented flows and sampled boundaries; several subsystem links are based on README capabilities because their implementation was not sampled.
Main entry points: agent-manager.ts Agent manager · database.ts SQLite database · mobile-api-server.ts Mobile API · App.tsx Desktop UI
Components 20
User clients
- Desktop UI
src/renderer/src/App.tsx - Mobile client
src/mobile/App.tsx - Task management
src/renderer/src/components/tasks/TaskWorkspace.tsx
Desktop runtime
- Preload bridge
src/preload/index.ts - IPC handlers
src/main/ipc-handlers.ts - Mobile API
src/main/mobile-api-server.ts - SQLite database
src/main/database.ts
Task execution
- Agent manager
src/main/agent-manager.ts - Agent adapters
src/main/adapters/index.ts - Git worktrees
src/main/worktree-manager.ts - Skills and plugins
src/main/claude-plugin-manager.ts - MCP tools
src/main/mcp-tool-caller.ts - Task schedulers
src/main/task-automation-scheduler.ts
Integrations
- Task integrations
src/main/plugins/registry.ts - OAuth manager
src/main/oauth/oauth-manager.ts
Local capabilities
- Artifacts
src/main/artifacts.ts - Voice sessions
src/main/voice/voice-session-manager.ts - Heartbeat sync
src/main/enterprise-heartbeat.ts
Other components
- User
- Coding agents
Connections 24
- User → Desktop UI: creates tasks
- Desktop UI → Task management: manages tasks
- Task management → Preload bridge: invokes IPC
- Preload bridge → IPC handlers: dispatches calls
- IPC handlers → SQLite database: reads and writes
- IPC handlers → Agent manager: controls sessions
- Task integrations → SQLite database: syncs task data
- OAuth manager → SQLite database: stores tokens
- Agent manager → SQLite database: loads task state
- Agent manager → Git worktrees: prepares worktrees
- Agent manager → Skills and plugins: loads instructions
- Agent manager → MCP tools: calls tools
- Agent manager → Agent adapters: selects adapter
- Agent adapters → Coding agents: runs sessions
- Agent manager → SQLite database: saves outcomes
- Task schedulers → SQLite database: schedules tasks
- Mobile client → Mobile API: requests task data
- Mobile API → SQLite database: reads and writes
- Mobile client → Mobile API: starts sessions
- Mobile API → Agent manager: controls sessions
- Desktop UI → Voice sessions: controls voice
- Agent manager → Artifacts: stores outputs
- Heartbeat sync → SQLite database: syncs state
- Task integrations → OAuth manager: uses authorization