Draft-Guided Constrained Diffusion for Structured Generation in LLMs
Abstract
Structured generation requires language models to produce outputs that are both task-correct and compliant with hard structural constraints, such as JSON schemas, often within a fixed output budget. Constrained decoding (CD) enforces such constraints in autoregressive (AR) models, but restricting the next-token distribution can alter the model's solution and may still leave the output incomplete when the generation budget is exhausted. We observe that template-based diffusion offers a complementary mechanism, however, using a diffusion language model (dLLM) directly still limits task accuracy to the dLLM's own problem-solving ability. We propose Draft-Guided Constrained Diffusion (DGCD), which separates these roles. An AR model first produces an unconstrained draft, and a dLLM then expresses its content within a fixed schema template. For feasible template-expressible schemas under our validity assumptions, DGCD guarantees structural validity by construction, while its task accuracy depends on faithfully preserving the draft's answer. Across six AR drafters from 1B to 14B on mathematical reasoning and structured extraction, DGCD achieves observed structure adherence on every evaluated setting and improves average accuracy over draft-conditioned constrained decoding by up to percentage points. DGCD also remains robust under tight output budgets and is faster than DCCD in our latency evaluation.
Then back it, or bet against it.
Related papers
Open the market on this paper to see 7 more related papers.