2023-11-16 15:56:23 +00:00
|
|
|
from __future__ import annotations
|
|
|
|
|
2024-02-21 23:16:58 +00:00
|
|
|
from ..providers.types import BaseProvider, ProviderType
|
2024-02-27 10:55:40 +00:00
|
|
|
from ..providers.retry_provider import RetryProvider, IterProvider
|
2024-02-21 23:16:58 +00:00
|
|
|
from ..providers.base_provider import AsyncProvider, AsyncGeneratorProvider
|
|
|
|
from ..providers.create_images import CreateImagesProvider
|
|
|
|
|
2024-01-01 16:48:57 +00:00
|
|
|
from .deprecated import *
|
2024-02-08 21:02:52 +00:00
|
|
|
from .selenium import *
|
2024-01-01 16:48:57 +00:00
|
|
|
from .needs_auth import *
|
|
|
|
from .unfinished import *
|
|
|
|
|
2023-10-05 03:13:37 +00:00
|
|
|
from .AiAsk import AiAsk
|
2023-11-18 03:38:31 +00:00
|
|
|
from .AiChatOnline import AiChatOnline
|
2023-10-05 03:13:37 +00:00
|
|
|
from .AItianhu import AItianhu
|
2024-01-23 00:50:44 +00:00
|
|
|
from .Aura import Aura
|
|
|
|
from .Bestim import Bestim
|
2023-10-05 03:13:37 +00:00
|
|
|
from .Bing import Bing
|
2024-02-21 23:16:58 +00:00
|
|
|
from .BingCreateImages import BingCreateImages
|
2023-11-16 15:56:23 +00:00
|
|
|
from .ChatAnywhere import ChatAnywhere
|
2023-10-05 03:13:37 +00:00
|
|
|
from .ChatBase import ChatBase
|
2023-10-13 22:31:48 +00:00
|
|
|
from .ChatForAi import ChatForAi
|
2023-10-05 03:13:37 +00:00
|
|
|
from .Chatgpt4Online import Chatgpt4Online
|
|
|
|
from .ChatgptAi import ChatgptAi
|
|
|
|
from .ChatgptDemo import ChatgptDemo
|
2023-11-18 03:38:31 +00:00
|
|
|
from .ChatgptDemoAi import ChatgptDemoAi
|
2023-10-12 18:28:54 +00:00
|
|
|
from .ChatgptFree import ChatgptFree
|
|
|
|
from .ChatgptLogin import ChatgptLogin
|
2023-11-18 03:38:31 +00:00
|
|
|
from .ChatgptNext import ChatgptNext
|
2023-10-05 03:13:37 +00:00
|
|
|
from .ChatgptX import ChatgptX
|
2023-12-27 05:13:52 +00:00
|
|
|
from .Chatxyz import Chatxyz
|
2023-10-26 19:32:49 +00:00
|
|
|
from .DeepInfra import DeepInfra
|
2023-10-21 23:22:25 +00:00
|
|
|
from .FakeGpt import FakeGpt
|
2024-02-24 13:52:23 +00:00
|
|
|
from .FlowGpt import FlowGpt
|
2024-01-10 09:34:56 +00:00
|
|
|
from .FreeChatgpt import FreeChatgpt
|
2023-10-05 03:13:37 +00:00
|
|
|
from .FreeGpt import FreeGpt
|
2024-01-02 13:58:28 +00:00
|
|
|
from .GeekGpt import GeekGpt
|
2024-02-23 10:33:38 +00:00
|
|
|
from .GeminiPro import GeminiPro
|
2024-01-02 13:58:28 +00:00
|
|
|
from .GeminiProChat import GeminiProChat
|
2023-12-25 00:38:42 +00:00
|
|
|
from .Gpt6 import Gpt6
|
2023-10-07 02:03:36 +00:00
|
|
|
from .GPTalk import GPTalk
|
2023-10-12 18:28:54 +00:00
|
|
|
from .GptChatly import GptChatly
|
2023-10-07 02:03:36 +00:00
|
|
|
from .GptForLove import GptForLove
|
2023-10-05 03:13:37 +00:00
|
|
|
from .GptGo import GptGo
|
2023-10-07 07:02:48 +00:00
|
|
|
from .GptGod import GptGod
|
2023-11-22 20:21:29 +00:00
|
|
|
from .GptTalkRu import GptTalkRu
|
2023-10-22 12:22:33 +00:00
|
|
|
from .Hashnode import Hashnode
|
2024-01-22 02:38:11 +00:00
|
|
|
from .HuggingChat import HuggingChat
|
2024-03-11 01:41:59 +00:00
|
|
|
from .HuggingFace import HuggingFace
|
2023-11-12 17:03:04 +00:00
|
|
|
from .Koala import Koala
|
2023-10-05 03:13:37 +00:00
|
|
|
from .Liaobots import Liaobots
|
2023-10-15 17:10:25 +00:00
|
|
|
from .Llama2 import Llama2
|
2023-11-18 03:38:31 +00:00
|
|
|
from .OnlineGpt import OnlineGpt
|
2024-01-23 00:50:44 +00:00
|
|
|
from .PerplexityLabs import PerplexityLabs
|
2023-12-01 22:56:12 +00:00
|
|
|
from .Pi import Pi
|
2023-10-05 03:13:37 +00:00
|
|
|
from .Vercel import Vercel
|
|
|
|
from .Ylokh import Ylokh
|
|
|
|
from .You import You
|
2023-08-27 15:37:44 +00:00
|
|
|
|
2023-11-16 15:56:23 +00:00
|
|
|
import sys
|
2023-10-09 22:45:29 +00:00
|
|
|
|
2023-11-16 15:56:23 +00:00
|
|
|
__modules__: list = [
|
|
|
|
getattr(sys.modules[__name__], provider) for provider in dir()
|
|
|
|
if not provider.startswith("__")
|
|
|
|
]
|
2024-01-01 16:48:57 +00:00
|
|
|
__providers__: list[ProviderType] = [
|
2023-11-16 15:56:23 +00:00
|
|
|
provider for provider in __modules__
|
|
|
|
if isinstance(provider, type)
|
|
|
|
and issubclass(provider, BaseProvider)
|
2023-10-12 18:28:54 +00:00
|
|
|
]
|
2023-11-16 15:56:23 +00:00
|
|
|
__all__: list[str] = [
|
|
|
|
provider.__name__ for provider in __providers__
|
|
|
|
]
|
2024-01-01 16:48:57 +00:00
|
|
|
__map__: dict[str, ProviderType] = dict([
|
2023-11-16 15:56:23 +00:00
|
|
|
(provider.__name__, provider) for provider in __providers__
|
|
|
|
])
|
|
|
|
|
|
|
|
class ProviderUtils:
|
2024-01-01 16:48:57 +00:00
|
|
|
convert: dict[str, ProviderType] = __map__
|