dataset-doctor SKILL.md skillB

dataset-doctor from rinne414/lora-training-skill is an agent skill: a SKILL.md folder an AI agent loads when a task calls for it.

Install it, pinned
mdr add rinne414/lora-training-skill/dataset-doctor@git:20261026.def0acc

Pins git:20261026.def0acc in mdr.lock. Pin the fingerprint instead.

Audit grade
B, 16 of 17 checks passed
Kind
SKILL.md skill
Repository
rinne414/lora-training-skill
Path
dataset-doctor/SKILL.md
Versions recorded
5
Latest version
git:20261026.def0acc, committed Oct 26, 2026
First version recorded
Jul 27, 2026
Size
11,249 bytes
Repository stars
13
License
MIT

Audit and repair a kohya-style LoRA dataset before training. Use when the user asks to check, validate, inspect, fix, clean, 体检, or 修 a dataset, captions, or tags. Inspect image count, repeats and step budget, resolution and aspect buckets, duplicates, corrupt or non-RGB images, missing or empty captions, trigger consistency, and tag-frequency hygiene. Return a structural PASS, WARN, or FAIL report and apply only confirmed fix_dataset.py actions, dry-run first with displaced originals…

Collected from public GitHub. Every version is saved exactly as it was and never changes. Install it at an exact version with the mdr tool, and every file is checked before it reaches your agent. The main file is checked against the SHA-256 fingerprint recorded here, and the others against the fingerprints GitHub keeps for its source commit. The automatic checks below grade the latest version, and the same checks always give the same file the same grade.

What the file says

# dataset-doctor — LoRA 数据集 / caption 体检 + 修复

在训练前对 LoRA 数据集与标注做**结构/卫生预检**,给出 **PASS / WARN / FAIL** 结论和按优先级排序的修复建议;PASS 不代表图像与 caption 的语义已经人工验证。确认后用 `fix_dataset.py` 一行命令执行修复。**体检只读**;修复**默认 dry-run**,加 `--apply` 才动文件,且**从不删除**——被移除的文件全部进数据集内的 `_quarantine/`(体检与训练都会忽略它),随时可还原。任何 `--apply` 都必须先得到用户确认。

底层针对 `lora-scripts-next`(SD-Trainer)的数据集约定:`train_data_dir` 下放 `<repeats>_<concept>` 子文件夹(如 `7_zkz` = 重复 7 次、概念 `zkz`),caption 是与图同名的 sidecar `.txt`——**单行**、逗号分隔、可在末尾用「`. `」接自然语言(已验证格式见 `../references/caption-guide.md`)。Anima `.json` caption 仅是 UI 宣称的可选项,训练端 v2.7.0 未发现读取实现,不要依赖。

## 默认职责

接收一个数据集路径,运行体检脚本,解读 JSON/报告,向用户说明问题与修复顺序;用户确认后用 `fix_dataset.py` 执行修复并重检。trainer 本身**只检查目录是否存在、有没有图**,不检查质量——质量这块由本 skill 负责,二者互补。

## 适用范围(不限 SD-Trainer)

体检与修复是**训练器无关**的:检查对象是标准 kohya 数据集约定(`<repeats>_<concept>` 文件夹 + 同名 sidecar caption),sd-scripts / kohya_ss / OneTrainer 等训练器通用;脚本全程离线、不碰 GPU、不需要 trainer 在线。用户打算在**任何**训练器上练 LoRA,体检都照做。只有两处例外:

- **WD14 打标**:Anima 使用 `../lora-pipeline/scripts/tag_dataset.py`,与完整 pipeline 保持一致;SD1.5/SDXL/Flux 可走 SD-Trainer 的 `POST /api/interrogate`。
…

Read the whole file at its exact version.

How to install

The exact contents, by fingerprint
mdr add rinne414/lora-training-skill/dataset-doctor@sha256:f42ab1c3b1725ff4

The line at the top of this page pins the label git:20261026.def0acc, which is what most people want. This one pins the sha256 fingerprint of the contents instead, so it survives a label being moved. Either way the exact version is written to mdr.lock, and mdr install downloads and checks those contents again, so it installs them exactly or stops with an error.

Badge

mdr badge

[![mdr](https://markdownregistry.com/badge/art_fo6ptnvbkx5gsqlc.svg)](https://markdownregistry.com/a/art_fo6ptnvbkx5gsqlc)

1 badge image fetches in 30 days. What the badge shows.

Versions

The registry has recorded 5 versions of this file, between Jul 27, 2026 and Oct 26, 2026, about one every 23 days. Its first recorded version is graded A and its latest B.

versioncommittedcommitsizeaudit
git:20261026.def0acc latest2026-10-26 def0acc 11,249 BB view · diff
git:20261026.c0dca6d2026-10-26 c0dca6d 10,837 BA view · diff
git:20260727.7eaa03a2026-07-27 7eaa03a 9,513 BA view · diff
git:20260727.8262efb2026-07-27 8262efb 9,655 BA view · diff
git:20260727.807afb62026-07-27 807afb6 9,650 BA view

Audit of the latest version

B  16 of 17 checks passed. Fixed automatic checks with no AI involved, so the same checks give the same answer every run.
  • fail: No link to a raw IP address (matched: http://127.0.0.1:28000)
  • pass: Frontmatter block present
  • pass: Frontmatter declares a name
  • pass: Frontmatter declares a description
  • pass: Size between 200 bytes and 200 KB (11249 bytes)
  • pass: No zero-width or bidi control characters
  • pass: No instruction hidden inside an HTML comment
  • pass: No link to an exfiltration or paste host
  • pass: No credential-shaped string
  • pass: No instruction to send local credentials anywhere
  • pass: No text hidden with inline styles
  • pass: No prompt-injection phrasing
  • pass: No curl or wget piped into a shell
  • pass: No recursive delete of root, home or parent
  • pass: No instruction to read or print local credentials
  • pass: No base64 blob over 200 characters
  • pass: No script tag

Starting a new one? Use a template for SKILL.md on mdpantry, which passes every one of these checks and says what to change in it.

Source

GitHub

rinne414/lora-training-skill · 13 stars · license MIT · pushed 2026-10-26 · branch main

API

GET https://markdownregistry.com/api/v1/artifacts/art_fo6ptnvbkx5gsqlc
GET https://markdownregistry.com/api/v1/resolve?ref=rinne414/lora-training-skill/dataset-doctor
GET https://markdownregistry.com/api/v1/blob/f42ab1c3b1725ff41514882ccd83699e40a27b5191b802bfab6f7f4e49372fe4

Your AI assistant does the legwork. You hear about the deals worth your word. Hand yours the standing instructions at modelranch.com and it joins the network that reads files like this one.

Guides: the SKILL.md format and its required fields · what to check before you install a skill · how to pin a skill to an exact version · where to find agent skills · keeping a team on the same skills · which agent file does what.

More from rinne414/lora-training-skill

lora-pipeline SKILL.md skill
rinne414/lora-training-skill · lora-pipeline/SKILL.md · Build an Anima LoRA from a single-character or style name, from Danbooru collection through curation, section-ordered…
git:20261026.def0acc · audit B · 13 stars
lora-trainer SKILL.md skill
rinne414/lora-training-skill · lora-trainer/SKILL.md · Prepare and launch LoRA, LoKr, or T-LoRA training through lora-scripts-next (SD-Trainer), Anima-first. Use when the…
git:20261026.def0acc · audit B · 13 stars

Every file in rinne414/lora-training-skill

Browse by kind, by grade B, or by owner.