Enable Liaobots, disable Phind provider

pull/1665/head
Heiner Lohaus 4 months ago
parent 1744321feb
commit eb48299195

@ -235,10 +235,10 @@ set G4F_PROXY=http://host:port
| ------ | ------- | ------- | ----- | ------ | ------ | ---- | | ------ | ------- | ------- | ----- | ------ | ------ | ---- |
| [bing.com](https://bing.com/chat) | `g4f.Provider.Bing` | ❌ | ✔️ | ✔️ | ![Active](https://img.shields.io/badge/Active-brightgreen) | ❌ | | [bing.com](https://bing.com/chat) | `g4f.Provider.Bing` | ❌ | ✔️ | ✔️ | ![Active](https://img.shields.io/badge/Active-brightgreen) | ❌ |
| [chat.openai.com](https://chat.openai.com) | `g4f.Provider.OpenaiChat` | ✔️ | ✔️ | ✔️ | ![Unknown](https://img.shields.io/badge/Active-brightgreen) | ✔️ | | [chat.openai.com](https://chat.openai.com) | `g4f.Provider.OpenaiChat` | ✔️ | ✔️ | ✔️ | ![Unknown](https://img.shields.io/badge/Active-brightgreen) | ✔️ |
| [raycast.com](https://raycast.com) | `g4f.Provider.Raycast` | ✔️ | ✔️ | ✔️ | ![Unknown](https://img.shields.io/badge/Unknown-grey) | ✔️ |
| [you.com](https://you.com) | `g4f.Provider.You` | ✔️ | ✔️ | ✔️ | ![Active](https://img.shields.io/badge/Active-brightgreen) | ❌ | | [you.com](https://you.com) | `g4f.Provider.You` | ✔️ | ✔️ | ✔️ | ![Active](https://img.shields.io/badge/Active-brightgreen) | ❌ |
| [liaobots.site](https://liaobots.site) | `g4f.Provider.Liaobots` | ✔️ | ✔️ | ✔️ | ![Active](https://img.shields.io/badge/Active-brightgreen) | ❌ |
| [raycast.com](https://raycast.com) | `g4f.Provider.Raycast` | ✔️ | ✔️ | ✔️ | ![Unknown](https://img.shields.io/badge/Unknown-grey) | ✔️ |
| [chat.geekgpt.org](https://chat.geekgpt.org) | `g4f.Provider.GeekGpt` | ✔️ | ✔️ | ✔️ | ![Inactive](https://img.shields.io/badge/Inactive-red) | ❌ | | [chat.geekgpt.org](https://chat.geekgpt.org) | `g4f.Provider.GeekGpt` | ✔️ | ✔️ | ✔️ | ![Inactive](https://img.shields.io/badge/Inactive-red) | ❌ |
| [liaobots.site](https://liaobots.site) | `g4f.Provider.Liaobots` | ✔️ | ✔️ | ✔️ | ![Inactive](https://img.shields.io/badge/Inactive-red) | ❌ |
### GPT-3.5 ### GPT-3.5
@ -293,11 +293,11 @@ set G4F_PROXY=http://host:port
| [huggingface.co](https://huggingface.co/chat) | `g4f.Provider.HuggingChat` | ❌ | ❌ | ✔️ | ![Unknown](https://img.shields.io/badge/Unknown-grey) | ❌ | | [huggingface.co](https://huggingface.co/chat) | `g4f.Provider.HuggingChat` | ❌ | ❌ | ✔️ | ![Unknown](https://img.shields.io/badge/Unknown-grey) | ❌ |
| [llama2.ai](https://www.llama2.ai) | `g4f.Provider.Llama2` | ❌ | ❌ | ✔️ | ![Active](https://img.shields.io/badge/Active-brightgreen) | ❌ | | [llama2.ai](https://www.llama2.ai) | `g4f.Provider.Llama2` | ❌ | ❌ | ✔️ | ![Active](https://img.shields.io/badge/Active-brightgreen) | ❌ |
| [labs.perplexity.ai](https://labs.perplexity.ai) | `g4f.Provider.PerplexityLabs` | ❌ | ❌ | ✔️ | ![Active](https://img.shields.io/badge/Active-brightgreen) | ❌ | | [labs.perplexity.ai](https://labs.perplexity.ai) | `g4f.Provider.PerplexityLabs` | ❌ | ❌ | ✔️ | ![Active](https://img.shields.io/badge/Active-brightgreen) | ❌ |
| [phind.com](https://www.phind.com) | `g4f.Provider.Phind` | ❌ | ❌ | ✔️ | ![Unknown](https://img.shields.io/badge/Active-brightgreen) | ❌ |
| [pi.ai](https://pi.ai/talk) | `g4f.Provider.Pi` | ❌ | ❌ | ✔️ | ![Unknown](https://img.shields.io/badge/Active-brightgreen) | ❌ | | [pi.ai](https://pi.ai/talk) | `g4f.Provider.Pi` | ❌ | ❌ | ✔️ | ![Unknown](https://img.shields.io/badge/Active-brightgreen) | ❌ |
| [beta.theb.ai](https://beta.theb.ai) | `g4f.Provider.Theb` | ✔️ | ✔️ | ✔️ | ![Unknown](https://img.shields.io/badge/Unknown-grey) | ❌ | | [beta.theb.ai](https://beta.theb.ai) | `g4f.Provider.Theb` | ✔️ | ✔️ | ✔️ | ![Unknown](https://img.shields.io/badge/Unknown-grey) | ❌ |
| [free.chatgpt.org.uk](https://free.chatgpt.org.uk) | `g4f.Provider.FreeChatgpt` | ✔️ | ✔️ | ✔️ | ![Unknown](https://img.shields.io/badge/Unknown-grey) | ❌ | | [free.chatgpt.org.uk](https://free.chatgpt.org.uk) | `g4f.Provider.FreeChatgpt` | ✔️ | ✔️ | ✔️ | ![Unknown](https://img.shields.io/badge/Unknown-grey) | ❌ |
| [theb.ai](https://theb.ai) | `g4f.Provider.ThebApi` | ❌ | ❌ | ❌ | ![Unknown](https://img.shields.io/badge/Unknown-grey) | ✔️ | | [theb.ai](https://theb.ai) | `g4f.Provider.ThebApi` | ❌ | ❌ | ❌ | ![Unknown](https://img.shields.io/badge/Unknown-grey) | ✔️ |
| [phind.com](https://www.phind.com) | `g4f.Provider.Phind` | ❌ | ❌ | ✔️ | ![Inactive](https://img.shields.io/badge/Inactive-red) | ❌
| [open-assistant.io](https://open-assistant.io/chat) | `g4f.Provider.OpenAssistant` | ❌ | ❌ | ✔️ | ![Inactive](https://img.shields.io/badge/Inactive-red) | ✔️ | | [open-assistant.io](https://open-assistant.io/chat) | `g4f.Provider.OpenAssistant` | ❌ | ❌ | ✔️ | ![Inactive](https://img.shields.io/badge/Inactive-red) | ✔️ |
### Models ### Models

@ -10,11 +10,9 @@ class FlowGpt(AsyncGeneratorProvider, ProviderModelMixin):
url = "https://flowgpt.com/chat" url = "https://flowgpt.com/chat"
working = True working = True
supports_gpt_35_turbo = True supports_gpt_35_turbo = True
supports_gpt_4 = True
supports_message_history = True supports_message_history = True
default_model = "gpt-3.5-turbo" default_model = "gpt-3.5-turbo"
models = [ models = [
"gpt-4",
"gpt-3.5-turbo", "gpt-3.5-turbo",
"gpt-3.5-long", "gpt-3.5-long",
"google-gemini", "google-gemini",

@ -7,6 +7,7 @@ from aiohttp import ClientSession, BaseConnector
from ..typing import AsyncResult, Messages from ..typing import AsyncResult, Messages
from .base_provider import AsyncGeneratorProvider, ProviderModelMixin from .base_provider import AsyncGeneratorProvider, ProviderModelMixin
from .helper import get_connector from .helper import get_connector
from ..errors import RateLimitError
models = { models = {
"gpt-4": { "gpt-4": {
@ -73,7 +74,7 @@ models = {
class Liaobots(AsyncGeneratorProvider, ProviderModelMixin): class Liaobots(AsyncGeneratorProvider, ProviderModelMixin):
url = "https://liaobots.site" url = "https://liaobots.site"
working = False working = True
supports_message_history = True supports_message_history = True
supports_gpt_35_turbo = True supports_gpt_35_turbo = True
supports_gpt_4 = True supports_gpt_4 = True
@ -122,6 +123,8 @@ class Liaobots(AsyncGeneratorProvider, ProviderModelMixin):
json={"authcode": ""}, json={"authcode": ""},
verify_ssl=False verify_ssl=False
) as response: ) as response:
if response.status == 401:
raise RateLimitError("Rate limit reached. Use a other provider or ip address")
response.raise_for_status() response.raise_for_status()
cls._auth_code = (await response.json(content_type=None))["authCode"] cls._auth_code = (await response.json(content_type=None))["authCode"]
cls._cookie_jar = session.cookie_jar cls._cookie_jar = session.cookie_jar

@ -51,7 +51,6 @@ from .Liaobots import Liaobots
from .Llama2 import Llama2 from .Llama2 import Llama2
from .OnlineGpt import OnlineGpt from .OnlineGpt import OnlineGpt
from .PerplexityLabs import PerplexityLabs from .PerplexityLabs import PerplexityLabs
from .Phind import Phind
from .Pi import Pi from .Pi import Pi
from .Vercel import Vercel from .Vercel import Vercel
from .Ylokh import Ylokh from .Ylokh import Ylokh

@ -5,13 +5,14 @@ import json
from urllib import parse from urllib import parse
from datetime import datetime from datetime import datetime
from ..typing import AsyncResult, Messages from ...typing import AsyncResult, Messages
from .base_provider import AsyncGeneratorProvider from ..base_provider import AsyncGeneratorProvider
from ..requests import StreamSession from ...requests import StreamSession
class Phind(AsyncGeneratorProvider): class Phind(AsyncGeneratorProvider):
url = "https://www.phind.com" url = "https://www.phind.com"
working = True working = False
lockdown = True
supports_stream = True supports_stream = True
supports_message_history = True supports_message_history = True

@ -22,4 +22,5 @@ from .Cromicle import Cromicle
from .Opchatgpts import Opchatgpts from .Opchatgpts import Opchatgpts
from .Yqcloud import Yqcloud from .Yqcloud import Yqcloud
from .Aichat import Aichat from .Aichat import Aichat
from .Berlin import Berlin from .Berlin import Berlin
from .Phind import Phind

@ -35,4 +35,7 @@ class MissingAuthError(Exception):
... ...
class NoImageResponseError(Exception): class NoImageResponseError(Exception):
...
class RateLimitError(Exception):
... ...

@ -183,7 +183,6 @@
<option value="OpenaiChat">OpenaiChat</option> <option value="OpenaiChat">OpenaiChat</option>
<option value="Gemini">Gemini</option> <option value="Gemini">Gemini</option>
<option value="Liaobots">Liaobots</option> <option value="Liaobots">Liaobots</option>
<option value="Phind">Phind</option>
<option value="You">You</option> <option value="You">You</option>
<option value="">----</option> <option value="">----</option>
</select> </select>

Loading…
Cancel
Save