Fix call ID detection (Mistral parser mostly) + atomicity for tag-json parsers#21230
Merged
pwilkin merged 3 commits intoggml-org:masterfrom Apr 3, 2026
Merged
Fix call ID detection (Mistral parser mostly) + atomicity for tag-json parsers#21230pwilkin merged 3 commits intoggml-org:masterfrom
pwilkin merged 3 commits intoggml-org:masterfrom
Conversation
|
Tried current master, I saw < /s > still being generated at the end of the content (if i remember correctly that's what broke many things before). Then applied this patch, and it was gone. After that, I loaded the mistral 3.2 small model in Roo code (llama server) and did some tool calls in native mode, it all worked alright. Thanks for the fix! |
Member
Author
|
Bump, as evidenced above this fixes the issue, so would appreciate some reviews :) |
ggerganov
reviewed
Apr 3, 2026
common/chat.h
Outdated
| const std::optional<json> & tools_override = std::nullopt, | ||
| const std::optional<json> & additional_context = std::nullopt); | ||
|
|
||
| std::optional<common_chat_params> try_specialized_template( |
Member
There was a problem hiding this comment.
I can't review the rest, just noticed this function can be named better:
Suggested change
| std::optional<common_chat_params> try_specialized_template( | |
| std::optional<common_chat_params> common_chat_try_specialized_template( |
c0746e7 to
ed9aa13
Compare
Member
Author
Co-authored-by: Sigbjørn Skjæret <sigbjorn.skjaeret@scala.com>
aldehir
approved these changes
Apr 3, 2026
icex
added a commit
to icex/llama.cpp
that referenced
this pull request
Apr 5, 2026
Includes: - server: Fix undefined timing measurement errors (ggml-org#21201) - server: save and clear idle slots on new task --clear-idle (ggml-org#20993) - common: fix tool call type detection for nullable/enum schemas (ggml-org#21327) - CUDA: fix FA kernel selection logic (ggml-org#21271) - kv-cache: do not quantize SWA KV cache (ggml-org#21277) + revert (ggml-org#21332) - common/parser: fix call ID detection + atomicity (ggml-org#21230) - jinja: coerce input for string-specific filters (ggml-org#21370) - Various CI, HIP, WebGPU, and documentation fixes
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Overview
Fix autoparser handling of call ID section detection
Additional information
Should fix handling of old Mistral templates
Requirements