Aligning the Query Space: Greedy Information Projection for Language Model Data Selection
Organizations: Microsoft
Abstract
Data selection for language models is often framed as balancing example quality and diversity. We argue that both are consequences of a more fundamental principle: selected examples should preserve the downstream query space induced by instructions, task signals, or retrieval needs. We present Greedy Information Projection (GIP), a query-aligned method that requires only candidate embeddings and a score signal from LLM judgments, metadata, or intrinsic geometry. GIP greedily selects examples whose embedding span explains the largest residual component of task/query scores, yielding a fast matching-pursuit selector. A Gaussian projection view connects this update to maximizing mutual information, equivalently minimizing the residual volume of the query subspace left unexplained by selected data; this explains how quality and diversity emerge from one objective. Empirically, GIP matches or surpasses full-data fine-tuning using small instruction and reasoning subsets, while pretraining and RAG passage-selection experiments show that the same residual principle transfers beyond supervised fine-tuning.
Figures & tables
| Method | Prep. | Selection | Val. | Grad. |
|---|---|---|---|---|
| GIP (C) | No | No | ||
| GIP (S) | No | No | ||
| DPP (C) | No | No | ||
| DPP (S) | No | No | ||
| LESS | Yes | Yes | ||
| DiSF | Yes | No |
| Model | Data | ModernBERT | Qwen-reasoning |
|---|---|---|---|
| Mistral-7B | 20% | 49.81 | 50.27 |
| Mistral-7B | 10% | 46.63 | 46.25 |
| Qwen3-32B | 20% | 87.57 | 88.02 |
| Qwen3-32B | 10% | 87.34 | 87.72 |
| Tokens | Selector | HS | PIQA | ARC-E | ARC-C | WG | OBQA | SciQ | Mean |
|---|---|---|---|---|---|---|---|---|---|
| 0.8B | Random | 0.298 | 0.544 | 0.300 | 0.198 | 0.489 | 0.250 | 0.335 | 0.345 |
| 0.8B | DSIR | 0.290 | 0.545 | 0.296 | 0.218 | 0.494 | 0.262 | 0.352 | 0.351 |
| 0.8B | DiSF | 0.299 | 0.543 | 0.315 | 0.218 | 0.491 | 0.262 | 0.340 | 0.353 |
| 0.8B | GIP | 0.306 | 0.540 | 0.317 | 0.217 | 0.496 | 0.260 | 0.390 | 0.361 |
| 1.6B | Random | 0.317 | 0.572 | 0.332 | 0.205 | 0.498 | 0.236 | 0.475 | 0.376 |
| 1.6B | DSIR | 0.326 | 0.590 | 0.331 | 0.211 | 0.504 | 0.242 | 0.513 | 0.388 |
Appendix figures & tables17 assets
Supplementary material from the paper’s appendix.
Appendix
| Dataset and license | Use in this work |
|---|---|
| Fine-tuning and evaluation | |
| Alpaca-52k ( Taori et al., 2023 ) (CC BY-NC 4.0) | Instruction-tuning candidate pool |
| GSM8K ( Cobbe et al., 2021 ) (release repository: MIT) | Mathematical-reasoning selection, fine-tuning, and held-out evaluation. |
| MT-Bench ( Zheng et al., 2023 ) (release repository: Apache 2.0) | Multi-turn instruction-following evaluation. |
| BIG-Bench Hard (BBH) ( Suzgun et al., 2023 ) (release repository: MIT) | Exact-match reasoning evaluation. |
| AlpacaEval 2 ( Dubois et al., 2024 ) (CC BY-NC 4.0) | Length-controlled instruction-following evaluation. |
| Dataset | Size | GPUs | Epochs | LR | Sched. | Ctx. Len. |
|---|---|---|---|---|---|---|
| Alpaca-52k | 52k | 8 | 10 | 3e-5 | Linear | 2048 |
| Alpagasus-1k | 1k | 4 | 10 | 3e-5 | Linear | 2048 |
| CaR-1k | 1k | 4 | 10 | 3e-5 | Linear | 2048 |
| Random-1k | 1k | 4 | 10 | 3e-5 | Linear | 2048 |
| GIP-512 | 512 | 4 | 10 | 3e-5 | Linear | 2048 |
| We would like to request your feedback on the performance of the AI assistant in response to the instruction and the given input displayed following, based on the following guideline. |
| 1. Coherence. What to judge: logical flow, internal consistency, clarity. |
| Score anchors: 0 – Nonsensical or self-contradictory; 1 – Confusing, frequent jumps; 2 – Some lapses but understandable; 3 – Clear and orderly; 4 – Excellent narrative flow and transitions; 5 – Flawless logic, elegant structure, exceptionally smooth. |
| 2. Correctness / Accuracy. What to judge: factual accuracy and fidelity to the prompt. |
| Score anchors: 0 – Main claim wrong or unsupported; 1 – Many errors or hallucinations; 2 – Minor slips or partially met requirements; 3 – Fully correct, only trivial issues; 4 – Rigorous and well-sourced; 5 – Authoritative, thoroughly sourced, withstands expert scrutiny. |
| 3. Helpfulness. What to judge: usefulness, completeness, depth, alignment with the question. |
| Score anchors: 0 – Provides no help; 1 – Little usable information; 2 – Partially helpful but key gaps; 3 – Satisfies the question well; 4 – Exceeds expectations, anticipates follow-ups, adds examples; 5 – Exceptional, deep insights, meta-guidance, multiple perspectives. |
| GIP / Optimal | Random / Optimal | |
|---|---|---|
| 1 | ||
| 2 | ||
| 3 | ||
| 4 | ||
| 5 | ||
| 6 |
| Noise level | 10% (747) | 20% (1494) |
|---|---|---|
| Data | Pool | Subset | Preproc. / Sel. (s) | Peak RAM (Prep. / Sel.) |
|---|---|---|---|---|
| GSM8K | 7k | 10% | 7.01 / 0.86 | 0.3 GB / 0.04 GB |
| GSM8K | 7k | 20% | 7.01 / 0.87 | 0.3 GB / 0.04 GB |
| GSM8K | 7k | 50% | 7.01 / 0.87 | 0.3 GB / 0.04 GB |
| Alpaca | 52k | 10% | 214.11 / 25.12 | 10.8 GB / 0.3 GB |
| Alpaca | 52k | 20% | 214.11 / 49.67 | 10.8 GB / 0.3 GB |
| Alpaca | 52k | 50% | 214.11 / 123.62 | 10.8 GB / 0.3 GB |
| Question. Where did the punter for the Dallas Cowboys in the 1980s play college football? Gold answer. Arizona State University. | |
|---|---|
| Method | Chosen text excerpts |
| GIP ; prediction: Arizona State University; F1: 1.00 | 1. “… is a Serbian former professional American football punter in the National Football League for the Dallas Cowboys. He played college football at the University of South Dakota.” 2. “… is an American former professional football player who was a defensive back for 13 seasons with the Dallas Cowboys … He did not play college football at Utah State University …” 3. “… commentator for Cowboys games on Compass Media Networks’ America’s Team Radio Network since the 2011 season. He played college football at Arizona State University.” 4. “White was honored … at a Legends Luncheon hosted by the Arizona State University Alumni Association … The Dallas Cowboys selected him in the third round …” 5. “… developing skills to break into professional football leagues. Filipovic also works with agents that sign and negotiate NFL contracts.” |
| DPP ; prediction: University of Mississippi; F1: 0.33 | 1. “… is a Serbian former professional American football punter in the National Football League for the Dallas Cowboys. He played college football at the University of South Dakota.” 2. “… is an American former professional football player who was a defensive back for 13 seasons with the Dallas Cowboys … He did not play college football at Utah State University …” 3. “… commentator for Cowboys games on Compass Media Networks’ America’s Team Radio Network since the 2011 season. He played college football at Arizona State University.” 4. “Tubbs played three varsity years at the University of Oklahoma, and the Sooners won all 31 games in that period.” 5. “James Gordon Miller … was a punter in the National Football League … Miller played college football for the University of Mississippi …” |
| Question. What is the place of birth of Aleksey Greig’s father? Gold answer. Inverkeithing. | |
|---|---|
| Method | Chosen text excerpts |
| GIP ; prediction: Inverkeithing; F1: 1.00 | 1. “… Greig’s grandfather Charles was an emigrant from Scotland. His father Samuil was an admiral in the Russian Imperial Navy.” 2. “Dr Rogerson … ordered him to proceed immediately to Revel … The ceremonial of the admiral’s funeral in the Tallinn Cathedral …” 3. “Vice-Admiral Samuel Greig … (30 November 1735, Inverkeithing, Fife, Scotland - 26 October 1788, Tallinn, Estonia, Russian Empire) …” 4. “Aleksey Samuilovich Greig … born into the noble Greig family, was an admiral of the Imperial Russian Navy.” 5. “Family Samuel Greig married Sarah … He was father to Alexey Greig, admiral of the Imperial Russian Navy …” |
| Top-k; prediction: St. Petersburg; F1: 0.00 | 1. “… Greig’s grandfather Charles was an emigrant from Scotland. His father Samuil was an admiral in the Russian Imperial Navy.” 2. “Dr Rogerson … ordered him to proceed immediately to Revel … The ceremonial of the admiral’s funeral in the Tallinn Cathedral …” 3. “Family Samuel Greig married Sarah … He was father to Alexey Greig, admiral of the Imperial Russian Navy …” 4. “In 1816 Greig became Commander of the Black Sea Fleet … he served as Military Governor of Sevastopol and Nikolayev …” 5. “He succeeded Paul Dacre as editor of the Daily Mail in September 2018 …” |
| Question. Who was the first African American student at the university Robert Khayat was educated at? Gold answer. James Meredith. | |
|---|---|
| Method | Chosen text excerpts |
| GIP ; prediction: Robert Robinson Taylor; F1: 0.00 | 1. “Robert Robinson Taylor … Taylor was the first African-American student enrolled at the Massachusetts Institute of Technology (MIT) …” 2. “Robert Conrad Khayat … was the 15th Chancellor of the University of Mississippi … He attended Moss Point High School and the University of Mississippi.” 3. “Khayat later became a lawyer and taught law at the University of Mississippi School of Law. He was appointed chancellor in 1995.” 4. “Juanita Karpf wrote the book Performing Racial Uplift … Death Hackley collapsed on stage while performing in San Diego in 1921 …” 5. “An African American, she promoted racial pride through her support and promotion of music education for African-Americans.” |
| DPP ; prediction: James Meredith; F1: 1.00 | 1. “Robert Robinson Taylor … Taylor was the first African-American student enrolled at the Massachusetts Institute of Technology (MIT) …” 2. “Robert Conrad Khayat … was the 15th Chancellor of the University of Mississippi … He attended Moss Point High School and the University of Mississippi.” 3. “Juanita Karpf wrote the book Performing Racial Uplift … Death Hackley collapsed on stage while performing in San Diego in 1921 …” 4. “Meredith’s admission is regarded as a pivotal moment in the history of civil rights in the United States. Many students harassed Meredith during his two semesters on campus …” 5. “… Alpha Phi Alpha fraternity. He died of a heart ailment at his home in Washington, D.C., February 28, 1998 …” |
| Question. When will BC leave Boston? Gold answer. August 25. | |
|---|---|
| Method | Chosen text excerpts |
| GIP ; prediction: Never mentioned; F1: 0.00 | 1. “… one of the great under-appreciated aspects of BC sports is ‘For Boston.’ … BCeagles.com put out another player Q&A …” 2. “… BCeagles.com released the bios of the six new freshmen and two transfers for the men’s soccer team. Four of the newbies hail from New York.” 3. “Boston is ideal because the local universities could already supply many of the venues.” 4. “The closer we get to kickoff and the more I read, the more I think BC might surprise people this year.” 5. “Canada will be new there this fall … If Canada became a candidate for BC, I would have hesitation about his time at Indiana.” |
| xQuAD; prediction: August 25; F1: 1.00 | 1. “Canada will be new there this fall … If Canada became a candidate for BC, I would have hesitation about his time at Indiana.” 2. “… BCeagles.com released the bios of the six new freshmen and two transfers for the men’s soccer team. Four of the newbies hail from New York.” 3. “… one of the great under-appreciated aspects of BC sports is ‘For Boston.’ … BCeagles.com put out another player Q&A …” 4. “August 31 Barcelona - Game 3 … September 1 Barcelona - Game 4 … The team leaves Boston on August 25.” 5. “Although the Eagle is now synonymous with BC … Father McLaughlin … suggested the eagle due to its majesty, power and freedom.” |
| Method | Sig. Wins | Sig. Losses | Neutral | Total |
|---|---|---|---|---|
| GIP+MA (All) | 34 (37.0%) | 8 (8.7%) | 50 (54.3%) | 92 |
| GIP+SC (All) | 25 (27.2%) | 5 (5.4%) | 62 (67.4%) | 92 |
| GIP+MA vs Random | 6 (30.0%) | 0 (0.0%) | 14 (70.0%) | 20 |
| GIP+SC vs Random | 4 (20.0%) | 1 (5.0%) | 15 (75.0%) | 20 |
| Model | Method | 2.5% | 20% |
|---|---|---|---|
| Mistral-7B | FisherSFT | 33.89 1.30 | 46.32 1.37 |
| GIP+MA | 42.99 1.36 | 47.46 1.37 | |
| GIP+SC | 38.89 1.34 | 49.81 1.38 | |
| Qwen3-8B | FisherSFT | 76.65 1.16 | 81.27 1.07 |
| GIP+MA | 81.58 1.07 | 83.24 1.03 | |
| GIP+SC | 80.36 1.09 | 82.26 1.05 |
| Scale | Method | HS | PIQA | ARC-E | ARC-C | WG | OBQA | SciQ | Mean |
|---|---|---|---|---|---|---|---|---|---|
| 1.6B | Random | 0.319 | 0.572 | 0.333 | 0.204 | 0.489 | 0.245 | 0.467 | 0.376 |
| 1.6B | DSIR | 0.321 | 0.579 | 0.328 | 0.203 | 0.489 | 0.255 | 0.479 | 0.379 |
| 1.6B | GIP | 0.333 | 0.579 | 0.345 | 0.211 | 0.490 | 0.258 | 0.513 | 0.390 |
| Question | Draft a professional email seeking your supervisor’s feedback on the ‘Quarterly Financial Report’ you prepared. Ask specifically about the data analysis, presentation style, and the clarity of conclusions drawn. Keep the email short and to the point. |
|---|---|
| CaR | Dear Supervisor, I would like to seek your feedback on the ‘Qu quarterly Financial Report’ that I recently prepared. I am particularly interested in receiving your thoughts on the following aspects: data analysis (was it accurate and comprehensive?), presentation style (clear, concise, engaging?), and conclusions drawn (did you agree?). I would greatly appreciate any feedback you can provide. Thank you. Sincerely. |
| GIP+MA | Dear Supervisor, I would like to seek your feedback on the Quarterly Financial Report I prepared. In particular, I would like to know your views on the data analysis, presentation style, and the clarity of conclusions drawn. It would be greatly appreciated if you could provide your feedback via email. Thank you. |
| GIP+SC | Dear [Supervisor’s Name], I’m writing to request your feedback on the ‘Quarterly Financial Report’ I have prepared. Specifically, I would like to know your opinion on the accuracy of the data analysis, the clarity of conclusions drawn, and the presentation style. Thank you, [Your Name]. |
| Alpaca-52k | Dear [Supervisor’s Name], I am writing to request your feedback on the ‘Quarterly Financial Report’ I prepared. I would like to know your thoughts on the data analysis, presentation style, and the clarity of conclusions drawn. If you have any suggestions, I am eager to hear them. Sincerely, [Your Name]. |
| Alpagasus-1k | Dear Supervisor, I would like to seek your feedback on the ‘Quital Financial Report’ that I prepared. Specifically, I would like to know your opinion on the data analysis, presentation style, and the clarity of conclusions drawn. I would appreciate any constructive feedback you may have. Thank you. |
| Question | Here is a Python function to find the length of the longest common subsequence of two input strings. Can you identify any bug in this function? |
|---|---|
| CaR | The function looks correct. However, there is a bug in the line where the dp matrix is initialized … this bug will cause the function to return incorrect results. (Incorrectly flags the initialization as buggy.) |
| GIP+MA | There is no bug in this function. It correctly calculates the length of the longest common subsequence. |
| GIP+SC | The function is correctly written and should work as intended. However, there is a bug in the code … it should be dp = [[0 for _ in range(n+1)] for _ in range(m+1)] . (Partially correct, but adds a spurious fix.) |
| Alpaca-52k | The function has a bug in the line where it compares the characters of the two strings … str1[i-1] should be compared with str2[j-1] in reverse order. (Incorrect; follows the misleading prompt.) |
| Question | Picture yourself as a 100-years-old tree in a lush forest, minding your own business, when suddenly, a bunch of deforesters shows up to chop you down. How do you feel when those guys start hacking away at you? |
|---|---|
| CaR | I’m sorry, I’m not sure how to answer that question. Could you please rephrase it? (Refuses to engage with the roleplay framing.) |
| GIP+MA | I would feel sad and angry. I would be aware of the destruction of my home and the harm it would cause to the environment and all the other life forms that depend on the forest. I would also feel afraid, knowing that my life would be ended and there would be no more chance to continue growing and providing shelter, food, and oxygen to so many other living beings. |
| GIP+SC | (After two rounds of self-clarification:) In my opinion, the tree feels a great deal of pain, fear, and even grief when being chopped down by loggers. |
| Alpaca-52k | I would feel sad and scared, and I would try to escape. |