rtl-bidi-lint
Skill43 starsChanged 29 days agoMITView on GitHub
Use when reviewing or generating Arabic text, UI strings, HTML or Markdown that mixes RTL with LTR content, to catch digit mixing, unbalanced bidi isolates, stray LTR marks and hardcoded dir="ltr".
We split this skill into the rules it gives an agent
1 rule. About 0 are common, 1 is distinctive, and 0 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈1
Distinctive · estimate
This author's own choices. Worth a look.
0
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 29
Run the script on the files in question (or write the text to a temp file first).
≈ “Common” is an estimate: at least 1 in 5 of the 308,232 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
RTL / Bidi Lint
Runs a small stdlib-only linter over text files and explains each finding.
Run
python ${CLAUDE_PLUGIN_ROOT}/skills/rtl-bidi-lint/bidi_lint.py <files...>Output lines look like path:line: CODE message. Exit code 1 means findings, 0 means clean.
Codes and fixes
| Code | Meaning | Fix |
MIXED_DIGITS | Arabic-Indic (٠-٩ or ۰-۹) and ASCII (0-9) digits on one line | Pick one digit system per document. Use ASCII for code, IDs, prices and data; Arabic-Indic only for prose when the audience expects it. |
UNBALANCED_ISOLATE | U+2066, U+2067 or U+2068 opened without a matching U+2069 | Close every isolate. Wrap embedded LTR runs (names, URLs, code) as U+2068 ... U+2069 (first-strong isolate). |
LTR_MARK_IN_ARABIC | U+200E sits between Arabic letters | Remove it. It breaks letter joining and shaping. If direction needs forcing, use an isolate around the foreign run instead. |
HARDCODED_LTR | dir="ltr" on a line that contains Arabic | Use dir="auto" for user content, or dir="rtl" for known-Arabic blocks. |
Procedure
- Run the script on the files in question (or write the text to a temp file first).
- For each finding, show the line and apply the fix from the table.
- Re-run until exit code 0.
Limits
The linter is line-based and heuristic. It does not render text, so check the final result visually when layout matters.
In this repository6 other files it gives its agents.
- CLAUDE.mdCLAUDE.md
- dist/llms.txtllms.txt
- arabic-ai-advisorSkill
- arabic-dialect-promptsSkill
- arabic-token-costSkill
- tashkeel-checkSkill
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.

