-
Notifications
You must be signed in to change notification settings - Fork 22.2k
model: add Hy3 (hy_v3) support with MTP speculative decoding #25395
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
Merged
Merged
Changes from all commits
Commits
Show all changes
9 commits
Select commit
Hold shift + click to select a range
a1cc3a5
model: add Hy3 (hy_v3) architecture support
claude f370e03
model: add MTP/nextn speculative decoding for hy_v3
claude 6105ebb
convert: add HYV3ForCausalLM (hy_v3) with MTP block export
claude 97181b7
tests : mark hy_v3 as MoE-mandatory in test-archs
claude 692d171
jinja : add str.format() support
pwilkin 56142c5
chat : detect separator between function name and arguments in autopa…
pwilkin d81d886
jinja: simplify format() to '{}' only; fix template dashes
satindergrewal cecbf5f
jinja: reduce format() scan to a single '{' + '}' check
satindergrewal a00f69a
jinja: validate int() base to avoid MSVC CRT fail-fast
satindergrewal File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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
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
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
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
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
Oops, something went wrong.
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't feel comfortable merging this large function (presumably fully AI-written) without proper considering and reviewing. a quick analyze with claude already brought up some problems that I won't mention here.
the template uses nothing other than simple
{}, better to skip all other cases and thrownot_implemented_exceptionfor themThere was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fair enough. Done exactly that as per your recommendation.
format()now handles only simple{}and throwsnot_implemented_exceptionfor indexed/named/spec fields.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you're doing it the over-complicated way
simply check if
{is directly followed by}There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done in cecbf5f. The scan now only checks whether
{is directly followed by}; any other character after{throwsnot_implemented_exception. Brace-escape handling, field extraction and the kwarg filtering are deleted (39 lines down to 6). The unsupported-form tests in test-jinja.cpp are left as Python reference behavior since the cpp harness already skipsnot_implementedcases.