A Second Pair of Eyes
The model that wrote your code is the worst reviewer of it. Elyra's /review gets you a cold, independent second opinion — no conversation history, optionally a different model entirely, scoped to exactly the changes you care about.
Elyra's /review — an independent code review from the model
Here's a subtle problem with AI-generated code. The model that wrote it is the worst possible reviewer of it.
Not because it's bad at reviewing — because it's invested. It just spent twenty turns building this thing. It has a whole conversation's worth of context arguing for why the code is right. Ask it "is this good?" mid-conversation and you get a biased answer, shaped by everything that came before.
What you actually want is a reviewer who has never seen the conversation. Someone who looks at the diff cold and judges it on its merits. That's /review.
How it works
You run it after the agent has made changes:
/review
Elyra grabs the diff of your changes and sends it to the model with a clean, reviewer-only system prompt and no conversation history:
const context: Context = {
systemPrompt: REVIEW_SYSTEM_PROMPT,
messages: [{ role: "user", content: `Review this diff:\n\n${diff}` }],
};
const result = await completeSimple(model, context, { apiKey });
That empty-context part is the whole point. The reviewer doesn't know what the conversation was about, doesn't have the original reasoning, isn't anchored on "we decided this earlier." It just sees the code.
The reviewer prompt keeps it honest and focused:
You are a senior software engineer doing a focused code review of a diff.
You did not write this code and have no prior context, so judge it on its
own merits.
Review for, in priority order:
1. Correctness and bugs
2. Security
3. Error handling and resource cleanup
4. Clarity and maintainability
- Be specific: reference the exact change.
- If the diff looks correct and well done, say so plainly rather than
inventing problems.
That last rule matters. A reviewer that always finds something is useless. This one is told to say "this looks good" when it does.
Scope it to what the agent did
The killer combination is with the session checkpoints:
/review --session
This reviews only what the agent changed during this session — diffed against the snapshot from before its first turn. So you're not reviewing your own unrelated uncommitted work, just the agent's contribution. "Here's exactly what you did this session — now let me get an independent opinion on it."
You can also scope to a path:
/review src/auth/
The provider-agnostic trick
Here's where Elyra's architecture pays off. /review uses whatever model you've got selected. But you can switch models per command:
/model anthropic claude-opus-4-8 # the heavy hitter
/review --session
So you can have a fast, cheap model do the coding, then bring in a stronger, more expensive model purely for the review — a second opinion from a different brain, not just a fresh context on the same one. Because Elyra is provider-agnostic, "have GPT review what Claude wrote" is one command away.
Why it matters
Trust in an agent is built on verification. The easier it is to get an honest second opinion on what the agent produced, the more comfortable you are letting it produce more.
/review makes that second opinion one command away — from a reviewer with no skin in the game, optionally a different model entirely, scoped to exactly the changes you care about. It's the code-review equivalent of asking someone who wasn't in the meeting.