Index of every page on this site: llms.txt
All skills
confident-ai avatar

/eval-trace

@1ae0870
Run it yourself

Capture and inspect a real AI application execution, or repair missing trace context before evaluation. Covers first local evidence and optional Confident AI tracing with confident-trace; not general infrastructure monitoring.

Use this Skill: https://skilld.dev/gh/confident-ai/eval-skills/eval-trace

Nothing lands on disk. Nothing to clean up.

Fork this Skill

Edit a local copy. It keeps the author and licence.

referencestrace-schema.md

≈825 tokens on demand. Your agent reads this file only when SKILL.md points to it.

<!-- Synced from shared/trace-schema.md by scripts/sync_shared.py. Edit shared/trace-schema.md, not this copy. -->

Local trace schema

Local tracks store traces as JSON Lines under .eval/default/traces/. There are two layers:

  1. Raw spans (.eval/default/traces/spans-*.jsonl), written by the local exporter template in first-trace. One line per finished OpenTelemetry span, in the OTLP/JSON span shape plus its resource attributes. Keep these: they can be replayed to any OTLP endpoint later, including Confident AI.
  2. Review records (.eval/default/traces/traces.jsonl), one line per trace, produced by normalize_traces from the raw spans (or by a one-off converter when traces come from another tool). This is what the review app, the dataset builder, and the eval runner read.

Review record

{
  "trace_id": "5b8aa5a2d2c872e8321cf37308d69df2",
  "thread_id": "conversation-42",
  "started_at": "2026-09-30T12:00:00Z",
  "duration_ms": 1830,
  "input": "Can I return shoes after 45 days?",
  "output": "Returns are accepted within 30 days of delivery…",
  "tags": ["returns"],
  "metadata": { "environment": "staging", "user_id": "u_123" },
  "steps": [
    { "type": "llm", "name": "chat gpt-4.1-mini", "input": "…", "output": "…",
      "model": "gpt-4.1-mini", "input_tokens": 812, "output_tokens": 96 },
    { "type": "retriever", "name": "search_policies", "input": "return window",
      "output": ["Returns are accepted within 30 days…"] },
    { "type": "tool", "name": "lookup_order", "input": { "order_id": "A17" },
      "output": { "status": "delivered" } }
  ],
  "error": null
}
Field Required Meaning
trace_id yes Stable id. Use the OTel trace id when there is one.
input / output yes What the user sent and what the app returned, as text or JSON.
thread_id no Groups turns of one conversation.
steps no Ordered spans below the entry point: llm, retriever, tool, agent, or custom.
tags no Short labels; tags[0] is the primary grouping key.
metadata no Anything else worth showing a reviewer.
error no Exception type if the request failed.

Mapping from OpenTelemetry

confident-trace records GenAI semantic conventions plus confident.trace.* and confident.span.* attributes. The normalizer uses:

  • the root span of each trace id as the entry point;
  • confident.trace.input / confident.trace.output (or the root span's confident.span.input / confident.span.output) for input / output;
  • confident.trace.thread_id or gen_ai.conversation.id for thread_id;
  • confident.span.type for step type, falling back to llm when gen_ai.operation.name is chat or text_completion;
  • gen_ai.request.model, gen_ai.usage.input_tokens, gen_ai.usage.output_tokens for model and usage.

Attribute names can evolve with the SDK. If a field comes out empty, print one raw span and adjust the mapping rather than guessing.

Converting from other tools

Traces already in Langfuse, LangSmith, Phoenix, Braintrust, or application logs: export them to JSON, then write a short converter to review records. Keep the original ids in metadata.source_id so annotations can be traced back.

Source: SKILL.md on GitHub

skilld matched fixed text patterns in SKILL.md and file names. Patterns miss obfuscated code.

skilld run checks every file with the same patterns. It asks for approval before it loads a Skill with a behavior marked Needs approval.

No alerts1mo3 checks · Risk SAFE
  • Gen Agent Trust Hub1mo

    The eval-trace skill provides a professional framework for capturing and inspecting AI application traces, supporting both local and managed workflows. It includes robust utilities for workspace setup, trace normalization, and historical data replaying. The skill demonstrates strong security awareness by emphasizing local-first processing, providing guidance on data redaction, and instructing agents to handle credentials securely via environment variables. Network operations and data transfers are restricted to the vendor's own documented endpoints and are integral to the skill's purpose.

  • Socket1mo

    No alerts

  • Snyk1mo

    Risk: LOW · No issues

Signed by skilld at 1ae0870. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub last month.

Steadyupdated 2 months ago
metadata
{
  "author": "Confident AI",
  "version": "1.1.0"
}

README badge

README badge for confident-ai/eval-skills/eval-trace