Explore the research collection
8 entries · Follow this search
- Paper
Context Language Models
Introduces Context Language Models (CLMs): language models that natively manage their own context by treating the context as a file and allowing unrestricted updates to it, letting the model learn what is most important to maintain in context and naturally extending to multi-agent systems where multiple agent contexts coexist as files. Building CLMs zero-shot with existing models outperforms SOTA context-management strategies: 11.4% higher accuracy with 21.5% fewer FLOPs on BrowseComp-Plus, 5% higher scores with 59% fewer FLOPs on 12-hour EdgeBench, and 65% greater improvement with the same compute on a 24-hour multi-repository agent-swarm task. Shifting context management from external harness control to intrinsic model behavior enables both in-context and parametric learning of context-management strategies: steering CLMs with natural-language instructions evolved through a skill-optimization loop improves held-out accuracy by up to 35.9 points while reducing compute. An online RL method for CLMs improves Qwen3.5-9B on BrowseComp-Plus by 47.6% while using 12% fewer FLOPs. Co-designed Suffix Cache Reuse for CLM serving further cuts server-side compute by 35% relative to standard SGLang at matched performance.
- Code
xattn
Efficient attention modules for the xLLM framework, with Python APIs for use in other PyTorch projects. Features high-precision FP32 attention output state for backward (reducing BF16 gradient error) and flexible segment-aware masking (segment IDs or BOS masks) for packed sequences. Supports causal Flash Attention, sliding window, sliding chunk, and SoftDelta attention variants; FP16/BF16 inputs; MHA, GQA, and MQA.
- Code
xLLM: Light-weight infrastructure for express LLM pre-training
Apache-2.0 PyTorch framework for long-context LLM pretraining supporting dense, MoE, and MoVA architectures, with FSDP1/FSDP2, data/model/context parallelism, custom CUDA kernels, FlashAttention, online tokenization and packing, evaluation, HuggingFace export, and vLLM support.
- Model
Naive-N0.5-Flash: Building Frontier AI with AI
NaiveAI open-weight 309B MoE (15.5B active; 48 layers) built via AI-centered R&D on MiMo-V2.5. Hybrid SWA (128-token window) + DeepSeek Sparse Attention (DSA top-2048, GQA4) with no full-attention layers; native 1M context. Continued pretraining 3.25T tokens (indexer warmup 50B + sparse CPT 3T + decay/SFT 200B). NaiveRT inference (mega-kernel fusion, PDL, speculative decoding) claims ~50 tok/s Standard and up to ~2,000–2,122 tok/s Ultrafast on 8 GPUs. Weights + inference code MIT; HF NaiveAI/Naive-N0.5-Flash (+ FP8); API pricing $0.10/$0.40/$0.01 per M input/output/cache-read. Strong coding / agent / AutoResearch evals (SWE-Bench Pro, Terminal-Bench, PaperBench, etc.).
- Model
SmolLM3: smol, multilingual, long-context reasoner
HuggingFaceTB 3B decoder (Llama-style, tied embeddings, GQA 4 groups, NoPE every 4th layer, intra-document masking) trained 11.2T tokens on 384 H100s over 24 days. Three-stage web/code/math mix, then 100B long-context (4k to 64k, YaRN to 128k) and 140B reasoning mid-train. SFT 1.8B tokens dual think/no_think, APO alignment, MergeKit soup. Outperforms Llama-3.2-3B and Qwen2.5-3B; competitive with 4B models. Think mode AIME 2025 36.7 percent vs 9.3 percent no-think. Apache-2.0. Languages EN/FR/ES/DE/IT/PT.
- Code
Recursive Language Models
Replaces llm.completion with rlm.completion: the prompt lives in a CodeAct-style REPL that the model can inspect, decompose, and recurse into via sub-(R)LM calls. Paper arXiv 2512.24601: process inputs up to two orders of magnitude beyond the base context window. pip install rlms. Sandboxes: local, ipython, docker, modal, prime, daytona, e2b. Training via verifiers + prime-rl (OOLONG example). Maintained by the paper authors at MIT OASYS. MIT license.
- Paper
Extending the Context of Pretrained LLMs by Dropping Their Positional Embeddings
Argues explicit PEs speed pretraining (NoPE has slower positional-bias gradients) but RoPE-scaling (YaRN/NTK/PI) must compress low frequencies, shifting semantic heads so zero-shot long context matches a cropped-window baseline on NIAH. DroPE trains with RoPE, drops PEs, then recalibrates at the original context. From-scratch 0.5B on 16B FineWeb: last 2B tokens without PE matches full-RoPE perplexity and beats YaRN/NTK/ALiBi/NoPE on RULER NIAH at 2x. SmolLM-360M (600B pretrain): 30-120B recalibration recovers in-context benches; LongBench avg 30.52 vs YaRN 19.94, NIAH 74.92 vs 48.25. SmolLM-1.7B (20B rec, 2 percent of pretrain) and Llama-2-7B (20B, 0.5 percent) also beat YaRN/NTK. NIAH at 8x: DroPE 52.20 vs YaRN 12.18 / LongRoPE2 16.45.
- Paper
Memory Caching: RNNs with Growing Memory
Memory Caching (MC) segments the sequence, caches each segment's memory state, and aggregates online plus cached memories at retrieval. Four variants: Residual Memory, Gated Residual Memory (GRM), Memory Soup, and Sparse Selective Caching (SSC). Complexity O(NL) interpolates RNN O(L) and Transformer O(L^2). Applied to Linear Attention, SWLA, DLA, and Titans. On 760M/30B-token and 1.3B/100B-token FineWeb training, MC lifts language-modeling and commonsense averages; Titans+GRM is strongest. Closes part of the recall gap vs Transformers on NIAH, in-context retrieval, LongBench, and MQAR. No official code on the abs page.