From a26421bcd8b8580650fa05b3fb4f8fdfa0ef9921 Mon Sep 17 00:00:00 2001 From: Heiner Lohaus Date: Sun, 21 Apr 2024 15:15:55 +0200 Subject: Add image model list --- g4f/providers/base_provider.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'g4f/providers/base_provider.py') diff --git a/g4f/providers/base_provider.py b/g4f/providers/base_provider.py index 685a6f98..5624c9e1 100644 --- a/g4f/providers/base_provider.py +++ b/g4f/providers/base_provider.py @@ -271,13 +271,13 @@ class AsyncGeneratorProvider(AsyncProvider): raise NotImplementedError() class ProviderModelMixin: - default_model: str + default_model: str = None models: list[str] = [] model_aliases: dict[str, str] = {} @classmethod def get_models(cls) -> list[str]: - if not cls.models: + if not cls.models and cls.default_model is not None: return [cls.default_model] return cls.models -- cgit v1.2.3