GRACE: Generative Representation Learning via Contrastive Policy Optimization
On the map: LLM reasoning → Test-time compute and efficient thinking
Abstract (arXiv)
Prevailing methods for training Large Language Models (LLMs) as text encoders rely on contrastive losses that treat the model as a black box function, discarding its generative and reasoning capabilities in favor of static embeddings. We introduce GRACE (Generative Representation Learning via Contrastive Policy Optimization), a novel framework that reimagines contrastive signals not as losses to be minimized, but as rewards that guide a generative policy. In GRACE, the LLM acts as a policy that produces explicit, human-interpretable rationales--structured natural language explanations of its semantic understanding. These rationales are then encoded into high-quality embeddings via mean pooling. Using policy gradient optimization, we train the model with a multi-component reward function that maximizes similarity between query positive pairs and minimizes similarity with negatives. This transforms the LLM from an opaque encoder into an interpretable agent whose reasoning process is transparent and inspectable. On MTEB benchmark, GRACE yields broad cross category gains: averaged over four backbones, the supervised setting improves overall score by 11.5% over base models, and the unsupervised variant adds 6.9%, while preserving general capabilities. This work treats contrastive objectives as rewards over rationales, unifying representation learning with generation to produce stronger embeddings and transparent rationales. The model, data and code are available at https://github.com/GasolSun36/GRACE.
Key facts. Cited by 7 papers in the map (data through 14 Oct 2026). Placed in Test-time compute and efficient thinking, one of 17 directions in LLM reasoning. Builds on 34 of its 45 references that are in the map. First posted on arXiv 6 Oct 2025.
Builds on
34 of 45 references.
References · 34
- 2018BERT: Pre-training of Deep Bidirectional Transformers for Language Understandingcited by 40,399
- 2023GPT-4 Technical Reportcited by 18,396
- 2022Training language models to follow instructions with human feedbackcited by 15,971
- 2017Proximal Policy Optimization Algorithmscited by 15,215
- 2024The Llama 3 Herd of Modelscited by 14,715
- 2019RoBERTa: A Robustly Optimized BERT Pretraining Approachcited by 13,372
- 2020A Simple Framework for Contrastive Learning of Visual Representationscited by 12,049
- 2021Training Verifiers to Solve Math Word Problemscited by 10,109
- 2024DeepSeekMath: Pushing the Limits of Mathematical Reasoning in Open Language Modelscited by 9,379
- 2019Sentence-BERT: Sentence Embeddings using Siamese BERT-Networkscited by 9,170
- 2021Evaluating Large Language Models Trained on Codecited by 8,320
- 2020Measuring Massive Multitask Language Understandingcited by 7,963
22 more
- 2018Representation Learning with Contrastive Predictive Codingcited by 7,777
- 2024Qwen2.5 Technical Reportcited by 4,942
- 2020Dense Passage Retrieval for Open-Domain Question Answeringcited by 3,824
- 2017TriviaQA: A Large Scale Distantly Supervised Challenge Dataset for Reading Comprehensioncited by 2,955
- 2025DAPO: An Open-Source LLM Reinforcement Learning System at Scalecited by 2,810
- 2021SimCSE: Simple Contrastive Learning of Sentence Embeddingscited by 2,173
- 2022Challenging BIG-Bench Tasks and Whether Chain-of-Thought Can Solve Themcited by 1,807
- 2018FEVER: a large-scale dataset for Fact Extraction and VERificationcited by 1,375
- 2025Qwen3 Embedding: Advancing Text Embedding and Reranking Through Foundation Modelscited by 1,261
- 2023Towards General Text Embeddings with Multi-stage Contrastive Learningcited by 723
- 2023PyTorch FSDP: Experiences on Scaling Fully Sharded Data Parallelcited by 660
- 2022MTEB: Massive Text Embedding Benchmarkcited by 640
- 2023C-Pack: Packed Resources For General Chinese Embeddingscited by 578
- 2024NV-Embed: Improved Techniques for Training LLMs as Generalist Embedding Modelscited by 472
- 2024LLM2Vec: Large Language Models Are Secretly Powerful Text Encoderscited by 404
- 2025Layer by Layer: Uncovering Hidden Representations in Language Modelscited by 311
- 2023Improving Text Embeddings with Large Language Modelscited by 303
- 2024Generative Representational Instruction Tuningcited by 233
- 2023ReMax: A Simple, Effective, and Efficient Reinforcement Learning Method for Aligning Large Language Modelscited by 187
- 2024Repetition Improves Language Model Embeddingscited by 72
- 2024Your Mixture-of-Experts LLM Is Secretly an Embedding Model For Freecited by 37
- 2025O1 Embedder: Let Retrievers Think Before Actioncited by 15
Built on by
Citing papers per year: 2025: 1; 2026: 6.
7 papers.
- 2025Adaptation of Agentic AI: A Survey of Post-Training, Memory, and Skillscited by 22
- 2026LaSER: Internalizing Explicit Reasoning into Latent Space for Dense Retrievalcited by 9
- 2026Generate, Filter, Control, Replay: A Comprehensive Survey of Rollout Strategies for LLM Reinforcement Learningcited by 9
- 2026Learn Before Represent: Bridging Generative and Contrastive Learning for Domain-Specific LLM Embeddingscited by 2
- 2026TaSR-RAG: Taxonomy-guided Structured Reasoning for Retrieval-Augmented Generationcited by 2
- 2026SHIFT: Self-reconstruction Harnesses Implicit Fine-grained Thinking for Retrievalcited by 0
- 2026Retrieval Grounding Latent Reasoning for Dense Retrievalcited by 0
- 2026Retrieval Grounding Latent Reasoning for Dense Retrieval14 Aug 2026
- 2026SHIFT: Self-reconstruction Harnesses Implicit Fine-grained Thinking for Retrieval23 Jul 2026
- 2026Generate, Filter, Control, Replay: A Comprehensive Survey of Rollout Strategies for LLM Reinforcement Learning8 Apr 2026
- 2026TaSR-RAG: Taxonomy-guided Structured Reasoning for Retrieval-Augmented Generation10 Mar 2026
- 2026LaSER: Internalizing Explicit Reasoning into Latent Space for Dense Retrieval2 Mar 2026
- 2026Learn Before Represent: Bridging Generative and Contrastive Learning for Domain-Specific LLM Embeddings16 Jan 2026
- 2025Adaptation of Agentic AI: A Survey of Post-Training, Memory, and Skills18 Dec 2025
Similar, not cited
Close in wording, no citation either way
- 2026LLM2Vec-Gen: Generative Embeddings from Large Language Models
- 2025Let LLMs Speak Embedding Languages: Generative Text Embeddings via Iterative Contrastive Refinement
- 2025UME-R1: Exploring Reasoning-Driven Generative Multimodal Embeddings
- 2025Following the Autoregressive Nature of LLM Embeddings via Compression and Alignment
- 2025MAGNET: Augmenting Generative Decoders with Representation Learning and Infilling Capabilities
- 2025Sequence-level Large Language Model Training with Contrastive Preference Optimization
- 2026SemPA: Improving Sentence Embeddings of Large Language Models through Semantic Preference Alignment
- 2025GEM: Empowering LLM for both Embedding Generation and Language Understanding