fix(models)!: always prefix models with provider_id when registering (#3822)

**!!BREAKING CHANGE!!**

The lookup is also straightforward -- we always look for this identifier
and don't try to find a match for something without the provider_id
prefix.

Note that, this ideally means we need to update the `register_model()`
API also (we should kill "identifier" from there) but I am not doing
that as part of this PR.

## Test Plan

Existing unit tests
This commit is contained in:
Ashwin Bharambe 2025-10-16 06:47:39 -07:00 committed by GitHub
parent f205ab6f6c
commit f70aa99c97
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
10 changed files with 53 additions and 124 deletions

View file

@ -12,26 +12,7 @@
"body": {
"__type__": "ollama._types.ProcessResponse",
"__data__": {
"models": [
{
"model": "llama-guard3:1b",
"name": "llama-guard3:1b",
"digest": "494147e06bf99e10dbe67b63a07ac81c162f18ef3341aa3390007ac828571b3b",
"expires_at": "2025-10-13T14:07:12.309717-07:00",
"size": 2279663616,
"size_vram": 2279663616,
"details": {
"parent_model": "",
"format": "gguf",
"family": "llama",
"families": [
"llama"
],
"parameter_size": "1.5B",
"quantization_level": "Q8_0"
}
}
]
"models": []
}
},
"is_streaming": false