Skip to main content

autocurate

Curation is a compute multiplier: train on the right subset of your data and you reach the same quality with less compute. autocurate does it in one call. Point it at a table of training data. It detects what kind of data it is, scores every row with the signals that matter for that kind, applies the strongest established public filter, and hands you the subset to train on as a view: read straight from the table without copying it, in a globally shuffled order. Seven kinds of data are routed from the schema: web text, noisy labels, image-text pairs, SFT chats, preference pairs, RL prompts and robot episodes. Nothing in a default path calls an LLM. Give it your evaluation and it tunes the recipe; add agent=True and an LLM agent surveys the literature and writes recipes. A tuned recipe is applied only if it beats the default on your held-out metric. This is research code, and APIs may change.

Install

pip install -e ".[all]"     # torch, transformers, open_clip, optuna (TPE search), anthropic (opt-in agent)
pip install fasttext        # for the web-text default (DCLM); without it, text falls back to FineWeb-Edu and says so

One verb, three levels

import autocurate as ac

ds = ac.load("data/*.parquet", name="pool", uri="./db")      # parquet, pandas, pyarrow, hf://... into a Lance table

def train_eval(recipe, ids):                                 # your proxy training; higher is better
    model = train(ds.view(ids, columns=["text"]))
    return {"score": evaluate(model), "heldout": evaluate(model)}   # use a held-out set the search never sees
cur = ac.curate(ds)                                          # 1. default: domain recipe, no LLM, no training
cur = ac.curate(ds, eval=train_eval, budget=8)               # 2. tuned: TPE on your eval, guarded by the default
cur = ac.curate(ds, eval=train_eval, budget=8, agent=True)   # 3. agent: literature signals + LLM recipes, guarded
print(cur, cur.report["level"], cur.report["guard"])         # what ran, what was picked and why
loader = cur.to_torch(columns=["text"], batch_size=256)      # zero-copy, globally shuffled batches

ac.diagnose(ds) runs pre-flight checks before you spend compute. Level 2 is TPE by default (no LLM); level 3 is opt-in and the only path that calls an LLM (a logged-in claude CLI, ANTHROPIC_API_KEY, OPENAI_API_KEY or the codex CLI). Without eval=, agent=True only runs signal discovery and applies the default. Every signal is a column, cataloged with its citations and provenance. Tables live on local disk or an object store (S3).

Defaults

kind of data detected from ac.curate(ds) applies vs no curation
web text one long text column DCLM fastText top 10% + SemDeDup 1.8× (GPT-2-small, 4B tokens)
image-text pairs image + caption DFN top 30% + SemDeDup 3.3× (DataComp-medium)
noisy labels a class label column lowest k-NN label disagreement per class 1.0-6.0×, median 2.8× (13 tasks)
SFT chats messages or prompt/response reward-model top 50% + prompt SemDeDup 2.2× (Tulu-3 → Qwen2.5-0.5B)
preference pairs prompt/chosen/rejected top 75% by reward-model margin better held-out z; no curve
RL prompts problem/answer learnability: 0 < pass rate < 1, ranked by p(1-p) ≈1×
robot episodes episode/action columns lowest k-NN task-label disagreement per task n.s. on small sims

Each is a compute multiplier against training on the whole pool at matched quality, read off measured curves and never extrapolated (gross; DataComp-medium is the 80.2M-pair pool). An agent-searched recipe scored above DFN top 30% there on all 3 seeds (3.90×, p = 0.051). Net of curation compute, and against the strongest public filter, see results. Fallbacks when a model cannot run are logged in cur.report.

Docs

pip install -e ".[docs]" && mkdocs serve, or read them in docs/: quickstart · which level do I need? · the guard · guides · agent mode · API · results · benchmarks · contributing.

License

Apache-2.0.

Metadata

Release files for autocurate 0.3.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 autocurate 0.3.0
File Size Uploaded
autocurate-0.3.0.tar.gz 250.1 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for autocurate 0.3.0
File Interpreter ABI Platform
autocurate-0.3.0-py3-none-any.whl Python 3 none any Details

Total release size: 458.9 kB

Release files / autocurate-0.3.0.tar.gz

Download URL autocurate-0.3.0.tar.gz
Size 250.1 kB
Tags Source
SHA-256 checksum
How to use checksums
1e945f1c1631604b50b2d3f389087d7725918f674f2ca49a13a9d6bcba04f554
BLAKE2b-256 checksum
How to use checksums
096fb3d46fe70c41816cabbffeb369f87aad5c4ecb4411ea1eee532159404b83
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.11.17

Release files / autocurate-0.3.0-py3-none-any.whl

Download URL autocurate-0.3.0-py3-none-any.whl
Size 208.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
256d05d9b531ea9c5ddd995fe80b10b2f40b6e10c620ecccbbd824acdcfd171d
BLAKE2b-256 checksum
How to use checksums
01ad33bbba08c030f111aa04adc18a9dfe06b2a7cc6d7838346f9fdf32c396c0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.11.17

Release history Release notifications | RSS feed

This release

0.3.0 This release

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