Skip to main content

Easy Dataset Share

easy-dataset-share helps AI researchers share datasets responsibly. It prevents evaluation contamination by making datasets easy for researchers to use but hard for automated scrapers to ingest.

The easy-dataset-share CLI tool provides basic protection against scraping by making the dataset text itself less scrapeable.

However, sophisticated actors will still be able to scrape your content. Rather than providing unsophisticated further defenses which inconvenience real users, we think you should outsource that defense to a provider like CloudFlare. We wrote an easy tutorial on signing up with CloudFlare Turnstile, which is like CAPTCHA but a. actually effective and b. doesn't inconvenience your real users. See WEB_HOSTING_GUIDE.md

Python 3.10+ PyPI GitHub License: Other/Proprietary

Features

  • Canary markers: Unique identifiers to detect if your dataset was used for training.
  • Hash verification: Ensures that adding & removing canaries does not alter the dataset.
  • Zip and password-protect: Zips the data to make it not readable in plaintext by basic crawlers. Optional password-based encryption as well.
  • Default best practices: Generates a conservative robots.txt and a Terms of Service which prohibits use for AI training.
  • Clean removal: Removes all protection while preserving original data (use hash verification to confirm data-integrity).
  • Web hosting: Deploy a protected download site with Cloudflare-Turnstile (a CAPTCHA-replacement)- see WEB_HOSTING_GUIDE.md

Installation

pip install easy-dataset-share

Quick Start

Protect a dataset

easy-dataset-share protect-dir /path/to/your/dataset

Unprotect and clean

easy-dataset-share unprotect-dir <path/to/your/dataset>.zip --remove-canaries

Verify integrity

easy-dataset-share hash /path/to/dataset

Options

Run easy-dataset-share --help or for a subcommand easy-dataset-share protect-dir --help. To get a description of the options available.

How it Works

  1. Hash original dataset for integrity baseline
  2. Add canary markers throughout the dataset
  3. Package with robots.txt and optional encryption
  4. Verify integrity when unprotecting (canaries removed, data unchanged)

Example Workflow

# Protect with a password
easy-dataset-share protect-dir <path/to/your/dataset>

# Share <path/to/your/dataset>.zip publicly (the zip file contains your protected dataset)

# Recipients unprotect and remove canaries
easy-dataset-share unprotect-dir <path/to/your/dataset>.zip --remove-canaries
# Output shows: "📊 Dataset hash: abc123..." (matches original)

Use -p your-password to add a password when you zip (and for others to use when they unzip - will now be .zip.enc) Use -v for verbose output to see hashing details and canary operations.

Notes about licensing for Robots.txt (Text & Data Mining (TDM) opt-out)

The robots.txt generated by this helper add TDM protections, see EDRlab for more information.

Hosting with Anti-Scraper Protection

For datasets hosted outside of Hugging Face, we strongly recommend using Cloudflare Turnstile to add an additional layer of protection against automated AI scrapers. See WEB_HOSTING_GUIDE.md for a guide on how to do this.

This layered approach (dataset protection + hosting protection) provides comprehensive defense against automated data harvesting while maintaining accessibility for legitimate researchers.

Maintainence + Development

This is meant to be a collaborative and community project. Please feel encouraged to make PRs to update this repo!

For development:

git clone https://github.com/Responsible-Dataset-Sharing/easy-dataset-share.git
cd easy-dataset-share
pip install -e .
git config core.hooksPath .githooks

Current Maintainers

Acknowledgements

This project was kickstarted by Alex Turner and then funded by the following supporters:

Release files for easy-dataset-share 0.5.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for easy-dataset-share 0.5.0
File Size Uploaded
easy_dataset_share-0.5.0.tar.gz 440.2 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for easy-dataset-share 0.5.0
File Interpreter ABI Platform
easy_dataset_share-0.5.0-py3-none-any.whl Python 3 none any Details

Total release size: 898.8 kB

Release files / easy_dataset_share-0.5.0.tar.gz

Download URL easy_dataset_share-0.5.0.tar.gz
Size 440.2 kB
Tags Source
SHA-256 checksum
How to use checksums
153ac1c4b3bee914e4099a4803eaf5ad32ac8464d734afffc00cebeea6b7a8ab
BLAKE2b-256 checksum
How to use checksums
bf628bff5421826c82ee811a4d108cef31a945ff7eba0101033818a6ab83d735
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.11.11

Release files / easy_dataset_share-0.5.0-py3-none-any.whl

Download URL easy_dataset_share-0.5.0-py3-none-any.whl
Size 458.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
58b747ad52e5b9022de85db61613e33d59fb7b4f55d6e3048e69f3b9cc3da46f
BLAKE2b-256 checksum
How to use checksums
a24ea80920808e71ca8485c0ad02c8bdb19a34e0ceeef8aea22ebe4b598df8e8
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.11.11

Release history Release notifications | RSS feed

This release

0.5.0 This release

2 release files

0.4.3

2 release files

0.4.2

2 release files

0.4.1

2 release files

0.4.0

2 release files

0.3.1

2 release files

0.3.0

2 release files

0.2.2

2 release files

0.2.1

2 release files

0.2.0

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page