Spec 003: model configuration, and why the quirks must not be configured - #190
Merged
Conversation
Answers a question asked directly: switching models needs "something to configure it with". Half right, and the wrong half is the expensive one. Which model to use is a choice -- it differs per deployment and soon per surface, and belongs in config.yml beside profiles and quotas. How a model must be CALLED is a fact: gpt-5.6-luna accepts only temperature 1 and refuses function tools on /v1/chat/completions, gpt-4o-mini wants 0.0. Making a fact configurable adds no flexibility, only a way to be wrong, and the failure lands on a user's first question rather than when the mistake is made. The evidence is one commit old: that table was written with full attention and was wrong for eleven models (#189). So the spec is: configure the choice, derive the consequences, validate the pair before the server takes traffic. Two contributed PRs are the starting material -- #112 (@AaryanCode69) and #151 (@bhavyakeerthi3), two people independently hitting the same gap. #112's structure is the better base. Both contain the same serious defect, recorded in the spec. Both make the EMBEDDING model configurable and pass it straight to get_embedding, bypassing resolve_embedding_model(), which reads the model from the bundle path because a query embedded with a different model than built the vectors returns nonsense rather than an error. #112's config_default.yml pins text-embedding-3-large; applied to Plant Reactome that is the bge-m3 bug again from the other direction, and silent. FR-004 makes the embedding model permanently non-configurable. One decision left to the team: whether startup validates against the table alone or spends an API call. Recommendation is the table -- the pairing mistake is the one being made, and a mistyped model name fails obviously anyway. Spec 002's User Story 3 is marked superseded by this file.
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.
Answers a question asked directly: switching models needs "something to configure it with". Half right — and the wrong half is the expensive one.
Which model to use is a choice. Differs per deployment and soon per surface. Belongs in
config.yml.How a model must be called is a fact.
gpt-5.6-lunaaccepts onlytemperature=1and refuses function tools on/v1/chat/completions;gpt-4o-miniwants0.0. Making a fact configurable adds no flexibility — only a way to be wrong, with the failure landing on a user's first question rather than when the mistake was made.The evidence is one commit old: that temperature table was written with full attention on it and was wrong for eleven models (#189). An operator editing YAML has no better information and less context.
Two contributed PRs to harvest
ModelsConfig→LLMConfig/EmbeddingConfigllm: "openai/gpt-4o-mini"#112's structure is the better base — named fields, and
base_urlmatters for Plant Reactome.Both contain the same serious defect
Both make the embedding model configurable and pass it straight to
get_embedding, bypassingresolve_embedding_model().That function exists because a query embedded with a different model than built the stored vectors returns nonsense rather than an error. It reads the model from the bundle path, the only durable source of truth. It was written because a hardcoded
bge-m3default broke every fresh Reactome deployment while being correct for Plant Reactome.#112's
config_default.ymlpinsembedding.model: text-embedding-3-large. Applied to Plant Reactome that is thebge-m3bug again from the other direction — and silent, because a wrong embedding model does not error, it just retrieves the wrong documents.FR-004 makes the embedding model permanently non-configurable. The LLM half of both PRs is harvested, with credit to both contributors.
One decision for the team
D1 — does startup validate against the API, or only against the table? Recommendation: the table. It catches the pairing mistake for free and offline; a mistyped model name is a different, more obvious failure that no one will be confused by.
Spec 002's User Story 3 is marked superseded by this file.