observability

observability is a skill for Claude Code from rjmurillo/ai-agents. It costs 42 tokens per session (1,531 once invoked), scanned A, original, MIT.

A tool for querying structured JSONL event logs from coding-agent sessions. JSONL is a text format with one JSON object per line.

In plain words
What is it for?
Use it to investigate failures, trace decisions, compare sessions, and summarize session performance or tool usage.
Why use it?
It helps explain agent decisions and find errors, slow tool calls, or usage patterns without inspecting logs one event at a time.

Skill for Claude Code

Written for Claude Code: installed under .claude/. Also seen: model in frontmatter; reads .claude/ paths; mentions subagents.

Part of the project-toolkit plugin — 95 skills, 26 commands, 33 agents, 4 hooks shipped together

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/rjmurillo/ai-agents/observability
Any agent
npx skills add rjmurillo/ai-agents --skill observability
Clone the repo
git clone --depth 1 https://github.com/rjmurillo/ai-agents

Made for: Claude Code.

Or install project-toolkit, the plugin that ships this one along with the rest of its 95 skills, 26 commands, 33 agents, 4 hooks.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for observability

README.md
[![agentmods](https://agentmods.dev/badge/skills/rjmurillo/ai-agents/observability.svg)](https://agentmods.dev/skills/rjmurillo/ai-agents/observability)
Your own site
<a href="https://agentmods.dev/skills/rjmurillo/ai-agents/observability"><img src="https://agentmods.dev/badge/skills/rjmurillo/ai-agents/observability.svg" alt="Measured on agentmods" height="20"></a>
Per session 42 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,531 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00042 $0.01531
Opus 5 $0.00021 $0.00766
Sonnet 5 $0.00008 $0.00306
Haiku 4.5 $0.00004 $0.00153

Measured 2d ago against content hash d07aa90e79ff, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-06, from the pricing page.

Security

Grade A, and why

observability scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

The scan reads SKILL.md. This mod also ships 2 executable files (scripts/query_logs.py, tests/test_query_logs.py), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.claude/skills/observability/SKILL.md · 155 lines

How it starts

The opening of the file, as written. The whole thing — 155 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Agent Observability Skill

Query structured JSONL event logs to understand agent behavior, debug failures, and analyze performance.

Triggers

Trigger Phrase Operation
query agent logs Run query_logs.py with filters
find slow tool calls Run with --slow threshold
show agent errors Run with --errors-only
summarize session performance Run with --output summary-sessions
analyze tool usage Run with --output summary-tools

When to Use

Use this skill when:

  • Debugging why an agent chose a particular tool or approach
  • Finding slow tool calls that degrade agent performance
  • Analyzing error patterns across agent sessions
  • Comparing tool usage across sessions or agents
  • Tracing decisions from orchestrator through sub-agents

Use direct log file inspection instead when:

  • Checking a single known event in a small log
  • The log file has fewer than 10 events

Event Schema

Logs use JSONL format (one JSON object per line). See schema.json for the full JSON Schema.

Event Types

Type Purpose Key Fields
session_start Agent invocation begins agent, session_id
session_end Agent invocation completes agent, session_id
tool_call Tool invocation with timing tool.name, tool.duration_ms, tool.success
decision Reasoning captured alongside action decision.action, decision.reasoning
metric Numeric measurement metric.name, metric.value, metric.unit
error Error occurrence error.message, error.category, error.recoverable

Example Events

{"timestamp":"2026-03-30T10:00:00Z","event_type":"session_start","session_id":"sess-001","agent":"implementer","message":"Session started"}
{"timestamp":"2026-03-30T10:00:01Z","event_type":"tool_call","session_id":"sess-001","agent":"implementer","level":"INFO","tool":{"name":"Read","duration_ms":45,"success":true,"input_summary":"src/main.py"},"message":"Read source file"}
{"timestamp":"2026-03-30T10:00:02Z","event_type":"decision","session_id":"sess-001","agent":"implementer","level":"INFO","decision":{"action":"Edit existing function","reasoning":"Function exists, modifying is safer than rewriting","alternatives_considered":["Rewrite from scratch","Create wrapper"]}}
{"timestamp":"2026-03-30T10:00:10Z","event_type":"error","session_id":"sess-001","agent":"implementer","level":"ERROR","error":{"message":"Test failed: assertion error in test_parse","category":"test_failure","recoverable":true}}

Read the full file on GitHub · 155 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 155 lines · 42 tokens per session scan A d07aa90e79ff

Subscribe to this mod's changes

observability is a skill published in the GitHub repository rjmurillo/ai-agents (45 stars, last pushed today), licensed MIT. It adds 42 tokens to every session and 1,531 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.