Agent Observability Spec logo

Agent Observability Spec

CommunityPopular
mohitagw15856
agent-observability-spec

Specify the tracing, metrics, and alerting for an AI agent or LLM feature in production. Use when asked what to log for an LLM app, design agent tracing or spans, define quality and cost monitors, or answer 'how do we know if the agent is misbehaving?'. Produces an observability spec with a trace schema, metric definitions with owners and alert thresholds, sampling and retention policy, and a privacy note for logged content.

Overview

Publishermohitagw15856
Repositorypm-claude-skills
Skill nameagent-observability-spec
Stars
1.4K
Forks
240
Bundled files
Instructions only
LicenseMIT
Links
  • Markdown instructions

    A SKILL.md file the model loads on demand, so it only costs tokens when a request actually matches.

  • Works with any LLM

    AI skills are plain Markdown, not provider-specific code, so this works with GPT, Claude, Gemini, Grok, or a local model.

  • Self-contained

    Everything the model needs lives in the instructions — no extra files to sync.

  • Open source

    Published by mohitagw15856 on GitHub. Read the source before you install it.

Installation

Install the Agent Observability Spec AI skill in TypingMind to use it with any LLM, or drop it into another agent that reads SKILL.md.

1

Install in TypingMind

TypingMind installs a skill straight from its GitHub folder — it reads SKILL.md, bundles the resource files, and stores the result locally.

  1. Open the app and go to Plugins → Skills.
  2. Choose "Install from GitHub".
  3. Paste the skill folder URL below and confirm.
  4. Enable the skill in any chat where you want it available.
Plugins → Skills → Add skill → From GitHub URL, then paste the folder URL and press Continue.
2

Install in another agent

Any agent that reads the Agent Skills format can use this skill — copy the folder into that agent's skills directory.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/mohitagw15856/pm-claude-skills.git /tmp/pm-claude-skills
mkdir -p .claude/skills
cp -r /tmp/pm-claude-skills/exports/openclaw/agent-observability-spec .claude/skills/agent-observability-spec
Restart Claude Code after copying so it picks up the new skill.

Use it in TypingMind

Enable Agent Observability Spec in any TypingMind chat and the model takes it from there. Its name and description sit in the system prompt, and the moment a request matches, the model loads the full instructions itself — you never invoke it by hand, and it costs no tokens until it is actually used.

The model loads Agent Observability Spec on its own as soon as a request matches it.

Works with any AI model

AI skills are plain Markdown instructions rather than provider-specific code, so Agent Observability Spec is not tied to the model it was written for. Install it once in TypingMind and use it with GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama, or a local model you run yourself — all on your own API keys.

  • Loaded only when it is needed

    The system prompt carries just the name and description. The instructions are fetched on the first matching request, so an idle skill costs nothing.

  • Switch models mid-chat

    Because the skill is instructions rather than code, changing model does not break it — the next model reads the same SKILL.md.

Skill instructions

This is the SKILL.md content the model loads. Read it before installing — a skill is instructions your model will follow.

Agent Observability Spec Skill

You can't fix what you didn't record. For LLM systems the unit of observability is the trace — everything the model saw and did — because behaviour, not uptime, is what fails. This skill specifies what to capture, what to compute from it, and when to page someone.

What This Skill Produces

  • A trace schema: per-request spans and the fields each must carry
  • Metric definitions across health, quality, cost, and behaviour — each with a threshold and owner
  • A sampling and retention policy that keeps cost sane and debugging possible
  • A privacy note: what logged content contains, who can see it, and how long it lives

Required Inputs

Ask for (if not already provided):

  • The system's shape — single LLM call, RAG pipeline, or multi-step tool-using agent
  • Traffic volume and cost sensitivity — full tracing at 10M req/day is a budget decision
  • What "misbehaving" means here — the two or three failure modes that matter most (wrong facts? wrong actions? cost? refusals?)
  • Existing observability stack (Datadog, Langfuse, OTel, homegrown) — spec into it, not around it

Trace Schema

Every request produces one trace; every model call, retrieval, guardrail check, and tool execution is a span. Minimum fields:

SpanMust capture
Request rootrequest id, user/session (pseudonymous), feature + prompt version, model id, total tokens, total cost, latency, terminal status
Model callfull input context (or content-addressed ref), output, finish reason, tokens in/out, cached-token share, temperature
Retrievalquery, top-k ids + scores, which chunks entered the context
Tool calltool name, arguments, result (or ref), duration, error
Guardrailcheck name, verdict, and what it did (blocked / rewrote / flagged)
User signaledits, regenerates, thumbs, abandonment — joined to the trace id

The test of the schema: an engineer can replay any incident from its trace alone (see agent-incident-postmortem).

Metrics and Alerts

Define four families; every metric gets a threshold, a window, and an owner.

  • Health — error rate, p50/p95 latency, timeout rate, provider 429/5xx rate. Page on these.
  • Cost — cost per request (p50, p99), tokens per request, cache hit rate, daily spend vs. budget (pair with llm-cost-latency-budget). Alert on p99 and daily-budget burn — cost incidents are caused by the tail, not the mean.
  • Quality proxies — format/schema violation rate, refusal rate, groundedness-check failure rate, judge score on a sampled slice, regenerate/edit rate. Alert on drift vs. a rolling baseline: absolute thresholds go stale, deltas don't.
  • Behaviour (agents) — steps per task, tool-error rate, loop detection (same tool + same args N times), unauthorised-action attempts caught by guardrails. Page on the last one.

Sampling & Retention

  • Metadata for 100% of requests (ids, versions, tokens, cost, status) — this is cheap and non-negotiable.
  • Full content traces: 100% for errors, guardrail hits, and negative user signals; [1-10]% random sample for the rest, adjusted to volume.
  • Retention: full content [30-90] days, metadata [12+] months for trend baselines; incident traces pinned indefinitely.
  • Privacy: logged context contains user data — state where it lives, who has access, how deletion requests reach it, and that traces are scrubbed or access-gated before wide sharing.

Output Format

Observability Spec: [feature/agent]

System shape: [calls/pipeline/agent] · Volume: [req/day] · Stack: [tooling]

Trace schema: [the span table, tailored]

Metrics:

MetricFamilyThreshold / baselineWindowAlert → owner

Sampling & retention: [the policy]

Privacy: [content classification, access, deletion path]

Dashboards: [the 2-3 views: live health, quality drift, cost]

First incident drill: pick yesterday's worst trace and confirm it can be replayed end-to-end from the stored data.

Quality Checks

  • Any incident is replayable from its trace alone — the schema was tested against that bar
  • Every metric has a number, a window, and a named owner — no orphan dashboards
  • Quality alerts are drift-based against a rolling baseline, not absolute guesses
  • Sampling keeps 100% of error/guardrail/negative-signal traces
  • The privacy note exists and names retention and access — logged prompts are user data

Anti-Patterns

  • Do not log only inputs and outputs — without retrieval and tool spans, root cause analysis is guesswork
  • Do not alert on mean cost or mean latency — the tail is where both incidents live
  • Do not run judge-based quality scoring on 100% of traffic — sample; spend the budget on better baselines
  • Do not treat observability as launch-week scaffolding — drift metrics only work with months of baseline
  • Do not ship an agent that can take actions without logging the guardrail verdicts alongside the actions

Frequently asked questions

What does the Agent Observability Spec AI skill do?

Specify the tracing, metrics, and alerting for an AI agent or LLM feature in production. Use when asked what to log for an LLM app, design agent tracing or spans, define quality and cost monitors, or answer 'how do we know if the agent is misbehaving?'. Produces an observability spec with a trace schema, metric definitions with owners and alert thresholds, sampling and retention policy, and a privacy note for logged content.

Why use Agent Observability Spec on TypingMind?

Because you install it once and use it with any model. Agent Observability Spec is plain Markdown rather than provider-specific code, so the same skill runs on GPT-5, Claude, Gemini, Grok, or a local model — and you can switch model mid-chat without it breaking. TypingMind runs on your own API keys, so you pay providers directly instead of a per-seat subscription, and your skills and chats stay in your own storage.

How do I install Agent Observability Spec in TypingMind?

Open Plugins → Skills → Install from GitHub in TypingMind and paste https://github.com/mohitagw15856/pm-claude-skills/tree/main/exports/openclaw/agent-observability-spec. TypingMind reads its SKILL.md and installs it as a skill you can enable per chat.

Which AI models can use Agent Observability Spec?

Any model you connect in TypingMind. AI skills are plain Markdown instructions rather than provider-specific code, so GPT, Claude, Gemini, Grok, and local models can all load this skill when a request matches it.

How many AI models can I use with Agent Observability Spec?

As many as you like. As long as a model supports skills, you can use Agent Observability Spec with it — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama and more — all on TypingMind with your own API keys.

Is the Agent Observability Spec AI skill free?

Yes. It is published on GitHub by mohitagw15856 under the MIT license. You only pay your own AI provider for the tokens you use.

What are AI skills?

An AI skill is a reusable instruction bundle that teaches an AI model how to do one specific task. It follows the open Agent Skills format: a SKILL.md file with a name and description, plus any scripts, templates or reference files the model may need. The model reads the instructions only when your request matches the skill, so an installed skill costs nothing until it is used.

How are AI skills different from plugins or MCP servers?

A plugin or MCP server gives a model new tools to call — code that runs somewhere and returns a result. An AI skill gives the model knowledge and process instead: how to approach a task, which steps to follow, what good output looks like. Skills are plain Markdown, so they need no server, no API key and no runtime, and they work with any model.

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇