__init__.py 2.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. from __future__ import annotations
  2. from ..providers.types import BaseProvider, ProviderType
  3. from ..providers.retry_provider import RetryProvider, IterListProvider
  4. from ..providers.base_provider import AsyncProvider, AsyncGeneratorProvider
  5. from ..providers.create_images import CreateImagesProvider
  6. from .deprecated import *
  7. from .selenium import *
  8. from .needs_auth import *
  9. from .not_working import *
  10. from .local import *
  11. from .AIUncensored import AIUncensored
  12. from .Allyfy import Allyfy
  13. from .Airforce import Airforce
  14. from .Bing import Bing
  15. from .Blackbox import Blackbox
  16. from .ChatGpt import ChatGpt
  17. from .ChatGptEs import ChatGptEs
  18. from .Cloudflare import Cloudflare
  19. from .DarkAI import DarkAI
  20. from .DDG import DDG
  21. from .DeepInfraChat import DeepInfraChat
  22. from .Free2GPT import Free2GPT
  23. from .FreeGpt import FreeGpt
  24. from .GizAI import GizAI
  25. from .HuggingChat import HuggingChat
  26. from .Liaobots import Liaobots
  27. from .MagickPen import MagickPen
  28. from .PerplexityLabs import PerplexityLabs
  29. from .Pi import Pi
  30. from .Pizzagpt import Pizzagpt
  31. from .Prodia import Prodia
  32. from .Reka import Reka
  33. from .ReplicateHome import ReplicateHome
  34. from .RubiksAI import RubiksAI
  35. from .TeachAnything import TeachAnything
  36. from .Upstage import Upstage
  37. from .You import You
  38. from .Mhystical import Mhystical
  39. import sys
  40. __modules__: list = [
  41. getattr(sys.modules[__name__], provider) for provider in dir()
  42. if not provider.startswith("__")
  43. ]
  44. __providers__: list[ProviderType] = [
  45. provider for provider in __modules__
  46. if isinstance(provider, type)
  47. and issubclass(provider, BaseProvider)
  48. ]
  49. __all__: list[str] = [
  50. provider.__name__ for provider in __providers__
  51. ]
  52. __map__: dict[str, ProviderType] = dict([
  53. (provider.__name__, provider) for provider in __providers__
  54. ])
  55. class ProviderUtils:
  56. convert: dict[str, ProviderType] = __map__