Skip to content

Review

Review turns what your agent wrote into something you can read the way you read a pull request: the diff, comments on the lines they are about, and answers under them. Bay 02.

The difference from every other way of reviewing an agent’s work is that the comments are data, not prose. The agent fetches them with a tool, answers each one, and marks it resolved — and a resolve is checked against the file before it is believed.

you the agent
─── ─────────
read the diff
comment on a line
comment on a range
submit ──────▶ review_list what is waiting, with the code
(changes the code)
◀────── review_reply what it did, resolved=true
see the answer
in the panel
◀────── review_open a note of its own, for later

Four things make that a loop rather than a nicer diff viewer:

Comments outlive the conversation. They are stored per branch, not per chat. Start a new session, switch branches and come back, close OpenCode — the review is where you left it, because a review is about the work, not about the conversation you happened to be having.

Submit is a handoff, not a paste. It sends a short message; the notes travel as structured data for review_list to fetch. Without the server half installed it sends the whole review as text instead, so the loop degrades to a one-shot review rather than breaking.

A resolve is checked. A thread remembers the lines it was written against. If the agent says “done” and the file still reads exactly as it did, the reply is kept and the thread stays open for you, with the agent told plainly that nothing changed. Being told is the point: an agent that claims a fix over an untouched file learns nothing, and you would have found out by reading.

The agent can leave notes too. review_open puts its own comment on a line — a bug noticed on the way past, a decision that wants a second opinion, work it is deliberately leaving. It appears in the panel beside yours and outlives the chat it was thought of in.

The situationIn the conversationIn Review
Three files changed, one is wrongDescribe the file, the line and the objection in prosePut the comment on the line
You disagree with one decisionThe whole turn gets re-litigatedOne thread, on the lines it is about
Half the work is right“Keep the first part, redo the second”Resolve what is right, leave the rest open
You are interruptedScroll back and reconstruct where you wereThe review is still there, with what you marked read
The agent says it fixed itTake its word for itResolving is checked against the file

Rule of thumb: if you would have left a comment on a pull request, leave it here instead of describing it.

Two sources, switched with b:

  • Uncommitted — what is in the worktree now: the work that just happened.
  • Branch — this branch against its base, which is the pull-request reading. The default, because by the time you go looking for the work it is usually committed.

Both come from git, and both are read as whole files rather than as a patch, which is what lets Review compute its own hunks — so the line numbers are the file’s real line numbers and the syntax is highlighted like code, not like a diff.

{
"plugin": ["@opencode-cockpit/review"]
}

The package ships both halves: the panel you drive and the tools the agent gets. <leader>v opens it — <leader> is OpenCode’s own prefix, ctrl+x by default.