AgenTest: Mining Business Rules to Test LLM Agents for Business Logic Bugs

Large language model (LLM) agents increasingly execute business operations through tools and interact directly with application data and services. Beyond completing user requests, these agents must obey domain-specific business rules that constrain when actions are permitted and what data or resources may be affected. Violating such rules can lead to business logic bugs, even when a task appears successful. Detecting these bugs is difficult because the rules are rarely available as explicit, testable specifications. They are distributed across system prompts and tool definitions, while others remain implicit in domain knowledge. Existing agent testing approaches typically evaluate task success, predefined policies, or known attack scenarios. This limits their ability to systematically uncover previously unspecified business-rule violations. We present AgenTest, which mines business rules from system prompts, tool definitions, and domain knowledge, refines them into Given-When-Then specifications, and systematically tests each specification. For each extracted specification, AgenTest instantiates its Given conditions by constructing a satisfying environment state and simulated user, exercises the agent through multi-turn interactions, and checks its Then conditions over messages, tool calls, and state changes using a hybrid oracle. On the airline, retail, and telecom agents of tau2-bench with two underlying models, AgenTest produces 551 refined specifications, and detects violations of 89 and 121 distinct specifications, respectively -- 3.4X and 2.5X as many as all baselines combined. Only AgenTest detects cases where an agent improperly accesses or modifies another user's data. Moreover, about 60% of bug-triggering runs cannot be detected from the final state alone, highlighting the need to check the full interaction against explicit business rules.

Link
https://www.semanticscholar.org/paper/7b4f37c5a57bac7e97ff64b0d278729ccf4bf21b
Found by
Semantic Scholar
Authors
Li-Li Quan, Long-Tian Wang, Yue-Lin Wang, Ming-Fei Cheng, Chao Shen, Sen Chen, Xiao-Fei Xie
Categories
evaluation, agentic
Published
2026-10-20
Last seen by the radar
2026-10-22
Citations
0
Influential citations
0
Radar score
35.50 / 100 (how it is scored)
Why it scored so
Matched: agent~evaluate, evaluat; Primary record: Semantic Scholar
Related links
https://arxiv.org/abs/2610.28116
Is this record right? If you made this work and something here is wrong or missing, tell us what to fix.

More records found by Semantic Scholar