chore: make convert gguf as experimental feature (#2156)
Signed-off-by: James <james@jan.ai> Co-authored-by: James <james@jan.ai>
This commit is contained in:
parent
773963a456
commit
64ea290ca3
@ -1,7 +1,6 @@
|
|||||||
import { useAtomValue } from 'jotai'
|
import { useAtomValue } from 'jotai'
|
||||||
|
|
||||||
import {
|
import {
|
||||||
conversionErrorAtom,
|
|
||||||
conversionStatusAtom,
|
conversionStatusAtom,
|
||||||
repoDataAtom,
|
repoDataAtom,
|
||||||
} from '@/helpers/atoms/HFConverter.atom'
|
} from '@/helpers/atoms/HFConverter.atom'
|
||||||
@ -11,8 +10,6 @@ export const HuggingFaceConvertingErrorModal = () => {
|
|||||||
const repoData = useAtomValue(repoDataAtom)!
|
const repoData = useAtomValue(repoDataAtom)!
|
||||||
// This component only loads when conversionStatus is not null
|
// This component only loads when conversionStatus is not null
|
||||||
const conversionStatus = useAtomValue(conversionStatusAtom)!
|
const conversionStatus = useAtomValue(conversionStatusAtom)!
|
||||||
// This component only loads when conversionError is not null
|
|
||||||
const conversionError = useAtomValue(conversionErrorAtom)!
|
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<>
|
<>
|
||||||
|
|||||||
@ -1,4 +1,4 @@
|
|||||||
import { useCallback, useState } from 'react'
|
import { useCallback, useContext, useState } from 'react'
|
||||||
|
|
||||||
import {
|
import {
|
||||||
Input,
|
Input,
|
||||||
@ -15,6 +15,8 @@ import {
|
|||||||
import { useAtomValue, useSetAtom } from 'jotai'
|
import { useAtomValue, useSetAtom } from 'jotai'
|
||||||
import { Plus, SearchIcon } from 'lucide-react'
|
import { Plus, SearchIcon } from 'lucide-react'
|
||||||
|
|
||||||
|
import { FeatureToggleContext } from '@/context/FeatureToggle'
|
||||||
|
|
||||||
import { setImportModelStageAtom } from '@/hooks/useImportModel'
|
import { setImportModelStageAtom } from '@/hooks/useImportModel'
|
||||||
|
|
||||||
import ExploreModelList from './ExploreModelList'
|
import ExploreModelList from './ExploreModelList'
|
||||||
@ -36,6 +38,8 @@ const ExploreModelsScreen = () => {
|
|||||||
const [showHuggingFaceModal, setShowHuggingFaceModal] = useState(false)
|
const [showHuggingFaceModal, setShowHuggingFaceModal] = useState(false)
|
||||||
const setImportModelStage = useSetAtom(setImportModelStageAtom)
|
const setImportModelStage = useSetAtom(setImportModelStageAtom)
|
||||||
|
|
||||||
|
const { experimentalFeature } = useContext(FeatureToggleContext)
|
||||||
|
|
||||||
const filteredModels = configuredModels.filter((x) => {
|
const filteredModels = configuredModels.filter((x) => {
|
||||||
if (sortSelected === 'Downloaded') {
|
if (sortSelected === 'Downloaded') {
|
||||||
return (
|
return (
|
||||||
@ -100,6 +104,7 @@ const ExploreModelsScreen = () => {
|
|||||||
<p>Import Model</p>
|
<p>Import Model</p>
|
||||||
</Button>
|
</Button>
|
||||||
</div>
|
</div>
|
||||||
|
{experimentalFeature && (
|
||||||
<div className="text-center">
|
<div className="text-center">
|
||||||
<p
|
<p
|
||||||
onClick={onHuggingFaceConverterClick}
|
onClick={onHuggingFaceConverterClick}
|
||||||
@ -108,6 +113,7 @@ const ExploreModelsScreen = () => {
|
|||||||
Convert from Hugging Face
|
Convert from Hugging Face
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
|
)}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div className="mx-auto w-4/5 py-6">
|
<div className="mx-auto w-4/5 py-6">
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user