From 3119b8e37e73c958157ce8277bd7801202ab6962 Mon Sep 17 00:00:00 2001 From: kqlio67 Date: Sat, 12 Oct 2024 21:34:04 +0300 Subject: chore: temporarily disable some new providers --- g4f/Provider/nexra/NexraLLaMA31.py | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'g4f/Provider/nexra/NexraLLaMA31.py') diff --git a/g4f/Provider/nexra/NexraLLaMA31.py b/g4f/Provider/nexra/NexraLLaMA31.py index c67febb3..d461f2b2 100644 --- a/g4f/Provider/nexra/NexraLLaMA31.py +++ b/g4f/Provider/nexra/NexraLLaMA31.py @@ -17,10 +17,18 @@ class NexraLLaMA31(AsyncGeneratorProvider, ProviderModelMixin): default_model = 'llama-3.1' models = [default_model] + model_aliases = { + "llama-3.1-8b": "llama-3.1", + } @classmethod def get_model(cls, model: str) -> str: - return cls.default_model + if model in cls.models: + return model + elif model in cls.model_aliases: + return cls.model_aliases.get(model, cls.default_model) + else: + return cls.default_model @classmethod async def create_async_generator( -- cgit v1.2.3