Skip to content

Bug: Chat.append fails with multi-part tool result messages #109

@ncoghlan

Description

@ncoghlan

(Reported in Discord)

When multi-part tool result messages were added, Chat.add_entry was not updated, so tool messages are still checked to ensure they have exactly one entry in their content list. That's not correct, so passing chat.append to model.act will fail if the LLM generates two or more tool call requests in a single response (as the results of those calls get combined into a single multi-part response, which then fails to be appended).

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions