Skip to content

feat: HuggingFace dataset integration#47

Merged
jkbennitt merged 1 commit into
masterfrom
feat/hf-dataset-integration
Jun 12, 2026
Merged

feat: HuggingFace dataset integration#47
jkbennitt merged 1 commit into
masterfrom
feat/hf-dataset-integration

Conversation

@jkbennitt

Copy link
Copy Markdown
Member

Closes #45.

What

Wires the (previously never-functional) HF push end to end, targeting the real AppSprout/rle-benchmarks dataset:

  • build_dataset_card() — pure function rendering the README as a live leaderboard from leaderboard.json: Hub frontmatter (mit/tags), ranked table, billed costs unmarked vs ~-marked estimates (subscription models), baseline-beaters called out, N=1 framing, layout docs.
  • HFLogger — token + repo from RLEConfig (HF_TOKEN / HF_DATASET_REPO in .env; pydantic-settings doesn't export to os.environ so explicit passing is required), new push_card / push_spread methods, text-only allow patterns (json/jsonl/csv/md/ts) so capture leftovers never upload.
  • scripts/push_hf.py — push an existing run dir without re-running the benchmark; --dry-run lists exactly what would upload (verified: 235 files / 9.6MB spread + 16-file baseline + history).
  • run_benchmark --push-hf — the --runs 4+ hard error is now a labeled warning (N=1 content spreads are valid dataset entries; the card carries the framing), and the baseline push points at the static results/baseline instead of the stale results/baselines.
  • mypy — per-module disallow_untyped_calls=false for the two tracking modules: with the tracking extra installed locally, strict mode sees wandb/hf_hub's untyped APIs; CI doesn't install the extra, so inline ignores would be flagged unused there.

Verification

519 tests pass (+6 card-builder tests), ruff clean, mypy strict clean, dry-run output verified. The inaugural real push (v0.3.0 spread + baseline + history) happens post-merge.

🤖 Generated with Claude Code

Makes AppSprout/rle-benchmarks the public home for benchmark data:

- hf_logger: build_dataset_card() renders the README as a live
  leaderboard from leaderboard.json (billed costs unmarked, estimates
  marked with ~, baseline-beaters called out); push_card/push_spread
  methods; text-only allow patterns; token + repo wired from RLEConfig
  (HF_TOKEN / HF_DATASET_REPO in .env).
- scripts/push_hf.py: standalone push of an existing spread dir
  (card + history + baseline + runs/spread-<date>/) with --dry-run.
- run_benchmark --push-hf: N<4 hard error relaxed to a warning (N=1
  content spreads are valid dataset entries when labeled); baseline
  push now points at the static results/baseline.
- mypy: per-module override for the untyped wandb/huggingface_hub
  call surfaces (tracking extra installed locally; CI skips it, so a
  type: ignore would be flagged unused there).

519 tests pass (+6 card-builder tests), mypy strict clean.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@jkbennitt jkbennitt merged commit 8a20c18 into master Jun 12, 2026
3 checks passed
@jkbennitt jkbennitt deleted the feat/hf-dataset-integration branch June 12, 2026 21:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

HuggingFace dataset integration: auto-push spreads + leaderboard dataset card

1 participant