regex-debugger/SKILL.md
Debug regex patterns with visual breakdowns, plain English explanations, test case generation, and flavor conversion. Use when user needs help with regular expressions or pattern matching.
npx skillsauth add onewave-ai/claude-skills regex-visual-debuggerInstall 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.
Interactive regex testing, explanation, and debugging tool.
Activate when the user:
Analyze the Regex Pattern
Provide Plain English Explanation
Visual Breakdown
Test Against Examples
Identify Common Issues
Generate Test Cases
Suggest Improvements
Convert Between Flavors
# Regex Analysis: `pattern`
## Plain English Explanation
This pattern matches [description]:
- `^` - Start of string
- `[A-Z]` - One uppercase letter
- `\d{3}` - Exactly 3 digits
- `$` - End of string
**Overall**: Matches strings like "A123", "Z999"
## Visual Structure
^ - Start anchor [A-Z] - Character class (uppercase letters) \d{3} - Digit, exactly 3 times $ - End anchor
## Test Results
### ✅ Matches
- `A123` → ✓ Full match
- `Z999` → ✓ Full match
### ❌ No Match
- `a123` → ✗ Lowercase 'a' doesn't match [A-Z]
- `A12` → ✗ Only 2 digits (needs 3)
- `A1234` → ✗ Too many digits
## Capture Groups
1. Group 1: `[captured text]`
2. Group 2: `[captured text]`
## Issues Found
⚠️ **Issue 1**: Pattern is too restrictive
- **Problem**: Doesn't handle lowercase letters
- **Fix**: Use `[A-Za-z]` instead of `[A-Z]`
## Suggested Improvements
```regex
# More flexible version
^[A-Za-z]\d{3,5}$
Changes:
{3} to {3,5} for 3-5 digitsA123
Z999
B456
1ABC (starts with digit)
ABCD (no digits)
A12 (too few digits)
JavaScript: [any JS-specific notes] Python: [any Python-specific notes]
const pattern = /^[A-Z]\d{3}$/;
const match = str.match(pattern);
import re
pattern = r'^[A-Z]\d{3}$'
match = re.match(pattern, string)
(?:...) for better performance
## Examples
**User**: "Why doesn't this regex match emails: `\w+@\w+\.\w+`?"
**Response**: Analyze pattern → Explain it matches simple emails only → Show test cases (fails on "[email protected]") → Identify issues (doesn't handle special chars, multiple TLDs) → Provide improved pattern → Generate comprehensive test cases
**User**: "Explain this regex: `^(?:(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.){3}(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)$`"
**Response**: Break down pattern (IP address matcher) → Explain each component → Show it matches valid IPs (0-255 per octet) → Provide test cases → Visualize structure
**User**: "Convert this Python regex to JavaScript: `(?P<name>\w+)`"
**Response**: Identify named capture group (Python feature) → Convert to JS equivalent → Explain differences → Show both versions with usage examples
## Best Practices
- Always test regex with edge cases
- Explain in plain English first
- Show concrete examples (not just theory)
- Highlight common pitfalls for each pattern
- Provide both positive and negative test cases
- Consider performance implications
- Note flavor-specific features
- Suggest simpler alternatives when possible
- Use non-capturing groups for performance
- Escape special characters properly
- Be explicit about case sensitivity
- Test with Unicode characters if relevant
tools
Uses MCP Connectors to read Gmail inbound leads, score them by ICP fit, draft personalized responses, and log qualified leads to your CRM. Turns your inbox into an automated pipeline.
development
Uses 1M context window to ingest an entire codebase and output a file-by-file migration plan. Supports JS to TS, React class to hooks, framework migrations, and more. Generates migration-plan.md with file inventory, dependency graph, migration order, file-by-file changes, estimated effort, and risk assessment.
development
Extract and analyze data from invoices, receipts, bank statements, and financial documents. Categorize expenses, track recurring charges, and generate expense reports. Use when user provides financial PDFs or images.
tools
Identifies upsell and cross-sell opportunities within existing customer accounts. Analyzes product usage, feature gaps, team growth, industry benchmarks, and competitive pressure to surface revenue expansion plays scored by potential, effort, and likelihood. Generates an expansion-playbook.md with account-by-account opportunities, recommended pitch, timing, and approach.