M-RAG: Semantic Key-Value Indexing for Retrieval-Augmented Generation

Xu Sun, Tongkai Xu, Baiheng Xie, Li Huang, Qiang Gao +1 more
1/6/2026
cs.IRcs.AI
rag

No confident code implementation found for this paper.

Abstract

Retrieval-augmented generation (RAG) turns external documents into evidence for large language models. In practice, this is also a data access problem: a system must decide what to index, what to retrieve, and what evidence to place in the context under a token budget.

Show full abstract

Most RAG pipelines use text chunks for both lookup and generation. This couples two different objectives. Retrieval benefits from compact and discriminative records, while generation needs contextual and faithful evidence. As a result, small chunks may fragment answer-bearing information, whereas large chunks may introduce noise and waste the context budget. We propose M-RAG, a semantic key-value indexing layer for budget-constrained RAG query processing. M-RAG extracts meta-markers from complete documents, where each record contains a retrieval key, an information value, and provenance pointers. Online retrieval operates over the key field, which can be searched by dense vector retrieval or sparse lexical retrieval; the paired values are returned as generation payloads and assembled under the token budget. Provenance pointers further support coverage validation and position-aware context ordering. This design separates the physical index entry from the evidence payload without changing the underlying retriever or generator. Experiments on LongBench QA subtasks show that M-RAG achieves competitive or better accuracy than representative chunk-based baselines, especially under tight token budgets. Further analyses show high document coverage, stronger robustness under expanding candidate corpora, and lower online retrieval latency. These results suggest that semantic key-value indexing is a practical access method for RAG workloads.

View on arXivView PDF

Code Implementations

No confident code match yet

We couldn't find an author-owned or strongly-evidenced community implementation for this paper. Any repos shown below are weak matches — verify before relying on them.

No code implementations found yet.

Know of an implementation? Let us know in the comments below!

Similar Papers

Cite this paper

@article{sun2026mrag,
  title  = {M-RAG: Semantic Key-Value Indexing for Retrieval-Augmented Generation},
  author = {Xu Sun and Tongkai Xu and Baiheng Xie and Li Huang and Qiang Gao and Kunpeng Zhang},
  year   = {2026},
  eprint = {2603.26667},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2603.26667v2}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2603.26667.svg)](https://codeofpaper.com/paper/2603.26667)

Discussion