auditing-sft-dataset

Audit SFT datasets for schema validity, template conformance, deduplication, leakage, and PII risk.

2|Updated May 23, 2026
One-click install
npx skills add https://github.com/rocklambros/rcs --skill auditing-sft-dataset
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: auditing-sft-dataset
Source: https://github.com/rocklambros/rcs/tree/main/skills/ml-datasci/auditing-sft-dataset
Command: npx skills add https://github.com/rocklambros/rcs --skill auditing-sft-dataset

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

It audits supervised fine-tuning datasets before training so you can catch schema errors, template mismatches, duplicates, leakage into eval, and sensitive-content exposure before a bad dataset reaches production.

Core Features & Use Cases

  • Schema and format validation: Checks ShareGPT, Alpaca, OpenAI-style messages, or custom schemas for parse failures and malformed rows.
  • Chat-template conformance: Verifies every row renders correctly under the target template and flags cross-template token leakage.
  • Dataset integrity checks: Finds exact duplicates, near-duplicates, and train-vs-eval contamination using overlap-based leakage detection.
  • PII and policy enforcement: Applies a user-supplied or minimum default PII policy and quarantines or flags sensitive rows with an audit trail.
  • Human review support: Produces a label-quality sample for manual inspection instead of guessing at answer correctness.
  • Use case: A team scraping support chats for Llama fine-tuning can audit the corpus, quarantine bad rows, and re-run the audit after remediation.

Quick Start

Audit the attached SFT training file against the held-out eval split, the target chat template, and the supplied PII policy, then return a findings report with quarantine files and remediation steps.

Frequently Asked Questions about auditing-sft-dataset

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I audit an SFT dataset for fine-tuning?

To audit an SFT dataset for fine-tuning, validate schema formats like ShareGPT or Alpaca, check chat-template conformance, detect duplicates, and quarantine PII using a supplied policy.

What is train-vs-eval contamination in instruction-tuning corpora?

Train-vs-eval contamination in instruction-tuning corpora is data leakage where training rows overlap with held-out eval splits. Overlap-based leakage detection identifies this to prevent skewed model evaluation.

How do I remove duplicates and detect PII in scraped chats?

Remove duplicates and detect PII in scraped chats by applying dataset integrity checks for exact and near-duplicates, then enforcing a PII policy to quarantine sensitive rows with an audit trail.

Does this dataset audit work with custom schemas and OpenAI-style messages?

Yes, dataset audit works with custom schemas and OpenAI-style messages. Schema and format validation checks these structures alongside ShareGPT and Alpaca formats for parse failures and malformed rows.

Why does chat-template cross-template token leakage happen?

Chat-template cross-template token leakage happens when rows render incorrectly under the target template. Template conformance verification flags these mismatches before a bad dataset reaches production.

What is needed to check label quality before model training?

To check label quality before model training, you need a held-out eval split, a target chat template, and an operator-supplied PII policy to produce a label-quality sample for manual inspection.