{"id": "http://arxiv.org/abs/2607.01775v1", "title": "Set Diffusion: Interpolating Token Orderings Between Autoregression and Diffusion for Fast and Flexible Decoding", "abstract": "Discrete diffusion models have steadily improved in quality relative to autoregressive (AR) models. However, these models are normally constrained to fixed-length generation and do not support key-value (KV) caching. Block diffusion partially bridges diffusion and AR by generating token blocks left-to-right, but its fixed-size sequential blocks limit decoding flexibility and parallelism. Here, we present a new class of language models, set diffusion, comprised of (i) a likelihood parameterization that factorizes over flexible-position, flexible-length token sets and (ii) a set-causal diffusion architecture that supports KV cache updates after every inference step. By factorizing over token sets instead of fixed-size blocks, tokens can be decoded in arbitrarily-ordered sets, including sliding-window sets, enabling faster inference and support for any-order decoding. Set diffusion achieves better speed-quality tradeoffs on mathematical reasoning, summarization, and unconditional generation compared to prior diffusion language models while offering stronger infilling performance than block diffusion. We provide the code, along with the model weights and blog post on the project page: https://m-arriola.com/setdlms/", "published_at": "2026-07-02T06:45:43+00:00", "source_updated_at": null, "source_url": "https://arxiv.org/abs/2607.01775v1", "source_hash": "4b29b51f7ba4405014396421387b749cc15391cd85a3eb2d59d36dcb2dc88d81", "source_version": "v1", "full_text_available": true, "evidence_kind": "full_text_excerpt", "analysis_scope": "full_text_excerpt", "scope": "core", "topics": ["discrete-diffusion", "inference-acceleration", "reasoning"], "code_url": null, "has_code": false, "indexable": true, "authors": [], "related_ids": ["http://arxiv.org/abs/2609.00495v1", "http://arxiv.org/abs/2608.30922v1", "http://arxiv.org/abs/2608.20123v1"], "related_work": {"version": "related-work-v1", "status": "not_assessed", "reason": "missing_context", "items": []}, "review": null, "explanations": {}, "full_article_summary": {"format": "research_guide_v14", "analysis_scope": "full_article_map_reduce", "source_hash": "4b29b51f7ba4405014396421387b749cc15391cd85a3eb2d59d36dcb2dc88d81", "source_url": "https://arxiv.org/abs/2607.01775v1", "source_version": "v1", "revision_id": "5150ebe6b2a8525385b682183853d056755d57c3d30a846f9ab9123284e7caad", "canonical_text_hash": "0905b79e8d2ac7210d39c22a5cdac086f1b8d6753d1a49ceb66056febba8e77f", "prompt_version": "full-article-research-guide-v14", "sections": {"verdict": {"ru": "Set Diffusion — содержательно обоснованное обобщение диффузионной генерации, объединяющее авторегрессию, блочную и masked diffusion. SW-SetDLM показывает улучшенный компромисс качество–скорость и гибкое декодирование, но оптимальный уровень параллелизма и расписание порядка остаются нерешёнными.", "en": "Set Diffusion is a substantiated generalization of diffusion generation that unifies autoregression, block diffusion, and masked diffusion. SW-SetDLM shows improved quality–speed tradeoffs and flexible decoding, but the optimal parallelism level and ordering schedule remain unresolved."}, "main_idea": {"ru": "Генерация факторизуется по множествам токенов произвольной позиции и размера. Управление порядком множеств и их размером задаёт смещение между левосторонним качеством, произвольным порядком, инфиллингом и параллельностью.", "en": "Generation is factorized over token sets with arbitrary positions and sizes. Controlling set order and size tunes the balance among left-to-right quality, arbitrary-order generation, infilling, and parallelism."}, "claims": {"ru": "Метод восстанавливает AR при singleton-множествах, block diffusion при блочном порядке и masked diffusion при равномерном порядке. Set-causal transformer обновляет KV-кэш после каждого сгенерированного множества, поддерживая sliding-window и variable-length decoding. SW-SetDLM сообщает более высокую скорость или качество против проверенных diffusion/block-diffusion базовых методов; превосходство не доказано универсально и зависит от расписания, бюджета и условий.", "en": "The method recovers AR with singleton sets, block diffusion with block ordering, and masked diffusion with uniform ordering. A set-causal transformer updates the KV cache after every generated set, enabling sliding-window and variable-length decoding. SW-SetDLM reports better speed or quality than tested diffusion/block-diffusion baselines, but universal superiority is not established and depends on schedule, budget, and conditions."}, "mechanism": {"ru": "Состояние: раскрытый контекст, выбранные позиции, наборы токенов, времена раскрытия и KV-кэш. Обучение: сэмплируется политика порядка, затем суммируются diffusion-NELBO для последовательных условных наборов; singleton-обучение использует causal mask и даёт полное условное likelihood-обучение. Нормализация по реализованному ratio снижает дисперсию градиента. SW-SetDLM использует position-offset ordering, независимое предсказание токенов внутри выбранного множества одним denoising-шагом и фиксацию принятых токенов в кэше. Для совместного вычисления используется конкатенация длины 2L со специальными set-diagonal, offset-causal и set-causal масками; отдельные N denoising-вызовы не требуются. При инференсе выбираются позиции, сэмплируется или принимается подмножество, токены денойзятся и их ключи/значения добавляются в кэш. Размер множества управляет параллелизмом, политика порядка — bias и lookahead. Для воспроизведения: (1) задать политику reveal times и преобразовать её inverse-CDF в перестановки; (2) сформировать наборы и специальные маски; (3) обучить по conditional-set NELBO с реализованной ratio-нормализацией; (4) реализовать поэтапное принятие токенов и KV-cache update; (5) сравнить расписания при фиксированном prediction budget. Детали целевой функции denoising внутри каждого набора и точного acceptance rule в записях не раскрыты.", "en": "State: revealed context, selected positions, token sets, reveal times, and a KV cache. Training samples an ordering policy and sums diffusion NELBO terms for successive conditional sets; singleton training uses a causal mask and provides full conditional-likelihood supervision. Normalization by the realized ratio reduces gradient variance. SW-SetDLM uses position-offset ordering, independently predicts tokens within a selected set in one denoising step, and commits accepted tokens to the cache. Joint computation uses a 2L concatenation with specialized set-diagonal, offset-causal, and set-causal masks, avoiding N separate denoising calls. At inference, positions are selected, a subset is sampled or accepted, tokens are denoised, and their keys and values are appended to the cache. Set size controls parallelism; ordering policy controls bias and lookahead. Reproduction: (1) define reveal-time policies and convert them to permutations with the inverse CDF; (2) construct sets and specialized masks; (3) train with the conditional-set NELBO and realized-ratio normalization; (4) implement staged token acceptance and KV-cache updates; (5) compare schedules at a fixed prediction budget. The records do not specify the exact within-set denoising target or acceptance rule."}, "evidence": {"ru": "На OpenWebText SW-SetDLM сообщает ≤22,42 PPL и 97,9±1,6 токенов/с против ≤23,34 и 80,2±0,6 у BD3LM. На LM1B указаны ≤27,83 PPL и ≥98,5±1,6 токенов/с при S≤8; efficient training снизил дисперсию градиента с 7,50×10⁻² до 2,73×10⁻² и PPL с ≤54,49 до ≤42,02 в соответствующем сравнении. На GSM8K приведены 66,41 pass@1 и 60,42 токенов/с при S≤8 против 63,53 и 55,39 у BD3LM S=4; другая абляция сообщает 26,61 против 6,37 pass@1 и 40,83 против 24,48 токенов/с с и без efficient training/causal masking. Для ROCStories сообщается более высокий ROUGE и примерно до 25% более быстрое декодирование. При сопоставимом likelihood заявлено ускорение на 22%. Условия различаются, включая дистилляцию GSM8K из Qwen3-32B и детерминированное decoding; результаты не устанавливают превосходство на всех задачах.", "en": "On OpenWebText, SW-SetDLM reports ≤22.42 PPL and 97.9±1.6 tokens/s versus ≤23.34 and 80.2±0.6 for BD3LM. On LM1B, it reports ≤27.83 PPL and ≥98.5±1.6 tokens/s at S≤8; efficient training reduced gradient variance from 7.50×10⁻² to 2.73×10⁻² and PPL from ≤54.49 to ≤42.02 in the corresponding comparison. On GSM8K, it reports 66.41 pass@1 and 60.42 tokens/s at S≤8 versus 63.53 and 55.39 for BD3LM S=4; another ablation reports 26.61 versus 6.37 pass@1 and 40.83 versus 24.48 tokens/s with and without efficient training/causal masking. ROCStories reports higher ROUGE and up to about 25% faster decoding. A 22% speedup is reported at comparable likelihoods. Conditions differ, including GSM8K distillation from Qwen3-32B and deterministic decoding; the results do not establish superiority across all tasks."}, "applicability": {"ru": "Подходит для генерации с регулируемой параллельностью, infilling, sliding-window decoding, variable-length output и систем, где важен KV-кэш. Особенно полезен, когда требуется выбирать компромисс между задержкой и качеством или применять разные порядки раскрытия для разных позиций.", "en": "It applies to generation with controllable parallelism, infilling, sliding-window decoding, variable-length output, and systems where KV caching matters. It is most useful when latency–quality tradeoffs must be selected or different reveal orders are needed for different positions."}, "limitations": {"ru": "Главный риск — нерешённый компромисс точность–параллелизм: лучшее position-offset расписание может зависеть от оборудования и предпочтений пользователя. Расписания могут различаться между обучением и инференсом, а learned orderings требуют дискретной оптимизации и оставлены для будущей работы. Архитектура и результаты проверены в указанных условиях; часть деталей воспроизведения, включая точный acceptance rule, отсутствует.", "en": "The main risk is the unresolved accuracy–parallelism tradeoff: the best position-offset schedule may depend on hardware and user preferences. Training and inference schedules may differ, while learned orderings require discrete optimization and are left for future work. The architecture and results are demonstrated under the stated conditions; some reproduction details, including the exact acceptance rule, are absent."}, "next_action": {"ru": "Провести контролируемый sweep расписаний при фиксированном prediction budget: (1) сравнить singleton, block, uniform и shaped position-offset policies; (2) измерить PPL/pass@1, tokens/s и качество infilling; (3) отдельно варьировать размер множества и ширину окна; (4) проверить чувствительность к аппаратуре и разным latency budgets; (5) выбрать Pareto-оптимальное расписание.", "en": "Run a controlled schedule sweep at a fixed prediction budget: (1) compare singleton, block, uniform, and shaped position-offset policies; (2) measure PPL/pass@1, tokens/s, and infilling quality; (3) vary set size and window width separately; (4) test sensitivity to hardware and latency budgets; (5) select the Pareto-optimal schedule."}}, "source_coverage": {"canonical_text_hash": "0905b79e8d2ac7210d39c22a5cdac086f1b8d6753d1a49ceb66056febba8e77f", "covered_chunks": 10, "map_input_digest": "5991c0abd4bcc32ecfa696ab6da9ba3e35286dd8057f42d155ec6ebe9dc7246d", "prompt_version": "full-article-research-guide-v14", "revision_id": "5150ebe6b2a8525385b682183853d056755d57c3d30a846f9ab9123284e7caad", "total_chunks": 10}}, "resources": {"version": "paper-resources-v1", "source_hash": "4b29b51f7ba4405014396421387b749cc15391cd85a3eb2d59d36dcb2dc88d81", "evidence_kind": "full_text_excerpt", "availability": "not_checked", "limited": false, "items": []}, "slug": "2607.01775-set-diffusion-interpolating-token-orderings-between-autoregression-and-diffusion-for-fast-and-fl"}