How gurukiran10/ai-workforce works
Acme Workforce is a role-configured AI employee system that carries out browser-based business tasks, escalates decisions to a human, and reports completion only after independent verification. The principal workflow runs from task assignment through role selection, planning and browser actions, safety checks, and verification; the console also supports reviewing runs and approving learned rules. The sandbox supplies sample mail, ERP, recruiting, and ATS applications. Some console-to-runtime wiring and unsampled subsystem details are documented but not shown in the excerpts, so those links are marked unverified or omitted.
Main entry points: runtime.py Task runtime · routes.py Workforce console · verifier.py Independent verifier · llm.py Model interface
Components 22
Worker runtime
- Task runtime
worker/runtime.py - Plans and prompts
worker/prompts.py - Model interface
worker/llm.py - Model providers
worker/llm_converse.py - Generic action tools
worker/tools.py - Browser interaction
worker/browser.py - Safety policy
worker/policy.py - Independent verifier
worker/verifier.py
Roles and learning
- Role definitions
worker/role.py - Employee role files
roles/diya.yaml - Learning and trust
worker/learning.py - Company memory
worker/memory.py
Human oversight
- Workforce console
viewer/routes.py - Human decision channel
worker/human.py
Sandbox company apps
- Sandbox web apps
sandbox/app.py - Company sample data
sandbox/seed.py - Invoice PDFs
sandbox/invoices.py
Run evidence
- Run trace and state
worker/trace.py - Run report
worker/report.py - Saved run artifacts
runs
Other components
- Employee
- LLM service
Connections 27
- Employee → Workforce console: assigns work
README.md - Workforce console → Task runtime: routes tasks
- Task runtime → Role definitions: loads role
worker/runtime.py - Role definitions → Employee role files: reads definitions
README.md - Task runtime → Plans and prompts: builds prompts
worker/runtime.py - Task runtime → Model interface: requests decisions
worker/runtime.py - Model interface → Model providers: selects adapter
worker/llm.py - Model providers → LLM service: sends requests
- Task runtime → Generic action tools: dispatches tools
worker/runtime.py - Generic action tools → Browser interaction: performs actions
worker/tools.py - Task runtime → Safety policy: checks actions
worker/runtime.py - Task runtime → Human decision channel: requests decisions
worker/runtime.py - Human decision channel → Workforce console: exchanges responses
worker/human.py - Browser interaction → Sandbox web apps: uses web apps
README.md - Task runtime → Independent verifier: checks completion
worker/runtime.py - Independent verifier → Model interface: requests review
worker/verifier.py - Independent verifier → Browser interaction: rechecks systems
README.md - Task runtime → Learning and trust: records learning
- Learning and trust → Company memory: adds approved rules
worker/learning.py - Workforce console → Learning and trust: reviews proposals
viewer/routes.py - Task runtime → Run trace and state: records events
worker/runtime.py - Task runtime → Run report: creates report
worker/runtime.py - Run trace and state → Saved run artifacts: persists evidence
- Run report → Saved run artifacts: saves result
- Workforce console → Saved run artifacts: reads run evidence
viewer/routes.py - Sandbox web apps → Company sample data: uses sample data
sandbox/app.py - Company sample data → Invoice PDFs: renders invoices
sandbox/seed.py