$ lexprog.com

// notes from an old coder -- php, databases, and the occasional rant

[November 09, 2026] OpenCode

Define role-specific agents: in CI

Give each agent its own prompt and tool access instead of restating the role every session. Use the headless entrypoint and fail the job on a non-zero exit.

────────────────────────────────────────────────────────

Define role-specific agents: in CI

Tip: A reviewer is not a writer

Give each agent its own prompt and tool access instead of restating the role every session. Use the headless entrypoint and fail the job on a non-zero exit.

{ "agents": { "reviewer": { "prompt": "Report only. Do not edit." } } }

Gotcha: One god-agent (in ci)

A single agent that can commit, push, and talk to prod MCP will eventually do all three. The TUI will hang with no TTY; never pipe yes into permission prompts.

{ "tools": "*" }

Source: https://opencode.ai/docs/agents

────────────────────────────────────────────────────────
<-- back to posts