Skip to content

Letting Relevance Rewrite Compression Weights: RRC for Dense Retrieval

THE ARGUMENT

Spectral compression weights should not be set by corpus statistics alone: RRC folds relevance judgments in by adjusting only each direction offset from a shared trend, lifting useful directions while preserving the compressor overall spectral shape.

On this page

An engineer managing vector-index cost must decide how far to shrink document embeddings and which compression scheme to ship. The usual check derives a compression rule from an offline corpus, shortens the vectors, reruns retrieval, and approves whatever loses the least overall accuracy. Hidden in that check is a premise never written into the acceptance sheet: how much weight each direction in the shortened vector keeps is decided only by what the corpus looks like, never by whether that direction actually puts relevant documents on top. So one kind of mistake stays invisible: a direction that looks unremarkable in the corpus and gets squeezed hard might be exactly the one that matters most for relevance. Paper [1] offers a tool for this, called Relevance-Guided Residual Calibration: use known relevance answers to correct the compression weights direction by direction, without overturning the overall trend.[1]

The Default: Weights Set by Corpus Statistics, Disconnected From Relevance

Start with the default being changed. Dense retrieval turns both a query and a document into a list of numbers and compares how close they are; that list is called an embedding vector. Spectral compression projects high-dimensional vectors onto a few leading directions of variation and rescales the coordinates, which cuts storage and scoring cost. It builds a fixed compression map straight from corpus statistics: take the top k principal directions and rescale the projected coordinates by some exponent. The paper names the existing rules PCA with exponent zero, Whitening with exponent one, and SpecTemp, which picks its exponent from the corpus spectrum and the target dimension, applying full whitening up to the knee of a spectral signal-to-noise curve and progressively weaker whitening at larger target dimensions.

The shared problem is that these weights are corpus-derived: whether a direction is amplified or suppressed depends only on its variance across all documents. Variance says how much a projected coordinate fluctuates across documents, not whether that direction helps separate relevant documents from competing candidates. Worse, as the paper points out, within the retained principal subspace a single shared exponent ties every weight to the same power-law trend. It can only shift weight between high- and low-variance directions as a block; it cannot single out one direction and strengthen it because that direction happens to be useful. Put plainly, the weights carry no information about relevance at all.

Relevance judgments, meaning a set of queries paired with documents already labeled as relevant, supply exactly what is missing. With them you can ask, for each direction, how far positive scoring contributions pull ahead of negative ones and how much they vary. A small contribution sitting on a low-variance direction still deserves to be kept, even boosted, as long as it reliably helps the relevant document win. The default rule flattens precisely this signal, and that is the loss an acceptance test based only on total score drop cannot see. The paper states the motivation bluntly: corpus variance describes how a coordinate varies, not whether its direction contributes to telling relevance apart.

What Changed: Folding Relevance Answers Into the Weights

The proposed method is Relevance-Guided Residual Calibration, or RRC, a closed-form method, meaning a solution computed directly from statistics in one step rather than by iteratively training a model, that refines spectral weights using relevance judgments. It is explicitly built to attach to three existing compressors: PCA, Whitening and SpecTemp, all three supported. The corrections are merged into the very same transformation already shared by documents and queries, which is why the paper stresses two conveniences: no additional inference stage and no iterative model training. For anyone shipping this, the change stays local to the compression map.

The experimental scale is concrete. The paper uses three encoders and nine datasets spanning conventional and reasoning-intensive retrieval. Of the nine, the conventional group is MS MARCO Passage Ranking plus three BEIR datasets, Natural Questions, HotpotQA and FiQA, which the paper collectively calls the BEIR group. The reasoning-intensive group is five BRIGHT datasets drawn from three StackExchange domains, Biology, Earth Science and Economics, plus coding with LeetCode and theorem-based retrieval with TheoremQA-T. StackExchange contributes three datasets because on its own it accounts for seven of BRIGHT twelve.

The evaluation protocol is also spelled out in detail and worth copying into any reproduction checklist. Target dimensions are 768, 512, 256 and 128. MS MARCO is reported with MRR@10 and the rest with nDCG@10, with scores multiplied by 100. Scoring uses cosine similarity, a proximity measure that compares direction rather than length; the original embeddings are L2-normalized before compression and the compressed vectors are normalized again before scoring. To avoid leakage the setup uses folds: for each fold the transformation is fit on judgments from the other four folds, then applied to the held-out queries and the whole document corpus, and results are pooled across folds.

How It Works: Split the Trend, Keep Positive Directions, Add the Residual Back

The method has a few steps and the paper gives a closed-form derivation. For each retained direction, look at the score margin of a triple, that is, how far the relevant document outscores a negative one, computed as the positive score minus the negative score. Under a normal approximation, which treats scoring fluctuations as a bell-shaped distribution, the probability that the relevant document wins rises monotonically with the ratio of this margin mean to its standard deviation. So what decides whether a direction is useful is the mean and variance of its contribution, not its variance in the corpus. RRC therefore estimates a margin-based weight from the means and variances of positive and negative score contributions along each retained direction.

That is where the word residual comes from. It first keeps only directions whose estimated weight is positive, since a negative weight means the direction is actively hurting relevance. It then decomposes the log of those weights into two parts: a fitted power-law trend and, for each direction, the residual, which is simply what is left after subtracting the overall trend from the individual value. That residual is added back to the compressor original log weights, but only on the support of the retained directions. The overall power-law trend therefore stays exactly as the compressor set it, while the only thing changed is each direction individual offset from that trend. Relevance judgments can adjust directions one by one without breaking the shared spectral shape.

StepWhat it doesBasis
Estimate weightsDerive a margin weight from the mean and variance of positive and negative contributions per directionUnder a normal approximation, win probability rises with mean over standard deviation
Filter directionsKeep only directions with positive estimated weightA negative weight means the direction harms relevance discrimination
Split the trendDecompose log weights into a fitted power-law trend plus a per-direction residualSeparates the shared trend from individual offsets
Add the residualAdd the residual back to log weights on the retained supportAdjusts individual directions while preserving the overall trend

All of this lands inside the single transformation matrix shared by documents and queries. The paper's wording is that corrections are folded into the existing transformation, with no separate inference stage and no iterative training, yielding 'a single fixed compression map for document indexing and query compression', adding no per-vector computation beyond the underlying spectral compressor and requiring no test-time relevance feedback.[1] Concretely, it computes the corpus mean, the spectral basis and the eigenvalues, takes the positive prior weights from the chosen compressor, then uses relevance judgments to estimate per-direction weights, split out the residual and add it back, so the new weights apply to both documents and queries. One engineering boundary belongs here (my judgment, not a paper finding): 'no additional inference stage' is not 'not a line of the serving call chain has to change'. Once the transform changes, the document index must be rebuilt with the new map and the query side must switch to the same map; if the two drift apart, vectors no longer share a space and cosine similarity stops meaning anything. What the paper offers is savings on the compute path, not a zero-change rollout.[1]

What the Numbers Say

Look at the headline first. The paper says that SpecTemp plus RRC achieves the highest mean effectiveness among tested compressors on the BEIR group and on BRIGHT at every target dimension; that claim of highest mean effectiveness is taken directly from the paper Table 2, not recomputed here. On the reasoning-heavy BRIGHT side, the paper reports that on the five evaluated BRIGHT datasets at 768 dimensions, SpecTemp plus RRC improves over SpecTemp by an average of 2.34 nDCG@10 points. That 2.34 is the paper own figure, quoted as given, and I will not rescale it to other dimensions or other groups.

The counting in Table 2 deserves its own note so the protocol is not mistaken for the effect. The BEIR group holds 12 encoder-dataset configurations and BRIGHT holds 15. Win, tie and loss comparisons are made after averaging over three random seeds, 1999, 5 and 2026. Because compressed methods are summed over the four target dimensions, the comparison counts are 48 and 60 respectively. Beyond that, each BRIGHT training fold contains 60 to 114 judged queries, the BEIR group uses 80 queries per training fold when fitting the trend, and Figure 1 looks specifically at how power-law fit quality relates to the gain at 768 and 512. Every one of these counts is given by the paper rather than derived here.

One more result matters for deployment: the gains persist under scalar and product quantization, and the full text gives checkable numbers rather than only a qualitative claim. Section 4.4 uses SpecTemp as the prior, three encoders, the five BRIGHT datasets and k=768; quantizers are trained on corpus embeddings only, and it reports mean nDCG@10 (x100) over 15 encoder-dataset configurations and three seeds. Table 4 shows that FP16 and SQ8 largely preserve the gain seen with FP32, SQ4 reduces it, and the gains remain positive at every tested PQ and OPQ code length.[1] One figure you can plug in directly: under the same SQ8 encoding, SpecTemp+RRC reaches a mean nDCG@10 of 32.49 at 768 bytes per document, against 32.02 at an average of 3,413 bytes per document for the original full-dimensional embeddings -- higher mean effectiveness at substantially less storage.[1] The paper also notes that up to 128 bytes per document the SpecTemp frontier closely follows the original embeddings, then levels off below the full-dimensional FP32 mean at larger budgets, so raising encoding precision alone does not close the gap. These are results from the released implementations on this hardware and panel, not hardware-independent constants.[1]

ItemReported figureNote
Evaluation datasets9Conventional BEIR group plus five reasoning-intensive BRIGHT sets
Encoders3Differ in dimension, MRL support and reasoning training
Target dimensions768 / 512 / 256 / 128Four settings
Mean BRIGHT gain2.34 nDCG@10 pointsAt 768, over SpecTemp, five datasets
Configurations12 (BEIR) / 15 (BRIGHT)Encoder-dataset configurations in Table 2
Comparisons48 / 60Win-tie-loss counts summed over four dimensions
Judged queries per fold60-114 (BRIGHT)Labeled queries in each training fold
Random seeds1999, 5, 2026Three seeds averaged
Storage-effectiveness under quantization (Table 4)SQ8: 32.49 at 768 B/document vs original 32.02 at 3,413 B/documentSame SQ8, mean over 15 configurations and three seeds; FP16/SQ8 preserve the gain, SQ4 reduces it

Where the Method Stops

Being clear about scope matters more than memorizing the 2.34 figure. By the paper own account, the boundaries are roughly these.

  • It needs relevance judgments as input: without labeled query-relevant-document pairs the weight estimation has no basis, so a purely unsupervised setting cannot use it. The paper uses judgments from existing benchmarks, with five-fold cross-fitting over 60-114 judged queries per fold on BRIGHT (80 on BEIR), and reports no annotation cost. On your own corpus or with a different encoder, judgments must be prepared again and the transform refitted; a few dozen queries per fold does not mean labeling is cheap.[1]
  • Conclusions are scoped to three encoders, nine datasets and dimensions 768 down to 128, and the paper does not verify another encoder family or even lower dimensions;
  • It corrects the weights of spectral compression, not the underlying embeddings, so if the retrieval bottleneck is encoder quality, calibrating the compression map will not help;
  • Weight estimation relies on a normal approximation plus means and variances, so with very few samples or a heavily skewed distribution the reliability of this closed-form estimate degrades;
  • Highest mean effectiveness is a group-level claim, not a win on every encoder-dataset configuration, as the win-tie-loss counts in Table 2 themselves show;
  • Gains persist under quantization, but 'remaining effective' should not be read as zero loss: Table 4 gives concrete results -- FP16 and SQ8 largely preserve the gain, SQ4 reduces it, and PQ/OPQ gains stay positive at every code length -- with 32.49 at 768 B/document under SQ8 against 32.02 at 3,413 B/document for the original embeddings. These are ratios from specific implementations and this panel, not cross-hardware constants.[1]

In one line: this method applies when you already have spectrally compressed vectors, hold a batch of relevance judgments, and are willing to work only on the compression transform. It answers how to let the weights listen a little to relevance without overturning the overall trend. If you have no labels, want to change the encoder itself, or demand a win on every single configuration, it cannot help you; in that case, settling the labeling budget and the acceptance criteria first is more practical than picking a louder method name [1].

References

  1. Relevance-Guided Residual Calibration for Spectral Compression of Dense Retrieval Embeddings

Sign in to Padda

A code in your inbox. No password to remember.

Connecting to sign-in…