您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符

use-configs-map.ts 726B

123456789101112131415161718192021222324
  1. import { useMemo } from 'react'
  2. import { useStore } from '@/app/components/workflow/store'
  3. import { FlowType } from '@/types/common'
  4. import { Resolution, TransferMethod } from '@/types/app'
  5. export const useConfigsMap = () => {
  6. const pipelineId = useStore(s => s.pipelineId)
  7. const fileUploadConfig = useStore(s => s.fileUploadConfig)
  8. return useMemo(() => {
  9. return {
  10. flowId: pipelineId!,
  11. flowType: FlowType.ragPipeline,
  12. fileSettings: {
  13. image: {
  14. enabled: false,
  15. detail: Resolution.high,
  16. number_limits: 3,
  17. transfer_methods: [TransferMethod.local_file, TransferMethod.remote_url],
  18. },
  19. fileUploadConfig,
  20. },
  21. }
  22. }, [pipelineId])
  23. }