uv scripts

community
Activity Feed

AI & ML interests

None defined yet.

Recent Activity

davanstrien  updated a dataset 1 day ago
uv-scripts/ocr
davanstrien  updated a dataset 3 days ago
uv-scripts/vllm
davanstrien  updated a dataset 4 days ago
uv-scripts/classification
View all activity

UV Scripts

Ready-to-run ML tools powered by UV - zero setup, maximum power

Run state-of-the-art ML workflows with a single command. From OCR to classification, all scripts work instantly with uv run.

What are UV scripts?

UV scripts are self-contained Python scripts that use inline metadata to specify dependencies. Just uv run script.py and everything installs automatically.

Perfect for:

  • 🚀 GPU workflows on HF Jobs
  • 💻 Local processing on your machine
  • 🔄 Reproducible pipelines that work anywhere

🚀 Quick Example

# Extract text from images with state-of-the-art OCR (no local GPU needed!)
hf jobs uv run --flavor l4x1 \
  https://huggingface.co/datasets/uv-scripts/ocr/raw/main/nanonets-ocr.py \
  your-images your-extracted-text

📚 Browse Scripts

Script Collection Description GPU Required
ocr Extract text from images with VLMs (LaTeX, tables, forms)
classification Text classification with guaranteed valid outputs
dataset-creation Create datasets from PDFs and files
vllm High-performance inference with vLLM

🎯 Why UV Scripts?

Zero Setup

No virtual environments, no dependency conflicts, no installation steps. UV handles everything automatically when you run the script.

GPU Optimized

Seamlessly run on local GPUs or scale to cloud with HF Jobs. Same script, different compute.

🌟 Featured Scripts

OCR Any Document Dataset

Extract text from images with state-of-the-art accuracy:

# Handles LaTeX, tables, forms, handwriting
hf jobs uv run --flavor l4x1 \
  https://huggingface.co/datasets/uv-scripts/ocr/raw/main/nanonets-ocr.py \
  your-images extracted-text

Classify with Guaranteed Valid Outputs

Text classification that always returns valid labels:

# Uses vLLM's structured generation - no invalid outputs!
hf jobs uv run --flavor l4x1 \
  https://huggingface.co/datasets/uv-scripts/classification/raw/main/classify-dataset.py \
  --input-dataset imdb --column text \
  --labels "positive,negative" --output-dataset imdb-classified

🚀 Getting Started with HF Jobs

Run any UV script on GPU infrastructure:

hf jobs uv run --flavor l4x1 \
  https://huggingface.co/datasets/uv-scripts/[collection]/raw/main/[script].py \
  [args]

Choose your GPU flavor:

  • l4x1 - Good balance for most tasks
  • a10g-large - More memory for larger models
  • a100-large - Maximum performance

📖 Learn More


UV Scripts is a community project showcasing the power of UV for ML workflows.

models 0

None public yet