{"type":"begin","data":{"path":{"text":"/home/hyc/projects/agent-sdk/packages/comate_cli/comate_cli/terminal_agent/tool_result_formatters.py"}}}
{"type":"match","data":{"path":{"text":"/home/hyc/projects/agent-sdk/packages/comate_cli/comate_cli/terminal_agent/tool_result_formatters.py"},"lines":{"text":"def _truncate(content: str, max_len: int = 120) -> str:\n"},"line_number":33,"absolute_offset":766,"submatches":[{"match":{"text":"def "},"start":0,"end":4}]}}
{"type":"match","data":{"path":{"text":"/home/hyc/projects/agent-sdk/packages/comate_cli/comate_cli/terminal_agent/tool_result_formatters.py"},"lines":{"text":"def _one_line(value: Any) -> str:\n"},"line_number":39,"absolute_offset":916,"submatches":[{"match":{"text":"def "},"start":0,"end":4}]}}
{"type":"match","data":{"path":{"text":"/home/hyc/projects/agent-sdk/packages/comate_cli/comate_cli/terminal_agent/tool_result_formatters.py"},"lines":{"text":"def _tool_signature(display_name: str, args_summary: str) -> str:\n"},"line_number":43,"absolute_offset":992,"submatches":[{"match":{"text":"def "},"start":0,"end":4}]}}
{"type":"match","data":{"path":{"text":"/home/hyc/projects/agent-sdk/packages/comate_cli/comate_cli/terminal_agent/tool_result_formatters.py"},"lines":{"text":"def _record_signature(rec: ToolResultRecord) -> str:\n"},"line_number":49,"absolute_offset":1154,"submatches":[{"match":{"text":"def "},"start":0,"end":4}]}}
{"type":"match","data":{"path":{"text":"/home/hyc/projects/agent-sdk/packages/comate_cli/comate_cli/terminal_agent/tool_result_formatters.py"},"lines":{"text":"def _agent_signature(rec: ToolResultRecord) -> str:\n"},"line_number":56,"absolute_offset":1443,"submatches":[{"match":{"text":"def "},"start":0,"end":4}]}}
{"type":"match","data":{"path":{"text":"/home/hyc/projects/agent-sdk/packages/comate_cli/comate_cli/terminal_agent/tool_result_formatters.py"},"lines":{"text":"def _json_block(value: Any) -> str:\n"},"line_number":71,"absolute_offset":2065,"submatches":[{"match":{"text":"def "},"start":0,"end":4}]}}
{"type":"match","data":{"path":{"text":"/home/hyc/projects/agent-sdk/packages/comate_cli/comate_cli/terminal_agent/tool_result_formatters.py"},"lines":{"text":"def _relative_time(ts: float) -> str:\n"},"line_number":78,"absolute_offset":2236,"submatches":[{"match":{"text":"def "},"start":0,"end":4}]}}
{"type":"match","data":{"path":{"text":"/home/hyc/projects/agent-sdk/packages/comate_cli/comate_cli/terminal_agent/tool_result_formatters.py"},"lines":{"text":"def _format_metric_duration_ms(value: Any) -> str:\n"},"line_number":87,"absolute_offset":2461,"submatches":[{"match":{"text":"def "},"start":0,"end":4}]}}
{"type":"match","data":{"path":{"text":"/home/hyc/projects/agent-sdk/packages/comate_cli/comate_cli/terminal_agent/tool_result_formatters.py"},"lines":{"text":"def _format_metric_tokens(value: Any) -> str:\n"},"line_number":104,"absolute_offset":2970,"submatches":[{"match":{"text":"def "},"start":0,"end":4}]}}
{"type":"match","data":{"path":{"text":"/home/hyc/projects/agent-sdk/packages/comate_cli/comate_cli/terminal_agent/tool_result_formatters.py"},"lines":{"text":"def _agent_summary_metrics(rec: ToolResultRecord) -> list[str]:\n"},"line_number":120,"absolute_offset":3430,"submatches":[{"match":{"text":"def "},"start":0,"end":4}]}}
{"type":"match","data":{"path":{"text":"/home/hyc/projects/agent-sdk/packages/comate_cli/comate_cli/terminal_agent/tool_result_formatters.py"},"lines":{"text":"def _with_expand_hint(subtitle: str | None, *, show_hint: bool) -> str:\n"},"line_number":142,"absolute_offset":4060,"submatches":[{"match":{"text":"def "},"start":0,"end":4}]}}
{"type":"match","data":{"path":{"text":"/home/hyc/projects/agent-sdk/packages/comate_cli/comate_cli/terminal_agent/tool_result_formatters.py"},"lines":{"text":"def _non_empty_lines(content: str) -> list[str]:\n"},"line_number":151,"absolute_offset":4314,"submatches":[{"match":{"text":"def "},"start":0,"end":4}]}}
{"type":"match","data":{"path":{"text":"/home/hyc/projects/agent-sdk/packages/comate_cli/comate_cli/terminal_agent/tool_result_formatters.py"},"lines":{"text":"def _preview_line_limit(line_count: int, *, max_lines: int = MAX_LINES_TO_RENDER) -> int:\n"},"line_number":155,"absolute_offset":4432,"submatches":[{"match":{"text":"def "},"start":0,"end":4}]}}
{"type":"match","data":{"path":{"text":"/home/hyc/projects/agent-sdk/packages/comate_cli/comate_cli/terminal_agent/tool_result_formatters.py"},"lines":{"text":"def _preview_lines(lines: list[str], *, max_lines: int = MAX_LINES_TO_RENDER) -> list[str]:\n"},"line_number":161,"absolute_offset":4627,"submatches":[{"match":{"text":"def "},"start":0,"end":4}]}}
{"type":"match","data":{"path":{"text":"/home/hyc/projects/agent-sdk/packages/comate_cli/comate_cli/terminal_agent/tool_result_formatters.py"},"lines":{"text":"def _remaining_preview_lines(\n"},"line_number":166,"absolute_offset":4846,"submatches":[{"match":{"text":"def "},"start":0,"end":4}]}}
{"type":"match","data":{"path":{"text":"/home/hyc/projects/agent-sdk/packages/comate_cli/comate_cli/terminal_agent/tool_result_formatters.py"},"lines":{"text":"def _is_truncated_for_expand_hint(line_count: int) -> bool:\n"},"line_number":174,"absolute_offset":5044,"submatches":[{"match":{"text":"def "},"start":0,"end":4}]}}
{"type":"match","data":{"path":{"text":"/home/hyc/projects/agent-sdk/packages/comate_cli/comate_cli/terminal_agent/tool_result_formatters.py"},"lines":{"text":"def _metadata_line_count(metadata: dict[str, Any] | None, key: str) -> int | None:\n"},"line_number":178,"absolute_offset":5154,"submatches":[{"match":{"text":"def "},"start":0,"end":4}]}}
{"type":"match","data":{"path":{"text":"/home/hyc/projects/agent-sdk/packages/comate_cli/comate_cli/terminal_agent/tool_result_formatters.py"},"lines":{"text":"def _message_from_mapping(value: Mapping[str, Any]) -> str | None:\n"},"line_number":185,"absolute_offset":5396,"submatches":[{"match":{"text":"def "},"start":0,"end":4}]}}
{"type":"match","data":{"path":{"text":"/home/hyc/projects/agent-sdk/packages/comate_cli/comate_cli/terminal_agent/tool_result_formatters.py"},"lines":{"text":"def _parse_mapping_text(text: str) -> Mapping[str, Any] | None:\n"},"line_number":199,"absolute_offset":5863,"submatches":[{"match":{"text":"def "},"start":0,"end":4}]}}
{"type":"match","data":{"path":{"text":"/home/hyc/projects/agent-sdk/packages/comate_cli/comate_cli/terminal_agent/tool_result_formatters.py"},"lines":{"text":"def _message_from_labeled_error_text(text: str) -> str | None:\n"},"line_number":216,"absolute_offset":6297,"submatches":[{"match":{"text":"def "},"start":0,"end":4}]}}
{"type":"match","data":{"path":{"text":"/home/hyc/projects/agent-sdk/packages/comate_cli/comate_cli/terminal_agent/tool_result_formatters.py"},"lines":{"text":"def _system_tool_error_message(rec: ToolResultRecord) -> str | None:\n"},"line_number":237,"absolute_offset":6977,"submatches":[{"match":{"text":"def "},"start":0,"end":4}]}}
{"type":"match","data":{"path":{"text":"/home/hyc/projects/agent-sdk/packages/comate_cli/comate_cli/terminal_agent/tool_result_formatters.py"},"lines":{"text":"def _join_subtitle_lines(\n"},"line_number":255,"absolute_offset":7579,"submatches":[{"match":{"text":"def "},"start":0,"end":4}]}}
{"type":"match","data":{"path":{"text":"/home/hyc/projects/agent-sdk/packages/comate_cli/comate_cli/terminal_agent/tool_result_formatters.py"},"lines":{"text":"def _subtitle_with_status_and_preview(\n"},"line_number":267,"absolute_offset":7894,"submatches":[{"match":{"text":"def "},"start":0,"end":4}]}}
{"type":"match","data":{"path":{"text":"/home/hyc/projects/agent-sdk/packages/comate_cli/comate_cli/terminal_agent/tool_result_formatters.py"},"lines":{"text":"def build_tool_subtitle_legacy(\n"},"line_number":284,"absolute_offset":8372,"submatches":[{"match":{"text":"def "},"start":0,"end":4}]}}
{"type":"match","data":{"path":{"text":"/home/hyc/projects/agent-sdk/packages/comate_cli/comate_cli/terminal_agent/tool_result_formatters.py"},"lines":{"text":"def _normalize_diff_line(line: str) -> str:\n"},"line_number":452,"absolute_offset":14907,"submatches":[{"match":{"text":"def "},"start":0,"end":4}]}}
{"type":"match","data":{"path":{"text":"/home/hyc/projects/agent-sdk/packages/comate_cli/comate_cli/terminal_agent/tool_result_formatters.py"},"lines":{"text":"def _diff_code_sample(lines: list[str]) -> str:\n"},"line_number":456,"absolute_offset":14989,"submatches":[{"match":{"text":"def "},"start":0,"end":4}]}}
{"type":"match","data":{"path":{"text":"/home/hyc/projects/agent-sdk/packages/comate_cli/comate_cli/terminal_agent/tool_result_formatters.py"},"lines":{"text":"def _build_diff_syntax(file_path: str | None, lines: list[str]) -> Syntax | None:\n"},"line_number":472,"absolute_offset":15477,"submatches":[{"match":{"text":"def "},"start":0,"end":4}]}}
{"type":"match","data":{"path":{"text":"/home/hyc/projects/agent-sdk/packages/comate_cli/comate_cli/terminal_agent/tool_result_formatters.py"},"lines":{"text":"def _strip_syntax_background(raw_style: object) -> Style | None:\n"},"line_number":490,"absolute_offset":16046,"submatches":[{"match":{"text":"def "},"start":0,"end":4}]}}
{"type":"match","data":{"path":{"text":"/home/hyc/projects/agent-sdk/packages/comate_cli/comate_cli/terminal_agent/tool_result_formatters.py"},"lines":{"text":"def _highlight_code_segment(\n"},"line_number":506,"absolute_offset":16493,"submatches":[{"match":{"text":"def "},"start":0,"end":4}]}}
{"type":"match","data":{"path":{"text":"/home/hyc/projects/agent-sdk/packages/comate_cli/comate_cli/terminal_agent/tool_result_formatters.py"},"lines":{"text":"def render_diff_text(\n"},"line_number":527,"absolute_offset":17095,"submatches":[{"match":{"text":"def "},"start":0,"end":4}]}}
{"type":"match","data":{"path":{"text":"/home/hyc/projects/agent-sdk/packages/comate_cli/comate_cli/terminal_agent/tool_result_formatters.py"},"lines":{"text":"def _diff_summary_subtitle(diff_lines: list[str]) -> str:\n"},"line_number":607,"absolute_offset":19701,"submatches":[{"match":{"text":"def "},"start":0,"end":4}]}}
{"type":"match","data":{"path":{"text":"/home/hyc/projects/agent-sdk/packages/comate_cli/comate_cli/terminal_agent/tool_result_formatters.py"},"lines":{"text":"def scrollback_preview(rec: ToolResultRecord) -> tuple[RenderableType, str | None]:\n"},"line_number":631,"absolute_offset":20472,"submatches":[{"match":{"text":"def "},"start":0,"end":4}]}}
{"type":"match","data":{"path":{"text":"/home/hyc/projects/agent-sdk/packages/comate_cli/comate_cli/terminal_agent/tool_result_formatters.py"},"lines":{"text":"def viewer_list_row(rec: ToolResultRecord, *, selected: bool) -> Text:\n"},"line_number":652,"absolute_offset":21199,"submatches":[{"match":{"text":"def "},"start":0,"end":4}]}}
{"type":"match","data":{"path":{"text":"/home/hyc/projects/agent-sdk/packages/comate_cli/comate_cli/terminal_agent/tool_result_formatters.py"},"lines":{"text":"def viewer_detail(rec: ToolResultRecord) -> list[RenderableType]:\n"},"line_number":672,"absolute_offset":21888,"submatches":[{"match":{"text":"def "},"start":0,"end":4}]}}
{"type":"match","data":{"path":{"text":"/home/hyc/projects/agent-sdk/packages/comate_cli/comate_cli/terminal_agent/tool_result_formatters.py"},"lines":{"text":"def _detail_header(rec: ToolResultRecord) -> Text:\n"},"line_number":688,"absolute_offset":22385,"submatches":[{"match":{"text":"def "},"start":0,"end":4}]}}
{"type":"match","data":{"path":{"text":"/home/hyc/projects/agent-sdk/packages/comate_cli/comate_cli/terminal_agent/tool_result_formatters.py"},"lines":{"text":"def _section(title: str, body: str) -> Text:\n"},"line_number":703,"absolute_offset":22841,"submatches":[{"match":{"text":"def "},"start":0,"end":4}]}}
{"type":"match","data":{"path":{"text":"/home/hyc/projects/agent-sdk/packages/comate_cli/comate_cli/terminal_agent/tool_result_formatters.py"},"lines":{"text":"def _bash_detail(rec: ToolResultRecord) -> list[RenderableType]:\n"},"line_number":712,"absolute_offset":23105,"submatches":[{"match":{"text":"def "},"start":0,"end":4}]}}
{"type":"match","data":{"path":{"text":"/home/hyc/projects/agent-sdk/packages/comate_cli/comate_cli/terminal_agent/tool_result_formatters.py"},"lines":{"text":"def _read_detail(rec: ToolResultRecord) -> list[RenderableType]:\n"},"line_number":747,"absolute_offset":24363,"submatches":[{"match":{"text":"def "},"start":0,"end":4}]}}
{"type":"match","data":{"path":{"text":"/home/hyc/projects/agent-sdk/packages/comate_cli/comate_cli/terminal_agent/tool_result_formatters.py"},"lines":{"text":"def _grep_detail(rec: ToolResultRecord) -> list[RenderableType]:\n"},"line_number":754,"absolute_offset":24691,"submatches":[{"match":{"text":"def "},"start":0,"end":4}]}}
{"type":"match","data":{"path":{"text":"/home/hyc/projects/agent-sdk/packages/comate_cli/comate_cli/terminal_agent/tool_result_formatters.py"},"lines":{"text":"def _glob_detail(rec: ToolResultRecord) -> list[RenderableType]:\n"},"line_number":762,"absolute_offset":25017,"submatches":[{"match":{"text":"def "},"start":0,"end":4}]}}
{"type":"match","data":{"path":{"text":"/home/hyc/projects/agent-sdk/packages/comate_cli/comate_cli/terminal_agent/tool_result_formatters.py"},"lines":{"text":"def _ls_detail(rec: ToolResultRecord) -> list[RenderableType]:\n"},"line_number":766,"absolute_offset":25170,"submatches":[{"match":{"text":"def "},"start":0,"end":4}]}}
{"type":"end","data":{"path":{"text":"/home/hyc/projects/agent-sdk/packages/comate_cli/comate_cli/terminal_agent/tool_result_formatters.py"},"binary_offset":null,"stats":{"elapsed":{"secs":0,"nanos":166971,"human":"0.000167s"},"searches":1,"searches_with_match":1,"bytes_searched":25233,"bytes_printed":13377,"matched_lines":41,"matches":41}}}
{"data":{"elapsed_total":{"human":"0.001376s","nanos":1376028,"secs":0},"stats":{"bytes_printed":13377,"bytes_searched":25233,"elapsed":{"human":"0.000167s","nanos":166971,"secs":0},"matched_lines":41,"matches":41,"searches":1,"searches_with_match":1}},"type":"summary"}
