(data: MothershipStreamV1ToolCallDescriptor)
| 172 | * hidden }`; presentation (title/icon) is derived client-side from the tool name. |
| 173 | */ |
| 174 | export function getToolCallUI(data: MothershipStreamV1ToolCallDescriptor): { |
| 175 | clientExecutable: boolean |
| 176 | simExecutable: boolean |
| 177 | internal: boolean |
| 178 | hidden: boolean |
| 179 | } { |
| 180 | const raw = asRecord(data.ui) |
| 181 | return { |
| 182 | clientExecutable: |
| 183 | raw.clientExecutable === true || data.executor === MothershipStreamV1ToolExecutor.client, |
| 184 | simExecutable: data.executor === MothershipStreamV1ToolExecutor.sim, |
| 185 | internal: raw.internal === true, |
| 186 | hidden: raw.hidden === true, |
| 187 | } |
| 188 | } |
| 189 | |
| 190 | /** |
| 191 | * Handle the completion signal from a client-executable tool. |
no test coverage detected