Repository navigation
Studio: classify MLX repos by name or model-card tag everywhere - #16883
Conversation
The model picker decided MLX by repo name only, while the Hub page search, On Device inventory, inspector precision card, picker precision-folder expansion and the backend precision-folder listing decided it by the model card's mlx tag or library_name only. The Hub only marks MLX from the model card, so untagged MLX uploads (including unsloth/*-MLX-* repos) and tagged repos without MLX in the name landed in different formats depending on the screen. Add hasMlxCardTag and an optional hint to isMlxId (mirroring isGgufId) in hub/lib/format-filters.ts, and use name OR tag on every surface that has both. matchesFormatFilter keeps GGUF precedence so a GGUF repo's mlx tag never moves it into MLX. The backend name rule moves to hub/utils/mlx_variants.py as looks_like_mlx_repo and also gates the MLX precision-folder listing.
|
@codex review |
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
Codex Review: Something went wrong. Try again later by commenting “@codex review”. ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: e2bf8169b2
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
The cached inventory row's repo field holds only the repo name, so the mlx-community/ owner rule never matched there; use repoId.
|
@codex review |
|
Codex Review: Didn't find any major issues. Chef's kiss. Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
|
Review and CI status for
|
|
@codex review |
|
Codex Review: Didn't find any major issues. Hooray! Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
Review + reproduction evidencePinned review: I checked both halves of the rule against live Hub data and ran the changed tests on the merge base
The earlier review item (cached On Device rows classified by repo name instead of the full Hub id) is fixed in One small note on the description: Conclusion: the inconsistency is real on main and the PR fixes it on every surface that has both an id and model-card data, with GGUF precedence kept. Tests discriminate. Not yet covered: before/after screenshots of the Hub page and picker. |
Problem
Unsloth Studio decided whether a Hub repo is MLX in two different ways, and each screen used only one of them:
mlx-community/owner, or anmlxsegment in the repo name)/api/models/listdefaultslibrary_name: mlxor anmlxtag)The Hub marks a repo as MLX only from its README front-matter and never inspects the weights, so many real MLX uploads are untagged, and many tagged ones have no MLX in the name. The same repo therefore landed in different formats depending on the screen:
unsloth/gemma-4-E2B-it-UD-MLX-4bit(nomlxtag or library): MLX in the model picker, Safetensors on the Hub page and On Device, and no precision-folder expansion.FluidVoice-Labs/Qwen3.5-9B-4bit(taggedmlx, no MLX in the name): MLX on the Hub page, Safetensors in the model picker.Change
hub/lib/format-filters.tsowns both halves:hasMlxCardTag({ tags, libraryName })andisMlxId(id, hintedIsMlx?), which mirrorsisGgufId(id, hintedIsGguf).recommended-fit.tsre-exports them, so existing imports keep working.matchesFormatFiltergains an optionalhintedIsMlxand keeps GGUF precedence: a GGUF repo'smlxtag never moves it into the MLX filter, matchingdetectResultFormat. Name-based behaviour for GGUF ids is unchanged.routes/models.pytohub/utils/mlx_variants.pyaslooks_like_mlx_repo, so the MLX precision-folder listing inhub/servicescan accept name-matched repos too, without importing a route module.All classification uses data the search listing already returns. No per-repo requests are added for classification.
Tradeoffs and scope
hfModelFitsDevice,/api/models/listdefaults, picker local rows) keep the name rule because they have no tag data.quantization_config.bitswithoutquant_methodalso matches non-MLX formats such as modelopt NVFP4, EXL3, CoreML, OpenVINO and ONNX exports.Validation
gemma-4-E2B-it-UD-MLXwith the MLX format filter now listsunsloth/gemma-4-E2B-it-UD-MLX-4bit.