Repository navigation
fix: subir el limite de salida de 16k a 32k (v1.0.4) - #5
Merged
Merged
Conversation
OpenCode forwards limit.output as max_completion_tokens, so the hardcoded 16,384 capped every Command Code response regardless of what the model supports. The DeepSeek V4.1 Flash 1017 build declares 393,216 output tokens. - Default is now 32,768, the highest value safe across the whole catalog: the minimum declared output in models.dev's commandcode provider is exactly 32,768. - COMMANDCODE_OUTPUT_TOKENS overrides it per process (verified: 131072 reaches the wire as max_completion_tokens). - The 28 static model entries in opencode.json carried output: 16384, which won over the plugin; the limits are now owned by the plugin alone. - Verified end to end with a local echo provider: default 32768, override 131072.
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.
Problema
OpenCode envia
limit.outputcomomax_completion_tokens, y el plugin lo tenia fijo en 16.384 para todos los modelos. Eso capaba cada respuesta, aunque el catalogo soporta mucho mas (el build DeepSeek V4.1 Flash 1017 declara 393.216 de salida).Ademas, los 28 modelos estaticos de
opencode.jsonllevabanoutput: 16384, que ganaba sobre el plugin.Solucion
commandcodede models.dev es exactamente 32.768 (Qwen3.8-27B y Ling 3.1 Flash).COMMANDCODE_OUTPUT_TOKENSlo sobreescribe por proceso.Verificacion
max_completion_tokens: 32768por defecto y131072con el overridebun test: 84 pass / 0 failbun run typechecklimpio