How Good Are LLMs at Processing Tool Outputs?

Kiran Kate, Yara Rizk, Poulami Ghosh, Ashu Gulati, Tathagata Chakraborti, Zidane Wright, Mayank Agarwal · 2025

Read How Good Are LLMs at Processing Tool Outputs? by Kiran Kate, Yara Rizk, Poulami Ghosh, Ashu Gulati, Tathagata Chakraborti, Zidane Wright, Mayank Agarwal (2025) in the Tower of Babel, a free online library of public-domain works preserved in clean, searchable text. No sign-up. The full text is served as a plain-text file at a predictable URL, where text is present: https://antarctic-labs.com/tower-of-babel/arxiv-2510-15955.txt.

Introduction

Kiran Kate and six co-authors test how well language models can work through the messy replies that tools return. Real automation needs a model to call tools, then mine their complex JSON responses for the facts that finish the task. That second step is rarely measured on its own, so the team built a data set for exactly it.

They evaluate fifteen open and closed models under several prompting styles. Structured response processing stays hard even for frontier models across all styles tried. The best strategy depends on the output's nature and size and on how much reasoning the extraction needs. Switching approaches alone can swing performance across a very wide range, from a few points to half the score. The study maps a quiet bottleneck in tool-using systems, the seven authors argue.

Catalog record

CREATORKiran Kate, Yara Rizk, Poulami Ghosh, Ashu Gulati, Tathagata Chakraborti, Zidane Wright, Mayank Agarwal
YEAR2025
COLLECTIONPAPERS
FORMATTXT
FILE SIZE76 KB
VERSION1.0
LICENSEhttp://creativecommons.org/licenses/by/4.0/
RIGHTSCC BY
SOURCEarXiv

Source: https://arxiv.org/abs/2510-15955

Browse the full library · About the Tower of Babel

Full text

The opening of the work, from the library's hosted text:

How Good Are LLMs at Processing Tool Outputs? Kiran Kate, Yara Rizk, Poulami Ghosh, Ashu Gulati, Tathagata Chakraborti, Zidane Wright, Mayank Agarwal Abstract Most realistic task automation problems require large language models (LLMs) to call tools, which often return complex JSON responses. These responses must be further processed to derive the information necessary for task completion. The ability of LLMs to do so is under-studied. In this paper, we study the tool response processing task and LLMs’ abilities to process structured (JSON) responses. We created a dataset for this task, and evaluated 15 open and closed weight models using multiple prompting approaches 1 1 1 https://github.com/LongFuncEval/toolJSONprocessing . Our results show that JSON processing remains a difficult task even for frontier models across multiple prompting strategies. The optimal response processing strategy depends on both the nature and size of the tool outputs, as well as the complexity of the required reasoning. Variations in processing approaches can lead to performance differences ranging from 3% to 50%. 1 Introduction Tool-augmented large language models (LLMs) ( Qin et al. 2023 ; Li et al. 2023 ; Xu et al. 2023 ; Lu et al. 2025 ; Shen 2024 ) can perform tasks beyond their parametric knowledge by calling external tools. A typical multi-turn tool-calling scenario is shown in Figure 1 . Given a user’s request, an LLM may need to use multiple tools in sequence to address it. Each tool call generated by the LLM is executed and the tool returns data that contains information useful for either responding to the user or for performing the next steps leading to the final answer. Real-world enterprise tools may be existing REST APIs which return large JSON objects as their response Qin et al. 2024 ; Zhong et al. 2025 . The process of extracting useful information from their response, then, becomes non-trivial. A common approach is to simply append the tool response to the LLM context ( Yao et al. 2023 ) . This works well for scenarios with small and simple tool outputs ( Li et al. 2023 ; Liu et al. 2024b ; Basu et al. 2025 ) . For real-world APIs with long and complex outputs, the response is either added as is or is pruned to fit in the context ( Qin et al. 2023 ; Zhong et al. 2025 ) . Sometimes, LLMs are used to summarize the tool output ( Aksitov et al. 2023 ) or to generate code to process it ( Song et al. 2023 ) . When building real-world agentic systems, it is crucial to understand which of these tool response processing approaches works best. This analysis remains a gap in the literature despite the existence of many works focused on understanding LLMs’ tool selection and end-to-end task execution abilities. In this paper, we address this gap by isolating the tool response processing task, creating an evaluation dataset, and analyzing LLMs’ performance. The task is formulated as question-answering (QA) on structured tool responses. Specifically, we consider the JSON response format which is popular among real-world tools ( Qin et al. 2024 ) . We manually create the QA dataset based on real tool responses, obtained from RapidAPI 2 2 2 https://rapidapi.com/ . We evaluate 15 high performing LLMs across model families, model sizes, reasoning abilities and context lengths. We compare different prompting techniques including prompting the model to generate the final answer versus to generate Python code to parse the JSON, utilizing chain of thought (CoT) reasoning, and adding various arguments (response, schema, etc.) to the prompt. We structure our analysis across several key dimensions: response length, prompting approach, and question type. Our experimentation and analysis led to three main conclusions: 1) JSON processing is a non-trivial task even for frontier models (GPT-4o highest accuracy is 77%), 2) models can handle this task better by generating JSON parsing code instead of deriving the answer by looking at the JSON when the processing involves reasoning over the data (ranging from +3% to +50%), 3) including a schema of the structured data in the prompt improves performance (up to +12%), and 4) including even a condensed version of the response is better than excluding the response entirely when it doesn’t fit in the model’s context window. Section 4 provides detailed results and ablation studies. Our contributions are as follows: • We formulated tool response processing as a QA task and created an evaluation dataset; • We evaluated 15 open and closed weight models on this task with different processing approaches focusing on 4 main control points; • We performed an in-depth analysis of LLM performance and derived practical insights to inform real-world applications. Figure 1: A typical multi-turn tool use pipeline. Tool response processing is shown here as an explicit step to highlight its importance. This paper studies LLM-based approaches to tool response processing and measures the correctness of output "Data" from the processing step by creating a handcrafted evaluation dataset for it. 2 Tool Response Processing The ability of LLMs to extract and/or derive useful information from tool responses is crucial to the success of end-to-end agentic systems. As shown in Figure 1 , our goal is to isolate the tool response processing component within an agent and evaluate the state of the art approaches for that task. 2.1 Dataset Creation The task is formulated as a QA task on tool responses. The dataset consists of triplets (tool response, natural language (NL) question, answer) where the tool response is in JSON format and the answer to the question is based on the data in the response. The queries are categorized into one of three types: extractive (returns a value in the JSON given a key), filtering (returns multiple entries corresponding to filtering criteria) and aggregation (combines multiple entries by performing an aggregation operation). Figure 2 shows an example of these three types of questions (with additional examples in Figures 13 , 14 , 15 in the Appendix). To perform our study, we collected multiple responses from six REST API endpoints from RapidAPI, covering domains such as hotel booking, car rentals, flight seats, SEC filings, and product search. For the travel related endpoints, we extract the API responses from the ComplexFuncBench dataset ( Zhong et al. 2025 ) . We manually reviewed those responses to understand the JSON structure, created question templates and wrote Python code to retrieve the ground truth answers. Our dataset contains 1298 QA-samples (Table 1 ), with 580 extractive (derived from 14 templates), 394 filtering (18 templates), and 324 aggregation (18 templates) questions. The JSON responses varied in length (averaging 24,000 to 74,000 characters) and complexity. Endpoint Total Samples Extractive Filtering Aggregation Avg. #Characters in API Response Booking - Get Hotels 13 6 5 2 25,008 Booking - Search Car Rentals 87 34 34 19 24,048 Booking - Get Seat Map 184 29 89 66 53,698 Real Products - Shoes 228 75 75 78 55,968 SEC-Filings 267 84 98 85 74,319 Booking - Get Rooms 519 352 93 74 65,341 Total 1298 580 394 324 - Table 1: Dataset statistics 2.2 Common Approaches Figure 2: Tool response processing approaches We consider multiple processing approaches from the literature Aksitov et al. 2023 ; Song et

Read the complete text