XFE Git
XFE Studio Git
Git 首页 全局搜索
XFE 主站 文档 NuGet
公开
关注 0 Fork 0 Star 0
返回提交历史

XFEstudio/gpt4free

Update PollinationsAI login URL and fix response handling in Completions class

dd08d9e4
hlohaus <983577+hlohaus@users.noreply.github.com>
提交于

代码差异

2 个文件 +2 -3
Modified g4f/Provider/PollinationsAI.py +1 -2
@@ -1,7 +1,6 @@
1 1 from __future__ import annotations
2 2
3 3 import time
4 import json
5 4 import random
6 5 import requests
7 6 import asyncio
@@ -34,7 +33,7 @@ DEFAULT_HEADERS = {
34 33 class PollinationsAI(AsyncGeneratorProvider, ProviderModelMixin):
35 34 label = "Pollinations AI 🌸"
36 35 url = "https://pollinations.ai"
37 login_url = "https://auth.pollinations.ai"
36 login_url = "https://enter.pollinations.ai"
38 37 active_by_default = True
39 38 working = True
40 39 supports_system_message = True
Modified g4f/client/__init__.py +1 -1
@@ -361,7 +361,7 @@ class Completions:
361 361 yield chunk
362 362 if stream:
363 363 return raw_response(response)
364 return next(raw_response())
364 return next(raw_response(response))
365 365 if stream:
366 366 return fallback(response)
367 367 return next(fallback(response))