Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Merge dev into fix/391-collection-one-value
  • Loading branch information
scratch authored and sromoam committed Dec 3, 2026
commit ce2e8f226d65bfd45f25fc0607466e15f347943c
Original file line number Diff line number Diff line change
Expand Up @@ -861,7 +861,18 @@ def _install_object_grade_comparators(cls) -> None:
# comparator at definition time changes what `to_json_schema()` exports
# for that shape -- which is exactly the reader alignment this branch is
# for. All four object-grade shapes now take the one path.
#
if ConfigurationHelper.is_list_of_structured_models(field_info):
# `List[StructuredModel]` takes the object-grade clip default
# but keeps its own matcher, so only the clip is amended. Written
# here so `to_json_schema()` exports the clip the engine uses and
# a round trip does not turn clipping on (#415).
extra = getattr(field_info, "json_schema_extra", None)
if callable(extra):
clip = ConfigurationHelper.object_grade_clip(extra)
if clip != getattr(extra, "_clip_under_threshold", True):
_amend_clip_default(field_info, extra, clip)
continue

# A tuple, set or frozenset, or a list of one, gets ExactComparator
# (#659, #391). It is deliberately NOT object-grade: ANLS* reads a tuple as
# one of several allowed answers, so `(1, 2)` against `(2, 1)` scored
Expand Down
You are viewing a condensed version of this merge commit. You can view the full changes here.