regex-explainer
Skill2 starsChanged 4 days agoMITView on GitHub
Takes any regular expression and explains it piece by piece in plain English, shows what it matches on sample text, flags risky parts like greedy matches and catastrophic backtracking, and suggests a safer or simpler version. Use when the user pastes a regex and wants to understand or fix it.
1 other project uses a version of this.
Adopted by
Most recently taken up by
- Lethe044/agentskill-kittheir own version, first seen Nov 15, 2026
Other versions1 project uses a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 1
- Lethe044/agentskill-kit★ 50same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository76 other files it gives its agents.
- customer-reply-helperSkill
- product-description-writerSkill
- research-briefSkill
- research-workflowSkill
- cold-outreach-writerSkill
- cover-letter-writerSkill
- interview-practice-coachSkill
- linkedin-about-writerSkill
- resume-bullet-rewriterSkill
- star-story-builderSkill
- code-reviewerSkill
- code-review-pipelineSkill
- commit-message-writerSkill
- explain-errorSkill
- git-helperSkill
- readme-writerSkill
- test-writerSkill
- character-voice-builderSkill
- plot-hole-detectorSkill
- poem-polisherSkill
- story-idea-generatorSkill
- worldbuilding-questionsSkill
- chart-chooserSkill
- data-cleaning-advisorSkill
- data-storytellerSkill
- spreadsheet-formula-helperSkill
- sql-query-explainerSkill
- api-reference-writerSkill
- bug-repro-writerSkill
- changelog-generatorSkill
- dependency-upgrade-advisorSkill
- log-analyzerSkill
- release-notes-writerSkill
- contract-red-flag-scannerSkill
- policy-first-draftSkill
- privacy-notice-writerSkill
- terms-simplifierSkill
- beginner-workout-builderSkill
- habit-system-builderSkill
- meal-prep-plannerSkill
- travel-itinerary-plannerSkill
- explain-like-im-newSkill
- quiz-flashcard-makerSkill
- study-plan-makerSkill
- glossary-builderSkill
- readme-localizerSkill
- translation-workflowSkill
- ad-copy-ab-testerSkill
- keyword-cluster-builderSkill
- landing-page-copywriterSkill
- seo-meta-writerSkill
- social-calendar-builderSkill
- subject-line-testerSkill
- bill-split-plannerSkill
- invoice-draft-writerSkill
- personal-budget-builderSkill
- price-quote-writerSkill
- subscription-audit-helperSkill
- decision-helperSkill
- meeting-notes-cleanerSkill
- The first 60 shown.
The file
We split this skill into the rules it gives an agent
7 rules. About 0 are common, 6 are distinctive, and 1 is very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈6
Distinctive · estimate
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 15
If no sample text is given, invent two or three short sample strings yourself and say they are examples you made.
- Very specific: line 16
If the flavor is unknown, explain using common syntax and note the places where flavors differ (e.g.
- Distinctive: line 17
If the paste might be a glob or shell pattern instead of a regex, ask one question before explaining.
- Distinctive: line 21
Run the regex mentally on 2-3 sample strings and show exactly which parts match and which do not.
- Distinctive: line 23
If a simpler or safer regex does the same job, show it and explain the difference.
- Distinctive: line 39
Never claim a regex is safe for security-sensitive matching (emails, cards) without caveats.
- Distinctive: line 40
If the regex has a bug (unbalanced bracket, typo), say so in the first line and show the corrected form.
≈ “Common” is an estimate: at least 1 in 5 of the 408,460 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Regex Explainer
Role
You are a friendly interpreter between regular expressions and humans.
Input
The user will paste a regular expression, and ideally some sample text it should match. They may name the flavor (JavaScript, Python, PCRE, POSIX, grep).
If the input is unclear
- If no sample text is given, invent two or three short sample strings yourself and say they are examples you made.
- If the flavor is unknown, explain using common syntax and note the places where flavors differ (e.g. lookbehind support,
\dvs[0-9]). - If the paste might be a glob or shell pattern instead of a regex, ask one question before explaining.
Steps
- Rewrite the regex into its pieces, in order, in a table: piece, what it matches, plain-English meaning.
- Run the regex mentally on 2-3 sample strings and show exactly which parts match and which do not.
- Flag risky or surprising parts: greedy quantifiers, unescaped dots, missing anchors, character classes that swallow more than expected, and catastrophic backtracking on nested quantifiers.
- If a simpler or safer regex does the same job, show it and explain the difference.
Output format
- What it matches, in one sentence
- Piece by piece (table: Part | Matches | Meaning)
- On samples (each sample with the matched part marked)
- Watch out (risks, or "nothing risky")
- A safer version (only if one helps)
Example
Input: /^\d{3}-\d{4}$/ with the sample "555-1234".
Output: one-sentence summary ("exactly 3 digits, a hyphen, 4 digits, nothing else"), a piece-by-piece table, the full match on the sample, no risks ("anchored and bounded"), and a note that [0-9]{3} is the same as \d{3} but stricter in some flavors.
Rules
- Explain every token; do not skip "obvious" ones.
- Be honest about flavor differences instead of guessing; say which flavor you assumed.
- Never claim a regex is safe for security-sensitive matching (emails, cards) without caveats.
- If the regex has a bug (unbalanced bracket, typo), say so in the first line and show the corrected form.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

