(result: Any)
| 123 | |
| 124 | |
| 125 | def extract_text(result: Any) -> str: |
| 126 | if not result: |
| 127 | return "" |
| 128 | first = result[0] if isinstance(result, list) else result |
| 129 | if isinstance(first, dict): |
| 130 | text = first.get("text", "") |
| 131 | else: |
| 132 | text = str(first) |
| 133 | try: |
| 134 | return rich_transcription_postprocess(text) |
| 135 | except Exception: |
| 136 | return text |
| 137 | |
| 138 | |
| 139 | def write_jsonl(path: Path, rows: Iterable[Dict[str, Any]]) -> None: |
no test coverage detected
searching dependent graphs…