(name: string, input: Record<string, unknown>)
| 89 | } |
| 90 | |
| 91 | function toolSummary(name: string, input: Record<string, unknown>): string { |
| 92 | const verb = TOOL_VERBS[name] ?? name |
| 93 | const target = |
| 94 | (input.file_path as string) ?? |
| 95 | (input.filePath as string) ?? |
| 96 | (input.pattern as string) ?? |
| 97 | (input.command as string | undefined)?.slice(0, 60) ?? |
| 98 | (input.url as string) ?? |
| 99 | (input.query as string) ?? |
| 100 | '' |
| 101 | if (target) { |
| 102 | return `${verb} ${target}` |
| 103 | } |
| 104 | return verb |
| 105 | } |
| 106 | |
| 107 | function extractActivities( |
| 108 | line: string, |