TL;DR
This paper introduces Iterative Agent Decoding (IAD), a novel framework for improving the performance of AI agents at test time by effectively leveraging feedback. IAD demonstrates significant accuracy gains, up to 10%, over existing methods, particularly in compute-constrained scenarios, highlighting feedback as a critical component for agentic AI.
What Problem Does This Paper Address?
Agentic AI workflows, designed to autonomously plan and act, are becoming increasingly prevalent. However, their success rate on complex tasks remains low. A promising avenue for improvement is "inference-time alignment," which uses additional computational resources during testing to boost performance. This alignment typically involves three components: sampling (generating multiple potential outputs), evaluation (assessing the quality of these outputs), and feedback (using evaluation results to guide future generations). While sampling and evaluation have been extensively studied, the role and effective integration of feedback remain underexplored, especially in "black-box" agentic systems where internal model workings are inaccessible. This paper aims to fill this gap by systematically investigating the impact of feedback on the test-time scaling of agentic AI.
Methods
The core contribution of this paper is the introduction of Iterative Agent Decoding (IAD), a sequential framework designed to incorporate various forms of feedback for inference-time alignment. IAD works by iteratively refining a candidate solution. In each iteration:
- Sampling and Generation: A new candidate solution is generated by the agent's policy, conditioned on the initial input, the best solution found in previous iterations, and the feedback received.
- Evaluation and Selection: The newly generated candidate is evaluated against the current best solution using a verifier or reward function. The better of the two is selected as the new best-so-far.
- Feedback Integration: This is a crucial step where feedback is generated based on the evaluation. The paper explores two main types of feedback:
- Textual Feedback: Natural language critiques or instructions.
- Scalar Feedback: Numerical scores or preference comparisons.
A key innovation is how IAD handles scalar feedback. Instead of simply appending the score, it transforms it into structured, directional feedback by identifying the best and worst responses from the current iteration. This feedback is then incorporated into the prompt for the next generation step, guiding the agent towards improvement. The framework is designed to be API-friendly and compatible with various underlying models, making it suitable for black-box scenarios.
Datasets
The authors evaluate their approach on four challenging agentic benchmarks:
- Sketch2Code (Li et al., 2024b): Tests multi-modal abilities by converting wireframe sketches into functional HTML prototypes. Metrics include Layout Similarity, Text IoU, and Image IoU.
- Text2SQL (Li et al., 2024a): Focuses on translating natural language questions into executable SQL queries over structured databases. The BIRD benchmark is used, featuring over 12,000 question-SQL pairs across 95 databases. The primary metric is execution accuracy (EX).
- Intercode (Yang et al., 2023a): Evaluates agents in structured programming tasks (Bash, Python, SQL, CTF). Performance is measured by task execution correctness. The Bash domain was used for experiments.
- WebShop (Yao et al., 2023): Simulates a real-world online shopping environment requiring long-horizon, language-guided decision-making. Metrics include Success Rate (SR) and Progress Rate (PR).
Key Insights and Ideas
- Feedback is Crucial for Budget-Constrained Scaling: The most significant finding is that feedback plays a vital role in improving agent performance when computational resources (like the number of samples or model calls) are limited. IAD consistently outperforms feedback-free baselines in these scenarios.
- Adaptive Refinement, Not Just Diversity: The gains from IAD are not solely due to generating more diverse outputs (as in Best-of-N sampling). Instead, the adaptive, feedback-guided refinement process is the primary driver of performance improvements.
- Scalar Feedback Design Matters: While textual feedback is easier to integrate, designing effective feedback from scalar rewards is challenging. IAD's method of transforming scalar scores into directional prompts is key to unlocking their potential.
- Robustness to Imperfect Feedback: IAD shows reasonable robustness to mild noise or sparsity in feedback signals, leveraging pairwise comparisons effectively. However, extreme sparsity or noise can degrade performance, underscoring the importance of feedback fidelity.
- Model Capability vs. Feedback Benefit: As base models become more capable, the advantage of iterative feedback diminishes, as stronger models can achieve better results with parallel sampling alone. This highlights a trade-off between model power and the need for iterative refinement.
Key Results
- Accuracy Gains: IAD achieves up to 10% absolute performance improvement over feedback-free baselines like Best-of-N (BoN) in budget-constrained settings across various tasks.
- Sketch2Code: IAD consistently outperforms BoN and single-turn baselines by 3-4% even with a weaker model (Gemini-1.5-Pro) and few iterations. With improved models, the gap narrows, but IAD still shows benefits.
- Text2SQL: IAD achieves higher execution accuracy with fewer LLM calls compared to few-shot CoT and BoN, effectively correcting SQL errors through feedback.
- WebShop: IAD shows a 3-4% absolute gain in Success Rate compared to strong baselines like BoN-SC + GPT-40.
- Feedback Modality: Transforming scalar feedback into directional prompts yields gains of up to 6-7% over baselines in Sketch2Code and Text2SQL.
- Sensitivity to Quality: IAD remains effective under mild noise and sparsity. However, performance declines significantly under extreme conditions, with gains dropping by approximately 4-5%.
Limitations and Future Work
- Sequential Nature and Latency: IAD's iterative, sequential nature inherently leads to increased user-facing latency compared to parallelizable methods like BoN. Future work could explore combining these approaches with adaptive stopping or controlled decoding to mitigate this.
- Verifier's Role: The verifier (or judge) plays a critical role in IAD's success. The paper suggests that a more concrete investigation and selection of optimal judges for challenging tasks is a crucial next step.
- Generalizability of Feedback: While IAD integrates diverse feedback forms, representing scalar or preference signals effectively in sequential designs remains an open challenge.
- Prompt Engineering for Judges: The paper acknowledges that more specific prompts could further improve LLM judges, but this falls outside the current scope.
- Language Limitation: The current study is limited to English language text due to the nature of the open-source datasets used.
Summary updated