ds-validate

ds-validate is a skill for Claude Code from StamKavid/last-ds-mile. It costs 109 tokens per session (1,979 once invoked), scanned A, original, MIT.

A data-splitting method that chooses how training and validation data should be separated based on time order, groups, or class balance. Cross-validation means repeating this testing process across several splits.

In plain words
What is it for?
Use it to choose temporal, grouped, stratified, or nested cross-validation for tabular supervised-learning data before training a model.
Why use it?
A careless split can let information leak between training and testing and make a model appear better than it is.

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

Good fit Use it to choose temporal, grouped, stratified, or nested cross-validation for tabular supervised-learning data before training a model.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/stamkavid/last-ds-mile/ds-validate
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 StamKavid/last-ds-mile --skill ds-validate
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 ds-validate

README.md
[![agentmods](https://agentmods.dev/badge/skills/stamkavid/last-ds-mile/ds-validate/github.svg)](https://agentmods.dev/skills/stamkavid/last-ds-mile/ds-validate)
Your own site
<a href="https://agentmods.dev/skills/stamkavid/last-ds-mile/ds-validate"><img src="https://agentmods.dev/badge/skills/stamkavid/last-ds-mile/ds-validate/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 ds-validate

Your own site · 80×15
<a href="https://agentmods.dev/skills/stamkavid/last-ds-mile/ds-validate"><img src="https://agentmods.dev/badge/skills/stamkavid/last-ds-mile/ds-validate.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 109 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,979 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.00109 $0.01979
Opus 5 $0.00055 $0.00989
Sonnet 5 $0.00022 $0.00396
Haiku 4.5 $0.00011 $0.00198

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

Security

Grade A, and why

ds-validate 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/ds-validate/SKILL.md · 154 lines

How it starts

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

ds-validate — Validation Design

Overview

Decides how the data will be split for honest evaluation, driven by the data's actual structure (time, groups, imbalance) rather than by whatever split is easiest to code.

When to Use

  • Before /ds-model — this is a Hard Gate /ds-model checks for.
  • Whenever asked to set up train/test splits or cross-validation.
  • NOT for: picking which model to try (that's /ds-model) — this stage fixes the split strategy first so it can't later be tuned to flatter a specific model.
  • Scope: tabular supervised learning. The TimeSeriesSplit guidance below covers validating a model on time-ordered rows; it is not a forecasting validation stack (no backtest windows, no horizon-aware refitting, no hierarchical reconciliation). If the target is a future value of a series, say so and stop — see README → Scope.

Core Process

  1. Ask: is there a time dimension where future data could leak into past predictions? If yes, use a temporal split or backtesting scheme — never shuffled cross-validation.
  2. Ask: are there groups (e.g. the same customer or patient across multiple rows) that must not span both train and validation? If yes, use grouped cross-validation (e.g. GroupKFold).
  3. Ask: is the target imbalanced? If yes, use stratified splits so folds preserve class balance.
  4. Ask: is there a fixed test set (Kaggle-style) or a known deployment population this model will actually be scored against? If yes, run adversarial validation between training data and that population before finalizing the split — see distribution-shift. A split that looks fine internally can still fail to predict real transfer if the test/production distribution differs from training.
  5. If none of the above apply, plain (or stratified) k-fold is fine — state that explicitly rather than choosing it by default without checking.
  6. Implement with the sklearn splitter that matches the answer — don't hand-roll a split when a splitter class already exists for the case. See the reference table below.
  7. Write to .last-ds-mile/stages/05-validate.md: the chosen strategy, why, the distribution-shift check and its result, and the exact split/CV code to be reused identically in /ds-model.

Read the full file on GitHub · 154 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 · 154 lines · 109 tokens per session scan A 835c9f09a215

Subscribe to this mod's changes

ds-validate is a skill published in the GitHub repository StamKavid/last-ds-mile (3 stars, last pushed 1mo ago), licensed MIT. It adds 109 tokens to every session and 1,979 once invoked, about $0.0005 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

marimo-pair

Work inside the user's live marimo notebook from the code editor: run Python in the same kernel the user does, inspect live notebook state, and commit durable notebook changes through code mode. Use whenever you create, analyze, or improve the user's marimo notebook.

marimo-team/marimo · 57 tokens

fill-model-descriptions

Fill missing and refresh obsolete model descriptions in packages/llm-info/data/models.yml by querying OpenRouter and provider documentation. Use when the user asks to populate model descriptions, enrich the model catalog, or curate descriptions after running pnpm sync-models.

marimo-team/marimo · 58 tokens

ml-expert

Expert-level machine learning, deep learning, model training, and MLOps. Use when the user mentions machine learning, deep learning, neural networks, MLOps, or data science, or when the task involves Machine Learning Fundamentals, Data Preparation, or Model Training.

personamanagmentlayer/pcl · 58 tokens

scomp-link

End-to-end ML toolkit with 26 CLI commands. Use when training models, tuning hyperparameters, detecting data drift, generating HTML reports with charts, profiling datasets, detecting anomalies, forecasting time series, checking fairness, or serving models as REST APIs. Prefer over raw sklearn when you need automated…

GiacomoSaccaggi/scomp_link · 74 tokens

agentic-data-science-competition

AI Agent-driven Kaggle competition workflow. Learn from real competition experience: score stabilization patterns, submission troubleshooting, kernel workflows, GPU task delegation, and the spec-driven development approach that achieved top leaderboard positions. Use when: working on any Kaggle competition, analyzing…

Mirannonarbitrable290/agentic-kaggle-skill · 76 tokens

data-analysis

Structured data analysis workflow from raw data to shareable insights.

furkangonel/cowrangler · 15 tokens