arXiv(opens in a new tab)cs.CLAug 2026Cited by 1 paper on PaperVantage

Manuscript Offprint

arXiv:2608.30391

Using Grounded Theory for Agent Behavior Analysis at Scale

Zhuoran Lu, Yangyang Yu, Zhuoyan Li, Yibo Meng, Nan Jiang, Chengxi Zang, Jie Gao, Ziang Xiao

Open access. PaperVantage converted this article to text, so layout and figures may differ from the original.

Zhuoran Lu1^{1}, Yangyang Yu2^{2}, Zhuoyan Li1^{1}, Yibo Meng3^{3}, Nan Jiang4^{4}, Chengxi Zang3^{3}, Jie Gao5^{5} and Ziang Xiao5^{5}

1^{1}Purdue University, 2^{2}Stevens Institute of Technology, 3^{3}Cornell University, 4^{4}University of Texas at El Paso, 5^{5}Johns Hopkins University

Understanding agent behavior requires methods that scale to thousands of trajectories and surface new patterns in long, often unfamiliar tasks where pre-built classifiers fall short. We propose to bring grounded theory into agent trajectory analysis: a six-decade-old qualitative method from the social sciences, with a principled saturation criterion and an auditable trail from data to theory. We propose AutoTraceGT 1^{1}, the first multi-agent pipeline that automates grounded theory on agent trajectories: it iteratively performs open, axial, and theoretical coding until saturation, producing a behavioral taxonomy tailored to each task. Across six trajectory corpora, AutoTraceGT produces codebooks that recover 73 – 91% of the failure modes in human-annotated taxonomies and surface additional patterns that those taxonomies miss. The emergent theoretical narrative aligns with prior expert accounts. Used as a deductive feature space, the codebook outperforms zero-shot and few-shot LLM baselines on downstream failure prediction. These results suggest Grounded Theory offers a scalable analytic tool for ML researchers and agent developers studying what agents actually do.

1. Introduction

Recent advances in large language models (LLMs) have enabled agents to address increasingly complex tasks, including software engineering (Jimenez et al., 2024; Yang et al., 2024), web browsing (Deng et al., 2023; Zhou et al., 2024), computer use (Xie et al., 2024), and deep research (Mialon et al., 2024). These systems typically operate through agentic frameworks, in which an LLM interacts with external environments over multi-step trajectories consisting of planning, actions, observations, and revisions. However, stronger task-solving ability does not eliminate brittleness. Agents may still fail after long sequences of locally reasonable decisions, making it difficult to understand which behaviors support successful problem solving and which behaviors lead to failure. This motivates a critical question: what do agents actually do while solving tasks, and how can we characterize these behaviors at scale?

Existing analyses fall into two methodologically constrained regimes. Lightweight quantitative metadata (length, action counts, task success) scales easily but explains little about the underlying problem-solving process (Jimenez et al., 2024; Yang et al., 2024). Human analysis is interpretable but expensive, especially for agent trajectories with hundreds of steps (Cemri et al., 2025; Gao et al., 2026). A hybrid approach that builds behavioral classifiers based on pre-defined, often expert-derived, behavioral patterns is too rigid to generalize to novel tasks and emergent agent behaviors. The deeper gap is that the ML community currently lacks a methodology for studying agent behavior that is scalable and generalizable, a problem the social sciences have long faced and for which they have developed methodological responses.

We propose to bring a six-decade-old methodology widely used across qualitative research, Grounded Theory, into ML as a new analytic method for agents. Grounded theory (Charmaz, 2014; Glaser and Strauss, 1967) is an inductive qualitative methodology in which theories and

Corresponding author(s): Ziang Xiao, ziang.xiao@jhu.edu

Code: https://github.com/ZhuoranLu/Qual-Agent-Behavior-Analysis

Figure

References (2)

  • none observed
  • Not all categories will have → equal weight