From ec51e9c76433b9e9498ade1dbe5de2268ad84218 Mon Sep 17 00:00:00 2001 From: Heiner Lohaus Date: Mon, 11 Mar 2024 02:41:59 +0100 Subject: Fix HuggingChat and PerplexityLabs and add HuggingFace provider Add more models and image generation in You provider Use You as second default image provider --- g4f/providers/base_provider.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'g4f/providers') diff --git a/g4f/providers/base_provider.py b/g4f/providers/base_provider.py index 17c45875..32a0c01b 100644 --- a/g4f/providers/base_provider.py +++ b/g4f/providers/base_provider.py @@ -274,7 +274,7 @@ class ProviderModelMixin: model = cls.default_model elif model in cls.model_aliases: model = cls.model_aliases[model] - elif model not in cls.get_models(): + elif model not in cls.get_models() and cls.models: raise ModelNotSupportedError(f"Model is not supported: {model} in: {cls.__name__}") debug.last_model = model return model \ No newline at end of file -- cgit v1.2.3