Back to browse
Dare v2 – A token-efficient, AI-native language for PDF generation

Dare v2 – A token-efficient, AI-native language for PDF generation

by hassan-elkady·Feb 23, 2026·1 point·1 comment

AI Analysis

●●●BangerWizardryShip ItSolve My Problem

10x token efficiency + pixel-perfect determinism fixes LLM PDF generation without the HTML chaos.

Strengths
  • Honest problem statement: HTML's responsive cascade breaks for fixed-layout PDFs; DARE eliminates cascading conflicts entirely.
  • Real token benchmarking: 28 vs 65 tokens on same invoice header—measurable, reproducible, directly saves LLM API cost.
  • Compiler ships in-browser (client-side, zero backend); v2 adds charts, tables, header/footer, cols—serious professional feature set.
Weaknesses
  • Nascent ecosystem: adoption depends on LLM instruction-following; no evidence of production use in the wild yet.
  • Competing against HTML+CSS literacy; requires users to learn another DSL despite the simplicity claims.
Target Audience

AI engineers building document automation, agentic workflows, invoice/report generation pipelines

Similar To

Pug/Jade (template syntax) · Nunjucks · Typst

Post Description

Hey HN,

I built DARE to solve a specific problem: LLMs are terrible at generating complex, rigid PDF documents using HTML/CSS. HTML was designed for the responsive web, and when you ask an LLM to generate an invoice or a dashboard PDF, you waste massive amounts of tokens on boilerplate, and the layout often breaks depending on the renderer.

DARE (Document & Report Engine) is a deterministic markup language built specifically for AI agents.

Why it's better for AI:

-Extreme Token Economy: The syntax is up to 10x more compact than HTML. A full professional invoice fits in a single tweet.

-Deterministic Output: A box defined as h=50mm will always be exactly 50mm high. No cascading conflicts.

-AI-Native: It ships with 16 core components (tables, charts, QR codes, columns) and 40+ CSS shorthands.

-Drop-in Prompt: You literally just paste SYSTEM_PROMPT.md

to any LLM, and it instantly knows how to write pixel-perfect DARE code. For v2, I've completely refactored the engine into a modular architecture (tokenizer, flexible CSS engine, and component registry). It renders in sub-seconds via Puppeteer.

Repo: https://github.com/local-over/DARE

Docs & Live Compiler: https://dare.pages.dev/

Would love your feedback on the syntax and the concept of an AI-first document language!

Similar Projects