How vercel-labs/eve-software-factory-template works
Foreman is an AI software factory: work arrives through GitHub, Linear, HTTP intake, or the eve channel, then is triaged and routed through specialist stations to a reviewed draft pull request. The README also documents clarification, research, CI repair, and pull-request summaries. The graph preserves those capabilities, but the source excerpts are incomplete; edges for unsampled subsystems rely on README statements, and uncertain internal wiring is omitted.
Main entry points: agent.ts Foreman orchestrator · github.ts GitHub events · intake.ts Ticket intake · run.ts Task triage
Components 26
Work intake
- GitHub events
agent/channels/github.ts - Linear sessions
agent/channels/linear.ts - Ticket intake
agent/channels/intake.ts - Ticket handling
agent/lib/intake/ticket.ts - Eve channel
agent/channels/eve.ts
Orchestration and triage
- Foreman orchestrator
agent/agent.ts - Task triage
agent/lib/triage/run.ts - Triage decisions
agent/lib/triage/decisions.ts - Clarification routing
agent/lib/triage/pretriage.ts
Agent stations
- Classifier
agent/subagents/classifier/agent.ts - Researcher
agent/subagents/researcher/agent.ts - Analyst
agent/subagents/analyst/agent.ts - Implementer
agent/subagents/implementer/agent.ts - Reviewer
agent/subagents/reviewer/agent.ts - Station dispatch
agent/tools/run_reviewer.ts
Repository operations
- Repository sandbox
agent/lib/github/repo-sandbox.ts - Approval policy
agent/lib/github/approval.ts - GitHub command policy
agent/lib/github/cli.ts - Scoped credentials
agent/lib/github/lease.ts - CI diagnosis
agent/tools/diagnose_ci_failure.ts
Memory and artifacts
- Factory memory
agent/lib/memory/brain.ts - Station artifacts
agent/lib/artifacts/tools.ts
Other components
- GitHub users
- Linear users
- HTTP callers
- Task requester
Connections 29
- GitHub users → GitHub events: triggers
- Linear users → Linear sessions: delegates
- HTTP callers → Ticket intake: submits ticket
- Task requester → Eve channel: starts task
- Ticket intake → Ticket handling: renders ticket
agent/channels/intake.ts - Ticket intake → Foreman orchestrator: starts session
agent/channels/intake.ts - GitHub events → Foreman orchestrator: dispatches work
- Linear sessions → Foreman orchestrator: starts pipeline
- Eve channel → Foreman orchestrator: starts task
- Foreman orchestrator → Task triage: triages work
- Task triage → Triage decisions: classifies task
agent/lib/triage/run.ts - Task triage → Clarification routing: checks readiness
agent/lib/triage/pretriage.ts - Clarification routing → Classifier: asks questions
- Foreman orchestrator → Station dispatch: dispatches stations
agent/tools/run_reviewer.ts - Station dispatch → Researcher: runs on demand
- Foreman orchestrator → Analyst: plans work
- Foreman orchestrator → Implementer: executes plan
- Foreman orchestrator → Reviewer: requests review
- Analyst → Repository sandbox: uses checkout
- Implementer → Repository sandbox: implements changes
- Implementer → Reviewer: hands off branch
- Reviewer → Foreman orchestrator: returns verdict
- Foreman orchestrator → Approval policy: checks permissions
- Approval policy → GitHub command policy: parses commands
agent/lib/github/approval.ts - Repository sandbox → Scoped credentials: uses scoped tokens
agent/lib/github/repo-sandbox.ts - GitHub events → CI diagnosis: handles red CI
- Foreman orchestrator → Factory memory: loads shared notes
- Analyst → Station artifacts: saves analysis
- Researcher → Station artifacts: saves findings