error-analysis

error-analysis is a skill for Claude Code from StamKavid/last-ds-mile. It costs 66 tokens per session (828 once invoked), scanned A, original, MIT.

A method for examining a model’s individual mistakes and performance across groups, time periods, or input ranges instead of relying only on one average score.

In plain words
What is it for?
Use it to compare error rates across meaningful segments, find the worst predictions, and identify patterns that explain where the model fails.
Why use it?
An average score can hide serious failures affecting particular cases. It helps reveal who or what the model performs poorly on before you trust it broadly.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin.

Part of the last-ds-mile plugin — 29 skills, 17 commands, 3 agents, 4 hooks shipped together

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/stamkavid/last-ds-mile/error-analysis
Any agent
npx skills add StamKavid/last-ds-mile --skill error-analysis
Clone the repo
git clone --depth 1 https://github.com/StamKavid/last-ds-mile

Made for: Claude Code.

Or install last-ds-mile, the plugin that ships this one along with the rest of its 29 skills, 17 commands, 3 agents, 4 hooks.

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 error-analysis

README.md
[![agentmods](https://agentmods.dev/badge/skills/stamkavid/last-ds-mile/error-analysis.svg)](https://agentmods.dev/skills/stamkavid/last-ds-mile/error-analysis)
Your own site
<a href="https://agentmods.dev/skills/stamkavid/last-ds-mile/error-analysis"><img src="https://agentmods.dev/badge/skills/stamkavid/last-ds-mile/error-analysis.svg" alt="Measured on agentmods" height="20"></a>
Per session 66 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 828 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.1 $0.00066 $0.00828
Opus 5 $0.00033 $0.00414
Sonnet 5 $0.00013 $0.00166
Haiku 4.5 $0.00007 $0.00083

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

Security

Grade A, and why

error-analysis 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 5d 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/error-analysis/SKILL.md · 69 lines

How it starts

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

error-analysis

Overview

An aggregate metric answers "how good on average" — error analysis answers "good for whom, and wrong how." This is the systematic version of what /ds-evaluate does inline, useful any time a deeper failure-mode investigation is needed.

When to Use

  • After a model's aggregate metric is known and acceptable, before trusting it broadly.
  • Debugging a specific complaint ("the model is bad for X") by finding the actual pattern, not guessing.
  • NOT for: picking the metric itself (see metric-selection) — this skill assumes the metric is already chosen and asks where performance diverges from that metric's average.

Core Process

  1. Compute out-of-fold (not in-sample) predictions for every row — error analysis on training-set-fit predictions is optimistic and misleading.
  2. Slice error by every dimension the decision cares about: a segment, a time period, a feature range, a subgroup — not just one arbitrary cut.
  3. Pull the worst N individual mispredictions and look for a shared trait (not just eyeball them one at a time with no hypothesis).
  4. State the finding as a concrete, actionable pattern ("underperforms on X because Y"), not a vague "some errors exist."

Techniques/Patterns

Technique What it reveals
Slice metric by categorical subgroup (segment, region, neighborhood, product line) Whether one subgroup is silently much worse than the aggregate suggests
Slice metric by a continuous feature's quantile bins (e.g. price quintile, age decile) Whether performance degrades at one end of a range — often the extremes
Residual vs. predicted-value plot (or a groupby summary of the same) Systematic over/under-prediction bias at specific value ranges, not just noise
Worst-N mispredictions table, sorted by absolute error Concrete cases to trace back to a shared root cause (a data issue, an undermodeled feature, an edge case)
Residual vs. time (for any temporal data) Whether the model is drifting/degrading as time moves away from the training window

Read the full file on GitHub · 69 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. 5d ago First seen · 69 lines · 66 tokens per session scan A 3c7beeeac465

Subscribe to this mod's changes

error-analysis is a skill published in the GitHub repository StamKavid/last-ds-mile (3 stars, last pushed 28d ago), licensed MIT. It adds 66 tokens to every session and 828 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.

Related

Other skills, from other repositories

understanding-streamlit-architecture

Explains Streamlit's internal architecture including backend runtime, frontend rendering, and WebSocket communication. Use when debugging cross-layer issues, understanding how features work end-to-end, planning architectural changes, or onboarding to the codebase. Covers ForwardMsg/BackMsg protocol, script rerun…

streamlit/streamlit · 75 tokens

fixing-streamlit-ci

Analyze and fix failed GitHub Actions CI jobs for the current branch/PR. Use when CI checks fail, PR checks show failures, or you need to diagnose lint/type/test errors and verify fixes locally.

streamlit/streamlit · 47 tokens

updating-internal-docs

Review internal documentation (.md files) against the current codebase state and propose updates for outdated or incorrect information.

streamlit/streamlit · 29 tokens

assessing-external-test-risk

Assesses whether branch or PR changes are high-risk for externally hosted or embedded Streamlit usage and recommends whether external e2e coverage with @pytest.mark.externaltest is needed. Use during code review, PR triage, or test planning when changes touch routing, auth, websocket/session behavior, embedding…

streamlit/streamlit · 88 tokens

sharing-pr-agent-artifacts

Uploads agent-generated artifacts (specs, plans, learnings) to the streamlit.wiki for sharing via PR comments. Use when you have agent artifacts to share with reviewers.

streamlit/streamlit · 42 tokens

developing-with-streamlit

Use for ALL Streamlit tasks: creating, editing, debugging, beautifying, styling, theming, optimizing, or deploying Streamlit apps. Also custom components, st.components.v2, HTML/JS/CSS work. Discovers and loads version-matched reference docs from the user's installed Streamlit (>=1.57). Triggers: streamlit, st.…

streamlit/streamlit · 128 tokens