Skip to content

My5t3r10us/cesizen / .agents/skills/apex

Systematic implementation using APEX methodology (Analyze-Plan-Execute-eXamine) with optional parallel subagents, self-validation, and adversarial review. Use when implementing features, fixing bugs, or making code changes that benefit from structured workflow.

steps/step-06-resolve.md

View on GitHub
---
name: step-06-resolve
description: Resolve findings - interactively address review issues
prev_step: steps/step-05-examine.md
next_step: COMPLETE
---

# Step 6: Resolve Findings

## MANDATORY EXECUTION RULES (READ FIRST):

- πŸ›‘ NEVER auto-fix Noise or Uncertain findings
- πŸ›‘ NEVER skip validation after fixes
- βœ… ALWAYS present resolution options to user (unless auto_mode)
- βœ… ALWAYS validate after applying fixes
- βœ… ALWAYS provide clear completion summary
- πŸ“‹ YOU ARE A RESOLVER, addressing identified issues
- πŸ’¬ FOCUS on "How do we fix these issues?"
- 🚫 FORBIDDEN to proceed with failing validation

## EXECUTION PROTOCOLS:

- 🎯 Present resolution options first
- πŸ’Ύ Log each fix applied (if save_mode)
- πŸ“– Validate after all fixes
- 🚫 FORBIDDEN to skip post-fix validation

## CONTEXT BOUNDARIES:

- Findings from step-05 are classified
- Some are Real, some Noise, some Uncertain
- User may want different resolution strategies
- Must validate after any changes
- **If `{teams_mode}` = true:** Agent team is still alive. Do NOT shutdown teammates β€” that happens in step-09-finish only.

## YOUR TASK:

Address adversarial review findings interactively - fix real issues, dismiss noise, discuss uncertain items.

---

<available_state>
From previous steps:

| Variable | Description |
|----------|-------------|
| `{task_description}` | What was implemented |
| `{task_id}` | Kebab-case identifier |
| `{auto_mode}` | Auto-fix Real findings |
| `{save_mode}` | Save outputs to files |
| `{output_dir}` | Path to output (if save_mode) |
| Findings table | IDs, severity, validity |
| Finding todos | For tracking |
</available_state>

---

## EXECUTION SEQUENCE:

### 1. Initialize Save Output (if save_mode)

**If `{save_mode}` = true:**

```bash
bash {skill_dir}/scripts/update-progress.sh "{task_id}" "06" "resolve" "in_progress"
```

Append logs to `{output_dir}/06-resolve.md` as you work.

### 2. Present Resolution Options

**If `{auto_mode}` = true:**
β†’ Auto-fix all "Real" findings, skip Noise/Uncertain

**If `{auto_mode}` = false:**

```yaml
questions:
  - header: "Resolution"
    question: "How would you like to handle these findings?"
    options:
      - label: "Auto-fix Real issues (Recommended)"
        description: "Fix 'Real' findings, skip noise/uncertain"
      - label: "Walk through each finding"
        description: "Decide on each finding individually"
      - label: "Fix only critical"
        description: "Only fix CRITICAL/BLOCKING issues"
      - label: "Skip all"
        description: "Acknowledge but don't change"
    multiSelect: false
```

### 3. Apply Fixes Based on Choice

**Auto-fix Real:**
1. Filter to Real findings only
2. For each: Read file β†’ Apply fix β†’ Verify
3. Log each fix

**Walk through each:**
For each finding in severity order:

```yaml
questions:
  - header: "F1"
    question: "How should we handle this finding?"
    options:
      - label: "Fix now (Recommended)"
        description: "Apply the suggested fix"
      - label: "Skip"
        description: "Acknowledge but don't fix"
      - label: "Discuss"
        description: "Need more context"
      - label: "Mark as noise"
        description: "Not a real issue"
    multiSelect: false
```

**Fix only critical:**
1. Filter to CRITICAL/BLOCKING only
2. Auto-fix those, skip others

**Skip all:**
1. Acknowledge findings
2. If Critical/High exist, confirm:

```yaml
questions:
  - header: "Confirm"
    question: "You have unresolved Critical/High findings. Proceed anyway?"
    options:
      - label: "Go back and fix"
        description: "Return to resolution options"
      - label: "Proceed anyway"
        description: "Accept risks, continue"
      - label: "Fix only critical"
        description: "Just fix critical issues"
    multiSelect: false
```

### 4. Post-Resolution Validation

After any fixes:

```bash
bun run type-check && bun run lint
```

Both MUST pass.

### 5. Resolution Summary

```
**Resolution Complete**

**Fixed:** {count}
- F1: Parameterized SQL query in auth.ts:42
- F2: Added null check in handler.ts:78

**Skipped:** {count}
- F3: Complex function (uncertain)

**Validation:** βœ“ Passed
```

### 6. Complete Save Output (if save_mode)

**If `{save_mode}` = true:**

Append to `{output_dir}/06-resolve.md`:
```markdown
---
## Step Complete
**Status:** βœ“ Complete
**Findings fixed:** {count}
**Findings skipped:** {count}
**Validation:** βœ“ Passed
**Timestamp:** {ISO timestamp}
```

### 7. Completion Summary

```
**APEX Workflow Complete**

**Task:** {task_description}

**Implementation:**
- Files modified: {count}
- All checks passing: βœ“

**Review:**
- Findings identified: {total}
- Findings resolved: {fixed}
- Findings skipped: {skipped}

**Next Steps:**
- [ ] Commit changes
- [ ] Run full test suite
- [ ] Deploy when ready
```

---

## SUCCESS METRICS:

βœ… User chose resolution approach
βœ… All chosen fixes applied correctly
βœ… Validation passes after fixes
βœ… Clear summary of resolved/skipped
βœ… User understands next steps

## FAILURE MODES:

❌ Auto-fixing Noise or Uncertain findings
❌ Not validating after fixes
❌ No clear completion summary
❌ Proceeding with failing validation
❌ **CRITICAL**: Not using AskUserQuestion for decisions

## RESOLUTION PROTOCOLS:

- Only auto-fix Real findings
- Validate after EVERY fix round
- Clear summary at the end
- User controls final decision

---

## NEXT STEP:

Based on flags:
- **If verify_mode:** Load `./step-10-verify.md` to verify feature
- **If pr_mode:** Load `./step-09-finish.md` to create pull request
- **Otherwise:** Workflow complete - show summary

<critical>
Remember: Always validate after fixes - never proceed with failing checks!
</critical>
reverse-engineer-anythingmorluto/reaReverse engineer native, managed, Electron/JavaScript, packaged, firmware, and browser targets with REA, and build agent environments (AgentEnv bundles) of web applications from a live instance or a capture, and of Linux desktop apps with a task from a request. Use shipped-artifact or requested runtime evidence to explain features, compare versions, decompile code, or guide a reconstruction. Skip REA for ordinary source-repository architecture analysis.Stars: 472kUpdated Claude CodeCodexVerifiedInstall
diagnosing-superpowersobra/superpowersUse when a superpowers session went wrong and your human partner wants to know why β€” repeated work, ignored plans, stumbles, poor results, a skill that didn't fire, "it took too long", "why is it so expensive", "what is it doing" β€” or wants to build a bug report for the superpowers maintainers, for the current session or a past one identified by id or path, on any harness.Stars: 322kUpdated Claude CodeCodexVerifiedInstall
dispatching-parallel-agentsobra/superpowersUse when facing 2+ independent tasks that can be worked on without shared state or sequential dependenciesStars: 322kUpdated Claude CodeCodexVerifiedInstall
executing-plansobra/superpowersUse when executing an implementation plan in the current session as the implementer yourself β€” your human partner chose inline execution, or no subagent tool is availableStars: 322kUpdated Claude CodeCodexVerifiedInstall