brainstorming
brainstorming
You MUST use this before any creative work - creating features, building components, adding functionality, modifying behavior, or planning anything new, in software or out of it (a talk, a business, a renovation).
vibe-code-auditorAudit AI-generated or rapidly-prototyped code for structural flaws, hallucinated imports, fragility, and production risks before committing or handing off. Use when code was generated with AI assistance, evolved without deliberate architecture, or a prototype needs productionizing.
Independent GitHub snapshot · Automated classification · Original documentation governs
NO FINDINGS WITHOUT CODE EVIDENCE — every issue must cite file and line number (or structural location for snippets). Do not speculate about code you have not read.
AI-generated and rapidly-prototyped code that "works" may contain hallucinated imports, missing library versions, architectural fragility, and production risks that are invisible during casual review.
This skill is the pre-commit gate for AI-assisted code — it runs before code-reviewer and security-reviewer to catch AI-specific artifacts first.
Core distinction from code-reviewer: code-reviewer assumes production-intent code. This skill assumes prototype/AI-generated code and specifically checks for hallucinated APIs and prototype-to-production gaps.
Before beginning, confirm:
Quick Scan (first 60 seconds):
Pattern Recognition Shortcuts:
| Pattern | Likely Issue | Quick Check |
|---|---|---|
eval(), exec(), os.system() | Security critical | Search for these strings |
except: or except Exception: | Silent failures | Grep for bare excepts |
password, secret, key, token in code | Hardcoded credentials | Search + check if literal string |
if DEBUG, debug=True | Insecure defaults | Check config blocks |
| Functions >50 lines | Maintainability risk | Count lines per function |
Nested if >3 levels | Complexity hotspot | Visual scan |
| No tests in repo | Quality gap | Look for test_ / *.spec.ts files |
| Direct SQL string concat | SQL injection | Search for f"SELECT or + "SELECT |
| HTTP client calls without timeout | Production risk | Check fetch/axios/requests calls |
while True without break | Unbounded loop | Search for infinite loops |
Evaluate across all 7 dimensions. For each finding: dimension, title, location (file:line), severity, explanation, recommendation.
get_user vs fetchUser vs retrieveUserData)except or catch-all handlers that swallow failures silentlyevalDEBUG=True, permissive CORS)return, raise, or break in all paths)| Input size | Focus |
|---|---|
| Snippet (<100 lines) | Security, robustness, obvious bugs only |
| Single file (100-500 lines) | Add architecture and maintainability |
| Multi-file system (500+ lines) | Full audit across all 7 dimensions |
Produce the audit report in this exact structure. If a section has no findings, write "None identified."
Input: [file name(s) or "code snippet"] Assumptions: [list any assumptions about context or environment] Quick Stats: [X files, Y lines of code, Z language/framework]
In 3-5 bullets:
- [CRITICAL/HIGH] Most severe issue
- [CRITICAL/HIGH] Second most severe issue
- [MEDIUM] Notable pattern
- Overall: Deployable as-is / Needs fixes / Requires major rework
For each issue:
[CRITICAL] Short descriptive title
Location: filename.ts, line 42
Dimension: Architecture / Security / Robustness / etc.
Problem: What is wrong and why it is dangerous.
Fix: Minimum change required.
Code Fix (if applicable):
// Before: ...
// After: ...
Same format as Critical, tag [HIGH].
Same format, tag [MEDIUM] or [LOW].
Score: XX / 100
Scoring algorithm:
Start at 100
CRITICAL issue: -15 (security CRITICAL: -20)
HIGH issue: -8
MEDIUM issue: -3
Pervasive pattern (3+ similar issues): -5 additional
Floor: 0, Ceiling: 100
| Range | Meaning |
|---|---|
| 0-30 | Not deployable |
| 31-50 | High risk — significant rework required |
| 51-70 | Low-stakes / internal only with close monitoring |
| 71-85 | Production-viable with targeted fixes |
| 86-100 | Production-ready |
Top 3-5 changes in impact order:
1. [P1 - Blocker] Fix title — addresses [CRITICAL #1] — effort: S/M/L — prevents [specific failure]
2. [P2 - Blocker] Fix title — addresses [CRITICAL #2] — effort: S/M/L
3. [P3 - High] Fix title — addresses [HIGH #1] — effort: S/M/L
Effort: S = <1 day, M = 1-3 days, L = >3 days
processPayment()").| Finding Type | Next Skill |
|---|---|
| Deep security vulnerabilities found | security-reviewer — full OWASP deep-dive |
| Architectural anti-patterns found | architect-review — distributed systems assessment |
| Tests missing across codebase | test-driven-development — Red-Green-Refactor cycle |
| Duplicate logic patterns found | dedup-code-agent — systematic deduplication |