fix: inconsistent models from dropdown and hub
This commit is contained in:
parent
8c759676d9
commit
2a0d87a393
@ -509,7 +509,12 @@ const ModelDropdown = ({
|
|||||||
|
|
||||||
<ul className="pb-2">
|
<ul className="pb-2">
|
||||||
{filteredDownloadedModels
|
{filteredDownloadedModels
|
||||||
.filter((x) => x.engine === engine)
|
.filter(
|
||||||
|
(x) =>
|
||||||
|
x.engine === engine ||
|
||||||
|
(x.engine === InferenceEngine.nitro &&
|
||||||
|
engine === InferenceEngine.cortex_llamacpp)
|
||||||
|
)
|
||||||
.filter((y) => {
|
.filter((y) => {
|
||||||
if (isLocalEngine(y.engine) && !searchText.length) {
|
if (isLocalEngine(y.engine) && !searchText.length) {
|
||||||
return downloadedModels.find((c) => c.id === y.id)
|
return downloadedModels.find((c) => c.id === y.id)
|
||||||
|
|||||||
@ -54,14 +54,14 @@ const MyModelList = ({ model }: Props) => {
|
|||||||
<h6
|
<h6
|
||||||
className={twMerge(
|
className={twMerge(
|
||||||
'font-medium lg:line-clamp-1 lg:min-w-[280px] lg:max-w-[280px]',
|
'font-medium lg:line-clamp-1 lg:min-w-[280px] lg:max-w-[280px]',
|
||||||
model.engine !== InferenceEngine.nitro &&
|
!isLocalEngine(model.engine) &&
|
||||||
'max-w-none text-[hsla(var(--text-secondary))]'
|
'max-w-none text-[hsla(var(--text-secondary))]'
|
||||||
)}
|
)}
|
||||||
title={model.name}
|
title={model.name}
|
||||||
>
|
>
|
||||||
{model.name}
|
{model.name}
|
||||||
</h6>
|
</h6>
|
||||||
{model.engine === InferenceEngine.nitro && (
|
{!isLocalEngine(model.engine) && (
|
||||||
<div className="flex gap-x-8">
|
<div className="flex gap-x-8">
|
||||||
<p
|
<p
|
||||||
className="line-clamp-1 text-[hsla(var(--text-secondary))] lg:min-w-[160px] lg:max-w-[160px] xl:max-w-none"
|
className="line-clamp-1 text-[hsla(var(--text-secondary))] lg:min-w-[160px] lg:max-w-[160px] xl:max-w-none"
|
||||||
|
|||||||
@ -250,7 +250,12 @@ const MyModels = () => {
|
|||||||
<div className="mt-2">
|
<div className="mt-2">
|
||||||
{filteredDownloadedModels
|
{filteredDownloadedModels
|
||||||
? filteredDownloadedModels
|
? filteredDownloadedModels
|
||||||
.filter((x) => x.engine === engine)
|
.filter(
|
||||||
|
(x) =>
|
||||||
|
x.engine === engine ||
|
||||||
|
(x.engine === InferenceEngine.nitro &&
|
||||||
|
engine === InferenceEngine.cortex_llamacpp)
|
||||||
|
)
|
||||||
.map((model) => {
|
.map((model) => {
|
||||||
if (!showModel) return null
|
if (!showModel) return null
|
||||||
return (
|
return (
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user