What problem does it solve? Recurring semi-structured reports (emailed PDFs with photos plus an Excel/CSV carrying ground-truth labels) are painful to turn into a clean labeled dataset, and naive classifier attempts fail on imbalanced, noisy, sample-biased data. This Skill provides a re-runnable pipeline that joins PDF evidence to spreadsheet labels on an ID key and validates a vision/LLM classifier with imbalance-aware metrics before anything goes live. ## Core Features & Use Cases - Dataset assembly: Pull Gmail attachments via the REST API, parse Excel labels and PDF pages with PyMuPDF, join on a normalized ID key, and emit a manifest plus per-class image folders. - Label-scheme validation: Tabulate observable features against the verdict column at full scale to detect derivable rules, signal-vs-noise features, and labeler inconsistency before training. - Classifier training and evaluation: Fine-tune a pretrained ResNet18 with record-level train/val splits, class-weighted loss, and recall/precision/false-alarm reporting, plus threshold sweeps and Average Precision model selection. - Human-in-the-loop review: Generate a self-contained HTML reviewer with embedded photos, Grad-CAM explainability, and a prefilled mailto approval round-trip. - Use Case: A rail-car inspection workflow emails daily PDF reports with photos and an Excel verdict sheet; use this Skill to harvest all historical reports into a 10k-record labeled dataset, discover that the verdict is a derivable rule over observable features, and train a local image classifier that beats the vision-LLM baseline. ## Quick Start Ask the agent to pull all inspection report emails, parse the PDF pages and Excel labels, join them on the record ID, and build the labeled dataset manifest.