(buf)
| 1098 | // 50 tool_call_choice → {1=repeated ChatToolCall, 2=choice, 3=reason} |
| 1099 | // ChatToolCall (codeium_common_pb): 1=id, 2=name, 3=arguments_json |
| 1100 | const parseChatToolCall = (buf) => { |
| 1101 | const f = parseFields(buf); |
| 1102 | const id = getField(f, 1, 2); |
| 1103 | const name = getField(f, 2, 2); |
| 1104 | const args = getField(f, 3, 2); |
| 1105 | return { |
| 1106 | id: id ? id.value.toString('utf8') : '', |
| 1107 | name: name ? name.value.toString('utf8') : '', |
| 1108 | argumentsJson: args ? args.value.toString('utf8') : '', |
| 1109 | }; |
| 1110 | }; |
| 1111 | const customField = getField(sf, 45, 2); |
| 1112 | if (customField) { |
| 1113 | const cf = parseFields(customField.value); |
no test coverage detected