# Poster 27857

- Kind: Poster
- Talk page and recording: https://iclr.cc/virtual/2025/poster/27857

> Transcript of the talk's recording (session_asr), made by speech recognition or taken from the host's captions. It may contain errors. The words are the speakers'; listen to the recording on the talk's page before quoting it.

Hello, I'm Jonathan, a PhD student from the University of Cambridge. I'll be briefly talking about our paper on needle threading. Can large language models follow threads through near million scale haystacks? This work was carried out in collaboration with Kaihan and Samuel Albany. LLMs have been shown to possess remarkable capabilities.
And front -end models are being developed with longer contexts in this, which represents the maximum number of tokens they can process simultaneously. For some models, this can fit multiple full-length novels. A longer context window offers potential performance benefits and enables a broad range of real-world tasks, including academic research.
The rate of development of long context models has outpaced our understanding of how well they use their long context and can navigate it, and we seek to address this. Typical long context evaluations are structured as needle in a haystack style experiments, where models are tasked with retrieving needles containing specific information placed at different points in a haystack composed of text.
Prior research is limited by performance saturation and typically focuses on sub-100,000 token haystacks. We introduce challenging tasks, evaluate at longer context lengths and focus on synthetic data, enabling fine-grained control. Following other works, our haystacks are made up of JSON objects of universally unique IDs, arranged as keys shown in pink.
and corresponding values shown in blue. We design five different retrieval tasks based on these head stacks. In the most straightforward, given a key, the task is to return the corresponding value. This can be extended to include multiple needles in which all the values corresponding to the input keys are required and also two conditional needles.
in which the task is to return all the values corresponding to keys that meet a specified condition. We introduce a more challenging task of needle threading in which the keys correspond to values which themselves could correspond to another key. And this linked thread could continue further. So given an initial key, the task is to return the value at the end of the thread. This introduces directionality.
Threads can travel either forwards backwards or go back and forth. An actual extension to this is multi-threading in which the starting keys of multiple threads are given with the goal of retrieving the value at the end of each thread. We evaluated 17 frontier LLMs on our five tasks but for this overview I'll focus on the results of the more challenging threading tasks.
We evaluate on haystacks of different context lengths containing threads with different numbers of steps, where each square represents a retrieval accuracy after five repeats on unique haystacks for both backward and forward traveling threads. We find that performance decreases with thread lengths and is lower on longer contexts.
Most models exhibit a preference for forward -tracking threads. A notable exception is Claude 3.5 Sonnet, which demonstrates stronger accuracy on backwards-tracking threads. When aggregating results across all the thread lengths, the decline in performance with context length is clear. A similar observation can be made for the multi -threaded experiments. A close inspection suggests the total number of threads to follow does not significantly impact the retrieval accuracy.
And, in fact, this plot here for a 20k token haystack shows leading models are remarkably thread -safe and capable of simultaneously following multiple threads without significant loss in performance. We propose a task-specific metric to estimate an effective context limit beyond which models cannot reliably reason over and retrieve from. For each, we create a dense grid of points along the key experimental variables.
and interpolate the average accuracy at each point. We then determine a contour corresponding to a threshold accuracy level, and this contour represents the effective frontier beyond which retrieval is unreliable. In our paper, we include more experiments, a full set of quantitative results, and natural language ablations.
Thank you for watching. Feel free to reach out and contact us or visit our poster presentation.
