≈ Health Checks / Watchdogs / APM (Application Performance Monitoring)
Mechanisms for agents to define high-level objectives, break them into trackable sub-goals, and continuously monitor progress towards completion. The agent checks: "Am I closer to the goal than I was 5 minutes ago?"
Mechanisms for agents to define high-level objectives, break them into trackable sub-goals, and continuously monitor progress towards completion. The agent checks: "Am I closer to the goal than I was 5 minutes ago?"
1# Check if process is running2# if ps aux | grep my_script; then echo "OK"; else restart; fi34import subprocess5result = subprocess.run(["ps", "aux"], capture_output=True)6if "my_script" in result.stdout.decode():7 print("OK")8else:9 restart()1# Semantic Health Check2current_state = agent.get_state()3goal = "Draft a complete report on Q3 earnings"45# The Monitor is an Agent6status = critic_agent.evaluate(7 criteria="Is the report complete and accurate?",8 context=current_state9)1011if status == "INCOMPLETE":12 agent.plan.update("Gather more financial data")13 agent.resume()Traditional SWE
Health Checks / APM
Agentic Pattern
Goal Setting & Monitoring
Monitoring system health and progress toward a defined state.
Traditional monitoring checks system metrics (CPU usage, latency, error rate). Agentic monitoring checks semantic progress (e.g., "Have we gathered enough research data yet?", "Is the draft complete?"). It requires "Metacognition" — thinking about thinking.
Essential to prevent agents from getting stuck in infinite loops ("doom loops") or declaring premature success.
Monitoring consumes tokens. Balance oversight frequency against cost.
Adapt: You need to build "Manager Agents" whose only job is to supervise "Worker Agents." You are automating middle management.
BuildBuild a Self-Monitoring Report Agent. Create a system where an agent works toward a goal (writing a report), monitors its own progress, and adjusts its plan when falling behind.
Mechanisms for agents to define high-level objectives, break them into trackable sub-goals, and continuously monitor progress towards completion. The agent checks: "Am I closer to the goal than I was 5 minutes ago?"
Monitoring system health and progress toward a defined state. However, there is a key divergence: Traditional monitoring checks system metrics (CPU usage, latency, error rate). Agentic monitoring checks semantic progress (e.g., "Have we gathered enough research data yet?", "Is the draft complete?"). It requires "Metacognition" — thinking about thinking.
Essential to prevent agents from getting stuck in infinite loops ("doom loops") or declaring premature success. Monitoring consumes tokens. Balance oversight frequency against cost.