Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Trim trailing comma on tool calls #1229

Merged
merged 2 commits into from
May 31, 2024
Merged

Trim trailing comma on tool calls #1229

merged 2 commits into from
May 31, 2024

Conversation

Saghen
Copy link
Contributor

@Saghen Saghen commented May 30, 2024

The model likes to return trailing commas on the tool calls which JSON5 rejects. This trims the comma and adds a clearer message for the client for when tool call parsing fails

@Saghen Saghen requested review from gary149 and nsarrazin May 30, 2024 22:19
@Saghen Saghen self-assigned this May 30, 2024
@nsarrazin nsarrazin merged commit 203e1c0 into main May 31, 2024
3 checks passed
@nsarrazin nsarrazin deleted the feat/trim-trailing-comma branch May 31, 2024 08:46
ice91 pushed a commit to ice91/chat-ui that referenced this pull request Oct 30, 2024
* feat: trim trailing comma on tools results

* feat: clearer tool call parsing failure message
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants