Skip to content
Merged
Changes from all commits
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
9 changes: 1 addition & 8 deletions src/frontend_visualqa/schemas.py
Original file line number Diff line number Diff line change
Expand Up @@ -213,14 +213,7 @@ def validate_claims(cls, value: list[str]) -> list[str]:
def normalize_claim_navigation_hints(cls, value: list[str | None] | None) -> list[str | None] | None:
if value is None:
return None
normalized: list[str | None] = []
for hint in value:
if hint is None:
normalized.append(None)
continue
stripped = hint.strip()
normalized.append(stripped or None)
return normalized
return [None if hint is None else (hint.strip() or None) for hint in value]

@model_validator(mode="after")
def validate_claim_navigation_hint_alignment(self) -> "VerifyVisualClaimsInput":
Expand Down