-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
bug: Mismatch ID between model.json and folder path #3476
Comments
There is an edge case where a customized OpenAI-compatible remote model could have a |
@louis-jan @marknguyen1302 I think Model Folder detection and maintenance is going to important for Jan + Cortex to get right. We currently have 3 main model sources: Nitro
Cortex
What is our current logic that we currently use for Model detection, in the Model Folder? We should be really careful - I probably screwed up asking for folder names to be part of the design, and this will break in all sorts of ways cross-OS. |
@louis-jan @marknguyen1302 Additionally, to prepare for our upcoming Cortex migration, can we write test coverage for our existing Model Folder (i.e. all the variants we have, local, remote, etc). I think we need to make sure we don't break for existing users, and whatever patchwork of assumptions, edge cases are accounted for, before we make changes. We will likely need to do extensive Upgrade Testing, i.e. to make sure we don't break existing functionality for users. Jan is pretty much a single feature tool now: i.e. download models to our folder structure and run them. Investing in test coverage for this critical functionality will give us a stable base to build off in the longer term |
@louis-jan @imtuyethan @urmauur Quick check: will we do a hotfix for this in v0.5.4? |
Yeah, we should right? There still a long way to do a full cortex.cpp migration. I can take this. |
After investigation, both the model's ID generation and retrieving a folder from the model ID would not work and pose a high risk of breaking. One of the better fixes is to work with ModelFile (a type alias of Model & File), where:
There is no need to constrain the model ID and the JSON file path |
Current behavior
Manually added models are broken due to a mismatched ID between the model.json file and the folder path. The model_id in the JSON file doesn't match the folder name where the model is stored, causing issues with model recognition and functionality.
Minimum reproduction step
Expected behavior
Jan should consistently recognize and use manually added models, regardless of minor discrepancies between the model.json "id" field and the folder name. Ideally, Jan should use the folder name as the authoritative model_id to ensure consistency.
Screenshots / Logs
Jan version
In which operating systems have you tested?
Environment details
The text was updated successfully, but these errors were encountered: