Skip to content

refactor(config): remove the unread ocr_det_* region profile fields - #182

Merged
davidamacey merged 2 commits into
mainfrom
cleanup/ocr-det-profile-fields-181
Oct 9, 2026
Merged

davidamacey merged 2 commits into
mainfrom
cleanup/ocr-det-profile-fields-181

Conversation

@davidamacey

Copy link
Copy Markdown
Owner

Closes #181

Stacked on #180 (branch cleanup/dead-symbols-174, which deletes PaddleOcrRegionDetector); that PR's commit shows in this diff until it merges. Merge #180 first.

Changes

  • Remove ocr_det_model, ocr_det_version, ocr_det_input_size, ocr_det_prob_floor from DetectionProfile, RegionProfileBody, the license_plate example, docs, tests and contracts (regenerated).
  • Remove their remaining readers: range/multiple-of-32 validation, the ocr_det_model Triton readiness check, the unload guard and promoted-models listing entries, the 'OCR text hint' detector vocabulary entry, and the ocr_det_models choices_from value. The ocr.det_models vocabulary list stays.
  • ocr_engine_id (stamped as region_text_engine_version) is now <rec model>:<version>.
  • A stored or submitted profile still carrying any of the four keys is rejected (profile_field_unknown) with a message naming the key and saying it is retired (RETIRED_PROFILE_FIELDS in profile_registry.py). Tests cover the validate path and the stored-doc load path.
  • Frontend: types, fixtures, e2e stub and contract test updated; CHANGELOGs updated.
  • OCR_DET_MODEL (settings.py / ocr_service.py) is untouched.

Verification

  • Targeted pytest (profile validation, detection profile, region vocabulary/text, config vocabulary, router, unload): 193 passed.
  • Frontend: npm run check 0 errors, npm test 4390 passed.
  • pre-commit run --from-ref origin/main --to-ref HEAD exit 0.

@davidamacey
davidamacey merged commit 3621294 into main Oct 9, 2026
10 checks passed
@davidamacey
davidamacey deleted the cleanup/ocr-det-profile-fields-181 branch October 9, 2026 23:38
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.

cleanup: remove the now-unread DetectionProfile ocr_det_* fields

1 participant