Skip to content

armgit / dify

Public Imported from GitHub
0

Build Agentic workflows, RAG pipelines, with rich AI model and tool support on one collaborative workspace. Deploy on cloud, VPC, or self-hosted, so teams move from prototype to production without rebuilding the stack.

504 B
Raw Blame
import { VarType } from '@/app/components/workflow/types'
import { PipelineInputVarType } from '@/models/pipeline'

export const inputVarTypeToVarType = (type: PipelineInputVarType): VarType => {
  return (
    (
      {
        [PipelineInputVarType.number]: VarType.number,
        [PipelineInputVarType.singleFile]: VarType.file,
        [PipelineInputVarType.multiFiles]: VarType.arrayFile,
        [PipelineInputVarType.checkbox]: VarType.boolean,
      } as any
    )[type] || VarType.string
  )
}