(text: str)
| 2221 | |
| 2222 | |
| 2223 | def extract_metric_claims(text: str) -> list[str]: |
| 2224 | claims: list[str] = [] |
| 2225 | seen = set() |
| 2226 | for sentence in split_sentences(text): |
| 2227 | lower = sentence.lower() |
| 2228 | if not re.search(r"\d", sentence): |
| 2229 | continue |
| 2230 | if not any(token in lower for token in ["accuracy", "f1", "auc", "auprc", "mae", "rmse", "score", "%", "outperform", "improv", "bac"]): |
| 2231 | continue |
| 2232 | normalized = normalize_whitespace(sentence) |
| 2233 | key = normalize_title(normalized) |
| 2234 | if key in seen: |
| 2235 | continue |
| 2236 | seen.add(key) |
| 2237 | claims.append(normalized) |
| 2238 | if len(claims) >= 8: |
| 2239 | break |
| 2240 | return claims |
| 2241 | |
| 2242 | |
| 2243 | def extract_negative_claims(text: str, *, limit: int = 6) -> list[str]: |
no test coverage detected