Conversation
The bundled llama.cpp webui never sends `model` on /v1/chat/completions - it treats the server as single-model and takes the name from /props. The parser rejected that with 400 "missing required field: model", so every message typed into the UI served by --webui failed, whatever --model-id the server ran with. An absent model now leaves the field empty and the handler fills in the loaded artifact's public id before validation. A model that is present but does not match is still rejected, and `"model": ""` still fails as before. Verified on Windows 11 + RTX 5090 Laptop against the QUASAR v3 artifact: the webui at / now answers, and a curl POST without the field returns model=qwen3.8-27b. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
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.
The bundled llama.cpp webui never sends
modelon/v1/chat/completions— it treats the server as single-model and takes the display name from/props. The parser rejects that withso every message typed into the UI served by
--webuifails. It is not a stale-cache or webui-version problem: I reproduced it on both published bucket versions (1789559630374and1789652224694), in two browsers, and with--model-idset to the id the UI had listed from/v1/models.This PR makes an absent
modelleave the field empty;handle_chat_completionsfills inpublic_model_id_beforevalidate_openai_model. Unchanged: a model that is present but does not match is still rejected,"model": ""and a non-string model still fail, and the Anthropic and Responses paths are untouched.Verified on Windows 11 x64, RTX 5090 Laptop, against the QUASAR v3 artifact:
/: message sent, answer rendered,POST /v1/chat/completionsreturns 200 instead of 400;curlwithout the field returns"model":"qwen3.8-27b"in the response body;curlwith a wrong model still returnsmodel_not_found.Builds on
cometkim/dev@024f6a94. Independent of #2 (the Windows--webuidownload fix), though on Windows you need both before the UI can be reached at all.🤖 Generated with Claude Code