# Review Dataset

> Audit YOLO dataset quality — class distribution, annotation quality, image stats, and improvement suggestions.

- **Type:** Skill
- **Install:** `agentstack add skill-macroman5-autotrain-yolo-review-dataset`
- **Verified:** Yes — security-reviewed for prompt injection and unsafe behavior
- **Seller:** [MacroMan5](https://agentstack.voostack.com/s/macroman5)
- **Installs:** 0
- **Category:** [Content & Media](https://agentstack.voostack.com/c/content-and-media)
- **Latest version:** 0.1.0
- **License:** MIT
- **Upstream author:** [MacroMan5](https://github.com/MacroMan5)
- **Source:** https://github.com/MacroMan5/autotrain-yolo/tree/master/.claude/skills/review-dataset

## Install

```sh
agentstack add skill-macroman5-autotrain-yolo-review-dataset
```

Requires the [AgentStack CLI](https://agentstack.voostack.com/docs/cli). Works with Claude Code, Cursor, and any MCP-compatible agent.

## About

# Review Dataset

Dataset quality audit + profiling for architecture selection.

## Workflow

### 1. Load Config

Read `yolo-project.yaml` for dataset path, class names, and **imgsz**.
If no config, ask user for dataset path.

### 2. Run Structural Validation

```bash
yolo-validate  --strict
```

### 3. Deep Analysis

Scan label files for:
- **Class Distribution**: Count per class, imbalance ratio. CRITICAL if any class 0.9)
- **Empty images**: Count and percentage
- **Split Balance**: Compare class ratios between train and val

### 3.5 Visual Spot-Check (Claude Vision)

Sample random images and visually verify annotation quality using Claude's multimodal vision.

#### Categorize images by annotation type:
- **Both classes**: images containing all project classes
- **Single-class only**: images with only one class (e.g., body without head)
- **Empty**: negative samples with no annotations

#### For each category, sample 2-4 images:
1. Draw annotations using `python scripts/draw_annotations.py`
2. Read the annotated image with Claude vision
3. Assess:
   - Are visible objects properly annotated?
   - Are there **missing annotations** (visible objects with no box)?
   - Are boxes accurately placed?
   - Are class labels correct?

#### Flag issues:
- **Incomplete annotations**: If a significant % of single-class images have visible objects of the missing class (e.g., body annotated but visible head not annotated), flag as "incomplete annotations" with estimated scope
- **Misclassified**: Wrong class assigned to a box
- **Phantom boxes**: Boxes on non-objects (UI elements, background)

#### Report findings:
Include visual spot-check results in the audit report with:
- Number of images sampled per category
- Issues found with example filenames
- Estimated % of dataset affected
- Recommendation: auto-label, manual review, or acceptable as-is

### 4. Dataset Profile for Architecture Selection

Run the profiling script with imgsz from yolo-project.yaml (default 640):

```bash
python scripts/profile_dataset.py \
  --labels /labels/train \
  --images /images/train \
  --imgsz  \
  --class-names ""
```

The script outputs structured YAML with:
- Object scale distribution (% small/medium/large at training resolution)
- Min object size (px) at training resolution
- Class-wise profiles sorted by avg object size ascending (smallest first)
- Train/val scale divergence check (flags >15% difference in small_pct)
- Suggested starting point for architecture (head config + scale + reasoning)

Save the output to `experiments/dataset_profile.yaml`.

### 5. Write to training-plan.md

Fill the **Dataset Summary** section in training-plan.md with profile data:
- Total images: train/val counts
- Classes: N — [list]
- Class balance: most/least represented with counts
- Scale distribution: % small/medium/large at imgsz
- Min object size at training resolution
- Avg objects per image
- Train/val divergence flag

### 6. Write Report

Create `experiments/dataset_audit.md` with:
- Validation findings
- Class distribution table
- Quality issues
- Dataset profile (full YAML output)
- Architecture suggestion (labeled "Suggested starting point", NOT "Recommended")
- Top 3 recommendations

### 7. Print Summary

Key findings, profile highlights, and architecture suggestion.

## Guidelines

- Be specific: "Collect 400+ bird images" not "collect more data"
- Profile uses training-resolution-adjusted sizes, not native pixel sizes
- Architecture suggestion provides data for agent reasoning — it's not a directive

## Source & license

This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.

- **Author:** [MacroMan5](https://github.com/MacroMan5)
- **Source:** [MacroMan5/autotrain-yolo](https://github.com/MacroMan5/autotrain-yolo)
- **License:** MIT

Install and usage instructions live in the source repository linked above.

## Pricing

- **Free** — Free

## Security capabilities

Automated source analysis of v0.1.0 — what this tool can access:

- **Network access:** no
- **Filesystem access:** no
- **Shell / process execution:** no
- **Environment & secrets:** no
- **Dynamic code execution:** no

*"Yes" means the capability is present in the source — more access means more to trust, not that it is unsafe.*


## Versions

- **0.1.0** — security scan: passed — Imported from the upstream source.

## Links

- Listing page: https://agentstack.voostack.com/l/skill-macroman5-autotrain-yolo-review-dataset
- Seller: https://agentstack.voostack.com/s/macroman5
- Browse the marketplace: https://agentstack.voostack.com/browse

---
Listed on AgentStack — the marketplace for AI agent skills and MCP servers. Every listing is security-reviewed. Creators keep 70%.
