Skip to content

feat: add canonical Benchmark* types (Task/Observation/Action/Agent)#5

Merged
abrichr merged 1 commit into
mainfrom
feat/benchmark-types
Jul 13, 2026
Merged

feat: add canonical Benchmark* types (Task/Observation/Action/Agent)#5
abrichr merged 1 commit into
mainfrom
feat/benchmark-types

Conversation

@abrichr

@abrichr abrichr commented Jul 13, 2026

Copy link
Copy Markdown
Member

Summary

Phase 1 of the openadapt evals→ml refactor (Fork A). Adds the Benchmark* vocabulary to the canonical schema package so that both openadapt-ml and openadapt-evals import these types from openadapt-types instead of from each other — breaking the historical ml ↔ evals module-level import cycle.

What's added

  • openadapt_types/benchmark.pyBenchmarkTask, BenchmarkObservation, BenchmarkAction (dataclasses) and BenchmarkAgent (ABC). Faithful move of the definitions previously in openadapt_evals/adapters/base.py and openadapt_evals/agents/base.py.
  • Exported from openadapt_types.__init__.
  • tests/test_benchmark.py — 8 tests. Full suite: 117 passed.

Definitions are dependency-free (plain dataclasses + abc.ABC), so importing them never pulls in heavy optional deps.

⚠️ Release sequencing (IMPORTANT)

openadapt-types is a published PyPI package. This PR must merge AND release first. Then the dependent PRs bump their openadapt-types version pin:

  1. THIS PR merges → cut a new openadapt-types release (minor bump; new feat).
  2. openadapt-ml PR (adds openadapt-types dep, imports Benchmark* from here) bumps the pin.
  3. openadapt-evals PR (re-exports Benchmark* from here) bumps the pin.

Do not publish/release from this PR automatically without review.

Backward compatibility

openadapt-evals will re-export these names from their old locations, so existing from openadapt_evals import BenchmarkAction call sites keep working.

🤖 Generated with Claude Code

https://claude.ai/code/session_01CKrVJJy5jWVCkXAqgUqtqZ

Move the Benchmark* vocabulary into the canonical schema package so both
openadapt-ml and openadapt-evals can import it without depending on each
other, breaking the historical ml<->evals import cycle.

Definitions are dependency-free (dataclasses + abc) and faithfully match
the previous openadapt-evals definitions.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01CKrVJJy5jWVCkXAqgUqtqZ
@abrichr abrichr marked this pull request as ready for review July 13, 2026 16:33
@abrichr abrichr merged commit 82ad485 into main Jul 13, 2026
1 check passed
@abrichr abrichr deleted the feat/benchmark-types branch July 13, 2026 16:33
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.

1 participant