(ToolExecutionResult result)
| 613 | } |
| 614 | |
| 615 | private void emitToolResultSummary(ToolExecutionResult result) { |
| 616 | if (result == null || result.name() == null) { |
| 617 | return; |
| 618 | } |
| 619 | String summary = switch (result.name()) { |
| 620 | case "web_search" -> webSearchSummary(result); |
| 621 | case "web_fetch" -> webFetchSummary(result); |
| 622 | default -> ""; |
| 623 | }; |
| 624 | if (!summary.isBlank()) { |
| 625 | renderer().stream().println(AnsiStyle.subtle(" → " + summary)); |
| 626 | } |
| 627 | } |
| 628 | |
| 629 | private String webSearchSummary(ToolExecutionResult result) { |
| 630 | String text = result.result() == null ? "" : result.result(); |
no test coverage detected