Treat non-string research summaries as low quality
Filter malformed non-string research summaries instead of letting the broad exception path classify them as usable, with regression coverage.
This commit is contained in:
@@ -55,7 +55,7 @@ LOW_QUALITY_MARKERS = [
|
||||
def is_low_quality(summary: str) -> bool:
|
||||
"""Check if a finding summary indicates useless or irrelevant content."""
|
||||
try:
|
||||
if not summary:
|
||||
if not isinstance(summary, str) or not summary:
|
||||
return True
|
||||
low = summary.lower()
|
||||
return any(marker in low for marker in LOW_QUALITY_MARKERS)
|
||||
|
||||
Reference in New Issue
Block a user