NUDGE: Lightweight Non-Parametric Fine-Tuning of Embeddings for Retrieval

Sepanta Zeighami, Zac Wellmer, Aditya Parameswaran

In the world of Retrieval-Augmented Generation (RAG) and search, dense vector embeddings are the gold standard. We take our data, turn it into vectors using a pre-trained model, and then use $k$-Nearest Neighbor ($k$-NN) search to find the most relevant bits. But there’s a catch: out-of-the-box models often struggle with the specific nuances of a new dataset or domain.

Traditionally, developers have faced two choices: fine-tune the entire massive model (which is expensive and slow) or train a small "adaptor" model on top (which is faster but often inaccurate). A new paper from researchers at UC Berkeley and 1984.ai, titled NUDGE, introduces a third way: don't change the model at all—just "nudge" the data vectors themselves.

TL;DR

NUDGE is a lightweight, non-parametric method for fine-tuning embeddings that directly modifies data vectors to maximize retrieval accuracy. It runs in minutes, works with closed-source models (like OpenAI’s), and provides significantly higher accuracy boosts—averaging 3.3× more than model fine-tuning—while being up to 200× faster.

The Problem with Current Fine-Tuning

When a pre-trained embedding model (like BGE or OpenAI's text-embedding-3-large) doesn't perform well on your specific data, the standard approach is to "fine-tune" it. This typically takes one of two forms:

  1. Pre-trained Model Fine-Tuning (PTFT): This involves updating the millions of parameters inside the model itself. It’s computationally heavy, requires access to the model weights (impossible for many API-based models), and is expensive to deploy.
  2. Adaptors: These are small neural networks trained to transform the output of a frozen model. While more efficient, they often overfit or lack the flexibility to truly "fix" the embedding space for a specific dataset.

The authors identify a critical gap: we need a way to improve retrieval that is model-agnostic, computationally cheap, and highly effective for the specific data we have on hand.

The NUDGE Solution: Embeddings as Parameters

The core innovation of NUDGE is its non-parametric nature. Instead of viewing the embedding model as the thing to be fixed, it treats the embeddings of the data records themselves as the parameters to be optimized.

Conceptual overview of NUDGE fine-tuning

The researchers propose two main variants to achieve this:

  • NUDGE-M (Bounded Magnitude): It moves each data embedding closer to the queries for which it is the correct answer. To prevent the "semantics" of the pre-trained model from being destroyed, it constrains this movement (the "nudge") within a small radius.
  • NUDGE-N (Normalized): This version adds a constraint that the final embeddings must remain on the "unit ball" (normalized). This acts as a powerful form of regularization, preventing vectors from growing too large and hurting generalization.

While the general problem of maximizing retrieval accuracy is NP-Hard, the authors derived closed-form solutions for these constrained versions. This means instead of hours of gradient descent, NUDGE calculates the optimal "nudge" using simple vector algebra in a single pass.

Datasets and Evaluation

The authors evaluated NUDGE across a massive battery of tests:

  • Text Retrieval: 7 standard datasets including NF-Corpus, SciFact, ArguAna, Fever, NQ (Natural Questions), TriviaQA, and HotpotQA.
  • Image Retrieval: COCO and Flickr.
  • Models: They tested against five pre-trained models, including open-source ones like BGE-S and GTE-L, and closed-source ones like OpenAI's TE3-L.

Key Insights

  • The Power of Constraints: By limiting how far a vector can move, NUDGE retains the general knowledge the model learned during pre-training while specializing it for the local task.
  • Closed-World vs. Open-World: NUDGE is exceptionally good for "closed-world" settings (where the dataset is relatively static). For "open-world" settings (where new data is constantly added), the authors show NUDGE can be combined with parametric adaptors to get the best of both worlds.
  • Normalization is Key: NUDGE-N consistently outperformed NUDGE-M. Keeping vectors normalized prevents them from becoming "outliers" that dominate the search space, which is a common failure mode in unconstrained optimization.

Key Results

The quantitative results demonstrate a massive leap in both efficiency and performance compared to traditional methods.

Performance comparison of fine-tuning methods
  • Accuracy: NUDGE often achieved NDCG@10 scores at least 10% higher than existing fine-tuning methods. On average, it provided a 3.3× higher increase in accuracy than fine-tuning the full model and 4.3× higher than using adaptors.
  • Efficiency: NUDGE runs in minutes. It was 200× faster than full model fine-tuning and 3× faster than training adaptors.
  • Versatility: It successfully improved OpenAI’s latest large embedding model, which is otherwise a "black box" that users cannot fine-tune directly.

Limitations and Future Work

  • Out-of-Distribution (OoD) Generalization: Because NUDGE is non-parametric, it doesn't inherently know how to handle a brand-new data record added after the "nudging" process. The authors suggest combining NUDGE with parametric adaptors to solve this.
  • Query Dependency: NUDGE requires a set of training queries with ground-truth answers. While these can be generated using LLMs, the quality of the "nudge" depends heavily on the quality of this query set.
  • Future Directions: The authors suggest integrating NUDGE directly into vector databases, allowing the database to "self-correct" and optimize its own embeddings as it sees more user queries.

NUDGE represents a shift in how we think about customizing AI for retrieval: sometimes, a small, mathematically precise push is better than a total model overhaul.

Summary updated

BibTeX
@inproceedings{zeighami2025nudge,
  author = {Sepanta Zeighami and Zac Wellmer and Aditya Parameswaran},
  title = {{NUDGE: Lightweight Non-Parametric Fine-Tuning of Embeddings for Retrieval}},
  booktitle = {International Conference on Learning Representations},
  year = {2025},
  url = {https://openreview.net/forum?id=MYw74B77KQ},
}
Figure