fix: cloudflare-workers-ai: glm-5.3-flash limit 1310720 exceeds gateway max 1048576 (same as #4422 for glm-5.2) - #5825
Merged
Merged
Conversation
…ay max 1048576 (same as #4422 for glm-5.2)
|
it seems like this got partially reverted by the auto update - pi should be ok now but just flagging for posterity |
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.
Summary
Cloudflare Workers AI
@cf/zai-org/glm-5.3-flashhadlimit.context/limit.outputset to 1,310,720, which comes from catalog/search data and is above AI Gateway’s max (max_completion_tokens≤ 1,048,576). Clients that derivemax_tokensfrom catalog output (e.g. pi) then get HTTP 400. Limits are corrected to match Cloudflare’s documented context window.Changes
File:
providers/cloudflare-workers-ai/models/@cf/zai-org/glm-5.3-flash.tomllimit.context1_310_7201_048_576limit.output1_310_7201_048_576Leading comment notes the gateway cap and docs source.
Evidence
max_completion_tokens is too large: 1298829. This model supports at most 1048576— confirms gateway output max is 1,048,576, not 1,310,720.glm-5.2(catalog inflated limit → host-safe value).Lab
models/zhipuai/glm-5.3-flash.toml(context = 1_000_000,output = 131_072) was left unchanged; this is a Cloudflare host constraint, not a lab metadata correction.Validation
bun validateor live API calls (no shell per instructions).Review notes
providers/cloudflare-workers-ai/models/@cf/zai-org/glm-5.3.toml, which still has1_310_720/1_310_720and the same Cloudflare docs pattern (1,048,576 context). Out of scope for cloudflare-workers-ai: glm-5.3-flash limit 1310720 exceeds gateway max 1048576 (same as #4422 for glm-5.2) #5824; may need a follow-up.Closes #5824
Automated by the issue fixer: https://github.com/anomalyco/models.dev/actions/runs/33266781527