Anúncio

NexTalk

Automatize a primeira resposta. Mantenha o toque humano.

Chat ao vivo com agentes de IA no seu modelo e na sua chave de API, com passagem para a sua equipe.

Começar grátis

Shared KV Heads, Sliding Windows, and Vocabulary Size: Measured Memory and Retrieval Trade-offs in LLaMA 7B, Mistral 7B, and Qwen2.5-7B

arXiv AI Papersen

5d

Idade

Publicado
Coletado

Three widely used 7B-class language models, original LLaMA 7B, Mistral 7B v0.1, and Qwen2.5-7B, differ in three design choices that decide what fits on a small GPU: how many key-value (KV) heads the attention layers keep (32, 8, and 4), whether attention is limited to a sliding window (4,096 tokens in Mistral), and how large the vocabulary is (32,000 versus 151,643 tokens). We measure the consequences of each choice on one 16 GB T4 GPU. (1) Passkey retrieval in Mistral stops at the window. In 134 trials with the key placed 3,600 to 4,600 tokens from the end of the prompt, Mistral retrieved it in all 72 trials where it lay within 4,089 tokens and in none of the 62 trials where it lay 4,098 or more tokens away. With the same weights and the window turned off, retrieval succeeds at every tested position in 8K-token prompts, so the mask causes the limit; at 16K and 32K tokens the window-free model fails completely, while the windowed model still retrieves nearby keys. Qwen2.5 retrieves the key in all 60 trials up to 32K tokens. (2) KV-cache memory per token is 512, 128, and 56 KiB. LLaMA runs out of memory at 32K tokens, Qwen2.5 holds 64K tokens in 3.5 GiB, and Mistral's cache stops at 512 MiB. (3) On 1,997 parallel sentences in 15 languages, Qwen2.5's tokenizer removes 38-58% of tokens for five languages and 3-11% for the other ten; combined with KV sharing, LLaMA needs 9.5-22.0 times more cache memory than Qwen2.5 for the same sentence. (4) Decode latency in a common runtime grows with cache size, and copying the cache, measured on its own, costs about as much as that growth. Code and results are public.

Autores

Kapardhi Kannekanti, Durvankur Chavan, B Tarun Sandilya

Categorias

  • cs.CL
  • cs.LG
Leia o artigo completo em arxiv.org

O overfeed.news indexa e aponta. Publicamos um trecho curto — o artigo completo fica em arXiv AI Papers.

Entre para seguir esta fonte

Knowing Where Is Not Enough: Evaluating Multimodal Evidence Acquisition in Search Agents

Agentic search enables agents to discover relevant sources and acquire evidence to support reasoning, planning, and decision-making. End-to-end evaluations combine these abilities, making failures after source discovery difficult to diagnose. As such, we introduce InSite-Bench, comprising 802 tasks across 145 real-world websites. Each task specifies a starting URL and source boundary for studying evidence acquisition within a site. We measure task success across representative large language models (LLMs) and agent harnesses and inspect selected trajectories for acquisition failures. Our analysis shows that agents can reach the right resource yet fail to inspect the views or moments needed to answer the question. These findings point to evidence selection and observation coverage as practical targets for improving search agents and motivate examining acquisition behavior alongside answer quality. We will open-source the evaluation code soon. The benchmark dataset is available at https://huggingface.co/datasets/John1208/InSite-Bench.

en

Sequence-Level Score Centering Stabilizes Off-Policy LLM Reinforcement Learning

Numerical differences between rollout and training engines introduce drift into language model reinforcement learning (RL) policy gradients. Score centering (SC) cancels this drift at the token level, where each step independently subtracts the expected score under the sampler. Sequence-level RL methods instead weight an entire response by one bounded importance ratio, enabling mixture-of-experts (MoE) training without routing replay, yet token-level SC leaves substantial drift because each token also shifts that sequence ratio. We introduce sequence-level score centering (SeqSC), which cancels this drift for sequence-level RL by subtracting each token's expected weighted score. Replacing post-hoc bounds with optional stopping on a mean-one running ratio keeps those expected weights in closed form at every prefix, making centering exact for any policy and sampler. Applied to three sequence-level RL methods (Seq-TIS, GSPO, and TOPR), SeqSC trains Qwen3 models from 4B to 30B with zero collapses under quantized, noisy, and stale samplers. Across fifteen mismatch settings, it improves mean evaluation accuracy over SC by 14.6 points for Seq-TIS, 12.7 points for GSPO, and 6.6 points for TOPR. On Qwen3-30B-A3B without routing replay, SeqSC achieves the highest evaluation accuracy and reduces the training steps needed to match SC by roughly half at no extra per-step cost, enabling fast, stable MoE RL post-training.

en

SpatialPaw: Delegating Spatial Reasoning for Fast, Lightweight Training-Free Agents

Multi-step spatial agents achieve strong 3D/4D reasoning by planning and writing tool-calling code across turns, yet this iterative loop incurs heavy multi-turn decoding and tool latency even on large models, and struggles on lightweight vision-language models (VLMs) due to unrecovered code errors, repeated perception calls, and misread visual outputs. We propose SpatialPaw, a training-free agentic framework that delegates 3D spatial computation from the VLM to external modules, replacing multi-turn code generation with direct answering from compact text. Given a question, the VLM selects the relevant objects, keyframes, and viewpoint, whose 3D positions and motion are then computed and summarized in a compact text graph. The VLM prefills the video, question, and text graph only once and reuses the resulting KV cache to generate multiple answers in parallel for majority voting, substantially reducing redundant computation and inference latency. Without any training, SpatialPaw generalizes across model families and backbones from 0.8B to 125B. With a 4B backbone, it ranks first across seven benchmarks, outperforming spatially fine-tuned models and training-based agents while running 2.7x-7.1x faster than training-free agents, and at 125B it achieves accuracy competitive with recent multi-step agents while running up to 10.6x faster.

en

WASD: Writing Agents Steer Dreams

General-purpose agents offer strong spatial and task reasoning but are too slow for closed-loop control; robotic foundation models (RFMs) act at the control rate but struggle in out-of-distribution states. Combining them is a natural choice but requires a lightweight interface for agents to reliably steer the RFM. We introduce Writing Agents Steer Dreams (WASD), which steers a World Action Model (WAM) by selectively rewriting its imagined future. This interface works across WAMs, improving recovery success by 15.3% absolute over the same correction in language. WASD has two variants: WASD-Zero and WASD-Tune. In WASD-Zero, the agent reads and edits predicted futures once before and once during execution, without retraining. On LIBERO-Recover, it raises OpenWAM from 52.2% to 67.0% and Cosmos from 42.7% to 61.4%, matching oracle guidance with over 40 times fewer tokens than an agent harness. However, even with oracle guidance throughout execution, some failures remain unresolved, suggesting that guidance alone cannot compensate for missing specific execution skills. WASD-Tune therefore additionally incorporates automatically generated successful guided rollouts and a small amount of agent-generated skill data into post-training and calibrates the applicability of runtime guidance, reaching a state-of-the-art 71.8% and exceeding naive post-training (50.1%). Real-robot experiments further demonstrate the effectiveness of the approach. Project website: https://wasd-tasl.github.io/ .

en
Shared KV Heads, Sliding Windows, and Vocabulary Size: Measured…