Explore the research collection
15 entries · Follow this search
- Paper
LoopKV: Loop-Aware KV Cache Compression for Serving Looped Transformers
LoopKV compresses per-loop KV caches when serving looped transformers like Ouro by allocating quantization precision to each layer's sensitivity at each loop, raising servable batch size.
- Paper
When Steering Shifts Discourse: Identifying and Intervening on Discourse-Level Changes due to Activation Steering in LLMs
Shows activation steering causes systematic discourse-level side effects beyond intended behavior change, and proposes ways to identify and intervene on them.
- Tool
Dist-MoE: Speed-of-Light Distributed Mixture-of-Experts Forward and Backward Kernels
A library of fused communication-and-compute kernels for expert-parallel (EP) MoE on NVIDIA SM100+ (Blackwell) GPUs. The caller supplies top-k expert IDs and scores (routing itself is out of scope); a reusable context owns symmetric, peer-addressable HBM dispatch/combine buffers (NVLink) and executes dispatch → grouped expert GEMM (W13 → SwiGLU → W2) → combine as one ordered operation, with forward and backward (FPROP/DGRAD/WGRAD) kernels throughout. Precision/pipeline matrix: BF16 "standard" (training + inference); MXFP8 E4M3 in Staged (separate W13 and SwiGLU/W2 kernels) or Mega (both projections fused into one chunk-pipelined kernel with chunk-local readiness) pipelines (training + inference); NVFP4 in Staged or Mega, inference only, prepared weights. Kernels are CuTe/CUTLASS-DSL; validated stack is Linux ARM64, PyTorch 2.14 + CUDA 13.0, NCCL 2.30.7; no CPU fallback. Two mechanisms distinguish it from DeepEP (dispatch/combine comms only, no fused expert compute), MegaBlocks, DeepSeek's Mega MoE/DeepGEMM (fused forward only, no fused training backward), ByteDance Comet/Flux (no CUDA graphs on the dynamic-routing path, no packing policy), and Cursor's Mixture-of-Kittens (MoK): (1) dynamic activation packing — a planner packs saved forward state from all layers sharing an activation slot into one bounded buffer instead of reserving a per-layer budget, and it works during CUDA-graph replay; (2) dynamic, capacity-driven recompute — when the slot budget is exhausted the planner keeps mandatory layer inputs and rebuilds the remaining intermediates in backward, decided by device predicates so the host launches one fixed, graph-stable sequence (soft limit; scratch overflow without VMM host-backed overflow is a hard error). Also: full CUDA-graph support and non-strict make_fx (full torch.compile/strict export explicitly NOT supported), fused post-expert RMSNorm + score weighting + top-k reduction, clamped SwiGLU, in-place WGRAD accumulation into standard parameter.grad, and no shared-expert branch required — routed-only execution, -1 expert ID disables a route (MoK's reviewed API, by contrast, requires shared-expert weights). TorchTitan integration: a DistMoeTransform swaps stock RoutedExperts for the Dist-MoE backend in place (same GroupedLinear parameter layout, so FSDP/optimizer/checkpoint ownership is unchanged; requires mixed_precision_param="bfloat16"), plus a rank-wide DistMoeRuntime.Config (scratch/activation-slot capacity factors, VMM factor, pipeline-parallel slot policy); verified 671B DeepSeek-V3 recipes ship in torchtitan_recipes, MXFP8 Mega fused inference is wired for RL generators, and NVFP4 inference is in the library but not yet exposed by TorchTitan. Benchmarks — ALL Meta-reported, GB300 NVL72, no independent replication: "useful" throughput counts only real GEMM FLOPs (fwd = 6·T·K·D·F per GPU; bwd = 2× fwd), excluding padding and replay work, divided by whole-layer iteration time (median of five 30-iteration CUDA-graph windows, slowest rank; comm/quantization/padding time stays in the denominator). Headline MoK comparison (both implementations given one BF16 shared expert, D=7,168, 384 experts, top-6, 2,048 tokens/GPU, CUDA graphs on): up to 1.40× over MoK — specifically the synthetic ten-layer packing training workload under per-layer routing imbalance (MXFP8, EP64), where Dist-MoE packed all ten layers' saved state at capacity factor 2.5 with zero capacity-induced recompute (peak allocation 49.73 GiB vs MoK 48.37 GiB); Meta notes the experiment does not isolate how much of the gain is avoided recompute alone. MoK was chosen as baseline because Cursor's published single-layer NVL72 results lead the other OSS stacks (DeepEP+PyTorch, DeepEP+TransformerEngine, HybridEP+Megatron). Separate standalone suite (zero shared experts, one routed layer): 3.09 useful PFLOP/s per GPU NVFP4 Mega inference (EP16), 1.86 MXFP8 Staged training (EP64), 1.27 BF16 training (EP64) — vs dense datasheet peaks of 15/5/2.5 PFLOP/s respectively. Imbalance scaling is sub-linear: NVFP4 inference EP16, 8× received rows on the busiest GPU → 4.82× iteration time (~40% lower time per received row). Stated limitations: SM100+ only; no NVFP4 training, MXFP8 E5M2, MXFP4, A8W4, communication quantization, or expert borrowing in this release; the explainer itself discloses that EP32/EP64 training ran at different sites, some allocations shared an NVLink fabric with unconfirmed timing overlap (not uncontended-peak evidence), and HBM byte rates are modeled, not measured.
- Paper
Beyond Parameters: Exploring Virtual Logic Depth for Scaling Laws
Proposes virtual logical depth (VLD) as a fourth scaling dimension alongside depth, width, and parameter count: VLD = effective algorithmic depth minus base layer count, increased by repeating whole transformer layers with tied weights inside the computation graph, during training and/or inference — not token-wise test-time scaling. Three reuse patterns (after Takase & Kiyono 2021): sequence (adjacent layers share parameters in uniform blocks), cycle (a block of layers repeated), and inverse cycle (the block repeated in reverse order, motivated by larger gradient norms in higher layers). Repetition factors ×1–×3, cycle up to ×5. Two controlled measurements. (1) Knowledge capacity, operationalized Allen-Zhu & Li-style as absorbed entropy ΔH: train a model to memorize a 640k-token IID random sequence over a 50,257-token vocabulary (~15.6 bits/token, sized to the ~2 bits/parameter estimate) and measure the entropy reduction of its softmax outputs on the training sequence. Across 4-layer GPT-2 models of 5M/10M/15M/20M parameters, capacity grows with parameter count; at fixed parameters (5M and 20M tested), absorbed entropy stays nearly unchanged across all three patterns and factors ×1–×3 (reported in Fig. 4, graphically). (2) Reasoning, measured on synthetic iGSM (500K problems, trained at ≤15 operations, exact-answer accuracy, greedy decoding): GPT-2 models of 4/8/12/16 layers (≈50M/100M/150M/200M) trained from scratch. Cycle is the strongest pattern: the 4-layer model's op15 accuracy rises 46.3% (base) → 62.1% (×2) → 70.7% (×5), and the gains grow under depth distribution shift (op20: 21.8→43.8; op21: 21.2→40.2). A 50M cycle ×2 model (effective depth 12) scores 62.05%, beating the native 12-layer 150M model (61.15%) — reasoning decoupled from parameter count. Real-world check: LLaMA-3.2-3B-Instruct with Cycle VLD inserted before LoRA fine-tuning (both arms from identical pretrained weights, same 2.3B-token multi-domain SFT corpus) improves over base on Math500 30.40→35.40, GPQA 29.80→32.32, AIME 3.33→6.67, HumanEval 37.79→39.52, MBPP 38.36→40.22. "Properly implemented" is load-bearing: pattern and placement matter — inverse cycle at ×1 underperforms the base model (4-layer op15 43.9 vs 46.3; 8-layer 53.3 vs 60.5), and in an 8-layer placement ablation, cycle reuse on later layers only (5–8) scores 64.2 vs 62.0 for all layers and 54.2 for early layers only (below the 60.5 no-VLD baseline). Scaling is also non-monotonic: cycle ×3 dips below ×2 on the 4-layer model (61.6 vs 62.1), and effective depth 32 underperforms depth 16 — the authors flag possible fixed points. No fitted scaling-law functional forms or exponents are given; the laws are qualitative (knowledge ∝ parameters; reasoning ↑ with VLD). Caveats: synthetic experiments cap at 200M from-scratch GPT-2 models; the real-world evidence is a single 3B model with LoRA-only fine-tuning and small absolute gains (AIME 3.33→6.67 is one additional problem in 30); knowledge capacity is a synthetic memorization probe, not natural knowledge; all reuse experiments train (or fine-tune) with the reuse graph in place — inference-only looping of a conventionally trained model is not tested; multi-seed statistics deferred to future work (authors' Appendix I).
- Paper
OperLoop: Looped Transformers as Optimizers
Reframes looped Transformers' recurrent transition as an optimizer update on the hidden state treated as a fast weight. Any loop transition derives from (1) an input-map projection, (2) a local objective whose gradient the shared blocks' output predicts, (3) an optimizer update rule. Diagnosis: existing transitions (Ouro, Huginn, Parcae, HyperLoop) have input-map mismatches between transitions and projections (Parcae omits Āᵀ; HyperLoop splits H^pre/H^post) — aligning maps cuts loss, +0.15pp Parcae / +0.54pp HyperLoop commonsense (aligned HyperLoop: 59.47 vs 58.93). Their design, OperLoop: delta objective ½‖o_l − t_l‖², explicit learned weight decay Λ_l, state-dependent causally-monotonic step size η_l (inspired by Delta Linear Attention, but target implicit rather than projected values). At matched training FLOPs (~50% params): best looped variant at both scales — EM avg 25.58 vs non-looped 5B baseline 23.89 (+1.69pp), 10B +1.04pp; Loop6 at 1.67× FLOPs: EM 31.90 (+8.01), 8-shot CoT GSM8K 17.13→31.08. Ablations: removing delta objective 25.58→24.84; causal step-size beats fixed η=1 (+1.18pp EM) and non-causal (+1.56pp). Caveats: all looped models have worse PPL and log-likelihood accuracy than the non-looped baseline (Wikitext 13.90 vs 13.08 at 5B) — the advantage shows only in generative EM eval (authors' own point: evaluate beyond PPL); gains vary by task (ARCcn at 5B: 37.63 vs baseline 40.96); small models (5B/10B, 300–500B tokens, 4k seq) — no frontier-scale evidence.
- Paper
DiscoLoop: Looping Discrete Embeddings and Continuous Hidden States for Multi-hop Reasoning
Looped Transformers fix the depth-local storage problem that blocks in-weight multi-hop reasoning (facts stored in early layers are unavailable where later retrieval happens), but they still generalize poorly out of distribution. This paper localizes the remaining failure as representational: on a controlled symbolic two-hop task (two entity-disjoint knowledge graphs, 500 entities / 50 relations each, compositions over the OOD graph never seen in training), a vanilla looped Transformer reaches only 71.1% ID and 8.3% OOD accuracy, even though a logit-lens probe shows the first loop already assigns probability ≈1.000 to the correct bridge entity. The problem is geometry: the post-first-loop hidden state has cosine similarity of only 0.327 (ID) / 0.266 (OOD) to the bridge token's embedding, so the second loop consumes a noisy continuous mixture instead of the clean discrete embedding it was trained on. A training-free intervention — mixing the normalized decoded bridge embedding into the hidden state at the bridge position between loops — lifts OOD accuracy from 8.3% to 25.9% at mixing weight α=0.1 and to near 100% (ID and OOD) at α≈0.5. DiscoLoop turns this into an architecture: the recurrence carries both channels, adding a gated, RMSNormed soft decode-then-encode term Φ(h) — the tempered LM-head distribution over the vocabulary re-embedded through the tied embedding matrix — into the residual stream at every position and loop. The learnable gate variant adds only d+1 parameters. On the symbolic task DiscoLoop reaches near-perfect ID and OOD accuracy with a sharp phase transition around epoch 500 (vs ~70% ID / <10% OOD for the vanilla loop and <20% ID / ~0% OOD for a FLOPs-matched non-looped model with K× the parameters); it also generalizes on a three-hop extension where both baselines fail OOD completely, and on a synthetic natural-language version it reaches ~100% ID / ~95% OOD vs the vanilla loop's ~90% ID and OOD failure. In real pretraining (440M model, 24 layers, 4 backbone applications, 20B tokens of 60% FineWeb-Edu + 40% FineMath-4plus), DiscoLoop beats the vanilla loop and PonderLM on a seven-benchmark zero-shot average, 50.5 vs 49.3 and 49.8, best or tied on six of seven benchmarks, overtaking the vanilla loop after ~13B tokens. Authors' stated limits: hop-length generalization (train ≤k hops, test >k) untested, pretraining verified only at 440M scale, and whether the recipe can be grafted onto existing pretrained models via continual pretraining is open.
- Paper
False Frontiers: Diagnosing and Mitigating Co-Cheating in Self-Evolving Search Agents
Self-evolving search agents build their own curricula: a proposer turns source documents into questions and pseudo-labels, a solver trains on admitted pairs, and solver agreement sets the proposer's reward. This paper names and measures the loop's failure mode — co-cheating: proposer and solver increasingly agree on shared errors, so internal reward improves while external correctness stagnates. Auditing the Dr. Zero proposer–solver loop post-hoc against source evidence (LLM judge, never fed into training), false-agreement mass — evaluated pairs matching on the same incorrect answer — grows from ~0.3–0.4% in round 1 to 6.1% (Qwen3.5-4B) and 8.8% (Qwen3.5-9B) by round 3, even as pseudo-label correctness stagnates or declines. Multi-sample verification (MSV) — three source-aware plus three source-blind samples per candidate, compatible majorities admit and relabel, at six extra labeler generations per candidate — only reduces false agreement to 5.7%/7.2% and adds 0.7–0.8 downstream points. CrossFit, the main method, partitions the proposer's source documents into two folds at the document level: questions from fold A are scored by an auxiliary solver trained only on fold B and vice versa, and the cross-fitted agreement determines proposer reward, so a same-source pseudo-label cannot be reproduced through the feedback solver; the main solver's update rule is unchanged and it still trains on all admitted questions. Rerunning the full loop (3 rounds, no human-annotated QA data): CrossFit cuts false agreement to 3.0%/3.7% (2.0%/1.7% combined with MSV) and raises adopted-label truth from 0.747 to 0.819 (4B) and 0.737 to 0.851 (9B). On a fixed 1,325-question suite (Cover-EM averaged over NQ, TriviaQA, PopQA, HotpotQA, 2WikiMultiHopQA, MuSiQue, Bamboogle), CrossFit reaches 48.8% at 4B and 51.2% at 9B — +8.8/+8.4 points over coupled Dr. Zero self-evolution and +8.7/+7.8 over Search-R1, with every benchmark improving and multi-hop gains largest (10.0/10.9 points). Controls isolate the mechanism: replaying identical proposals with source-excluded feedback cuts false agreement to 0.4%/0.1%; same-source or full-data auxiliary solvers stay near coupled levels, a random per-question split only reaches 5.0%/6.2% (the split must follow source ancestry), and a half-budget control rules out extra compute. Limitations (authors'): shared pretraining errors and overlapping or semantically related sources can still correlate mistakes, exclusion across connected sources is untested, the auxiliary solvers' end-to-end cost is unmeasured, and the audit relies on an LLM judge.
- Paper
Relative Generalization Invariance of LLM Pretraining
Introduces Relative Generalization Invariance (RGI): the validation-loss difference between any two tokens is preserved across models, i.e. L_A(d) = L_B(d) + C_AB — different training choices produce a token-independent constant shift rather than selective per-token improvement. GPT-style models (124M, 0.7B) trained on FineWeb with six optimizers (Adam, Adam-mini, Lion, Muon, Soap, Scion) from shared initialization and data streams show concordance correlation r_CCC > 0.95 and relative discrepancy r_diff < 0.05 after ~2,000 steps; at 10K steps the validation-loss relationship between optimizers is near-perfectly linear (R^2 >= 0.99). RGI persists approximately across architectural changes: RoPE/NoPE/ALiBi positional encodings, full vs sliding-window attention, GELU/SiLU/Squared-ReLU FFN activations, different initializations, and moderate width changes. Changing the training data breaks it: FineWeb-trained vs ArXiv- or CodeParrot-trained models (same Adam optimizer) fail to exhibit RGI; C4 shows partial, unstable alignment. Not explained by NTK/lazy training — parameters and hidden states move substantially from initialization and cross-optimizer similarity decreases while RGI persists — nor by mean-field regimes (RGI appears in narrower models); the authors prove RGI can emerge in an overparameterized quadratic model. License: CC BY 4.0.
- Paper
VERA: Scaling Verifiable Environments for Agentic co-Evolution
VERA (NVIDIA) addresses agent training's environment bottleneck by converting benchmark trajectories into 9,000+ restartable, rubric-scored sandboxes, then co-evolving the LLM and its harness on them. Auto-Rubric turns trajectories into sandboxes: a coding agent writes binary rubric items (scored {0,1} from observable evidence) over action arguments, execution effects, artifacts, and output quality; executable checks and an Agent Judge verify each sandbox, and a failed executable check overrides any judge score. Trajectories are segmented into five stages (plan, setup, verify, execute, submit), each restorable and scored independently. The co-evolution loop alternates two updates with the other component frozen: model rounds run full-parameter GRPO with rubric rewards (a Reward Verifier checks the rollout evidence behind each reward; a checkpoint is accepted if its dev-benchmark score drops no more than 20% relative to the previous accepted checkpoint), and harness rounds add/merge/remove skills (accepted only if a paired frozen-model rerun shows target-stage improvement, no end-to-end regression, safety checks pass, and self-tests pass with at least +5 Overall points on the dev set; at most three edits per round). At 9B (Qwen3.5-9B), the co-evolved agent beats the strongest single-axis baseline by 10.3 points on AutoCoWorkBench and 13.0 on AutoMedBench, leading SWE-Bench Verified and MedXpertQA under their official protocols. At 27B (Qwen3.8-27B), VERA reaches 71.6 on AutoCoWorkBench (above Claude Opus 4.8, 1.0 point below GPT-5.6-Sol) and 80.7 on AutoMedBench (within 1.2 of Claude Opus 4.8, highest Agentic score 94.1), and transfers out of domain to Automation-Bench (43.8%) and AgentClinic (76.4%). Only at 27B are general capabilities retained/improved (AIME 2026 +10.0, ALFWorld +3.8, GPQA-Diamond +7.7, IF-Bench +1.8 for the CoWork agent); 4B/9B agents lose heavily on AIME.
- Paper
OPUS: Towards Efficient and Principled Data Selection in Large Language Model Pre-training in Every Iteration
OPUS (Optimizer-induced Projected Utility Selection) linearizes AdamW/Muon one-step updates, sketches ghost outer-product gradients with CountSketch, and Boltzmann-samples a batch aligned with a Bench-Proxy retrieved from the corpus. Scoring overhead 4.7% vs naive 3.5×. GPT-2 XL Muon FineWeb 30B: avg 41.75 vs random 40.29, beating 60B random (41.29) and static filters. FineWeb-Edu: OPUS on score-3 beats baselines trained on score 4+5 (XL 44.99). Qwen3-8B-Base CPT on SciencePedia: 0.5B tokens beats 3B full CPT. Code https://github.com/gszfwsb/OPUS.
- Paper
Fine-Tuning Language Models with Just Forward Passes
MeZO adapts zeroth-order (gradient-free) SGD to fine-tune language models using only forward passes, operating in-place with inference-level memory. Supports full-parameter and parameter-efficient tuning (LoRA, prefix tuning) and non-differentiable objectives.
- Paper
TorchTitan: One-stop PyTorch native solution for production ready LLM pre-training
The development of large language models (LLMs) has been instrumental in advancing state-of-the-art natural language processing applications. Training LLMs with billions of parameters and trillions of tokens require sophisticated distributed systems that enable composing and comparing several state-of-the-art technique…
- Paper
Variational Reasoning for Language Models
We introduce a variational reasoning framework for language models that treats thinking traces as latent variables and optimizes them through variational inference. Starting from the evidence lower bound (ELBO), we extend it to a multi-trace objective for tighter bounds and propose a forward-KL formulation that stabili…
- Paper
Qwen-Audio-3.0-TTS: Freely Controllable and Highly Robust Speech Synthesis with Multi-Stage Training Paradigm
Technical report on Qwen-Audio-3.0-TTS, a production-oriented text-to-speech system that the authors position as jointly advancing content consistency, speaker similarity, prosodic naturalness, audio quality, controllability, multilingual coverage, efficiency and robustness. It pairs a 12.5 Hz low-frame-rate speech tokenizer (for reduced inference latency) with a five-stage progressive training paradigm that coordinates optimisation of the language model and the flow-matching model. Control is exposed at inference through free-style natural-language instructions plus fine-grained inline tags, and the system supports 16 languages and 20 Chinese dialect regions, one-pass long-form synthesis up to 3 minutes, and generation from noisy, reverberant or unclear reference speech. Evaluated on SEED-TTS-Eval, CV3-Eval, instruction-following, long-form and acoustic-robustness suites, where the paper reports state-of-the-art or strongest aggregate results on many dimensions and first place on the independent Artificial Analysis Text-to-Speech Leaderboard.
- Dataset
FineFineWeb: A Comprehensive Study on Fine-Grained Domain Web Corpus
FineFineWeb is a large-scale web corpus that classifies FineWeb data into fine-grained domains (e.g., aerospace, etc.) using a multi-iteration pipeline involving GPT-4 URL labeling, FastText coarse recall, and BERT fine recall. It contains ~4.89B rows across multiple domains with billions of tokens each, enabling researchers to build domain-specific pretraining mixtures with explicit control over domain composition.