Explore the research collection
8 entries · Follow this search
- Paper
e-means: outperforming k-means (in one-tenth the epochs)
e-means (Bessa et al., Meta FAIR; arXiv 2611.09501, Nov 6 2026, CC BY 4.0) replaces Lloyd's k-means with an exponential-moving-average optimization procedure over mini-batch updates - essentially treating centroid estimation the way deep learning treats weights, powered by modern DL machinery - with dead-cluster revival as a key component. The practical crux is that its two would-be hyperparameters, EMA decay rate and batch size, are set by fitted SCALING LAWS (fit on ~75k runs, validated on 5k+ runs) that prescribe them from problem size and dataset, so the user chooses only k: a genuine drop-in replacement with no sweep. Results across 26 embedding datasets (100k to 10B points): e-means reaches a LOWER loss than Lloyd k-means at 25 epochs in just 1.4 to 2.6 epochs, frequently beating even k-means++ from a random initialization (the mini-batch stochasticity escapes local minima Lloyd gets stuck in); the epoch savings translate to 10-45x GPU wall-clock speedups over state-of-the-art k-means implementations (launch-thread chart on DEEP, 1M vectors, 16,384 clusters: 12.5x fewer epochs, 11.8x faster on 64-core CPU, 13.6x on one H100, against faiss k-means, SuperKMeans and Flash-KMeans). At the extreme end it partitions DINO10B - 10 billion DINO embeddings - into 16 million clusters in 2.5 epochs, below Lloyd's 25-epoch loss; paired with IVF it gains another order of magnitude at billion scale. Released in FAISS 1.16.0 (contrib/e_means) with figure-reproduction code, a project site with an interactive results map across the 26 datasets, and a browser playground. Flags, as entered: first-party (Meta FAIR) results at abstract/thread level at cataloging time; the speedup range is wide (10-45x) and hardware/implementation-dependent; the comparison currency is training loss (inertia) on embedding datasets, which is the operative metric for quantization and data-curation uses but says nothing directly about downstream task quality. Relevance: k-means is the workhorse under vector quantization, retrieval indexing and dataset curation/dedup pipelines, so a tuning-free 10x-faster drop-in inside FAISS is immediately usable infrastructure rather than a research curiosity.
- Paper
Rethinking Activation Functions: Reducing Bias Can Improve Learning
ReLU, GELU, Swish, and Sigmoid all produce predominantly positive outputs, so their post-activation mean is nonzero — the paper names this the activation bias, b = E[phi(z)], and asks what it does to learning over the full course of training, not just at initialization. Intervention: subtract a fixed scalar b from the activation output (estimated at initialization: ReLU 0.230, GELU 0.115, Swish 0.077, Sigmoid 0.500), or, at scale, layerwise adaptive shifting (subtracting the running post-activation mean). Controlled evidence (deep residual teacher–student model with pre-norm MLP blocks, identical init/data/optimizer, only the shift differs): the unshifted student learns faster early but its residual-stream hidden state overshoots (~step 100), its parameter trajectory turns sharply within the initial-gradient plane, and its loss landscape is steeper (larger leading Hessian eigenvalues); the shifted student starts slower, moves in nearly orthogonal parameter directions, and ends at a lower final loss — despite the teacher itself using the unshifted activation. The bias component is not inert: in a VGG-style reconstruction task, decoding the bias component alone early in training recovers recognizable coarse image structure, color, and texture — the model transiently exploits information carried in the mean component, then relies on it less; shifting largely suppresses this. Theory: in the simplified settings studied, shifting by the activation mean minimizes or nearly minimizes Hessian / Gauss–Newton sharpness. Scale-up (adaptive shifting, everything else fixed): ViT-Base on ImageNet-1K (300 epochs) — shifted model trails early, finishes with HIGHER training loss but lower test loss and higher top-1 accuracy; DiT-B/2 on ImageNet-256 (400k steps) — comparable or lower training loss throughout and lower FID at every evaluated checkpoint; GPT-2 Small on OpenWebText (300k steps, nanoGPT setup) — consistent but small gain, ~0.01 absolute loss and ~1% relative perplexity. Appendix results extend to ViT-L and OLMo/HyenaDNA-style models, and document hidden-state overshoot in released Pythia-410M, OLMo-2-1B, and Amber-7B checkpoints.
- Paper
JetSpec++: Foresight Parallel Drafting with Self Refinements
Algorithm-system co-design for speculative decoding: acceptance rate and drafting cost co-optimized by hiding the draft model's cost almost entirely. Three components: (1) Intra-block self refinement — the causal parallel draft model (built on the original JetSpec architecture) is trained to iteratively correct its own parallel predictions within a token block via Jacobi-style passes; each pass moves the draft distribution toward a more autoregressive factorization with better target alignment; between passes, a context refresh re-predicts the target hidden states and an anchor replacement swaps the first draft token that disagrees with the decoder. (2) Inter-block foresight drafting — drafting the next block begins before the current block is verified, by anticipating possible verification outcomes and predicting the corresponding target hidden states and anchor tokens. (3) Pipelined drafting and verification — the two stages overlap (draft model on a second GPU) so drafting's marginal wall-clock cost approaches zero; the freed draft-side time funds the Jacobi passes and context refreshes. Lossless: standard speculative-sampling rejection rule preserves the target model's output distribution exactly (stated in the paper, §2). Results (all first-party, batch-size-1 serving on NVIDIA GB200 with CUDA graphs): targets Qwen3-8B and Qwen3.8-27B (thinking disabled); baselines DFlash, DSpark, Domino, JetSpec, SSD (Qwen3-0.6B drafter) — all drafters trained on 800k target-regenerated sequences, block size 16, verification budgets 16/32. Seven benchmarks: GSM8K, MATH-500, AIME25, HumanEval, MBPP, LiveCodeBench, MT-Bench. Up to 7.45× wall-clock speedup over autoregressive decoding and 1.54× over DSpark (1.54× on GSM8K, 1.51× on MATH-500); up to 1,361 tokens/s for a single request; average acceptance length 8.94 across the seven benchmarks (vs 6.89 for DSpark at temp 0) — longest of all methods on every benchmark at temperatures 0 and 1; cuts per-round overhead beyond verification by up to 84% vs DSpark. Caveats (authors' framing preserved): the 7.45× is the max (budget-16, single-request GB200 serving); the headline comparisons are at verification budget 16; all figures vendor/first-party, no independent repro; draft models are target-specific (trained per target on its own outputs).
- Paper
Towards joint scaling laws with optimal batch size schedules
Derives optimal batch-size schedules from LR schedules in closed form under a convex loss model. Given an LR schedule, horizon, and token budget, the noise-term-minimizing schedule is B_t^optim = (K/2)·η_t/√(∫₀ᵀη_k dk · ∫_tᵀη_k dk), with K = B_static·T — depends only on LR schedule shape and budget, independent of peak LR, weight decay, model size, architecture, or optimizer. Cosine LR → BS grows then declines; WSD → grows then plateaus; linear → exactly flat at B_static; constant LR → grows like 1/√(T−t). η_t/B_t is NOT a sufficient statistic (matched trajectories favor realizing the schedule through LR over BS, +0.017–0.743 val loss), so BS scheduling is an independent dimension. Scaling experiments (Llama3 dense, Qwen3 MoE, 0.1B–7B, up to 1e21 FLOPs, Fineweb-edu; peak LR ∝ 1/√T, same LR/WD for both): +15% compute efficiency on Llama3 at 50 TPP, +6% on Qwen3 MoE at 100 TPP; Llama3-1B best-perplexity gains 0.8%/2.5%/14.6% for cosine/WSD/constant; lm-eval-harness wins on all 8 tasks for both families. Joint scaling laws: peak LR and WD ∝ 1/√T, scale-free BS schedule, O(1/√T) convergence; universal dynamics (supercollapse) preserved. Holds on AdamW and Muon-NSGD; ablations incl. VLM post-training (dynamic wins 7/9 benchmarks) and math fine-tuning. Caveats: the cosine-derived schedule decays to zero at the end (proven endpoint behavior — nonzero-terminal-slope schedules give constant terminal BS instead); no practical floor prescribed, and end-of-training tiny batches are systems-impractical; convex foundation is empirical-fit, not a theorem; token-based compute optimality, not wall-clock. Zero overhead — it's a schedule-shape recipe, no extra tuning.
- Paper
Co-Evolving Acting and Forecasting for Language Agents
CoPE adds one multi-step action-forecasting loss on top of GRPO for sample-efficient RL of long-horizon language agents. Standard agentic RL learns only from a terminal scalar reward; value targets label every step with the same outcome, and observation targets (HTML pages, terminal logs) are noisy, one-step, and waste loss on irrelevant tokens. CoPE's third kind of target: on successful on-policy trajectories, the shared policy backbone learns to predict the action chunk a_{t:t+K} from each history (population optimum: the hindsight distribution Pr(a|h, success) — success is a selection condition, not a per-step label). Each action is thus supervised both where it is taken and when forecast from the K preceding histories, forming an implicit temporal ensemble absorbed into the policy; acting and forecasting co-evolve. Inference still acts one step at a time — zero overhead. On five benchmarks (ALFWorld, ScienceWorld, WebShop, τ²-bench, AppWorld): ALFWorld +5.0pp over GRPO, WebShop success 64.5→77.0, ScienceWorld 64.5→72.5 (best of all RL baselines including ECHO and RWML), τ²-bench 27.5→28.7 (Retail 17.5→29.4, with an honestly reported Airline drop 26.2→16.2), AppWorld 41.67→55.36 (normal) / 18.71→22.54 (challenge). Sample efficiency: 2.0× vs GRPO and 1.7–1.9× vs ECHO on ScienceWorld; 1.6× vs GRPO on AppWorld. Cost: +11% per-step training compute, −9% end-to-end step time; no separate model, no pretraining, no inference overhead. Ablations: K=2 best (all K≥1 beat GRPO), λ=10⁻², gains hold on Qwen3-8B, group normalization stabilizes training. Explicit-ensembling control (separate LoRA forecaster reranking 8 candidates) improves GRPO but adds nothing to CoPE, supporting the implicit-ensembling claim. Plain success-filtered BC on successful rollouts hurts (−7.5pp) — multi-step forecasting is the crucial ingredient. Limitations: outcome-conditioned imitation over-represents easy tasks; the Airline failure shows refusal tasks bleeding into action tasks. Code MIT at github.com/ulab-uiuc/CoPE (AgentGym-RL/verl stack).
- Paper
Learning What to Investigate Next: Meta-Reasoning for Long-Horizon Research Agents
Long-horizon research agents must decide both how to investigate and what to investigate next, but allocation decisions are sparse in long traces and their consequences emerge several investigations later. MIRA (Meta-reasoning for Iterative Research Agents) makes those decisions explicit: an outer-loop meta-reasoner curates context from a persistent Git-based research record and writes a work order (objective, proposed approach, success criteria) or ends the episode; a fresh inner-loop executor carries out each work order, so every investigation — however long — is one meta-reasoning transition. The decision boundaries also give natural credit-assignment units: a generative critic forecasts expected remaining return from the curated observation using the LM's native next-token distribution, and MIRA-AC jointly trains actor and critic in one model, propagating a single decision-level advantage to the tokens of the decision response while masking the longer executor trace, using buffered single-rollout async optimization. Without policy training, MIRA raises GPT-5.5's IMOProofBench Advanced score 67.1% → 100% (all 30 problems in each of 3 trials) and achieves the lowest proxy and gold loss in matched 24h/48h neural-architecture hill-climbing campaigns (per-cell residual-write gates on RMT; signed attention + leaky recurrent update on Loop Transformer), revisiting proof directions more often than baselines (strategic inertia 0.772 vs 0.958 direct). The generative decision-level critic beats token-level alternatives by 0.110 RMSE, and cross-environment LOO pretraining improves forecasting and adaptation (−0.053 RMSE after 5 target episodes). Trained on the model's own proxy hill-climbing signals, MIRA-AC improves gold performance across four autoresearch environments (symbolic regression, physics discovery, HillClimbBench-CPU, BNLearn causal discovery), with the cross-environment policy transferring to BNLearn held out from actor training; only 25.8% of output tokens (the decision responses) receive actor loss.
- Paper
Hybrid Reasoning Agents
HybridAgent is an LLM agent that dynamically navigates between latent reasoning and text-based interaction within a single unified generation process, combining efficient latent "inner thinking" with text-based tool calls and external inspection. The core mechanism is HybridLink, a lightweight residual adapter mapping last-layer hidden states back into the input embedding space (e_{t+1} = h_t + W2·GELU(W1·h_t), ~10M params at 4B), enabling sequence-wise recurrence in latent mode without representation mismatch. Mode transitions: text mode emits a <latent> anchor token to enter latent mode; latent mode exits when the HybridLink-projected state nearest-matches a </latent> anchor; span lengths emerge adaptively. Latent thoughts remain interpretable: each latent step maps to its nearest token embedding, recovering readable pseudo-text. Multi-turn generation runs over a continuous working memory (KV entries from text, latent thoughts, and tool observations), losslessly preserving hybrid context across turns. Post-training: HybridSFT (format activation, HybridLink activation with cos+MSE regression, then self-conditioned two-pass training with joint CE at text and regression at latent positions, closing the train-inference mismatch) stabilizes tool-integrated hybrid generation; HybridRL scales reasoning via a hybrid policy factorization (policy likelihoods only over sampled text positions, since latents are deterministic given the backbone and fixed HybridLink) with exact rollout replay, rewarding correctness, format, and multi-tool use — learning when to think in latent space vs act through text. Built on Qwen3-Base at 4B/8B/14B and evaluated on 11 benchmarks (math, science, medicine, search, agentic reasoning) against text-based, latent, and frontier-agent baselines: HybridAgent improves performance by 10.4% on average at the RL stage (18.5% at SFT stage; 14B beats the strongest agentic baseline by 17.4%), with 35.5–54.7% token reduction, 1.8–2.6× faster inference, and 2.7–3.7× cost savings. Tool use stays reliable (higher valid call rates than GRPO, 99.7% execution success) and the exposed text trace remains monitorable/debuggable (first-error localization 98–99%), exposing 43–49% fewer text tokens while carrying 26–28% more key reasoning steps per 100 visible tokens. Code, models, and training data are public: github.com/togethercomputer/HybridAgent (MIT) with HybridAgent-8B-Agentic and -14B-Agentic checkpoints plus HybridSFT-v1/v2 and HybridRL datasets on Hugging Face.
- Paper
Memory Mosaics at scale
Memory Mosaics (Zhang et al., 2025) replace transformer attention blocks with networks of associative memories: each unit stores key-value pairs (keys encode the recent past, values the near future) and retrieves via Gaussian kernel regression (fuzzy, soft retrieval), using L2-normalized keys, a symmetric key/query kernel, and no explicit position encoding. Memory Mosaics v2 scales this to 10B size (llama-8B scale) trained on 1T real-world tokens, adding three modifications: adaptive kernel bandwidth scheduled with memory size, a gated time-variant key feature extractor, and a 3-level memory design (short-term, long-term, persistent). The paper evaluates across three dimensions. Memory mosaics v2 only MATCH transformers on training-knowledge storage (first dimension) but significantly outperform them on new-knowledge storage and in-context learning (second and third dimensions): on new-knowledge storage, a 1T-token MM v2 beats a 1T-token transformer by 12.3% (53.4% vs 41.1%), and an 8x-data transformer (8T tokens) still lags by 6.5% (46.9% vs 53.4%); on anonymous-label in-context learning, the 8T transformer lags by a large margin, while on easier semantic-label ICL the 8T transformer matches MM v2. The paper frames this as 'predictive disentanglement' — compositional, in-context behavior achieved in a comparatively transparent way versus transformers. Code: github.com/facebookresearch/MemoryMosaics. Paper is CC BY-NC-ND 4.0 (non-commercial, no-derivatives).