tracelet-instrument

tracelet-instrument is a skill for Claude Code, Codex from jnMetaCode/skillet. It costs 51 tokens per session (707 once invoked), scanned A, original, MIT.

A local tracing setup for AI agents and language-model apps. It records model calls, tool calls, prompts, token counts, and response times in Tracelet, a local viewer.

In plain words
What is it for?
Use it to add OpenTelemetry tracing to an agent, inspect individual runs, and debug slow or unexpected behavior.
Why use it?
It shows what an agent actually did while keeping trace data on your computer instead of sending it to a cloud service.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it to add OpenTelemetry tracing to an agent, inspect individual runs, and debug slow or unexpected behavior.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/jnmetacode/skillet/tracelet-instrument
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.

Any agent
npx skills add jnMetaCode/skillet --skill tracelet-instrument
Clone the repo
git clone --depth 1 https://github.com/jnMetaCode/skillet

Made for: Claude Code, Codex.

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 tracelet-instrument

README.md
[![agentmods](https://agentmods.dev/badge/skills/jnmetacode/skillet/tracelet-instrument/github.svg)](https://agentmods.dev/skills/jnmetacode/skillet/tracelet-instrument)
Your own site
<a href="https://agentmods.dev/skills/jnmetacode/skillet/tracelet-instrument"><img src="https://agentmods.dev/badge/skills/jnmetacode/skillet/tracelet-instrument/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for tracelet-instrument

Your own site · 80×15
<a href="https://agentmods.dev/skills/jnmetacode/skillet/tracelet-instrument"><img src="https://agentmods.dev/badge/skills/jnmetacode/skillet/tracelet-instrument.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 51 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 707 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
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.00051 $0.00707
Opus 5 $0.00026 $0.00353
Sonnet 5 $0.00010 $0.00141
Haiku 4.5 $0.00005 $0.00071

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

Security

Grade A, and why

tracelet-instrument 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 9d ago.

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.

skills/tracelet-instrument/SKILL.md · 68 lines

How it starts

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

tracelet-instrument

Goal: make an agent's execution visible — every LLM call, tool call, prompt, token count and latency — without sending anything to a cloud service. tracelet is a local OTLP collector + UI; any OpenTelemetry exporter pointed at http://127.0.0.1:4318 shows up live.

Procedure

  1. Start the collector (keep it running in a terminal):

    npx @jnmetacode/tracelet        # ingests OTLP on :4318, UI on :4321
    
  2. Point the app's exporter at it. For most OpenTelemetry SDKs the zero-code route is environment variables:

    export OTEL_EXPORTER_OTLP_ENDPOINT=http://127.0.0.1:4318
    export OTEL_SERVICE_NAME=my-agent
    
  3. Framework-specific wiring (pick the one that matches the codebase):

    Vercel AI SDK — pass telemetry on each call and register a Node tracer:

    const result = await generateText({
      model, prompt,
      experimental_telemetry: { isEnabled: true },
    });
    

    OpenTelemetry JS (manual spans):

    import { NodeSDK } from '@opentelemetry/sdk-node';
    import { OTLPTraceExporter } from '@opentelemetry/exporter-trace-otlp-http';
    new NodeSDK({ traceExporter: new OTLPTraceExporter({ url: 'http://127.0.0.1:4318/v1/traces' }) }).start();
    

    Python: pip install opentelemetry-sdk opentelemetry-exporter-otlp-proto-http, then the same OTEL_EXPORTER_OTLP_ENDPOINT env var works.

  4. Name spans so the waterfall reads like the agent's plan: one root span per run (agent.run), one child per tool call (tool.<name>) and per model call. Attach gen_ai.request.model, input.value, output.value attributes — tracelet recognizes the GenAI/OpenInference conventions and renders prompts, tokens and tool I/O.

  5. Verify: trigger one agent run, open http://127.0.0.1:4321, and confirm the trace shows the expected span tree with prompts/tokens. If nothing arrives, the exporter is usually pointed at the wrong port (4318) or batching hasn't flushed — force a flush/shutdown on process exit.

Read the full file on GitHub · 68 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. 9d ago First seen · 68 lines · 51 tokens per session scan A 3cb30484fc3f

Subscribe to this mod's changes

tracelet-instrument is a skill published in the GitHub repository jnMetaCode/skillet (1 stars, last pushed 2mo ago), licensed MIT. It adds 51 tokens to every session and 707 once invoked, about $0.0003 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-08-31.