Repository navigation
fix: drop stale Ollama tags, and make add_models.py the catalog's only source - #15
Merged
Merged
Conversation
The weekly catalog check (#13) found nine tags that 404 on the registry. llmspec prints each one as the command to run, so every one of them was an `ollama pull` that fails for whoever follows it. `falcon:11b` moved: the same TII Falcon2 11B is now `falcon2:11b`. The other eight have no tag that is the same model, so they carry none rather than one that downloads something else. `qwen3-coder` ships only 30b-a3b and 480b, and `ministral-3:8b` is the 2512 model, not the 2410 one in the catalog. Phi-3 Small, Phi-3.5 MoE, Pixtral 12B, Mistral-NeMo-Minitron 8B and Llama 3.1 8B Enigma have no library tag at all. The records are edited in models.json directly. Re-running add_models.py would also strip the geometry later added to 139 records it still holds in an older form, so only the Ministral entry it owns is corrected there, to keep a future run from bringing the tag back. Closes #13 Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01MEBVX7k9mwJAxtHefcqWcm
The previous commit had to edit data/models.json by hand, because running scripts/add_models.py would have reverted 72 records. That is the defect behind it: the catalog had two sources and nothing kept them in step. The script held 139 of the 240 records and replaced each one wholesale on every run. After it was last touched, the geometry pass (checked against each model's config.json) and a round of corrections went straight into the JSON: 64 records gained geometry, and 19 values changed — context lengths such as CodeLlama 70B's 4096, `kv_heads` for DeepSeek Coder 33B and GLM-4 9B, DeepSeek V3 0324's MIT license, and `deepseek-r1:8b` moving to the 0528 distill. Running the script as documented would have undone all of it. The other 101 records were never in the script, so "fix it through add_models.py" — what the catalog check's issue tells you to do — could not be followed for 8 of the 9 tags in #13. Now: - The script holds all 240 records. The 72 that drifted were regenerated from the JSON, which is newer in every case; the 101 it lacked are added under a seed-catalog section. Running it leaves data/models.json byte-identical. - It generates the whole catalog: a record without an entry is dropped, so deleting an entry deletes the record. - Records keep their positions across runs before the stable sort, since runtime-tag lookups take the first match and 30 groups tie on the key. - `--check` exits non-zero and names each drifted record and field. CI runs it as its own job and the pre-commit hook runs it too. - It writes bytes, so a run on Windows no longer turns the file to CRLF. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01MEBVX7k9mwJAxtHefcqWcm
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.
Closes #13.
1. The nine stale tags
All nine tags from the catalog check return 404 from
registry.ollama.ai, rechecked today.falcon:11bfalcon2:11bqwen3-coder:32b30b(A3B) and480bqwen3-coder:8bministral:8bministral-3:8bis the 2512 model, not 2410phi3:7bphi3has only mini and mediumphi3.5:moephi3.5has only minipixtral:12bminitron:8benigma:8bNo tag is better than one that downloads a different model.
2. Why that had to be a hand edit, and the fix
scripts/add_models.pyanddata/models.jsonhad drifted apart, and running the script as documented would have reverted 72 records.Root cause: the catalog had two sources and nothing kept them in step. The script held 139 of 240 records and replaced each wholesale on every run. After it was last touched (2026-08-23), the geometry pass and a round of corrections went straight into the JSON (2026-08-24):
layers/hidden_size/kv_heads/head_dimkv_heads56 → 8, GLM-4 9Bkv_heads4 → 2, DeepSeek V3 0324 license → MIT,deepseek-r1:8bmoved to the 0528 Qwen3 distillThe other 101 records were never in the script at all, so the issue's own instruction ("fix a tag through
add_models.py") could not be followed for 8 of these 9 tags.Fix (66f8076):
data/models.jsonbyte-identical, which this PR verifies.find/find_for_runtimetake the first match, and 30 groups tie on (provider, params), so reshuffling ties would silently change lookups.python scripts/add_models.py --checkexits non-zero and names each drifted record and field. It runs as a new Catalog CI job and in the pre-commit hook.--checkwas exercised against a hand-edited catalog (a changed field plus an added record); it reported both and exited 1.Tests
286 cargo tests pass; clippy, fmt and the catalog check are clean.
🤖 Generated with Claude Code
https://claude.ai/code/session_01MEBVX7k9mwJAxtHefcqWcm