Du kan inte välja fler än 25 ämnen Ämnen måste starta med en bokstav eller siffra, kan innehålla bindestreck ('-') och vara max 35 tecken långa.

__init__.py 4.0KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144
  1. #
  2. # Copyright 2024 The InfiniFlow Authors. All Rights Reserved.
  3. #
  4. # Licensed under the Apache License, Version 2.0 (the "License");
  5. # you may not use this file except in compliance with the License.
  6. # You may obtain a copy of the License at
  7. #
  8. # http://www.apache.org/licenses/LICENSE-2.0
  9. #
  10. # Unless required by applicable law or agreed to in writing, software
  11. # distributed under the License is distributed on an "AS IS" BASIS,
  12. # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  13. # See the License for the specific language governing permissions and
  14. # limitations under the License.
  15. #
  16. from .embedding_model import *
  17. from .chat_model import *
  18. from .cv_model import *
  19. from .rerank_model import *
  20. from .sequence2txt_model import *
  21. from .tts_model import *
  22. EmbeddingModel = {
  23. "Ollama": OllamaEmbed,
  24. "LocalAI": LocalAIEmbed,
  25. "OpenAI": OpenAIEmbed,
  26. "Azure-OpenAI": AzureEmbed,
  27. "Xinference": XinferenceEmbed,
  28. "Tongyi-Qianwen": QWenEmbed,
  29. "ZHIPU-AI": ZhipuEmbed,
  30. "FastEmbed": FastEmbed,
  31. "Youdao": YoudaoEmbed,
  32. "BaiChuan": BaiChuanEmbed,
  33. "Jina": JinaEmbed,
  34. "BAAI": DefaultEmbedding,
  35. "Mistral": MistralEmbed,
  36. "Bedrock": BedrockEmbed,
  37. "Gemini": GeminiEmbed,
  38. "NVIDIA": NvidiaEmbed,
  39. "LM-Studio": LmStudioEmbed,
  40. "OpenAI-API-Compatible": OpenAI_APIEmbed,
  41. "Cohere": CoHereEmbed,
  42. "TogetherAI": TogetherAIEmbed,
  43. "PerfXCloud": PerfXCloudEmbed,
  44. "Upstage": UpstageEmbed,
  45. "SILICONFLOW": SILICONFLOWEmbed,
  46. "Replicate": ReplicateEmbed,
  47. "BaiduYiyan": BaiduYiyanEmbed,
  48. "Voyage AI": VoyageEmbed,
  49. "HuggingFace": HuggingFaceEmbed,
  50. "VolcEngine":VolcEngineEmbed,
  51. }
  52. CvModel = {
  53. "OpenAI": GptV4,
  54. "Azure-OpenAI": AzureGptV4,
  55. "Ollama": OllamaCV,
  56. "Xinference": XinferenceCV,
  57. "Tongyi-Qianwen": QWenCV,
  58. "ZHIPU-AI": Zhipu4V,
  59. "Moonshot": LocalCV,
  60. "Gemini": GeminiCV,
  61. "OpenRouter": OpenRouterCV,
  62. "LocalAI": LocalAICV,
  63. "NVIDIA": NvidiaCV,
  64. "LM-Studio": LmStudioCV,
  65. "StepFun": StepFunCV,
  66. "OpenAI-API-Compatible": OpenAI_APICV,
  67. "TogetherAI": TogetherAICV,
  68. "01.AI": YiCV,
  69. "Tencent Hunyuan": HunyuanCV
  70. }
  71. ChatModel = {
  72. "OpenAI": GptTurbo,
  73. "Azure-OpenAI": AzureChat,
  74. "ZHIPU-AI": ZhipuChat,
  75. "Tongyi-Qianwen": QWenChat,
  76. "Ollama": OllamaChat,
  77. "LocalAI": LocalAIChat,
  78. "Xinference": XinferenceChat,
  79. "Moonshot": MoonshotChat,
  80. "DeepSeek": DeepSeekChat,
  81. "VolcEngine": VolcEngineChat,
  82. "BaiChuan": BaiChuanChat,
  83. "MiniMax": MiniMaxChat,
  84. "Mistral": MistralChat,
  85. "Gemini": GeminiChat,
  86. "Bedrock": BedrockChat,
  87. "Groq": GroqChat,
  88. "OpenRouter": OpenRouterChat,
  89. "StepFun": StepFunChat,
  90. "NVIDIA": NvidiaChat,
  91. "LM-Studio": LmStudioChat,
  92. "OpenAI-API-Compatible": OpenAI_APIChat,
  93. "Cohere": CoHereChat,
  94. "LeptonAI": LeptonAIChat,
  95. "TogetherAI": TogetherAIChat,
  96. "PerfXCloud": PerfXCloudChat,
  97. "Upstage": UpstageChat,
  98. "novita.ai": NovitaAIChat,
  99. "SILICONFLOW": SILICONFLOWChat,
  100. "01.AI": YiChat,
  101. "Replicate": ReplicateChat,
  102. "Tencent Hunyuan": HunyuanChat,
  103. "XunFei Spark": SparkChat,
  104. "BaiduYiyan": BaiduYiyanChat,
  105. "Anthropic": AnthropicChat,
  106. "Google Cloud": GoogleChat,
  107. "HuggingFace": HuggingFaceChat,
  108. }
  109. RerankModel = {
  110. "LocalAI":LocalAIRerank,
  111. "BAAI": DefaultRerank,
  112. "Jina": JinaRerank,
  113. "Youdao": YoudaoRerank,
  114. "Xinference": XInferenceRerank,
  115. "NVIDIA": NvidiaRerank,
  116. "LM-Studio": LmStudioRerank,
  117. "OpenAI-API-Compatible": OpenAI_APIRerank,
  118. "Cohere": CoHereRerank,
  119. "TogetherAI": TogetherAIRerank,
  120. "SILICONFLOW": SILICONFLOWRerank,
  121. "BaiduYiyan": BaiduYiyanRerank,
  122. "Voyage AI": VoyageRerank,
  123. "Tongyi-Qianwen": QWenRerank,
  124. }
  125. Seq2txtModel = {
  126. "OpenAI": GPTSeq2txt,
  127. "Tongyi-Qianwen": QWenSeq2txt,
  128. "Azure-OpenAI": AzureSeq2txt,
  129. "Xinference": XinferenceSeq2txt,
  130. "Tencent Cloud": TencentCloudSeq2txt
  131. }
  132. TTSModel = {
  133. "Fish Audio": FishAudioTTS,
  134. "Tongyi-Qianwen": QwenTTS,
  135. "OpenAI": OpenAITTS,
  136. "XunFei Spark": SparkTTS,
  137. "Xinference": XinferenceTTS,
  138. }