This repository was archived by the owner on Nov 22, 2026. It is now read-only.
Repository navigation
mojo-uregex v0.3.1
mojo-uregex v0.3.1
Released: 2026-10-29 · Commit: 3222bf2 · Previous: v0.3.0
What it does
Unicode-aware regular expressions for Mojo, built for the pre-tokenizers of LLM
tokenizers (GPT-2, Llama 3, Qwen, DeepSeek, gpt-oss, Spark-X2.5) and checked
against Python's regex by differential testing. Pure Mojo, CPU. Build with
-I src; requires Mojo 1.2.
Highlights
- Builds and runs on the stable Mojo 1.2.0 release.
Changes
Changed
- The pin moves to Mojo 1.2.0 (
pyproject.toml); README says Mojo 1.2.
Fixed
- The library did not build on Mojo 1.2.0:
String(StringSlice(unsafe_from_utf8=...))sends the compiler into a recursion. It now usesString(unsafe_from_utf8=...), which builds on 1.1 and 1.2.
Verified
| Check | Result |
|---|---|
README setup in an empty directory (mojo==1.2.0), then tools/gate.sh |
PASS, 14/14 tests, every differential run |
Known limits
- As in v0.3.0.
Upgrade / run
python3 -m venv .venv && ./.venv/bin/pip install 'mojo==1.2.0' 'regex==2026.9.29'
Commits
3222bf2build: Mojo 1.2.0b4f718cfix: String(unsafe_from_utf8=X) instead of wrapping StringSlicefec09c0docs: NOTICE names the owner and contact