Lune

ICML2025Top-tier venue

Adaptive Self-improvement LLM Agentic System for ML Library Development

Genghan Zhang, Weixin Liang, Olivia Hsu, Kunle Olukotun

Abstract

ML libraries, often written in architecture-specific programming languages (ASPLs) that target domain-specific architectures, are key to efficient ML systems. However, writing these highperformance ML libraries is challenging because it requires expert knowledge of both ML algorithms and the ASPL. Large language models (LLMs), on the other hand, have shown general coding capabilities. However, challenges remain when using LLMs for generating ML libraries using ASPLs because 1) this task is complicated even for human experts and 2) there are limited code examples due to the esoteric and evolving nature of ASPLs. We present an adaptive selfimprovement agentic system that enables LLMs to perform such complex reasoning under limited data by iteratively improving their capability through self-generated experience. In order to evaluate the effectiveness of our system, we construct a benchmark of a typical ML library and generate ASPL code with both open and closedsource LLMs on this benchmark. Our results show improvements of up to 3.9× over a baseline single LLM 1 .

Ask Lune

Know this paper in minutes, not an afternoon.

Lune can read every page of it and the top-tier papers that cite it, and gives you its claims, its evidence and its limits, each one cited to the paper it comes from. No skimming, no AI slop.

5 top-tier papers have cited it since. Know what they found before your reviewers do.

Questions to start from

Lune can draw on

the full paper · the top-tier papers that cite it · related work

Get the answer

Free to start. No credit card required.

Lineage

  • Tree of Thoughts: Deliberate Problem Solving with Large Language Models cites Chain-of-Thought Prompting Elicits Reasoning in Large Language Models
  • Reflexion: language agents with verbal reinforcement learning cites Toolformer: Language Models Can Teach Themselves to Use Tools
  • Reflexion: language agents with verbal reinforcement learning cites Chain-of-Thought Prompting Elicits Reasoning in Large Language Models
  • Can Dependencies Induced by LLM-Agent Workflows Be Trusted? cites Tree of Thoughts: Deliberate Problem Solving with Large Language Models
  • Can Dependencies Induced by LLM-Agent Workflows Be Trusted? cites Reflexion: language agents with verbal reinforcement learning
  • Can Dependencies Induced by LLM-Agent Workflows Be Trusted? cites Chain-of-Thought Prompting Elicits Reasoning in Large Language Models
  • KVFlow: Efficient Prefix Caching for Accelerating LLM-Based Multi-Agent Workflows cites Reflexion: language agents with verbal reinforcement learning
  • Agentic Context Engineering: Evolving Contexts for Self-Improving Language Models cites Reflexion: language agents with verbal reinforcement learning
  • Agentic Context Engineering: Evolving Contexts for Self-Improving Language Models cites Chain-of-Thought Prompting Elicits Reasoning in Large Language Models
  • Agentic Context Engineering: Evolving Contexts for Self-Improving Language Models cites Agentic Plan Caching: Test-Time Memory for Fast and Cost-Efficient LLM Agents
  • Agentic Plan Caching: Test-Time Memory for Fast and Cost-Efficient LLM Agents cites Agentic Context Engineering: Evolving Contexts for Self-Improving Language Models
  • Agentic Plan Caching: Test-Time Memory for Fast and Cost-Efficient LLM Agents cites Chain-of-Thought Prompting Elicits Reasoning in Large Language Models
Builds onCited byLeft to right by year; the more cited, the higher.

Cited by top-tier papers5

  1. Agentic Context Engineering: Evolving Contexts for Self-Improving Language ModelsQizheng Zhang, Changran Hu, Shubhangi Upasani, Boyuan Ma et al.ICLR 2026 · 374 citations
  2. KVFlow: Efficient Prefix Caching for Accelerating LLM-Based Multi-Agent WorkflowsZaifeng Pan, Ajjkumar Patel, Yipeng Shen, Zhengding Hu et al.NeurIPS 2025 · 77 citations
  3. Agentic Plan Caching: Test-Time Memory for Fast and Cost-Efficient LLM AgentsQizheng Zhang, Michael Wornow, Kunle OlukotunNeurIPS 2025 · 27 citations
  4. Can Dependencies Induced by LLM-Agent Workflows Be Trusted?Yu Yao, Yiliao Song, Yian Xie, Mengdan Fan et al.NeurIPS 2025 · 4 citations
  5. CubeBench: Diagnosing Interactive, Long-Horizon Physical Intelligence under Partial ObservationsHuan-ang Gao, Zikang Zhang, Tianwei Luo, Kaisen Yang et al.ICLR 2026 · 2 citations

Builds on28

  1. Chain-of-Thought Prompting Elicits Reasoning in Large Language ModelsJason Wei, Xuezhi Wang, Dale Schuurmans, Maarten Bosma et al.NeurIPS 2022 · 22,562 citations
  2. Toolformer: Language Models Can Teach Themselves to Use ToolsTimo Schick, Jane Dwivedi-Yu, Roberto Dessì, Roberta Raileanu et al.NeurIPS 2023 · 5,989 citations
  3. Reflexion: language agents with verbal reinforcement learningNoah Shinn, Federico Cassano, Ashwin Gopinath, Karthik Narasimhan et al.NeurIPS 2023 · 5,828 citations
  4. FlashAttention: Fast and Memory-Efficient Exact Attention with IO-AwarenessTri Dao, Daniel Y. Fu, Stefano Ermon, Atri Rudra et al.NeurIPS 2022 · 5,493 citations
  5. Tree of Thoughts: Deliberate Problem Solving with Large Language ModelsShunyu Yao, Dian Yu, Jeffrey Zhao, Izhak Shafran et al.NeurIPS 2023 · 5,068 citations

Related papers

  1. ARBench: Algorithmic Reasoner or API Alchemist? Evaluating LLMs Beyond API CallsRenbiao Liu, Chao-Zeng Ma, Anqi Li, Hui Sun et al.AAAI 2026
  2. STARK: Strategic Team of Agents for Refining KernelsJuncheng Dong, Yang Yang, Tao Liu, Yang Wang et al.ICLR 2026 · 26 citations
  3. MLE-STAR: Machine Learning Engineering Agent via Search and Targeted RefinementJaehyun Nam, Jinsung Yoon, Jiefeng Chen, Jinwoo Shin et al.NeurIPS 2025 · 58 citations
  4. Enhancing Open-Domain Task-Solving Capability of LLMs via Autonomous Tool Integration from GitHubBohan Lyu, Xin Cong, Heyang Yu, Pan Yang et al.ACL 2025
  5. An Agentic Framework with LLMs for Solving Complex Vehicle Routing ProblemsNi Zhang, Zhiguang Cao, Jianan Zhou, Cong Zhang et al.ICLR 2026 · 8 citations
Dusk over the sea between two cliffs drawn in fine vertical lines