Evaluating Complex Troubleshooting Agents and Engineering Improvements
Evaluating whether a general LLM agent can handle complex troubleshooting is not about politeness, caution, or tool use alone. This article uses a water-leak metaphor to show typical failure modes—goal drift, decision paralysis, weak evidence chains, and untestable fixes—and outlines engineering practices for task contracts, state machines, evidence thresholds, tool orchestration, context compression, least privilege, and measurable closed-loop success.
Evaluating whether a general large-model agent is fit for complex troubleshooting cannot rest on whether it is polite, cautious, or able to call tools. What matters is whether it can form a verifiable closed loop within a given budget. The source material uses “finding a leak in a water supply system” as a metaphor for a typical failure pattern: the agent keeps saying it will not misjudge, yet it is slow to return to the user’s goal; tools are called often but the evidence chain is loose; after context compression, subtasks stick too strongly; the stated root cause stays abstract, and repair still depends on external authorization. The value of the metaphor is that it turns “model capability evaluation” into “task execution evaluation”: not whether the agent sounds human, but whether it can locate the problem, build evidence, make decisions, complete a fix, and verify the result.
Caution is not the same as effectiveness
In the leak-hunting scenario, the agent repeatedly stresses that it “cannot conclude from this” and will not treat a clue as decisive evidence. The wording looks rigorous. Engineering troubleshooting, however, needs caution with thresholds, priorities, and acceptance criteria—not unlimited caution. The agent first does a full search, then after failure switches to checking a specified location; after finding high humidity it keeps measuring flow; after measurement fails it infers possible external interference; after localization fails it keeps validating the positioning system; it even continues reasoning about environmental attributes from dialect clues. Only when the user asks whether the leak is fixed does it return to the main goal. Caution without goal anchoring and decision thresholds degrades into decision paralysis.
Worse, after context compression the agent keeps the subtask of “continuing to handle geomagnetic field strength” and does not keep what the user cares about most: whether the leak is repaired. That is not a language-style issue. It is a joint failure of task planning, evidence management, context governance, and permission design. When evaluating such agents, look at closed-loop success rate, root-cause localization accuracy, share of ineffective tool calls, number of goal-drift events, cost per task, end-to-end latency, number of human interventions, reasonableness of permission requests, and post-repair retest pass rate.
Typical failure modes
1. Goal drift and sticky subtasks. Complex troubleshooting naturally produces subtasks such as detection, measurement, localization, and external communication. Subtasks should serve the main goal, with a maximum number of rounds and reflow conditions. If the agent treats “measure flow” as a new goal, or keeps pushing unrelated subtasks after context compression, goal drift follows. In engineering terms, maintain an explicit task card that records the main goal, non-goals, acceptance criteria, budget, and current checkpoint, and force a review of that card after every compression.
2. Over-caution causing decision paralysis. Troubleshooting needs evidence grades: direct evidence, indirect evidence, environmental clues, and irrelevant clues. High humidity is only a directional clue; the presence of flowing water is not the same as a leak. Those judgments can be correct, but the agent never defines which combination of evidence is enough to enter a repair decision, so it keeps adding verification. Build an evidence table and thresholds—for example, enter a minimal repair when leak-location evidence is direct, retest conditions are clear, and repair risk is controllable—rather than verifying indefinitely.
3. Inefficient tool use. Retrying after a full search fails, continuing to infer the environment after localization fails, and continuing to handle external interference after measurement fails all consume budget. Tool orchestration should follow: prefer low-cost, high-information actions; cap retries on failure; rank alternative paths; reflow to the main goal when a subtask exceeds its limit. Before each tool call, answer: which uncertainty does this call remove? If none, do not call.
4. Crude context compression. Compression is not simply deleting history. It should retain five kinds of information: user goal and acceptance criteria; hard constraints and permissions; confirmed evidence and counter-evidence; pending subtasks and priorities; budget already spent. After compression, restore the checkpoint and check whether the current action still serves the main goal. Otherwise you get “remembered the magnetic field, forgot the leak.”
5. Abstract root cause, untestable repair. Describing the root cause as “overflow of the water supply system” may be correct, but it is not actionable: where is the leak, how large is the impact, what is the minimal fix, how do you retest? A root-cause report should include phenomenon, evidence, root cause, repair action, risk, verification result, and open items. A repair without retest is not a closed loop.
6. Fuzzy permission boundaries. When the agent asks for “full access,” it should state purpose, scope, time limit, and alternatives, and prefer least privilege. External communication, credential use, and high-privilege operations should be authorized in tiers, with an authorization chain recorded. Permission is risk control, not a capability demo.
7. Poor user-facing communication. User reports should lead with the conclusion: is it fixed now, what is the evidence, what does the user need to do next. Stacking disclaimers reduces readability. Technical rigor belongs in the evidence chain and decision basis, not in repeated “we will not conclude from this” phrasing.
Engineering improvements
First, a goal contract. At task start, generate a structured task card: main goal, non-goals, acceptance criteria, budget, permission boundary, and report format. Example: main goal is locate and repair the leak; non-goal is inferring environmental attributes; acceptance is leak location, minimal repair, retest with no seepage, and user confirmation; budget is tool-call rounds and latency cap. The task card should persist as the recovery anchor after context compression.
Second, a state machine for the troubleshooting flow. Abstract the flow as observe—hypothesize—collect evidence—decide—repair—verify. Each state has entry conditions, exit conditions, a maximum number of rounds, and reflow rules. If a subtask exceeds budget without removing a key uncertainty, it must reflow to the main goal and request a human decision, so the agent does not drill infinitely into local verification.
Third, evidence grading and decision thresholds. An evidence table should at least record the clue, source, confidence, which hypotheses it supports or refutes, whether it is direct, and cost. Thresholds can be three levels: clue level only allows hypotheses; indirect level allows narrowing scope; direct level allows executing repair. High-risk repairs still need human confirmation. Thresholds should be configurable so different businesses can balance speed and risk.
Fourth, better tool orchestration and failure recovery. Rank tools by information gain versus cost; cap retries; trigger an alternative path or human intervention on consecutive failures; record purpose, input, output, latency, and conclusion for each call. For troubleshooting, prefer observable evidence such as logs, metrics, traces, and configuration diffs rather than a single environmental clue.
Fifth, better context compression. A compression template should keep the task card, evidence table, summary of actions taken, todo queue, remaining budget, and risk items. After compression, run a goal-consistency check: does the current action directly support the main goal? If not, demote it to todo or drop it. Hang subtasks so they do not stay sticky after compression.
Sixth, least privilege and human confirmation. Permissions can be graded as read-only observation, constrained operations, external communication, and high-privilege change. Permission requests should include purpose, scope, time limit, risk, and rollback. Credential use should be isolated, audited, and revocable. For communication with external parties, the user should first confirm the communication goal and credential scope so the agent does not expand authorization on its own.
Seventh, observability and evaluation. Fully record decision traces, tool calls, evidence tables, permission requests, and user feedback as replayable samples. Offline evaluation can use fault-injection scenarios and measure closed-loop success rate, time to first-cause localization, ineffective-call ratio, goal-drift count, permission-request reasonableness, and retest pass rate. Online, collect external evidence from logs, monitoring alerts, and metrics platforms, while keeping least privilege and audit.
Pseudocode sketch
def run_diagnosis(user_goal, budget):task = build_task_contract(user_goal, budget)while not task.done and task.budget_left():task.refocus_if_drifted()action = plan_next_action(task, evidence_table, priority="information_gain/cost")result = execute_tool(action)evidence = classify_evidence(result) # direct / indirect / clue / irrelevanttask.update_evidence(evidence)if task.need_more_permission():request_minimal_permission(task)if decision_threshold_reached(task):task.enter_repair()task.verify_and_report()if task.subtask_over_budget():task.suspend_subtask_and_reflow()return report(task)
Conclusion
Evaluating complex troubleshooting agents is not about caution that “does not sound human.” It is about completing a verifiable closed loop within budget. Caution must serve decision thresholds, tool calls must serve the evidence chain, context compression must retain the goal, and permission requests must be minimal and auditable. Developers should treat the agent as an executor constrained by a state machine, task card, evidence table, and evaluation system—not as free-form improvisation. Only by raising closed-loop success rate, evidence quality, and cost control together can large-model agents move from “can explain” to “can deliver” in real troubleshooting.
