Doc2Weight: In-Weights Retrieval-Augmented Generation via Parameter Injection

GyuSik Jang, Wonkee Lee, Seung-Hoon Na


Abstract
Retrieval-augmented generation (RAG) typically incorporates external knowledge by appending retrieved documents to the input prompt. While effective for knowledge-intensive tasks, this in-context formulation increases memory use and serving cost as the retrieved context grows. Motivated by this limitation, we propose Doc2Weight, an in-weights RAG framework that injects retrieved information into model parameters rather than the textual context. Doc2Weight converts retrieved documents into parameter-efficient low-rank updates and fuses them in weight space according to their relevance to the query. This enables retrieval augmentation with a query-only prompt, decoupling retrieval depth from prompt length while allowing multiple retrieved passages to influence generation within a single forward pass. We evaluate Doc2Weight on instruction-tuned language models of different scales, including LLaMA-3.2-1B, Qwen2.5-1.5B, and LLaMA-3-8B, across major QA benchmarks. Experiments show that Doc2Weight achieves the best average F1 among standard in-context RAG and prior in-weights RAG baselines across backbones and prompting settings, while matching the throughput of in-context RAG once document signatures are cached. Our code is publicly available.
Anthology ID:
2026.findings-emnlp.744
Volume:
Findings of the Association for Computational Linguistics: EMNLP 2026
Month:
October
Year:
2026
Address:
Budapest, Hungary
Editors:
Hung-Yi Lee, Sunipa Dev, Jessy Li, Desmond Elliott
Venue:
Findings
SIG:
SIGDAT
Publisher:
Association for Computational Linguistics
Note:
Pages:
15657–15674
Language:
URL:
https://aclanthology.org/2026.findings-emnlp.744/
DOI:
Bibkey:
Cite (ACL):
GyuSik Jang, Wonkee Lee, and Seung-Hoon Na. 2026. Doc2Weight: In-Weights Retrieval-Augmented Generation via Parameter Injection. In Findings of the Association for Computational Linguistics: EMNLP 2026, pages 15657–15674, Budapest, Hungary. Association for Computational Linguistics.
Cite (Informal):
Doc2Weight: In-Weights Retrieval-Augmented Generation via Parameter Injection (Jang et al., Findings 2026)
Copy Citation:
PDF:
https://aclanthology.org/2026.findings-emnlp.744.pdf