fix: removed aggressive string splitting on dashes which truncated sentences and hid metrics (Greilmeier bug)

This commit is contained in:
2026-01-23 21:39:43 +00:00
parent f3ca139d85
commit 13119b0e8a

View File

@@ -79,9 +79,9 @@ class MetricParser:
for c in currencies:
text_processed = re.sub(f'(?i){c}', '', text_processed).strip()
# 4. Handle ranges: "80 - 100" -> "80"
text_processed = re.split(r'\s*(-||bis|to)\s*', text_processed, 1)[0].strip()
# 4. Remove Range Splitting (was too aggressive, cutting off text after dashes)
# Old: text_processed = re.split(r'\s*(-||bis|to)\s*', text_processed, 1)[0].strip()
# 5. Extract Multipliers (Mio, Mrd)
multiplier = 1.0
lower_text = text_processed.lower()