This skill should be used for thorough AI review via Codex CLI (gpt-5.2-max). Triggers include architectural decisions, blocking issues, final review before done, or when consult-light escalates due to low confidence.
Inherits all available tools
Additional assets for this skill
This skill inherits all available tools. When active, it can use any tool Claude has access to.
references/codex-config.mdreferences/escalation-patterns.mdreferences/review-prompts.mdthorough consultation tier using Codex CLI with gpt-5.2-max. architectural decisions, blocking issues, final review. receives escalations from consult-light.
"when you need to be sure, not just fast"
| principle | application |
|---|---|
| thorough analysis | examine all relevant code, not just snippets |
| second opinion | independent verification of consult-light decisions |
| structured review | use metaprompt patterns for consistency |
| clear escalation | surface to HIL when truly blocked |
| use | skip |
|---|---|
| architectural decisions | simple progress checks (→ consult-light) |
| blocking issues | context synthesis (→ consult-light) |
| final review before done | pre-flight validation (→ consult-light) |
| consult-light escalation | quick sanity checks (→ consult-light) |
| complex multi-file changes | single file edits |
codex exec --model gpt-5.2-max --approval-mode xhigh
| param | value | reason |
|---|---|---|
| model | gpt-5.2-max | best reasoning, most thorough |
| approval-mode | xhigh | maximum autonomy for analysis |
codex exec --model gpt-5.2-max --approval-mode xhigh \
"Architectural review needed.
Context:
- Issue: {issue_id} - {issue_title}
- Files involved: {file_list}
- Proposed approach: {approach}
- consult-light confidence: {confidence}
Task: Review this architectural decision.
Consider:
1. Does this fit existing patterns in the codebase?
2. Are there simpler alternatives?
3. What are the risks?
4. What's the recommended path forward?
Output structured analysis with:
- Decision: approve | reject | needs_clarification
- Reasoning: detailed justification
- Action items: specific next steps
- Confidence: 0-10"
codex exec --model gpt-5.2-max --approval-mode xhigh \
"Blocking issue analysis.
Context:
- Issue: {issue_id}
- What was attempted: {attempts}
- Current blocker: {blocker_description}
- Error messages: {errors}
Task: Diagnose and propose solution.
Workflow:
1. Read relevant files
2. Understand the root cause
3. Propose concrete fix
4. If truly blocked, explain why and what's needed
Output:
- Root cause: what's actually wrong
- Solution: specific code changes
- If blocked: what human input is needed
- Confidence: 0-10"
codex exec --model gpt-5.2-max --approval-mode xhigh \
"Final review before marking done.
Context:
- Issue: {issue_id} - {issue_title}
- Changes made: {change_summary}
- Tests: {test_status}
- consult-light assessment: {assessment}
Task: Verify this work is complete and correct.
Check:
1. Does it satisfy the issue requirements?
2. Are tests comprehensive?
3. Any edge cases missed?
4. Ready for PR?
Output:
- Status: ready | needs_work | blocked
- Issues found: list or empty
- Recommended next steps
- Confidence: 0-10"
codex exec --model gpt-5.2-max --approval-mode xhigh \
"Code review for changes.
Context:
- Issue: {issue_id}
- Diff: {diff_or_file_list}
Task: Review as if this were a PR.
Audit passes:
1. Correctness: logic errors, edge cases
2. Security: injection, XSS, secrets
3. Performance: N+1, hot paths
4. Maintainability: naming, structure
5. Tests: coverage, quality
Output:
- Merge readiness: 0-10
- Blocking issues: list with file:line
- Non-blocking suggestions: list
- Summary: 2-3 sentences"
when consult-deep can't resolve (confidence < 5 or explicit block):
# create gist with full context
gh gist create -p -d "HIL needed: {issue_id}" \
-f context.md << 'EOF'
## Issue
{issue_context}
## What was attempted
{attempts}
## consult-light analysis
{consult_light_output}
## consult-deep analysis
{consult_deep_output}
## Blocking question
{specific_question}
## Options considered
{options}
EOF
# add Linear comment (if linear CLI available)
command -v linear &>/dev/null && \
linear comment create -i {issue_id} -b "HIL escalation: {blocker}. Full context: {gist_url}"
# output for manual follow-up
echo "HIL needed for {issue_id}"
echo "Blocker: {blocker}"
echo "Context: {gist_url}"
# basic invocation
codex exec --model gpt-5.2-max "prompt"
# with high autonomy
codex exec --model gpt-5.2-max --approval-mode xhigh "prompt"
# with workspace
codex exec --model gpt-5.2-max --cwd /path/to/project "prompt"
# check Codex status
codex --version
# list available models
codex models