Back to browse
regex-builder
officialplatinum (7/8)
Install
mayros skill install regex-builder
mayros skill install [email protected]
Regex pattern library, explain mode, multi-language syntax reference
README
@apilium/regex-builder
Build, explain, and test regular expressions with examples. Provides common patterns, syntax reference, cross-language differences, and performance guidance.
Installation
Copy this skill directory into your Mayros skills folder:
cp -r skills/regex-builder ~/.mayros/skills/regex-builder
Or install via the Mayros CLI:
mayros skill install @apilium/regex-builder
Usage
Once configured, the agent can:
- Build patterns: generate a regex for email, URL, phone, UUID, date, semver, and more
- Explain patterns: break any regex into plain English, token by token
- Test patterns: provide test strings and show which match, which do not, and extracted groups
- Cross-language: adjust syntax for JavaScript, Python, Go, Rust, or Java
- Performance: detect catastrophic backtracking and suggest safe alternatives
Example prompts
"Build a regex to validate email addresses"
"Explain this regex: /^(?:\+?1[-.\s]?)?\(?[0-9]{3}\)?[-.\s]?[0-9]{3}[-.\s]?[0-9]{4}$/"
"Test this URL regex against these strings: https://example.com, ftp://bad, not-a-url"
"Convert this JavaScript regex to Python syntax"
"Is /^(a+)+$/ safe from backtracking?"
Semantic Predicates
| Predicate | Scope | Description |
|---|---|---|
| regex:pattern_created | agent | Patterns built by the agent |
| regex:explanation | agent | Pattern explanations recalled by the agent |
License
MIT
Versions
Comments
Sign in to leave a comment.
Loading comments...