From cc0ed0481e6f04f7eeba9fec836693a9fad45660 Mon Sep 17 00:00:00 2001 From: kqlio67 Date: Sat, 26 Oct 2024 18:54:47 +0300 Subject: feat(g4f/models.py): add new provider GizAI and update best providers --- g4f/models.py | 42 +++++++++++++++++++++++++++--------------- 1 file changed, 27 insertions(+), 15 deletions(-) (limited to 'g4f/models.py') diff --git a/g4f/models.py b/g4f/models.py index 1cea6447..1bea9eec 100644 --- a/g4f/models.py +++ b/g4f/models.py @@ -23,7 +23,6 @@ from .Provider import ( DDG, DeepInfra, DeepInfraChat, - DeepInfraImage, Editee, Free2GPT, FreeChatgpt, @@ -31,6 +30,7 @@ from .Provider import ( FreeNetfly, Gemini, GeminiPro, + GizAI, GigaChat, GPROChat, HuggingChat, @@ -87,6 +87,8 @@ class Model: """Returns a list of all model names.""" return _all_models + +### Default ### default = Model( name = "", base_provider = "", @@ -113,6 +115,8 @@ default = Model( ]) ) + + ############ ### Text ### ############ @@ -136,13 +140,13 @@ gpt_35_turbo = Model( gpt_4o = Model( name = 'gpt-4o', base_provider = 'OpenAI', - best_provider = IterListProvider([NexraChatGPT4o, Blackbox, ChatGptEs, AmigoChat, DarkAI, Editee, Liaobots, Airforce, OpenaiChat]) + best_provider = IterListProvider([NexraChatGPT4o, Blackbox, ChatGptEs, AmigoChat, DarkAI, Editee, GizAI, Airforce, Liaobots, OpenaiChat]) ) gpt_4o_mini = Model( name = 'gpt-4o-mini', base_provider = 'OpenAI', - best_provider = IterListProvider([DDG, ChatGptEs, FreeNetfly, Pizzagpt, MagickPen, AmigoChat, RubiksAI, Liaobots, Airforce, ChatgptFree, Koala, OpenaiChat, ChatGpt]) + best_provider = IterListProvider([DDG, ChatGptEs, FreeNetfly, Pizzagpt, MagickPen, AmigoChat, RubiksAI, Liaobots, Airforce, GizAI, ChatgptFree, Koala, OpenaiChat, ChatGpt]) ) gpt_4_turbo = Model( @@ -167,7 +171,7 @@ o1 = Model( o1_mini = Model( name = 'o1-mini', base_provider = 'OpenAI', - best_provider = AmigoChat + best_provider = IterListProvider([AmigoChat, GizAI]) ) @@ -216,13 +220,13 @@ llama_3_70b = Model( llama_3_1_8b = Model( name = "llama-3.1-8b", base_provider = "Meta Llama", - best_provider = IterListProvider([Blackbox, DeepInfraChat, ChatHub, Cloudflare, Airforce, PerplexityLabs]) + best_provider = IterListProvider([Blackbox, DeepInfraChat, ChatHub, Cloudflare, Airforce, GizAI, PerplexityLabs]) ) llama_3_1_70b = Model( name = "llama-3.1-70b", base_provider = "Meta Llama", - best_provider = IterListProvider([DDG, HuggingChat, Blackbox, FreeGpt, TeachAnything, Free2GPT, DeepInfraChat, DarkAI, Airforce, AiMathGPT, RubiksAI, HuggingFace, PerplexityLabs]) + best_provider = IterListProvider([DDG, HuggingChat, Blackbox, FreeGpt, TeachAnything, Free2GPT, DeepInfraChat, DarkAI, Airforce, AiMathGPT, RubiksAI, GizAI, HuggingFace, PerplexityLabs]) ) llama_3_1_405b = Model( @@ -299,7 +303,7 @@ mistral_nemo = Model( mistral_large = Model( name = "mistral-large", base_provider = "Mistral", - best_provider = Editee + best_provider = IterListProvider([Editee, GizAI]) ) @@ -347,13 +351,13 @@ phi_3_5_mini = Model( gemini_pro = Model( name = 'gemini-pro', base_provider = 'Google DeepMind', - best_provider = IterListProvider([GeminiPro, Blackbox, AIChatFree, GPROChat, NexraGeminiPro, AmigoChat, Editee, Liaobots, Airforce]) + best_provider = IterListProvider([GeminiPro, Blackbox, AIChatFree, GPROChat, NexraGeminiPro, AmigoChat, Editee, GizAI, Airforce, Liaobots]) ) gemini_flash = Model( name = 'gemini-flash', base_provider = 'Google DeepMind', - best_provider = IterListProvider([Blackbox, Liaobots, Airforce]) + best_provider = IterListProvider([Blackbox, GizAI, Airforce, Liaobots]) ) gemini = Model( @@ -424,14 +428,14 @@ claude_3_sonnet = Model( claude_3_haiku = Model( name = 'claude-3-haiku', base_provider = 'Anthropic', - best_provider = IterListProvider([DDG, Airforce, Liaobots]) + best_provider = IterListProvider([DDG, Airforce, GizAI, Liaobots]) ) # claude 3.5 claude_3_5_sonnet = Model( name = 'claude-3.5-sonnet', base_provider = 'Anthropic', - best_provider = IterListProvider([Blackbox, Editee, AmigoChat, Airforce, Liaobots]) + best_provider = IterListProvider([Blackbox, Editee, AmigoChat, Airforce, GizAI, Liaobots]) ) @@ -753,14 +757,14 @@ sdxl_lora = Model( sdxl = Model( name = 'sdxl', base_provider = 'Stability AI', - best_provider = IterListProvider([ReplicateHome, DeepInfraImage]) + best_provider = IterListProvider([ReplicateHome]) ) sd_1_5 = Model( name = 'sd-1.5', base_provider = 'Stability AI', - best_provider = NexraSD15 + best_provider = IterListProvider([NexraSD15, GizAI]) ) @@ -771,6 +775,13 @@ sd_3 = Model( ) +sd_3_5 = Model( + name = 'sd-3.5', + base_provider = 'Stability AI', + best_provider = GizAI + +) + ### Playground ### playground_v2_5 = Model( name = 'playground-v2.5', @@ -791,7 +802,7 @@ flux = Model( flux_pro = Model( name = 'flux-pro', base_provider = 'Flux AI', - best_provider = IterListProvider([AmigoChat, NexraFluxPro]) + best_provider = IterListProvider([NexraFluxPro, AmigoChat]) ) @@ -840,7 +851,7 @@ flux_4o = Model( flux_schnell = Model( name = 'flux-schnell', base_provider = 'Flux AI', - best_provider = ReplicateHome + best_provider = IterListProvider([ReplicateHome, GizAI]) ) @@ -1123,6 +1134,7 @@ class ModelUtils: 'sdxl-turbo': sdxl_turbo, 'sd-1.5': sd_1_5, 'sd-3': sd_3, +'sd-3.5': sd_3_5, ### Playground ### -- cgit v1.2.3 From 8768a057534b91e463f428fb91f301325110415c Mon Sep 17 00:00:00 2001 From: kqlio67 Date: Sun, 27 Oct 2024 20:14:45 +0200 Subject: Update (docs/providers-and-models.md g4f/models.py g4f/Provider/nexra/) --- g4f/models.py | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) (limited to 'g4f/models.py') diff --git a/g4f/models.py b/g4f/models.py index 1bea9eec..32a12d10 100644 --- a/g4f/models.py +++ b/g4f/models.py @@ -42,9 +42,6 @@ from .Provider import ( NexraBing, NexraBlackbox, NexraChatGPT, - NexraChatGPT4o, - NexraChatGptV2, - NexraChatGptWeb, NexraDallE, NexraDallE2, NexraEmi, @@ -140,7 +137,7 @@ gpt_35_turbo = Model( gpt_4o = Model( name = 'gpt-4o', base_provider = 'OpenAI', - best_provider = IterListProvider([NexraChatGPT4o, Blackbox, ChatGptEs, AmigoChat, DarkAI, Editee, GizAI, Airforce, Liaobots, OpenaiChat]) + best_provider = IterListProvider([NexraChatGPT, Blackbox, ChatGptEs, AmigoChat, DarkAI, Editee, GizAI, Airforce, Liaobots, OpenaiChat]) ) gpt_4o_mini = Model( @@ -158,7 +155,7 @@ gpt_4_turbo = Model( gpt_4 = Model( name = 'gpt-4', base_provider = 'OpenAI', - best_provider = IterListProvider([Chatgpt4Online, Ai4Chat, NexraBing, NexraChatGPT, NexraChatGptV2, NexraChatGptWeb, Airforce, Bing, OpenaiChat, gpt_4_turbo.best_provider, gpt_4o.best_provider, gpt_4o_mini.best_provider]) + best_provider = IterListProvider([Chatgpt4Online, Ai4Chat, NexraBing, NexraChatGPT, Airforce, Bing, OpenaiChat, gpt_4_turbo.best_provider, gpt_4o.best_provider, gpt_4o_mini.best_provider]) ) # o1 -- cgit v1.2.3