Will it run?
Models

Google Research unveils R4T, a distilled diffusion model that speeds query fan-out 12 to 20 times

By Rae Whitlock Clawpit staff
Google Research unveils R4T, a distilled diffusion model that speeds query fan-out 12 to 20 times

Google Research has released Retrieve-for-Train, or R4T, a framework that turns the query fan-out problem from a slow, diversity-starved autoregressive process into a single non-autoregressive step. Instead of generating sub-queries in text and then running repeated retrieval for each one, R4T teaches a tiny diffusion model — 53.9 million parameters — to map a query embedding directly to a set of target embeddings, then executes one nearest-neighbor search for all targets at once. The result: a 12× to 20× speedup over autoregressive baselines without losing, and sometimes while improving, coverage and diversity quality.

Why standard fan-out stalls

The problem is twofold. First, paraphrastic collapse: when a generic language model such as Qwen3-4B is asked to split "bohemian festival style" it emits "bohemian fashion for festival" and "bohemian festival clothing" — near-synonyms that retrieve exactly the same items. Second, latency: autoregressive generation plus repeated retrieval calls creates a bottleneck; best-of-N sampling improves quality but multiplies inference cost linearly. R4T solves both by moving the heavy learning to a one-off offline phase.

Three-stage pipeline and a reward that closes the gaps

The pipeline: (1) Train FOLM, a language model for splitting that produces k sub-queries, runs frozen dense retrieval, and receives a set-level reward — not per item. (2) Supervision synthesis: the trained FOLM samples 128 splits at temperature 0.9; the (query, target-set) pairs become training data with no human labels. (3) Diffusion retriever training: an EDM variance-exploding diffusion transformer learns to map a query embedding to a set of target embeddings in a single forward pass. The reward function for open-ended tasks (OAR) blends grounding (λg=0.6), Vendi-score diversity (λd=0.2), and alignment to the original query (λa=0.2); for composition tasks (WSCR) the reward is the fraction of reference-set items retrieved. Ablation shows grounding alone collapses to strings like "line ending line ending", adding alignment accelerates the collapse, and only the diversity component closes both failure modes.

Results: Polyvore and music, LLM judge and hard metrics

Experiments ran on Polyvore (fashion, encoded with 128-dimensional Matryoshka CLIP) and a proprietary playlist dataset with MuLan embeddings. Every method produced k=10 sub-queries; best-of-N used N=5. OAR quality was measured by an LLM judge on a five-point scale: on Polyvore, Gemma3-4B R4T-FOLM scored 49.1 versus 40.9 for best-of-N and 38.5 zero-shot. The diversity metric (Vendi) jumped from 56.0 to 76.8, and R4T-Diffusion preserved 74.3. On music: 58.1 versus 49.2. Grounding was not reported for the diffusion version because it does not generate text. On WSCR on Polyvore, R4T-FOLM (Qwen) reached Recall@5K of 20.9 and Hit@5K of 64.6, compared with 15.7 and 52.1 for Gemini-2.5-Flash, but the Vendi score dropped to 27.5 — a coverage-diversity trade-off the authors highlight.

What this means for production search and recommendation

R4T demonstrates that distilling an RL policy into a non-autoregressive diffusion model delivers the best of both worlds: FOLM-level quality with single-pass inference speed. For teams building search or recommendation engines that need to return a diverse set — not ten nearly identical tents — this is an architectural pattern worth studying: expensive offline training once, then a small, fast model in production. The code and weights have not yet been released, so for now the paper and its ablations remain the reference point.