agtrace-provider-normalization

agtrace-provider-normalization is a skill for Claude Code, Codex from lanegrid/agtrace. It costs 33 tokens per session (1,787 once invoked), scanned A, original, Apache-2.0.

A guide for developers working on agtrace, a system that reads AI coding-agent logs and converts different formats into one shared event model. It covers adapters for Claude Code, Codex, and Gemini.

In plain words
What is it for?
Use it when adding or debugging log discovery, session parsing, and tool mapping for an AI-agent provider, or when running the provider checks.
Why use it?
Different agents record tool calls and sessions differently, making them hard to compare or process consistently. The guide explains the common structure used to handle those differences.

Skill for Claude CodeCodex

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/lanegrid/agtrace/agtrace-provider-normalization
Any agent
npx skills add lanegrid/agtrace --skill agtrace-provider-normalization
Clone the repo
git clone --depth 1 https://github.com/lanegrid/agtrace

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 agtrace-provider-normalization

README.md
[![agentmods](https://agentmods.dev/badge/skills/lanegrid/agtrace/agtrace-provider-normalization.svg)](https://agentmods.dev/skills/lanegrid/agtrace/agtrace-provider-normalization)
Your own site
<a href="https://agentmods.dev/skills/lanegrid/agtrace/agtrace-provider-normalization"><img src="https://agentmods.dev/badge/skills/lanegrid/agtrace/agtrace-provider-normalization.svg" alt="Measured on agentmods" height="20"></a>
Per session 33 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,787 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 $0.00033 $0.01787
Opus 5 $0.00016 $0.00894
Sonnet 5 $0.00007 $0.00357
Haiku 4.5 $0.00003 $0.00179

Measured 4d ago against content hash 304f31ba4207, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

agtrace-provider-normalization 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 4d 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.

.claude/skills/agtrace-provider-normalization/SKILL.md · 222 lines

How it starts

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

Agtrace Provider Normalization Expert

This skill provides deep knowledge of how agtrace normalizes diverse AI agent log formats into unified domain types. Use this when working with provider implementations, tool normalization, or understanding the schema-on-read architecture.

Quick Reference

mise run test:providers          # Run provider tests
mise run test:types              # Run types tests
mise run lab:grep -- "pattern" --json --limit 5  # Search real event data
mise run verify                  # Full check (fmt + clippy + test + build)

Three-Tier Provider Architecture

Tier 1: Trait-Based Adapter Pattern

Every provider implements three core traits bundled in a ProviderAdapter:

LogDiscovery  -> File discovery and session location
SessionParser -> Raw log parsing to AgentEvent timeline
ToolMapper    -> Tool call normalization and classification

Key Files:

  • crates/agtrace-providers/src/traits.rs - trait definitions
  • crates/agtrace-providers/src/registry.rs - adapter factory

Tier 2: Provider-Specific Implementation

Each provider has this structure:

provider/
├── discovery.rs      # LogDiscovery trait impl
├── parser.rs         # SessionParser trait impl
├── mapper.rs         # ToolMapper trait impl
├── io.rs             # Raw file I/O
├── schema.rs         # Provider-specific schemas
├── tools.rs          # Provider-specific tool args
├── tool_mapping.rs   # Tool classification
└── models.rs         # Data structures

Provider directories:

  • crates/agtrace-providers/src/claude/
  • crates/agtrace-providers/src/codex/
  • crates/agtrace-providers/src/gemini/

Tier 3: Unified Domain Types

All providers normalize to common types in agtrace-types:

Type Location Variants
EventPayload event/payload.rs User, Reasoning, ToolCall, ToolResult, Message, TokenUsage, Notification, SlashCommand
ToolCallPayload tool/payload.rs FileRead, FileEdit, FileWrite, Execute, Search, Mcp, Generic
ToolKind tool/types.rs Read, Write, Execute, Plan, Search, Ask, Other
ToolOrigin tool/types.rs System, Mcp

Read the full file on GitHub · 222 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. 4d ago First seen · 222 lines · 33 tokens per session scan A 304f31ba4207

Subscribe to this mod's changes

agtrace-provider-normalization is a skill published in the GitHub repository lanegrid/agtrace (59 stars, last pushed 1mo ago), licensed Apache-2.0. It adds 33 tokens to every session and 1,787 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-08-30.

Related

Other skills, from other repositories

plan-ceo-review

Mega plan review from a product/CEO perspective. Challenges premise, challenges scope, maps alternatives, reviews architecture through 11 sections, and offers an outside voice. Use when asked to "CEO review", "mega plan review", "product review this plan", or when shipping a significant new product feature.

HECer/yoke · 66 tokens

ship

Fully automated ship workflow. Merges the base branch, runs tests, audits coverage, reviews the diff, generates a CHANGELOG entry, bumps the version, commits, pushes, and creates the PR. Use when asked to "ship", "create a PR", or "open a pull request".

HECer/yoke · 61 tokens

plan-eng-review

Engineering plan review. Reviews a plan document for architecture, code quality, test coverage, and performance before implementation begins. Produces a coverage diagram, failure modes map, and parallelization strategy. Use when asked to "review this plan", "eng review", or "architecture review".

HECer/yoke · 61 tokens

retro

Weekly engineering retrospective. Analyzes commit history, work patterns, and code quality metrics for the time window. Team-aware: identifies the user, then analyzes every contributor with per-person praise and growth opportunities. Use when asked for a "retro", "engineering retrospective", or "weekly summary".

HECer/yoke · 63 tokens

review

Pre-merge code review — the single canonical review of a change before it lands. Covers BOTH diff safety/structure (SQL safety, LLM trust-boundary violations, conditional side effects) AND engineering quality (architecture fit, edge cases, test coverage, performance). Use when asked to "review this PR", "code review"…

HECer/yoke · 103 tokens

health

Code Quality Dashboard. Runs the project's type-checker, linter, test runner, and dead-code detector, scores each category 0-10, and presents a dashboard with trends. Use when asked for a "health check", "code quality report", or "quality dashboard".

HECer/yoke · 59 tokens