.cursorrules · git:20260915.1667a72 · 2026-09-15 · sha256 2ac456e79c849ed8

.cursorrules git:20260915.1667a72A

Immutable. This exact content is served forever at /api/v1/blob/2ac456e79c849ed8.

# Cursor Rules for PDF-Translate Skill
# High-fidelity vector PDF translation, layout preservation, and automated audit.

# Rule 1: Layout & Height Preservation
- Always enforce CSS @page size (e.g. A4 portrait, margin 12mm 15mm).
- Always wrap each page in a container with class `.page` and strict `max-height: 270mm` with `overflow: hidden`.
- Never allow unconstrained flex or table heights that expand across pages.

# Rule 2: Zero Hallucination Pipeline
- Always extract clause hierarchy trees and numerical metrics into a structured schema before filling templates.
- Never summarize, merge, or omit statutory sub-clauses (e.g. 2.1.1~2.1.8).
- Never fabricate non-existent numbers, dates, or workflow steps.

# Rule 3: Automated Verification
- After generating HTML, run `python scripts/render_pdf.py input.html output.pdf --strict-overflow`.
- Always audit using `python scripts/audit_pdf.py --src original.pdf --tgt output.pdf`.
- Any Critical Error from `audit_pdf.py` must trigger self-repair before user delivery.