skills/opportunistic-improvement/SKILL.md
Two modes — (1) While working, notice and fix code smells in files you're already touching. (2) When idle, suggest the highest-impact improvements across the project. Always-on mini-audit while working, proactive suggestions when idle.
npx skillsauth add nhouseholder/nicks-claude-code-superpowers opportunistic-improvementInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Every file Claude reads is a chance to make the project better. Not a full audit — just sharp eyes while you work. If you stumble across something that's clearly subpar, fix it or flag it. The project should get better with every interaction, not just when explicitly asked.
This skill runs passively while you work on other tasks. It does NOT:
It DOES:
While reading/editing files for your current task, notice issues and fix no-brainers in-place (marginal cost is near zero since you're already there). Report all improvements at the end.
Fix these without asking — they're universally good and risk-free:
| Category | Examples |
|----------|---------|
| Dead code | Unused imports, commented-out blocks, unreachable code, unused variables |
| Obvious bugs | Unclosed resources, missing awaits, wrong comparison operators |
| Performance freebies | Unnecessary re-renders, missing keys in React lists, N+1 patterns in plain sight |
| Naming clarity | data → strainResults, temp → pendingScore, x → terpeneWeight |
| Consistency | Mixing const/let for same pattern, inconsistent quote styles, mixed naming conventions |
| Security basics | Console.log with sensitive data, hardcoded secrets, missing input sanitization |
| DX improvements | Missing helpful comments on non-obvious logic, outdated TODO comments |
1. Is the fix obviously correct? (No judgment calls)
2. Can it break anything? (No side effects)
3. Is it in a file I'm already touching? (No extra file reads)
4. Would ANY developer agree this is better? (Universal improvement)
All 4 = YES → Fix it silently
Any = NO → Flag it, don't fix
Flag these at the end — don't fix without asking:
| Category | Why Ask | |----------|---------| | Refactoring patterns | Changing how something works, even if cleaner | | API changes | Renaming exports, changing function signatures | | Architecture shifts | Moving files, restructuring modules | | Dependency changes | Adding/removing/updating packages | | Logic changes | Altering behavior, even if current behavior seems wrong | | Large-scale consistency | Renaming used across many files |
At the end of your response, after completing the primary task:
---
Improvements made while working:
- Removed 3 unused imports in QuizResults.jsx
- Fixed missing await on fetchStrainData() in useStrains.js
- Renamed `data` → `matchResults` for clarity in recommend.js
Also noticed (needs your call):
- dispensaryService.js has duplicated geocoding logic (lines 45-67 and 112-134) — want me to extract a shared helper?
When all tasks are complete and no active workflow exists, scan the project across 8 dimensions:
Quality bar: Every suggestion must be specific, grounded in code you've seen, impactful, actionable, and aligned with the user's goals.
Top 1-3 only — Pick the highest-impact improvements. Don't dump a laundry list.
Ask, don't do — Suggest improvements and wait for approval before implementing. If the user declines, back off.
Boundary with predictive-next: predictive-next suggests the next step in an active workflow. Proactive mode fires only when there IS no active workflow and no obvious next step.
tools
Unified context management and session continuity skill. Combines total-recall, strategic-compact, /ledger, and session continuity. Runs in background to preserve critical context across compaction and sessions.
tools
Toolkit for interacting with and testing local web applications using Playwright. Supports verifying frontend functionality, debugging UI behavior, capturing browser screenshots, and viewing browser logs.
tools
Suggest /ultraplan for complex planning tasks on Claude Code CLI (2.1.91+ only). Research preview.
tools
UI/UX design intelligence. 50 styles, 21 palettes, 50 font pairings, 20 charts, 9 stacks (React, Next.js, Vue, Svelte, SwiftUI, React Native, Flutter, Tailwind, shadcn/ui). Actions: plan, build, create, design, implement, review, fix, improve, optimize, enhance, refactor, check UI/UX code. Projects: website, landing page, dashboard, admin panel, e-commerce, SaaS, portfolio, blog, mobile app, .html, .tsx, .vue, .svelte. Elements: button, modal, navbar, sidebar, card, table, form, chart. Styles: glassmorphism, claymorphism, minimalism, brutalism, neumorphism, bento grid, dark mode, responsive, skeuomorphism, flat design. Topics: color palette, accessibility, animation, layout, typography, font pairing, spacing, hover, shadow, gradient. Integrations: shadcn/ui MCP for component search and examples.