Skip to content

Add model eval create and compatibility check - #591

Draft
leeclemnet wants to merge 9 commits into
mainfrom
feat/cross-version-model-eval
Draft

leeclemnet wants to merge 9 commits into
mainfrom
feat/cross-version-model-eval

Conversation

@leeclemnet

@leeclemnet leeclemnet commented Nov 26, 2026 •

Copy link
Copy Markdown
Contributor

What does this PR do?

Motivation

The platform adds evaluation of a model on another dataset version of its project. Scripts and agents that use the SDK or the CLI need a way to start one.

Before

  • The SDK and the CLI could only read model evaluations (roboflow eval list, compare, and the result commands). They could not start one.

After

  • Workspace.create_model_evaluation(model, project, version=None, rerun=False) starts the evaluation. It returns the response dict, with reused, trainedOnVersion, leakage, and classMismatch.
  • Workspace.check_model_evaluation_compatibility(model, project, version=None) checks the request and starts nothing.
  • New errors: ModelEvalBlockedError (HTTP 409, with .blocks) and ModelEvalConcurrencyLimitError (HTTP 429).
  • CLI: roboflow eval create and roboflow eval check-compatibility. Exit code 6 means blocked, and 7 means the concurrency limit.
  • Split leakage and a class mismatch do not block an evaluation. They come back as tags on the result.

Related Issue(s): none

This needs the platform release that adds the two routes.

Type of Change

  • New feature (non-breaking change that adds functionality)

Testing

  • I have tested this change locally
  • I have added/updated tests for this change

Test details:

Checklist

  • My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have commented my code where necessary, particularly in hard-to-understand areas
  • My changes generate no new warnings or errors
  • I have updated the documentation accordingly (if applicable)

Additional Context

The product docs for the new commands are not written yet.

🤖 Generated with Claude Code

leeclemnet and others added 3 commits November 26, 2026 17:00
Add rfapi.create_model_eval and rfapi.preflight_model_eval, and the
Workspace methods create_model_evaluation and preflight_model_evaluation.
Both return the full response. A 409 with blocks raises
ModelEvalBlockedError. A 429 with eval_concurrency_limit raises
ModelEvalConcurrencyLimitError.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Exit code 6 means a pre-flight block. Exit code 7 means the workspace
concurrency limit. Document both commands in the changelog and the CLI
quickstart.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
With rerun, a done eval does not satisfy the request, so a new eval
starts. A pending or running eval still returns with reused true.
Pre-flight does not take the field.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
@leeclemnet

Copy link
Copy Markdown
Contributor Author

Mega Review

Status: NOT CLEAN @ 1ce750a · round 1 · full scope

Two findings block, no Criticals. The request and response contract matches the platform change.
Review-clean does not replace typecheck, tests or CI.

❌ Blocking

What is wrong Where
⚠️ eval create and eval preflight reuse the hints of the eval reads. A not-found error points to eval list, an access error names the model-eval:read scope, and the blocked hint fits one block code of six. eval.py:298 · new
⚠️ Null tags are shown as "Trained on version: unknown" and "not checked", and three doc sentences say null means no pre-flight. The API also returns null tags when the target is the training version, which is the default. eval.py:268 · new

🤨 Non-blocking

Nine Minors
  • With --json, a blocked create has no structured blocks key in the error, but CLI-COMMANDS.md:504 says the list is in the error.
  • The docstring example at workspace.py:1680 indexes leakage, which can be None.
  • workspace.py:1695 says pre-flight takes the same arguments as create, but it has no rerun.
  • The 403 and 404 test fixtures do not have the error body shape that the API sends. No text test covers leakage with status unknown and null splits. No test asserts a hint.
  • The eval group help, the ModelEvalNotFoundError and ModelEvalAccessError docstrings, and the Raises: sections do not cover the new commands.
  • The changelog names one of the two routes, says eval get keeps the tags (true for --json only), and has no PR link.
  • The product docs do not have the new commands yet (repo documentation policy).
  • An SDK version such as "v5" gives a generic 400 error. rerun is positional where the neighbour method uses keyword-only arguments.
  • Before the platform change is live, both commands answer "Endpoint not found." with exit code 3.

Caveats

The contract was checked against the code of the platform change before its merge. No run against a live API was made.

Review Ledger

Open findings

  • roboflow/cli/handlers/eval.py:298:start-commands-read-hints | Warning | roboflow/cli/handlers/eval.py:298 | create and preflight pass errors to the read hint table (eval.py:250, :252, :260), so 404, 403 and five of six block codes get a false hint
  • roboflow/cli/handlers/eval.py:268:null-tags-described-as-unchecked | Warning | roboflow/cli/handlers/eval.py:268 | null tags print as unknown and not checked, and CHANGELOG.md:16, CLI-COMMANDS.md:500 and workspace.py:1670 say null means no pre-flight, but the API sends null tags for an eval of the training version

Prior key statuses

  • None. This is round 1.

Unresolved prior open findings

  • None.

Deliberate tradeoffs

  • Create and pre-flight return a plain dict, as compare_model_evaluations does: author decision, matches workspace.py, rated Minor at most.
  • CLI exit codes 6 (blocked) and 7 (concurrency limit): author decision, extends the 1 to 5 scheme of eval.py, tested, not a finding.
  • version is optional and the server sets the default: author decision, matches the request schema of the platform change.
  • rerun is sent only when true and never on pre-flight: author decision, needed because the pre-flight schema is strict.
  • Leakage and class mismatch are tags and never block, and a same-version eval has null tags: platform design, consumed unchanged.

Refuted

  • The new -v flag collides with the root --version flag: the root flag is on the root callback only, and eval compare uses -v at the base.
  • A 409 on create with no blocks maps to ModelEvalNotDoneError: the create handler of the platform change sends 409 only with a non-empty blocks list.
  • A blocks entry that is not a dict crashes the mapper at rfapi.py:2358: the response schema of the platform change permits dict entries only.
  • The eval-read error mapping changed: the read routes never send blocks or eval_concurrency_limit, and the 404, 409, 401 and 403 branches are the same as the base.

Implausible

  • None.

Pre-existing

  • The SDK error message is raw JSON text when the error body has a nested error object: the same lines are in _model_eval_error_for at the merge base (rfapi.py:2341).

Give eval create and eval preflight their own error hints. Do not print
null tags as unknown or not checked. Correct the docs for null tags,
the blocked --json output, and the pre-flight arguments.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
@leeclemnet

Copy link
Copy Markdown
Contributor Author

Mega Review

Status: NOT CLEAN @ 09d8885 · round 2 · narrowed to 1ce750a..09d8885

One finding blocks, no Criticals. Not converged.
Review-clean does not replace typecheck, tests or CI.

❌ Blocking

What is wrong Where
⚠️ An API key without the training-job:create scope gets a 404 from the API. eval create and eval preflight then say "Check the --model, --project and --version values." and no output names the scope. eval.py:269 · round 2

✅ Fixed since last round

  • Null tags are no longer shown as "unknown" or "not checked". 09d8885 makes _format_tags omit a null tag, and the three doc sentences now name the training-version case.
  • The read hints are gone from the start commands. _start_hint_for gives true hints for an unknown model, project or version and for a 403, and the blocked error has no hint.
  • Round 1 Minors fixed: the blocks sentence in the quickstart, the docstring example, the "same arguments" sentence, the group help, the error class docstrings, the create Raises: section, and the changelog routes and PR link.

🤨 Non-blocking

Seven Minors
  • The null-tag sentence in the changelog, the quickstart and workspace.py:1669 omits two cases: a model with no training version, and a blocked request. Only classMismatch is null when the trained-on version is deleted.
  • In that deleted-version case, the text output has no class mismatch line, so a reader cannot tell that the check did not run.
  • The 403 and 404 test fixtures still do not have the error body shape that the API sends. No test covers a pre-flight error hint. The null-tag test does not assert that the "Trained on" line is absent.
  • workspace.py:1702 says pre-flight "does not raise" and has no Raises: section. The create_model_eval adapter docstring lists two of the four errors.
  • The product docs do not have the new commands yet (repo documentation policy).
  • An SDK version such as "v5" gives a generic 400 error. rerun is positional where the neighbour method uses keyword-only arguments.
  • Before the platform change is live, both commands answer "Endpoint not found." with exit code 3.

Caveats

Narrowed round. The rest of the PR was reviewed at 1ce750a and not re-examined, so this verdict speaks across the rounds and not for one pass. The contract was checked against the code of the platform change before its merge. No run against a live API was made.

Review Ledger

Open findings

  • roboflow/cli/handlers/eval.py:298:start-commands-read-hints | Warning | roboflow/cli/handlers/eval.py:269 | a key without the training-job:create scope gets a 404 from the API, and the not-found hint of the start commands names only the model, project and version inputs, so no output names the scope | rounds=2

Prior key statuses

  • roboflow/cli/handlers/eval.py:298:start-commands-read-hints | partially-addressed | create and preflight now call _start_hint_for (eval.py:305, :330): the eval-list hint, the model-eval:read hint and the blocked hint are gone, verified; the missing-scope 404 still gets an input-only hint at eval.py:269
  • roboflow/cli/handlers/eval.py:268:null-tags-described-as-unchecked | resolved | _format_tags (eval.py:275-289) omits each null tag, and CHANGELOG.md:16, CLI-COMMANDS.md:500 and workspace.py:1669 now name the training-version case, verified

Unresolved prior open findings

  • None.

Deliberate tradeoffs

  • Create and pre-flight return a plain dict, as compare_model_evaluations does: author decision, matches workspace.py, rated Minor at most.
  • CLI exit codes 6 (blocked) and 7 (concurrency limit): author decision, extends the 1 to 5 scheme of eval.py, tested, not a finding.
  • version is optional and the server sets the default: author decision, matches the request schema of the platform change.
  • rerun is sent only when true and never on pre-flight: author decision, needed because the pre-flight schema is strict.
  • Leakage and class mismatch are tags and never block, and a same-version eval has null tags: platform design, consumed unchanged.
  • A blocked create has no structured blocks key in the --json error: author decision at 09d8885, CLI-COMMANDS.md:505-506 now says the message lists each block and points to eval preflight --json, rated Minor.

Refuted

  • The new -v flag collides with the root --version flag: the root flag is on the root callback only, and eval compare uses -v at the base.
  • A 409 on create with no blocks maps to ModelEvalNotDoneError: the create handler of the platform change sends 409 only with a non-empty blocks list.
  • A blocks entry that is not a dict crashes the mapper at rfapi.py:2358: the response schema of the platform change permits dict entries only.
  • The eval-read error mapping changed: the read routes never send blocks or eval_concurrency_limit, and the 404, 409, 401 and 403 branches are the same as the base.
  • Removing the blocked and concurrency branches from _hint_for changes a read command: no read route sends those errors, and eval compare uses _hint_for for access errors only.
  • The blocked error now gets a plan-upgrade hint from the shared output helper: no block message of the platform change matches a plan hint pattern.

Implausible

  • None.

Pre-existing

  • The SDK error message is raw JSON text when the error body has a nested error object: the same lines are in _model_eval_error_for at the merge base (rfapi.py:2341).
  • With --json, a hint in the error body of the API replaces the hint of the command: output_error uses setdefault at the merge base (cli/_output.py).

A key without the training-job:create scope gets a 404, so the not-found
hint names both causes. State the null tag rule once, list the errors
that create and pre-flight can raise, and test the pre-flight hint.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
@leeclemnet

Copy link
Copy Markdown
Contributor Author

Mega Review

Status: REVIEW-CLEAN @ b4b0c94 · round 3 · narrowed to 09d8885..b4b0c94

No Critical or Warning finding is open. Not converged yet: one new Minor needs a fix or an acceptance.
Review-clean does not replace typecheck, tests or CI.

✅ Fixed since last round

  • The not-found hint of the start commands now names the scope. b4b0c94 changes eval.py:270, so a key without training-job:create gets a hint that names it. Tests assert it for both commands.
  • Round 2 Minors fixed: the null-tag sentence no longer says "three tags" and names models with no training version, the pre-flight docstring has a Raises: section, the adapter docstring lists all four errors, and the null-tag test asserts that the "Trained on" line is absent.

🤨 Non-blocking

  • New: the null-tag sentence in the changelog, the quickstart and workspace.py:1669 lists "a blocked request". A pre-flight with a preprocessing block returns the tags with values, and a blocked create raises.
  • New, optional: the Raises: text at workspace.py:1705 says the model, project or version does not exist. A key without the scope gets the same error.
  • With --json, the hint in the error body of the API replaces the hint of the command, so the scope is named in text output only. The shared output helper does the same at the merge base.

Caveats

Narrowed round. The rest of the PR was reviewed at 1ce750a and 09d8885 and not re-examined, so this verdict is clean across the rounds and not in one pass. The contract was checked against the code of the platform change before its merge. No run against a live API was made.

Review Ledger

Open findings

  • None.

Prior key statuses

  • roboflow/cli/handlers/eval.py:298:start-commands-read-hints | resolved | the not-found branch of _start_hint_for (eval.py:268-271) now names the training-job:create scope, both start commands pass it (eval.py:307, :332), and text output shows it for the missing-scope 404 body, verified end to end
  • roboflow/cli/handlers/eval.py:268:null-tags-described-as-unchecked | resolved | closed in round 2 and the spot is unchanged: _format_tags omits each null tag, and the reworded sentences keep the training-version case

Unresolved prior open findings

  • None.

Deliberate tradeoffs

  • Create and pre-flight return a plain dict, as compare_model_evaluations does: author decision, matches workspace.py, rated Minor at most.
  • CLI exit codes 6 (blocked) and 7 (concurrency limit): author decision, extends the 1 to 5 scheme of eval.py, tested, not a finding.
  • version is optional and the server sets the default: author decision, matches the request schema of the platform change.
  • rerun is sent only when true and never on pre-flight: author decision, needed because the pre-flight schema is strict.
  • Leakage and class mismatch are tags and never block, and a same-version eval has null tags: platform design, consumed unchanged.
  • A blocked create has no structured blocks key in the --json error: author decision, CLI-COMMANDS.md says the message lists each block and points to eval preflight --json, rated Minor.
  • Text output omits a null tag, so the deleted-training-version case has no class mismatch line: author decision, stated in CLI-COMMANDS.md:501, rated Minor.
  • rerun is a positional parameter of create_model_evaluation: author decision on preference (round 3), rated Minor.
  • An SDK version such as "v5" gives the generic 400 error of the API: author decision on preference (round 3), the CLI validates the value, rated Minor.
  • The product docs for the new commands are in another repository and are not in this change: author decision (round 3), rated Minor.
  • Before the platform change is live, both commands answer "Endpoint not found." with exit code 3: author decision (round 3), the changelog names both required routes, rated Minor.
  • The test fixtures use a simplified error body, not the exact body of the API: author decision on preference (round 3), rated Minor.

Refuted

  • The new -v flag collides with the root --version flag: the root flag is on the root callback only, and eval compare uses -v at the base.
  • A 409 on create with no blocks maps to ModelEvalNotDoneError: the create handler of the platform change sends 409 only with a non-empty blocks list.
  • A blocks entry that is not a dict crashes the mapper at rfapi.py:2358: the response schema of the platform change permits dict entries only.
  • The eval-read error mapping changed: the read routes never send blocks or eval_concurrency_limit, and the 404, 409, 401 and 403 branches are the same as the base.
  • Removing the blocked and concurrency branches from _hint_for changes a read command: no read route sends those errors, and eval compare uses _hint_for for access errors only.
  • The blocked error now gets a plan-upgrade hint from the shared output helper: no block message of the platform change matches a plan hint pattern.
  • The new not-found hint is false for a 404 that is not a scope problem: the hint lists the inputs and the scope as checks and states no single cause, verified for unknown resources, a key of another workspace and a folder-limited key.

Implausible

  • None.

Pre-existing

  • The SDK error message is raw JSON text when the error body has a nested error object: the same lines are in _model_eval_error_for at the merge base (rfapi.py:2341).
  • With --json, a hint in the error body of the API replaces the hint of the command: output_error uses setdefault at the merge base (cli/_output.py:166, :171), and the lines are identical at this head.

A blocked pre-flight can return tags with values, so the null tag
sentence no longer lists it. The not-found error also covers a key
without the training-job:create scope.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
@leeclemnet

Copy link
Copy Markdown
Contributor Author

Mega Review

Status: REVIEW-CLEAN @ e25ee31 · round 4 · narrowed to b4b0c94..e25ee31 · converged after 4 rounds

No finding is open. Each Minor is fixed or is an accepted author decision.
Review-clean does not replace typecheck, tests or CI.

✅ Fixed since last round

  • The null-tag sentence no longer lists "a blocked request". e25ee31 replaces it in the changelog, the quickstart and workspace.py:1669 with a general rule and the training-version example.
  • The not-found Raises: text names the missing scope. Both docstrings (workspace.py:1677, workspace.py:1705) now say that a key with no training-job:create scope gets the same error.

🤨 Non-blocking

  • None new. The accepted author decisions are in the ledger below.

Caveats

Narrowed round. The rest of the PR was reviewed at 1ce750a, 09d8885 and b4b0c94 and not re-examined, so this verdict is clean across the four rounds and not in one pass. The contract was checked against the code of the platform change before its merge. No run against a live API was made.

Review Ledger

Open findings

  • None.

Prior key statuses

  • roboflow/cli/handlers/eval.py:298:start-commands-read-hints | resolved | closed in round 3 and the spot is unchanged in this delta: the not-found branch of _start_hint_for names the training-job:create scope, and both start commands pass it
  • roboflow/cli/handlers/eval.py:268:null-tags-described-as-unchecked | resolved | closed in round 2: _format_tags omits each null tag, and the sentence at CHANGELOG.md:16, CLI-COMMANDS.md:500 and workspace.py:1669 now gives a general rule with the training-version example, which the tag logic of the platform change supports

Unresolved prior open findings

  • None.

Deliberate tradeoffs

  • Create and pre-flight return a plain dict, as compare_model_evaluations does: author decision, matches workspace.py, rated Minor at most.
  • CLI exit codes 6 (blocked) and 7 (concurrency limit): author decision, extends the 1 to 5 scheme of eval.py, tested, not a finding.
  • version is optional and the server sets the default: author decision, matches the request schema of the platform change.
  • rerun is sent only when true and never on pre-flight: author decision, needed because the pre-flight schema is strict.
  • Leakage and class mismatch are tags and never block, and a same-version eval has null tags: platform design, consumed unchanged.
  • A blocked create has no structured blocks key in the --json error: author decision, CLI-COMMANDS.md says the message lists each block and points to eval preflight --json, rated Minor.
  • Text output omits a null tag, so the deleted-training-version case has no class mismatch line: author decision, stated in CLI-COMMANDS.md:501, rated Minor.
  • rerun is a positional parameter of create_model_evaluation: author decision on preference (round 3), rated Minor.
  • An SDK version such as "v5" gives the generic 400 error of the API: author decision on preference (round 3), the CLI validates the value, rated Minor.
  • The product docs for the new commands are in another repository and are not in this change: author decision (round 3), rated Minor.
  • Before the platform change is live, both commands answer "Endpoint not found." with exit code 3: author decision (round 3), the changelog names both required routes, rated Minor.
  • The test fixtures use a simplified error body, not the exact body of the API: author decision on preference (round 3), rated Minor.
  • With --json, a hint in the error body of the API replaces the hint of the command, so the scope is named in text output only: author decision (round 4), output_error uses setdefault at the merge base (cli/_output.py:166, :171) and the lines are identical at this head, rated Minor.

Refuted

  • The new -v flag collides with the root --version flag: the root flag is on the root callback only, and eval compare uses -v at the base.
  • A 409 on create with no blocks maps to ModelEvalNotDoneError: the create handler of the platform change sends 409 only with a non-empty blocks list.
  • A blocks entry that is not a dict crashes the mapper at rfapi.py:2358: the response schema of the platform change permits dict entries only.
  • The eval-read error mapping changed: the read routes never send blocks or eval_concurrency_limit, and the 404, 409, 401 and 403 branches are the same as the base.
  • Removing the blocked and concurrency branches from _hint_for changes a read command: no read route sends those errors, and eval compare uses _hint_for for access errors only.
  • The blocked error now gets a plan-upgrade hint from the shared output helper: no block message of the platform change matches a plan hint pattern.
  • The new not-found hint is false for a 404 that is not a scope problem: the hint lists the inputs and the scope as checks and states no single cause, verified for unknown resources, a key of another workspace and a folder-limited key.

Implausible

  • None.

Pre-existing

  • The SDK error message is raw JSON text when the error body has a nested error object: the same lines are in _model_eval_error_for at the merge base (rfapi.py:2341).

The operation checks if a model is compatible with a dataset version.
Use one term for it: the check-compatibility route, the
check_model_evaluation_compatibility method and the eval
check-compatibility command.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
@leeclemnet leeclemnet changed the title Add model eval create and pre-flight Add model eval create and compatibility check Nov 27, 2026
@leeclemnet

Copy link
Copy Markdown
Contributor Author

Mega Review

Status: REVIEW-CLEAN @ baf7f14 · round 5 · narrowed to e25ee31..baf7f14 · converged after 5 rounds

No finding is open. The rename to "check compatibility" is complete and does not change behavior.
Review-clean does not replace typecheck, tests or CI.

✅ Checked in this round

  • No call site, import, help text or doc has the old name. The SDK method, the adapter function, the CLI command, the changelog and the quickstart all use the new name. A search of the tree finds no other use.
  • The route name matches the platform change. The adapter posts to /{workspace}/model-evals/check-compatibility (rfapi.py:2441), and the platform change registers the same POST route.
  • No test passes for the wrong reason. Each patch target exists, and the adapter test and the CLI test assert the new URL.
  • Nothing else changed. The request body, the error mapping, the exit codes, the hints and the output text are the same as at e25ee31.

🤨 Non-blocking

  • None counted. Two internal names keep old wording and are below the bar for a finding: the test name at test_model_eval.py:305 has "pre_flight", and the docstring at eval.py:261 says "start commands" for a helper that the check command also uses. No user sees them.

Caveats

Narrowed round. The rest of the PR was reviewed at 1ce750a, 09d8885, b4b0c94 and e25ee31 and not re-examined, so this verdict is clean across the five rounds and not in one pass. The contract was checked against the code of the platform change before its merge. No run against a live API was made. The review lanes did not run the tests locally. CI ran them on this head: 15 of 15 checks pass.

Review Ledger

Open findings

  • None.

Prior key statuses

  • roboflow/cli/handlers/eval.py:298:start-commands-read-hints | resolved | closed in round 3: the delta changes only the docstring of the helper, and the not-found branch of _start_hint_for names the training-job:create scope, and both start commands pass it
  • roboflow/cli/handlers/eval.py:268:null-tags-described-as-unchecked | resolved | closed in round 2: _format_tags omits each null tag, and the sentence at CHANGELOG.md:16, CLI-COMMANDS.md:500 and workspace.py:1669 now gives a general rule with the training-version example, which the tag logic of the platform change supports

Unresolved prior open findings

  • None.

Deliberate tradeoffs

  • Create and the compatibility check return a plain dict, as compare_model_evaluations does: author decision, matches workspace.py, rated Minor at most.
  • CLI exit codes 6 (blocked) and 7 (concurrency limit): author decision, extends the 1 to 5 scheme of eval.py, tested, not a finding.
  • version is optional and the server sets the default: author decision, matches the request schema of the platform change.
  • rerun is sent only when true and never on the compatibility check: author decision, needed because that request schema is strict.
  • Leakage and class mismatch are tags and never block, and a same-version eval has null tags: platform design, consumed unchanged.
  • A blocked create has no structured blocks key in the --json error: author decision, CLI-COMMANDS.md says the message lists each block and points to eval check-compatibility --json, rated Minor.
  • Text output omits a null tag, so the deleted-training-version case has no class mismatch line: author decision, stated in CLI-COMMANDS.md:501, rated Minor.
  • rerun is a positional parameter of create_model_evaluation: author decision on preference (round 3), rated Minor.
  • An SDK version such as "v5" gives the generic 400 error of the API: author decision on preference (round 3), the CLI validates the value, rated Minor.
  • The product docs for the new commands are in another repository and are not in this change: author decision (round 3), rated Minor.
  • Before the platform change is live, both commands answer "Endpoint not found." with exit code 3: author decision (round 3), the changelog names both required routes, rated Minor.
  • The test fixtures use a simplified error body, not the exact body of the API: author decision on preference (round 3), rated Minor.
  • With --json, a hint in the error body of the API replaces the hint of the command, so the scope is named in text output only: author decision (round 4), output_error uses setdefault at the merge base (cli/_output.py:166, :171) and the lines are identical at this head, rated Minor.

Refuted

  • The new -v flag collides with the root --version flag: the root flag is on the root callback only, and eval compare uses -v at the base.
  • A 409 on create with no blocks maps to ModelEvalNotDoneError: the create handler of the platform change sends 409 only with a non-empty blocks list.
  • A blocks entry that is not a dict crashes the mapper at rfapi.py:2358: the response schema of the platform change permits dict entries only.
  • The eval-read error mapping changed: the read routes never send blocks or eval_concurrency_limit, and the 404, 409, 401 and 403 branches are the same as the base.
  • Removing the blocked and concurrency branches from _hint_for changes a read command: no read route sends those errors, and eval compare uses _hint_for for access errors only.
  • The blocked error now gets a plan-upgrade hint from the shared output helper: no block message of the platform change matches a plan hint pattern.
  • The rename leaves a stale call site, patch target or route name (round 5): the tree has no use of the old adapter, SDK or CLI name, each test patch target exists, and the platform change registers the same route.
  • The new not-found hint is false for a 404 that is not a scope problem: the hint lists the inputs and the scope as checks and states no single cause, verified for unknown resources, a key of another workspace and a folder-limited key.

Implausible

  • None.

Pre-existing

  • The SDK error message is raw JSON text when the error body has a nested error object: the same lines are in _model_eval_error_for at the merge base (rfapi.py:2341).

A blocked start returns the message in error, the code in code and the
blocks in details.blocks. The concurrency limit returns a nested error
object. The exception types and attributes stay the same.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
@leeclemnet

Copy link
Copy Markdown
Contributor Author

Mega Review

Status: REVIEW-CLEAN @ d3cb3bf · round 6 · narrowed to baf7f14..d3cb3bf

No Critical or Warning finding is open. Not converged yet: one new Minor needs a fix or an acceptance.
Review-clean does not replace typecheck, tests or CI.

✅ Checked in this round

  • The parser reads the new error bodies of the platform change. A blocked start (409 with code and details.blocks) raises ModelEvalBlockedError with the blocks list, exit code 6. The limit of active evals (429 with a nested error object) raises ModelEvalConcurrencyLimitError, exit code 7. Checked against the platform code and with a run of the CLI on each body.
  • The read routes are unchanged for the flat envelope. A not-done 409, a not-found 404 and a bad split give the same exception, message and exit code as at baf7f14.
  • Other bodies are unchanged: plain text, HTML, an empty body, a list, {"error": "<message>"} and a 409 that is not a block.
  • No exception class or attribute changed. ModelEvalBlockedError.blocks, its message format and the status codes are the same.
  • The docstrings are true. Both model_not_ready sentences (workspace.py:1675, workspace.py:1704) agree with the block code of the platform change.

✅ Fixed since last round

  • The SDK message for a nested error object is now the inner message, not raw JSON text. This closes the pre-existing item of the ledger.
  • With --json, eval create and eval check-compatibility now name the training-job:create scope for a 404. This removes the accepted --json hint tradeoff of round 4.

🤨 Non-blocking

  • New: the same parser change at rfapi.py:2343 also changes the released read commands for an error body with a nested error object. str(exc) changes from the JSON text to the inner message. With --json, the error object loses the type key of the API, and the hint of the API gives way to the hint of the command. Text output, exception types and exit codes do not change. No test and no changelog line covers this. Both review lanes found it.
  • Optional, not counted: the ModelEvalBlockedError docstring at rfapi.py:2298 says "HTTP 409 with blocks", and the list is now in details.blocks.

Caveats

Narrowed round. The rest of the PR was reviewed at 1ce750a, 09d8885, b4b0c94, e25ee31 and baf7f14 and not re-examined, so this verdict is clean across the six rounds and not in one pass. The contract was checked against the code of the platform change before its merge. No run against a live API was made. CI on this head: 15 of 15 checks pass.

Review Ledger

Open findings

  • None.

Prior key statuses

  • roboflow/cli/handlers/eval.py:298:start-commands-read-hints | resolved | closed in round 3: the delta changes only the docstring of the helper, and the not-found branch of _start_hint_for names the training-job:create scope, and both start commands pass it
  • roboflow/cli/handlers/eval.py:268:null-tags-described-as-unchecked | resolved | closed in round 2: _format_tags omits each null tag, and the sentence at CHANGELOG.md:16, CLI-COMMANDS.md:500 and workspace.py:1669 now gives a general rule with the training-version example, which the tag logic of the platform change supports

Unresolved prior open findings

  • None.

Deliberate tradeoffs

  • Create and the compatibility check return a plain dict, as compare_model_evaluations does: author decision, matches workspace.py, rated Minor at most.
  • CLI exit codes 6 (blocked) and 7 (concurrency limit): author decision, extends the 1 to 5 scheme of eval.py, tested, not a finding.
  • version is optional and the server sets the default: author decision, matches the request schema of the platform change.
  • rerun is sent only when true and never on the compatibility check: author decision, needed because that request schema is strict.
  • Leakage and class mismatch are tags and never block, and a same-version eval has null tags: platform design, consumed unchanged.
  • A blocked create has no structured blocks key in the --json error: author decision, CLI-COMMANDS.md says the message lists each block and points to eval check-compatibility --json, rated Minor.
  • Text output omits a null tag, so the deleted-training-version case has no class mismatch line: author decision, stated in CLI-COMMANDS.md:501, rated Minor.
  • rerun is a positional parameter of create_model_evaluation: author decision on preference (round 3), rated Minor.
  • An SDK version such as "v5" gives the generic 400 error of the API: author decision on preference (round 3), the CLI validates the value, rated Minor.
  • The product docs for the new commands are in another repository and are not in this change: author decision (round 3), rated Minor.
  • Before the platform change is live, both commands answer "Endpoint not found." with exit code 3: author decision (round 3), the changelog names both required routes, rated Minor.
  • The 403 and 404 test fixtures use a simplified error body, not the exact body of the API: author decision on preference (round 3), rated Minor. The blocked and limit fixtures have the exact body since d3cb3bf.

Refuted

  • The new -v flag collides with the root --version flag: the root flag is on the root callback only, and eval compare uses -v at the base.
  • A 409 on create with no blocks maps to ModelEvalNotDoneError: the create handler of the platform change sends 409 only with a non-empty blocks list.
  • A blocks entry that is not a dict crashes the mapper at rfapi.py:2368: the response schema of the platform change permits dict entries only.
  • The eval-read error mapping changed: the read routes never send blocks or eval_concurrency_limit, and the 404, 409, 401 and 403 branches are the same as the base.
  • Removing the blocked and concurrency branches from _hint_for changes a read command: no read route sends those errors, and eval compare uses _hint_for for access errors only.
  • The blocked error now gets a plan-upgrade hint from the shared output helper: no block message of the platform change matches a plan hint pattern.
  • The rename leaves a stale call site, patch target or route name (round 5): the tree has no use of the old adapter, SDK or CLI name, each test patch target exists, and the platform change registers the same route.
  • The new not-found hint is false for a 404 that is not a scope problem: the hint lists the inputs and the scope as checks and states no single cause, verified for unknown resources, a key of another workspace and a folder-limited key.

Implausible

  • A body with a top-level code that is not a string, or with code and message and no error, gets a worse message (round 6): the platform change sends no such body.

Pre-existing

  • None. The raw JSON message for a nested error object is fixed at d3cb3bf.

The read routes keep their released error text and --json output for a
body with a nested error object. Only create and the compatibility
check read the new bodies.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
@leeclemnet

Copy link
Copy Markdown
Contributor Author

Mega Review

Status: REVIEW-CLEAN @ 1434079 · round 7 · narrowed to d3cb3bf..1434079 · converged after 7 rounds

No finding is open. The Minor of round 6 is fixed.
Review-clean does not replace typecheck, tests or CI.

✅ Fixed since last round

  • The read commands are back to their behavior before this PR. 1434079 reads the nested error object, the top-level code and details.blocks only for the start calls (rfapi.py:2343, rfapi.py:2402). A run of eval get, eval list, eval map-results and eval compare on nine error bodies, in text and --json mode, gives output identical to the merge base. A new test covers the nested body on a read.

✅ Checked in this round

  • The start calls are unchanged from d3cb3bf. A blocked start raises ModelEvalBlockedError with blocks, exit code 6. The limit of active evals raises ModelEvalConcurrencyLimitError, exit code 7. A run of eval create and eval check-compatibility on eleven error bodies gives identical output at both heads.
  • No read goes through the start path. Only create and the compatibility check use the POST helper. Each read uses the GET helper.
  • The docstring is true.

🤨 Non-blocking

  • None new. The accepted author decisions are in the ledger below.
  • Optional, not counted: the ModelEvalBlockedError docstring at rfapi.py:2298 says "HTTP 409 with blocks", and the list is in details.blocks.

Caveats

Narrowed round. The rest of the PR was reviewed at 1ce750a, 09d8885, b4b0c94, e25ee31, baf7f14 and d3cb3bf and not re-examined, so this verdict is clean across the seven rounds and not in one pass. The contract was checked against the code of the platform change before its merge. No run against a live API was made. With --json, eval create and eval check-compatibility name the training-job:create scope for a 404, as at d3cb3bf. CI on this head: 15 of 15 checks pass.

Review Ledger

Open findings

  • None.

Prior key statuses

  • roboflow/cli/handlers/eval.py:298:start-commands-read-hints | resolved | closed in round 3: the delta changes only the docstring of the helper, and the not-found branch of _start_hint_for names the training-job:create scope, and both start commands pass it
  • roboflow/cli/handlers/eval.py:268:null-tags-described-as-unchecked | resolved | closed in round 2: _format_tags omits each null tag, and the sentence at CHANGELOG.md:16, CLI-COMMANDS.md:500 and workspace.py:1669 now gives a general rule with the training-version example, which the tag logic of the platform change supports

Unresolved prior open findings

  • None.

Deliberate tradeoffs

  • Create and the compatibility check return a plain dict, as compare_model_evaluations does: author decision, matches workspace.py, rated Minor at most.
  • CLI exit codes 6 (blocked) and 7 (concurrency limit): author decision, extends the 1 to 5 scheme of eval.py, tested, not a finding.
  • version is optional and the server sets the default: author decision, matches the request schema of the platform change.
  • rerun is sent only when true and never on the compatibility check: author decision, needed because that request schema is strict.
  • Leakage and class mismatch are tags and never block, and a same-version eval has null tags: platform design, consumed unchanged.
  • A blocked create has no structured blocks key in the --json error: author decision, CLI-COMMANDS.md says the message lists each block and points to eval check-compatibility --json, rated Minor.
  • Text output omits a null tag, so the deleted-training-version case has no class mismatch line: author decision, stated in CLI-COMMANDS.md:501, rated Minor.
  • rerun is a positional parameter of create_model_evaluation: author decision on preference (round 3), rated Minor.
  • An SDK version such as "v5" gives the generic 400 error of the API: author decision on preference (round 3), the CLI validates the value, rated Minor.
  • The product docs for the new commands are in another repository and are not in this change: author decision (round 3), rated Minor.
  • Before the platform change is live, both commands answer "Endpoint not found." with exit code 3: author decision (round 3), the changelog names both required routes, rated Minor.
  • The 403 and 404 test fixtures use a simplified error body, not the exact body of the API: author decision on preference (round 3), rated Minor. The blocked and limit fixtures have the exact body since d3cb3bf.
  • The parser takes a start flag, so one helper serves the read calls and the start calls: author decision (round 7), two callers, rated Minor at most.

Refuted

  • The new -v flag collides with the root --version flag: the root flag is on the root callback only, and eval compare uses -v at the base.
  • A 409 on create with no blocks maps to ModelEvalNotDoneError: the create handler of the platform change sends 409 only with a non-empty blocks list.
  • A blocks entry that is not a dict crashes the mapper at rfapi.py:2368: the response schema of the platform change permits dict entries only.
  • The eval-read error mapping changed: the read routes never send blocks or eval_concurrency_limit, and the 404, 409, 401 and 403 branches are the same as the base.
  • Removing the blocked and concurrency branches from _hint_for changes a read command: no read route sends those errors, and eval compare uses _hint_for for access errors only.
  • The blocked error now gets a plan-upgrade hint from the shared output helper: no block message of the platform change matches a plan hint pattern.
  • The rename leaves a stale call site, patch target or route name (round 5): the tree has no use of the old adapter, SDK or CLI name, each test patch target exists, and the platform change registers the same route.
  • The new not-found hint is false for a 404 that is not a scope problem: the hint lists the inputs and the scope as checks and states no single cause, verified for unknown resources, a key of another workspace and a folder-limited key.

Implausible

  • A body with a top-level code that is not a string, or with code and message and no error, gets a worse message on a start call (round 6): the platform change sends no such body.
  • A read gets ModelEvalConcurrencyLimitError for a flat 429 with the eval_concurrency_limit code, or a different message for a message that is not a string (round 7): the read routes send neither body.

Pre-existing

  • The SDK error message of a read call is raw JSON text when the error body has a nested error object: the same behavior is at the merge base, and 1434079 keeps it on purpose. The start calls give the inner message.

This branch has not been deployed

No deployments
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