arXiv

Diagnosing Knowledge Gaps in LLM Tool Use: An Agentic Benchmark for Novel API Acquisition

Title: Identifying Knowledge Deficits in LLM Tool Utilization: An Agentic Framework for Acquiring New APIs

Abstract

Large language models tasked with code generation frequently encounter APIs that were not included in their pretraining corpora. Mastering these tools demands more than simply recalling function names; models must effectively coordinate signatures, module paths, input-output contracts, semantic meanings, and executable usage patterns. Current benchmarks for novel APIs are often limited by their static nature, reliance on simplistic pass/fail metrics, or use of synthetic APIs that fail to mirror the complexity of real-world library evolution.

To address these limitations, we present NovelAPIBench, a fully automated dynamic benchmarking system. This framework operates across any base model and target library to discover novel APIs, extract decomposed knowledge bundles, generate executable coding tasks, and categorize failures into six distinct diagnostic groups. In an evaluation spanning approximately 1,900 tasks, four base models, and five distinct domains, we compared knowledge delivered via retrieval against knowledge internalized through parametric adaptation.

Our findings indicate that different knowledge components are not interchangeable. Usage examples emerged as the most potent standalone signal. The optimal two-component configuration involved pairing signatures with either mechanisms or examples, a choice dependent on the specific domain and backbone model. Furthermore, increasing context volume—particularly by adding source code—can be detrimental, as it tends to increase import-path errors.

Regarding parametric adaptation, we found that it does not eliminate the need for retrieval when external knowledge is removed. Instead, fine-tuning primarily equips models with the ability to utilize provided knowledge bundles, a skill that successfully transfers to unseen libraries. These results highlight a complementary relationship between the two approaches: retrieval serves to supply volatile API content, while tuning enhances procedural integration.


Source: arXiv Generated at: 2026-06-03 00:00:00 UTC

Related Articles

TikTok Billionaire Tops Ambani as Asia’s Second-Richest
Bloomberg

TikTok Billionaire Tops Ambani as Asia’s Second-Richest

TikTok founder surpasses Mukesh Ambani to become Asia’s second-richest person, marking a significant shift in the region...

Publishers in UK can opt out of Google AI search results
BBC News

Publishers in UK can opt out of Google AI search results

UK publishers can now opt out of Google’s AI search summaries, a CMA ruling designed to boost their bargaining power and...

Kioxia Edges Nearer Toyota’s Market Cap in Shakeup to Japan Inc.
Bloomberg

Kioxia Edges Nearer Toyota’s Market Cap in Shakeup to Japan Inc.

Kioxia’s market cap nears Toyota’s, signaling a major shift in Japan’s corporate hierarchy. This narrowing gap highlight...

Reuters

Morning Bid: Marvell, a fitting name for the latest AI darling

Reuters highlights Marvell as a top AI stock, noting its name perfectly suits its status as the newest market darling.

Financial Times

Tim Hayward: I built the Jaguar E-Type of computer keyboards

Tim Hayward compares his bespoke keyboard designs to the Jaguar E-Type. He explores high-end customization for personal ...

Financial Times

AI Labs: Zuckerberg’s $100bn gamble

Meta’s $100 billion AI investment aims to secure AI dominance, but questions remain whether sheer spending can outpace c...