Spaces:
Running
on
CPU Upgrade
Running
on
CPU Upgrade
Sort models lexiographically (#3)
Browse files
src/lib/components/Playground/Playground.svelte
CHANGED
|
@@ -51,6 +51,7 @@
|
|
| 51 |
// TODO: use hfjs.hub listModels after https://github.com/huggingface/huggingface.js/pull/795
|
| 52 |
const res = await fetch("https://huggingface.co/api/models?pipeline_tag=text-generation&inferenceStatus=loaded&filter=conversational");
|
| 53 |
compatibleModels = await res.json() as ModelEntry[];
|
|
|
|
| 54 |
})();
|
| 55 |
})
|
| 56 |
|
|
|
|
| 51 |
// TODO: use hfjs.hub listModels after https://github.com/huggingface/huggingface.js/pull/795
|
| 52 |
const res = await fetch("https://huggingface.co/api/models?pipeline_tag=text-generation&inferenceStatus=loaded&filter=conversational");
|
| 53 |
compatibleModels = await res.json() as ModelEntry[];
|
| 54 |
+
compatibleModels.sort((a, b) => a.id.toLowerCase().localeCompare(b.id.toLowerCase()));
|
| 55 |
})();
|
| 56 |
})
|
| 57 |
|