Skip to main content

Agent Workflow

Interns operate on an automated cycle: poll Linear for work, implement changes, open PRs, and respond to review feedback.

Linear → Code → PR

1

Create a Linear Ticket

Create an issue in Linear on the Mission Control team. Tag it with the intern’s label (e.g., intern:golf).The description should clearly state:
  • What needs to change
  • Which repos are affected (layerfivecore, l5ui, docs)
  • Acceptance criteria
2

Agent Picks Up the Ticket (≤5 min)

The linear-poll cron runs every 5 minutes. When it finds a new issue:
  1. Announces in Slack: 🚀 Starting MC-XXX: <title>
  2. Registers the task in Supabase
  3. Moves the issue to In Progress in Linear
  4. Resets repos to the default branch
3

Claude Code Implements

The orchestrator dispatches Claude Code CLI with full tool access:
  • Creates a feature branch: feature/mc-xxx-short-description
  • Reads the codebase to understand patterns
  • Implements the changes
  • Commits with messages referencing the Linear issue
  • Pushes to GitHub
  • Opens PRs via gh pr create
4

Results Announced

After implementation:
  • PRs registered in Supabase
  • Linear issue commented with PR links
  • Slack announcement: ✅ Finished MC-XXX: PRs opened
  • Live preview rebuilt (Angular + Django)

PR Review Cycle

1

Leave a Review Comment

Review the PR on GitHub. Leave inline comments on specific lines or top-level review comments.
The agent detects inline comments, review comments, and top-level PR comments from humans. It automatically filters out bot comments (Linear, Claude, GitHub Actions).
2

Agent Addresses Feedback (≤10 min)

The pr-review cron runs every 10 minutes. When it finds new human comments:
  1. Announces in Slack: 📝 Addressing review on l5ui#123
  2. Dispatches Claude Code CLI to make the changes
  3. Commits: [MC-XXX] Address review feedback
  4. Pushes to the same branch (PR auto-updates)
  5. Replies on the PR with a summary
  6. Rebuilds the live preview
  7. Announces: ✅ Updated l5ui#123
3

Merge When Ready

Once satisfied, merge the PR. The agent detects merged PRs and:
  • Marks the task as completed in Supabase
  • Frees capacity to pick up new work

Capacity

Each intern handles one ticket at a time. It won’t pick up new work until all PRs from the current ticket are merged or closed.

Cron Jobs

Both run as OpenClaw crons using Claude Haiku for orchestration (checking APIs, reading comments) and Claude Code CLI for actual coding work.

Repos

The agent works across three repositories in the Lunar-Mission-Control org: After pushing code, the agent automatically rebuilds the live preview:
  • l5ui changes → Angular rebuild + Nginx restart
  • layerfivecore changes → Django restart

Example Ticket

A good ticket for an intern:
Start with small, well-defined tickets. The agent works best with clear requirements and specific file references. As you build confidence, you can assign larger features that span multiple repos.