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

XFEstudio/gpt4free

fix subDomain of LockChat

e079d95b
Lê Anh Tuấn <justin.le.1105@gmail.com>
提交于

代码差异

1 个文件 +2 -2
Modified g4f/Provider/Providers/Lockchat.py +2 -2
@@ -2,7 +2,7 @@ import requests
2 2 import os
3 3 import json
4 4 from ...typing import sha256, Dict, get_type_hints
5 url = 'http://super.lockchat.app'
5 url = 'http://supertest.lockchat.app'
6 6 model = ['gpt-4', 'gpt-3.5-turbo']
7 7 supports_stream = True
8 8 needs_auth = False
@@ -18,7 +18,7 @@ def _create_completion(model: str, messages: list, stream: bool, temperature: fl
18 18 headers = {
19 19 "user-agent": "ChatX/39 CFNetwork/1408.0.4 Darwin/22.5.0",
20 20 }
21 response = requests.post("http://super.lockchat.app/v1/chat/completions?auth=FnMNPlwZEnGFqvEc9470Vw==",
21 response = requests.post("http://supertest.lockchat.app/v1/chat/completions",
22 22 json=payload, headers=headers, stream=True)
23 23 for token in response.iter_lines():
24 24 if b'The model: `gpt-4` does not exist' in token: