Vibeleaderboard
← All Intel
Intel / article

How Arcee stretched AFM-4.5B to 64k context with model soups

Source
arcee.ai
Publisher
Arcee AI
Author
Arcee.ai
Date

Context

Giving a a longer , meaning more text it can take in at once, usually makes it worse at ordinary short prompts. In a detailed write-up for Arcee AI, Charles Goddard describes how the team stretched AFM-4.5B from 4,096 to 64k tokens. Most of the lost short-context quality came back through cheap steps, mainly model merging and , rather than more long-context training. He tracks that loss with two short-context benchmarks, MMLU and Big Bench Hard (BBH), which he says correlated well with Arcee's full evaluation suite. The post also stresses that all numbers come from early checkpoints taken before further training, so they are preliminary.

The first step changes how the model encodes token positions. Arcee used YaRN, a method for stretching rotary position embeddings beyond the length a model was trained on, with DeepSeek's settings for 4k to 128k. On a trial checkpoint that alone dropped MMLU from 65.4% to 55.0%. Training only on short sequences with remapped position numbers, the PoSE approach, made MMLU worse. Training on real 64k-token sequences following Princeton's ProLong recipe worked better. What recovered quality was merging: averaging the weights of several checkpoints from these experiments into a soup raised MMLU to 63.6%. Goddard also found what he calls a free lunch: training with a larger position range than needed, then turning the YaRN scale down afterward, added a little more MMLU.

For the real run, starting from a midtrained checkpoint at 66.0% MMLU and 45.2% BBH, he reused the trial's long-context gains through task arithmetic. That treats the weight difference a fine-tune produced as a vector that can be added to another model (paper), so the soup's long-context changes were transplanted onto the new base and merged with a fresh 64k training run on it. He then used Arcee's DistillKit to train this merged model to imitate the original short-context checkpoint. In under two hours on eight H100s, that brought MMLU to 65.0% and BBH to 45.3%. A last 64k training pass improved long-context results but pulled BBH down to 43.2%. A final merge using Arcee Fusion, which keeps only the minimal weight changes needed, restored BBH to 45.0%. The finished model keeps 100% needle-in-a-haystack recall up to 32k and 97% up to 64k. These tests hide a specific fact in a long input and check that the model can retrieve it.

The whole process took about 700 H100-hours, which Goddard calls tiny compared with the budget. Arcee also applied the same playbook to the 32B GLM-4 base model, reporting roughly 5% better base benchmarks and much stronger recall out to 32k, and released that model.

Terms in this piece · Glossary
  • Large language model — A model trained on large amounts of data to process and generate language.
  • Context and context window — Context is the information available for a generation; the context window is the capacity available to hold it.
  • distillation — Training a small, cheap model to imitate a big one's outputs, keeping much of the capability at a fraction of the cost.
  • pretraining — The first, biggest phase of building a model: training it on enormous amounts of text so it learns language, facts, and reasoning in general.

Get the Brief

A cited digest of what matters for people building with AI, every morning. Unsubscribe anytime. See today’s edition

Read the source www.arcee.ai
More from Arcee.ai
Recommended reads