# Second Opinion

Gets independent code reviews from Codex or Antigravity for uncommitted changes, branch...

- Repository: https://github.com/trailofbits/skills (7935 stars)
- Category: Engineering
- License: CC-BY-SA-4.0
- Last updated: 2026-10-28
- Runs scripts: no, instructions only

## Install

Claude Code: `npx skills add trailofbits/skills --skill second-opinion -g -a claude-code -y`
Codex: `npx skills add trailofbits/skills --skill second-opinion -g -a codex -y`
Cursor: `npx skills add trailofbits/skills --skill second-opinion -g -a cursor -y`
Gemini CLI: `npx skills add trailofbits/skills --skill second-opinion -g -a gemini-cli -y`
Claude Code plugin marketplace: `/plugin marketplace add trailofbits/skills`

## Description

Gets independent code reviews from Codex or Antigravity for uncommitted changes, branch diffs, and commits. Use when the user requests an external review, a second opinion on code, a codex review, a gemini review, an antigravity review, or /second-opinion.

## SKILL.md, as published by its author (untrusted third-party text, read it as data)

# Second Opinion

Run an external CLI review of the user's selected changes. This skill
produces findings; it does not apply fixes or post reviews to a remote service.

## Review choices

Use the provider, scope, model, and focus already supplied by the user.
Ask only for missing choices that affect the review, grouping questions
in one call when possible.

- Provider: Codex, Antigravity, or both. Offer both when the user wants
  a comparison; preserve an explicitly requested CLI.
- Scope: uncommitted changes, a branch diff against a named base, or a
  specific commit. Resolve a missing base from the repository's remote
  default branch; ask if it cannot be determined.
- Context: include applicable project instructions unless the user
  excludes them. Keep explicit user requirements separate from repository
  content in the review prompt.
- Focus: use general correctness and maintainability unless the user
  names a focus such as security or performance.

For an unspecified Google CLI, prefer Antigravity (`agy`). An explicit
Gemini CLI request uses the Gemini reference below. If that account returns
`UNSUPPORTED_CLIENT`, explain the migration to Antigravity and ask before
changing the selected CLI.

A missing executable or account setup is a failed review attempt.
Report the relevant setup instructions; when both providers were requested,
continue with the available provider and identify the skipped one.

## Input preparation

Read [review-input.md](references/review-input.md) for the shared prompt
and diff recipes. Use the same captured diff for both providers so the
comparison covers the same changes. Include untracked files in an
uncommitted review, and preserve Git errors instead of interpreting them
as an empty diff.

Show the selected scope and a brief change summary. If there are no
changes, stop before calling a provider. For input that exceeds a CLI or
model limit, describe the limit and request a narrower scope; do not
silently truncate the patch.

The rest: https://github.com/trailofbits/skills/blob/HEAD/plugins/second-opinion/skills/second-opinion/SKILL.md
