Install
openclaw skills install @ehsanghaffar/persian-documentsGenerate production-quality Persian documents with correct RTL layout, bidirectional text handling, and professional typography. Use this skill whenever the user asks to create Persian documents — reports, letters, articles, technical documentation, resumes, PDFs, Word documents, or any document containing Persian text mixed with English, numbers, code, URLs, or other LTR content. Also trigger when the user asks to "fix RTL" or "fix direction" in a Persian document, or when a document needs to be regenerated because Persian text rendered incorrectly. This skill is NOT just for writing Persian prose — it is for producing documents where the final rendered output is typographically correct, structurally sound, and ready for real-world use.
openclaw skills install @ehsanghaffar/persian-documentsGenerate professional Persian documents that render correctly as RTL, not just Persian text inserted into an LTR layout.
Persian document generation is a RTL and bidirectional text rendering problem, not simply writing Persian text. The final rendered document — not the source text — is the judge of correctness.
Never:
Always:
| Format | Tool | Best for |
|---|---|---|
| DOCX | scripts/generate_docx.py | Editable Word documents, formal letters, reports |
scripts/generate_pdf.py | Finalized documents, print-ready, shared output | |
| Markdown | Direct | Drafting, simple articles, notes |
Before generating, identify:
Use the appropriate script with RTL-aware settings. The scripts handle:
After generation, check:
Persian text must be stored and processed in logical order (the order characters are typed and read), not visual order (the order they appear on screen). The document renderer handles the visual display.
Correct: The text "سلام دنیا" is stored as سلام دنیا (logical order) Wrong: Reversing to "ادینمالس" or manually rearranging characters
When Persian and English appear together, each runs in its own direction within the same paragraph. The document format handles this — the model must not try to rearrange characters.
Examples of correct mixed content:
نسخه Next.js 16.0.7 منتشر شد.API: https://api.example.com/v1/usersnpm install @tanstack/react-queryایمیل پشتیبانی: hello@example.comIn all cases, the Persian and English each maintain their own direction. The English is not reversed, and the Persian is not reordered.
$1,299.99 not 99.95$1,299Tables in Persian documents must have:
Professional Persian documents include:
Before finalizing any document, verify:
scripts/generate_docx.py — Generate RTL-aware Word documents with mixed-direction supportscripts/generate_pdf.py — Generate PDFs with correct Persian text shaping and RTL layoutscripts/validate_doc.py — Validate rendered documents for RTL correctness and common issues