fix: honor HTTP chat max_tokens limits - #2
Open
kimminhyun-ai wants to merge 1 commit into
Open
Conversation
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.
Map the validated HTTP max_tokens field to the runtime maxTokens option. Previously the request silently used the runtime default of 200. Regression coverage checks 1, 128, 1024 and default 200 for both base and patched calls. Docker typecheck and all 18 guard API tests pass against upstream node source with core commit 701fb58577d118f9edc5d66364f6eb7830bb5cca. The corresponding fix on the local experiment runtime was also verified against the real Qwen model: a 128-token request produced 128 base and 79 patched completion tokens. Semantic benchmark correctness still failed; this PR makes no model accuracy claim.