XC-Cache: Cross-Attending to Cached Context for Efficient LLM Inference

AI-generated keywords: ICL Cross-Attention LLM Inference Efficient Learning Models Robustness

AI-generated Key Points

  • Study focuses on challenges of in-context learning (ICL) approaches and their use of prompting for decoder-only language model generation
  • Introduces models inspired by encoder-decoder architecture utilizing cross-attention to condition generation on reference text without prompts
  • Models outperform ICL methods, comparable to fine-tuned prompted LLMs, and reduce space footprint compared to standard KV caching
  • All models experience a decline in accuracy in out-of-distribution scenarios due to variations in writing style, document lengths, signal-to-noise ratio, and distracting content
  • Enhancing the robustness of context-conditional models is identified as a promising avenue for future research
  • Importance of ethical considerations in developing efficient learning models is emphasized
Also access our AI generated: Comprehensive summary, Lay summary, Blog-like article; or ask questions about this paper to our AI assistant.

Authors: João Monteiro, Étienne Marcotte, Pierre-André Noël, Valentina Zantedeschi, David Vázquez, Nicolas Chapados, Christopher Pal, Perouz Taslakian

License: CC BY 4.0

Abstract: In-context learning (ICL) approaches typically leverage prompting to condition decoder-only language model generation on reference information. Just-in-time processing of a context is inefficient due to the quadratic cost of self-attention operations, and caching is desirable. However, caching transformer states can easily require almost as much space as the model parameters. When the right context isn't known in advance, caching ICL can be challenging. This work addresses these limitations by introducing models that, inspired by the encoder-decoder architecture, use cross-attention to condition generation on reference text without the prompt. More precisely, we leverage pre-trained decoder-only models and only train a small number of added layers. We use Question-Answering (QA) as a testbed to evaluate the ability of our models to perform conditional generation and observe that they outperform ICL, are comparable to fine-tuned prompted LLMs, and drastically reduce the space footprint relative to standard KV caching by two orders of magnitude.

Submitted to arXiv on 23 Apr. 2024

Ask questions about this paper to our AI assistant

You can also chat with multiple papers at once here.

AI assistant instructions?

Results of the summarizing process for the arXiv paper: 2404.15420v1

The study "XC-Cache: Cross-Attending to Cached Context for Efficient LLM Inference" delves into the challenges of in-context learning (ICL) approaches and their use of prompting for decoder-only language model generation. To address the inefficiency of just-in-time processing and space constraints in caching transformer states, the research introduces models inspired by the encoder-decoder architecture that utilize cross-attention to condition generation on reference text without prompts. By leveraging pre-trained decoder-only models and training a small number of additional layers, these models outperform ICL methods, are comparable to fine-tuned prompted LLMs, and significantly reduce space footprint compared to standard KV caching. However, when evaluated in an out-of-distribution scenario where test datasets differ greatly from training data, all models experience a decline in accuracy. This discrepancy may be due to variations in writing style, document lengths, signal-to-noise ratio, and distracting content related to questions but not useful for answers. Therefore, enhancing the robustness of context-conditional models is identified as a promising avenue for future research. Furthermore,of AI research is acknowledged and the importance of ethical considerations in developing efficient learning models is emphasized. The proposed architecture allows for improved performance on unseen datasets while also highlighting opportunities for further advancements in model generalization and robustness.
Created on 12 Nov. 2025

Assess the quality of the AI-generated content by voting

Score: 0

Why do we need votes?

Votes are used to determine whether we need to re-run our summarizing tools. If the count reaches -10, our tools can be restarted.

Similar papers summarized with our AI tools

Navigate through even more similar papers through a

tree representation

Look for similar papers (in beta version)

By clicking on the button above, our algorithm will scan all papers in our database to find the closest based on the contents of the full papers and not just on metadata. Please note that it only works for papers that we have generated summaries for and you can rerun it from time to time to get a more accurate result while our database grows.

Disclaimer: The AI-based summarization tool and virtual assistant provided on this website may not always provide accurate and complete summaries or responses. We encourage you to carefully review and evaluate the generated content to ensure its quality and relevance to your needs.