agentleFS
mlflowmlflow/skills/mlflow-trace-analysis/SKILL.md

mlflow-trace-analysis

Skill89 starsChanged 35 days agoApache-2.0View on GitHub

Analyze MLflow traces, agent failures, and multi-turn chat sessions. Explain errors, unexpected output, quality issues, latency, or cross-turn propagation without editing application code.

The file

We split this skill into the rules it gives an agent

3 rules. About 0 are common, 3 are distinctive, and 0 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈3

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 0

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Use the trace ID or session ID, configured backend, reported behavior and expected outcome.

    line 8
  2. Distinctive:

    Before searching for an unknown trace ID, read trace retrieval for filters, time bounds and pagination.

    line 12
  3. Distinctive:

    Prefer existing evidence. Only when no usable trace exists, reproduce once through the normal instrumented entry point when safe.

    line 14

≈ “Common” is an estimate: at least 1 in 5 of the 408,460 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Analyze MLflow traces

Use the trace ID or session ID, configured backend, reported behavior and expected outcome. Reuse traces already fetched. For a multi-turn conversation, read session analysis.

Prerequisites

Before searching for an unknown trace ID, read trace retrieval for filters, time bounds and pagination. Reuse an already fetched trace. If that skill is not installed, use the search guide and installed CLI help.

Prefer existing evidence. Only when no usable trace exists, reproduce once through the normal instrumented entry point when safe; otherwise report the missing evidence. Record HUMAN feedback only when authorized and attached to an identified trace.

Step 1: Fetch the trace

Fetch full JSON once to a file; large piped CLI output can be truncated by the execution tool. get needs no --output flag. Avoid --extract-fields for nested span diagnosis.

mlflow traces get --trace-id <TRACE_ID> > /tmp/trace.json

Step 2: Inspect the span tree

Summarize state, assessments and parent links:

jq '{state: .info.state,
     spans: [.data.spans[] | {span_id, parent_span_id, name, status}],
     error_spans: [.data.spans[] | select(.status.code == "STATUS_CODE_ERROR") | .name],
     assessments: .info.assessments}' /tmp/trace.json

Step 3: Read feedback

Read feedback source, value, top-level rationale, validity and scope before forming a hypothesis. HUMAN feedback describes the reported experience; corroborate it with spans. LLM_JUDGE/CODE feedback may be wrong or misconfigured. feedback.error means scoring failed, not that the application failed; exclude errored/overridden judgments from quality conclusions. Genuine zero/false values remain valid. Expectations are desired-output labels, not scores.

Step 4: Follow inputs and outputs

Follow actual inputs and outputs from root to the first divergence, then downstream effects. Raw MLflow span I/O is usually serialized JSON in attributes["mlflow.spanInputs"] / attributes["mlflow.spanOutputs"]; parse it before interpreting it. If the root is an empty wrapper, inspect descendants. For other OTel sources or versions, inspect raw keys instead of assuming this schema.

Step 5: Check errors and performance

Check exception events and status messages. OK means execution success, not correct output; STATUS_CODE_UNSET is not itself an error. For performance, distinguish enclosing wrappers, overlapping child work and uninstrumented gaps; repeated names alone do not prove retries. Inspect recorded token usage rather than inventing cost or assuming a token spike proves injection.

Step 6: Check the source

Correlate the decisive span's observed data with relevant source/configuration when available. Function names are clues; autologged names follow framework conventions. Separate observed facts, plausible causes and missing evidence. Do not edit code, create scorers or run an evaluation for diagnosis alone.

See the refund-policy evidence table for a retrieval miss, unsupported answer and later propagation.

Verification

Report observed versus expected behavior, trace and decisive span IDs, the evidence chain, confidence and the smallest likely remedy. Confirm claims against actual span I/O and feedback semantics, not previews alone. If evidence is missing, say what would resolve the uncertainty; do not promote a hypothesis to a confirmed root cause.

References

  • Fields, units, CLI versus SDK representation, OTel attributes or assessment interpretation: trace structure.
  • Bounded batches, recurring failures or component bottlenecks: cross-trace analysis.
  • Multi-turn propagation: session analysis.
  • A user-requested implementation: pass diagnosis and trace ID to mlflow-agent-improvement when installed; investigation itself stops at evidence and recommendations.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.