Skip to Content
ElectronicsElectronics
  • Article
  • Open Access

1 December 2026

41 Pages

Learning Reusable Action Rules from Language Agent Trajectories

and
School of Computer & Computing Science, Hangzhou City University, Hangzhou 310015, China
*
Author to whom correspondence should be addressed.
Electronics2026, 15(23), 5649;https://doi.org/10.3390/electronics15235649 
(registering DOI)
This article belongs to the Topic AI Agents: Progress, Architecture, and Applications

Abstract

Language agents repeatedly call models for recurring local operations. Traj2Rules learns short executable rules by linking success, failure, or unknown outcomes to specific action programs in previous trajectories. A generator proposes and revises rules using execution feedback within predefined domain interfaces. At deployment, a frozen rule library can execute a uniquely supported action before a model call, verify its effect, and reject or repair model proposals. With Qwen3.5-9B, success rates reached 69.65%, 54.44%, and 49.00% on ALFWorld, ScienceWorld, and WebShop. Paired tests supported gains of 10.00–11.44 percentage points over ReAct across the three domains, while model requests fell by 26.3–31.1%. Enumeration over the same interfaces recovered about three-fifths of the observed success-rate gain over ReAct. Fine-tuning increased mean probe coverage for the 9B generator from 40.6% to 57.4%. In the primary paired analysis, only WebShop showed a statistically significant gain over frozen AutoTool (AutoTool-F) without the additional registered checks (5.93 percentage points). When AutoTool-F used the same checks as Traj2Rules, only the WebShop gain was significant (4.87 percentage points, Holm-adjusted p=0.0118). Across the three domains, the full method scored 0.33–0.75 percentage points higher than direct rule generation with the untuned 27B model. These comparisons did not establish a success-rate benefit from generator training.

Article Metrics

Citations

Article Access Statistics

Article metric data becomes available approximately 24 hours after publication online.