Reproduce “Grammar-as-a-Drafter: More Tokens per Speculative Decoding Step on Grammar-Constrained Structured Outputs” on OpenResearch

Run Claude Code, Codex or any coding agent as a research agent: literature, hypotheses and experiments on your laptop, cluster or cloud GPUs.

Universal app for Apple silicon and Intel. Requires macOS 11 or later.

About this paper

John Zhang, Silky Arora

Grammar-as-a-Drafter combines grammar-forced tokens with model proposals in a speculative draft row, reusing the verification step. Its verifier accepts forced slots without comparing target logits. On a greedy JSON benchmark, MTP with Qwen3.5-0.8B raises acceptance length from 2.06 to 5.43 tokens per verify step and runs 2.68× faster at batch size 1 than the best MTP-only configuration; this result is workload-specific.

Summary by alphaXiv.

Tip: change arxiv.org to autoarxiv.org in any arXiv abstract link to open the paper here.