Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion packages/tasks/src/local-apps.ts
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,10 @@ function isLlamaCppGgufModel(model: ModelData) {
return !!model.gguf?.context_length;
}

function isMlxModel(model: ModelData) {
return model.tags.includes("mlx");
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
return model.tags.includes("mlx");
return model.library_name === "mlx";

or maybe like this @Vaibhavs10 if we want to be pedantic about it

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

actually nvm because https://huggingface.co/mlx-community/Llama-3.2-3B-Instruct-4bit for instance is not library=mlx

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes! Just mlx tag would be more reliable 👍

}

const snippetLlamacpp = (model: ModelData, filepath?: string): LocalAppSnippet[] => {
const command = (binary: string) =>
[
Expand Down Expand Up @@ -218,7 +222,7 @@ export const LOCAL_APPS = {
prettyLabel: "LM Studio",
docsUrl: "https://lmstudio.ai",
mainTask: "text-generation",
displayOnModelPage: isLlamaCppGgufModel,
displayOnModelPage: (model) => isLlamaCppGgufModel(model) || isMlxModel(model),
deeplink: (model, filepath) =>
new URL(`lmstudio://open_from_hf?model=${model.id}${filepath ? `&file=${filepath}` : ""}`),
},
Expand Down