(timestamp, sessionId, id, name, input = {})
| 66 | } |
| 67 | |
| 68 | function toolUse(timestamp, sessionId, id, name, input = {}) { |
| 69 | return { |
| 70 | timestamp, |
| 71 | sessionId, |
| 72 | type: 'assistant', |
| 73 | message: { |
| 74 | role: 'assistant', |
| 75 | content: [ |
| 76 | { |
| 77 | type: 'tool_use', |
| 78 | id, |
| 79 | name, |
| 80 | input, |
| 81 | }, |
| 82 | ], |
| 83 | }, |
| 84 | }; |
| 85 | } |
| 86 | |
| 87 | function toolResult(timestamp, sessionId, toolUseId, content = 'ok') { |
| 88 | return { |