(chunks: list[dict], limit: int)
| 275 | |
| 276 | |
| 277 | def first_chunks(chunks: list[dict], limit: int) -> list[dict]: |
| 278 | return [ |
| 279 | { |
| 280 | "claim": normalize_whitespace(str(item.get("text", ""))), |
| 281 | "evidence": normalize_whitespace(str(item.get("text", ""))), |
| 282 | "source_section": normalize_whitespace(str(item.get("source_section", ""))), |
| 283 | "page_hint": normalize_whitespace(str(item.get("page_hint", ""))), |
| 284 | } |
| 285 | for item in chunks[:limit] |
| 286 | if normalize_whitespace(str(item.get("text", ""))) |
| 287 | ] |
| 288 | |
| 289 | |
| 290 | def keyword_chunks( |
nothing calls this directly
no test coverage detected