Dataset Creation Scripts - Development Notes
This repository contains UV scripts for creating Hugging Face datasets from local files.
Important Configuration
Dataset Viewer
Since these are script repositories (not actual datasets), we should disable the dataset viewer to avoid confusion. Add the following to the dataset card YAML header:
---
viewer: false
---
This prevents Hugging Face from trying to display the scripts as data, which would be misleading since users are meant to download and run these scripts, not view them as datasets.
Reference: https://huggingface.co/docs/hub/datasets-viewer-configure#disable-the-viewer
Repository Structure
dataset-creation/
βββ README.md # User-facing documentation
βββ CLAUDE.md # Development notes (this file)
βββ pdf-to-dataset.py # PDF processing script
βββ pdf-examples/ # Test PDFs for development
βββ .gitignore # Ignore test outputs
Testing
Test locally with:
uv run pdf-to-dataset.py pdf-examples test-dataset --private
Future Scripts
Potential additions (when needed):
images-to-dataset.py
- Process image directoriestext-to-dataset.py
- Convert text filesaudio-to-dataset.py
- Process audio filesjson-to-dataset.py
- Structure JSON data
Design Decisions
- Simple is better: Scripts use built-in dataset loaders where possible
- No GPU required: These are data preparation scripts, not inference
- Direct upload: Use
push_to_hub
for simplicity - Flexible output: Upload raw objects (PDFs, images) for user processing
Maintenance Notes
- Always test scripts with local examples before pushing
- Keep dependencies minimal
- Follow UV script best practices from main CLAUDE.md
- Ensure ruff formatting and linting passes