Commit 1c82e387 authored by Joel's avatar Joel

feat: not choose model hide in node

parent 49ce9d22
......@@ -14,13 +14,16 @@ const Node: FC<NodeProps<LLMNodeType>> = ({
const {
textGenerationModelList,
} = useTextGenerationCurrentProviderAndModelAndModelList()
const hasSetModel = provider && modelId
return (
<div className='px-3'>
{hasSetModel && (
<ModelSelector
defaultModel={(provider || modelId) ? { provider, model: modelId } : undefined}
defaultModel={{ provider, model: modelId }}
modelList={textGenerationModelList}
readonly
/>
)}
</div>
)
}
......
......@@ -22,13 +22,17 @@ const Node: FC<NodeProps<QuestionClassifierNodeType>> = (props) => {
const {
textGenerationModelList,
} = useTextGenerationCurrentProviderAndModelAndModelList()
const hasSetModel = provider && modelId
return (
<div className='px-3'>
{hasSetModel && (
<ModelSelector
defaultModel={(provider || modelId) ? { provider, model: modelId } : undefined}
defaultModel={{ provider, model: modelId }}
modelList={textGenerationModelList}
readonly
/>
)}
<div className='mt-2 space-y-0.5'>
{topics.map((topic, index) => (
<div
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment