fix(ai): buffer partial tool call identity (#37847)

Co-authored-by: Aiden Cline <rekram1-node@users.noreply.github.com>
This commit is contained in:
opencode-agent[bot] 2026-07-19 22:12:49 -05:00 committed by GitHub
commit 2b8d1998d6
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
4 changed files with 117 additions and 3 deletions

View file

@ -140,8 +140,8 @@ export const appendOrStart = <K extends StreamKey>(
missingToolMessage: string,
): AppendOutcome<K> | LLMError => {
const current = tools[key]
const id = delta.id ?? current?.id
const name = delta.name ?? current?.name
const id = current?.id ?? delta.id
const name = current?.name ?? delta.name
if (!id || !name) return eventError(route, missingToolMessage)
const tool = {