Skip to content

chat : Fix Muse Glimmer tool-call first parser error - #29242

Merged
pwilkin merged 4 commits into
ggml-org:masterfrom
NickM-27:glimmer-parser-fail
Sep 22, 2026
Merged

pwilkin merged 4 commits into
ggml-org:masterfrom
NickM-27:glimmer-parser-fail

Conversation

@NickM-27

Copy link
Copy Markdown
Contributor

Overview

This PR fixes an error with Muse Glimmer when the turn started immediately as a tool call with no reasoning step.

Additional information

fixes #29240

This is similar to an behavior that GPT-OSS has and is handled by the parser

Requirements

  • I have read and agree with the contributing guidelines
  • AI usage disclosure: YES, used Opus 5 to diagnose the issue and implement the fix + a test to validate it.

@NickM-27
NickM-27 requested review from a team and pwilkin as code owners September 21, 2026 17:30
@github-actions github-actions Bot added the testing Everything test related label Sep 21, 2026
@ggml-gh-bot

ggml-gh-bot Bot commented Sep 21, 2026

Copy link
Copy Markdown

Hi @NickM-27, thanks for your contribution!

Per our contribution guidelines, the automated PR checker found the following issue(s) that need your attention:

  • Multiple open PRs from a new contributor: We limit new contributors (those without a previously merged PR) to 1 open PR at a time. You currently have 2 open PRs.

Please note that maintainers reserve the right to make final decisions on PRs. If you believe there is a mistake, please comment below.

@NickM-27

Copy link
Copy Markdown
Contributor Author

Happy to mark this as a draft if desired, but to be clear I do already have a PR merged that has been merged.

@aldehir

aldehir commented Sep 21, 2026

Copy link
Copy Markdown
Contributor

You can condense this to one rule:

-              "^( to=(?!self<\\|message\\|>)(?!user<\\|message\\|>)[^<]*?<\\|message\\|>)" },
-            { COMMON_GRAMMAR_TRIGGER_TYPE_PATTERN,
-              "<\\|start\\|>assistant( to=(?!self<\\|message\\|>)(?!user<\\|message\\|>)[^<]*?<\\|message\\|>)" },
+              "(?:^|<\\|start\\|>assistant)( to=(?!self<\\|message\\|>)(?!user<\\|message\\|>)[^<]*?<\\|message\\|>)" },

Comment thread tests/test-chat.cpp Outdated

@aldehir aldehir left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you!

@pwilkin
pwilkin merged commit 7ab4ee7 into ggml-org:master Sep 22, 2026
12 checks passed
@NickM-27
NickM-27 deleted the glimmer-parser-fail branch September 22, 2026 13:05
LadislavSopko pushed a commit to 0ics-srls/llama.cpp that referenced this pull request Oct 5, 2026
* Fix Muse Glimmer tool-call first parser error

* Add test to verify

* Condense patterns

* remove test for trigger patterns
frostyautumnleaf pushed a commit to frostyautumnleaf/llama.cpp that referenced this pull request Oct 5, 2026
* Fix Muse Glimmer tool-call first parser error

* Add test to verify

* Condense patterns

* remove test for trigger patterns
edwardyoon pushed a commit to edwardyoon/focus-llama that referenced this pull request Oct 7, 2026
* Fix Muse Glimmer tool-call first parser error

* Add test to verify

* Condense patterns

* remove test for trigger patterns

(cherry picked from commit 7ab4ee7)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

testing Everything test related

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Eval bug: Muse Glimmer unparsed peg-negative output

3 participants