Security

Code Inspector

Try it

Scan AI-generated code for bugs before deploying — 8 static analysis checks from critical (hardcoded secrets, unsafe eval) to low (unused imports). Productio...

What it does

Scan AI-generated code for bugs before deploying — 8 static analysis checks from critical (hardcoded secrets, unsafe eval) to low (unused imports). Production-readiness score 0-100. Because AI code looks fine until it isn't.

The skill document

code-inspector

Problem → Solution

The problem: AI generates code that compiles and looks correct. But it silently drops edge case handling, hardcodes secrets, catches exceptions with bare except/pass, and uses mutable defaults. You deploy it. It breaks. Reddit is full of "I let Claude loose and it broke the entire site" stories.

The solution: One command scans any Python file for 8 categories of AI-code bugs. Critical → High → Medium → Low severity. Production-readiness score 0-100. Don't deploy AI code blind.

Quick Start

pip install git+https://github.com/minirr890112-byte/code-inspector.git

code-inspector app.py           # scan a file
cat app.py | code-inspector     # scan from pipe

What It Checks

CheckSeverityExample
Hardcoded secrets🔴 criticalapi_key = "sk-abc123"
Unsafe eval/exec🔴 criticaleval(user_input)
Infinite loops🔴 criticalappend-while-iterating
Mutable defaults🟠 highdef fn(items=[])
Shadowed builtins🟠 highlist = [1,2,3]
Bare except/pass🔴 criticalexcept: pass
Deep nesting🟡 medium5+ nested loops
Unused imports⚪ lowAST-based detection

Scoring

90-100: 🟢 PRODUCTION-READY
70-89:  🟡 NEEDS REVIEW
50-69:  🟠 HIGH RISK
0-49:   🔴 DO NOT DEPLOY

Star this repo if AI code has ever broken your production: github.com/minirr890112-byte/code-inspector

Related skills

Review code for bugs, security, architecture, smells, patterns, performance, tests, and refactor plans

2 installs

AI Code Review and Code Risk Review quality gate for Git Diff, release readiness, regression testing, security testing, dependency impact, runtime risk, LLM...

3 installs

Security scanner for AI agent skills. Detects hardcoded secrets, unsafe code execution, prompt injection, and malware patterns in under 50ms. Scan before you...

Security and compliance auditing tool for AI agents. Scans code for vulnerabilities, checks GDPR/CCPA compliance, generates risk reports with remediation guidance.

Get senior-engineer-level code reviews with severity ratings, security checks, and ready-to-paste PR comments.

25 installs1 stars

Scan AI prompts for injection, jailbreak, and sensitive data leak risks

5 installs