How t54-labs/agent-commons works
Commons is a self-hosted control plane for independently started coding agents. The main workflow is to resolve a workspace’s local/remote/disabled scope, identify and register an agent, coordinate plans, tasks, messages and resource leases, then record activity and expose it in the private Console. The CLI and Skill are the agent-facing entry points; local service state and the remote Relay provide coordination backends. The README documents product capabilities beyond the sampled excerpts; links for those areas are included only where supported by its statements or the source index.
Main entry points: service.py Local service · cli.py Commons CLI · relay.py Private Relay · AgentVillage.tsx Agent Village
Components 22
Agent entry
- Commons CLI
commons/cli.py - Workspace scope
commons/scope.py - Human identity
commons/identity.py - Agent Skill
commons/skill_template
Coordination
- Local service
commons/service.py - Plans and tasks
commons/service.py - Resource leases
commons/service.py - Messages and handoffs
commons/service.py - Audit history
commons/service.py
State and transport
- Local database
commons/db.py - Local board
commons/board.py - State paths
commons/paths.py - Relay client
commons/remote.py - Private Relay
commons/relay.py - HTTP server
commons/http_server.py
Private Console
- Web Console
web/src/App.tsx - Console API client
web/src/api.ts - Agent Village
web/src/AgentVillage.tsx - Village map
web/src/villageLevel.ts - Village navigation
web/src/villageNavigation.ts
Other components
- Coding agents
- Product tour
video/src/scenes.tsx
Connections 22
- Coding agents → Commons CLI: uses
- Coding agents → Agent Skill: follows guidance
- Commons CLI → Workspace scope: resolves scope
commons/cli.py - Commons CLI → Human identity: manages identity
commons/cli.py - Commons CLI → Local service: dispatches operations
commons/cli.py - Local service → Local database: uses
commons/service.py - Local service → Local board: uses
commons/service.py - Local service → State paths: uses
commons/service.py - Local service → Plans and tasks: handles
commons/service.py - Local service → Resource leases: handles
commons/service.py - Local service → Messages and handoffs: handles
commons/service.py - Local service → Audit history: records
commons/service.py - Commons CLI → Relay client: dispatches remote
commons/cli.py - Relay client → Private Relay: calls over HTTP
- Commons CLI → Private Relay: starts server
commons/cli.py - Private Relay → HTTP server: uses server
commons/relay.py - Web Console → Console API client: requests data
web/src/App.tsx - Console API client → Private Relay: fetches Console data
- Web Console → Agent Village: renders
web/src/App.tsx - Agent Village → Village map: loads map
web/src/AgentVillage.tsx - Agent Village → Village navigation: plans paths
web/src/AgentVillage.tsx - Product tour → Coding agents: depicts coordination