Comments (6)
没有涉及config.py更新的话,最简单的可以删掉重新拉取,再替换config.py
from gpt_academic.
cp config.py config_private.py # 复制配置文件
git pull --force # 更新代码
# p.s. 更新完之后,config_private.py的读取顺序会比config.py高,所以不需要再把config_private.py的内容写回去
from gpt_academic.
更新后, 代理失效,报错如下:
代理配置 127.0.0.1:7890 , 代理所在地查询超时,代理可能无效
from gpt_academic.
@liulang915871 那可能是代理失效了,以下是测试代理的代码,是很简单的:
def check_proxy(proxies):
import requests
proxies_https = proxies['https'] if proxies is not None else '无'
try:
response = requests.get("https://ipapi.co/json/", proxies=proxies, timeout=4)
data = response.json()
print(f'查询代理的地理位置,返回的结果是{data}')
country = data['country_name']
result = f"代理配置 {proxies_https}, 代理所在地:{country}"
print(result)
return result
except:
result = f"代理配置 {proxies_https}, 代理所在地查询超时,代理可能无效"
print(result)
return result
if __name__ == '__main__':
try: from config_private import proxies # 放自己的秘密如API和代理网址 os.path.exists('config_private.py')
except: from config import proxies
check_proxy(proxies)
如果是飞机场,有可能是ip太多人共用?
from gpt_academic.
@binary-husky 谢谢您的帮助,终于搞定了。 我不是代理的问题,更新后config.py其实变了,我又将原来的储存为了config_private.py。最后我将所有的都删了,重新安装配置,就成功了。
from gpt_academic.
同出现问题,求详细解决步骤 … 感谢
from gpt_academic.
Related Issues (20)
- [Bug]:调用deepseek-coder时,会显示对话,但对话未完成出现: [Local Message] {finish_reason},获得以下报错信息: data: [DONE] HOT 2
- [Bug]: 随机小游戏应该怎么退出呢,我是菜鸟,请指教,谢谢! HOT 1
- [Bug]: 和protobuf版本相关的依赖冲突 HOT 4
- [Bug]: RuntimeError: Nougat解析论文失败。 HOT 1
- [Bug]: git pull到了新的版本,安装了requirements.txt HOT 4
- [Bug]: api额度不足
- [Feature]: 输入区,输入时换行无法实现
- [Bug]: docker代理地址查询超时 HOT 2
- [Feature]: 能否支持后台运行
- [Feature]: 微信群过期了T T
- [Bug]: 图片生产dall- HOT 1
- [Feature]: 针对OpenAI系的大模型,能否区别3.5和4.0API并在调用模型的时候自动切换
- [Bug]: 不支持不了智谱GM4的API KEY
- python main.py 不能运行[Bug]: HOT 1
- one-api 等待响应后显示 代理服务器无法使用 HOT 1
- [Bug]: 通义千问请配置 DASHSCOPE_API_KEY HOT 1
- [Bug]: Claude-3-5Sonnet
- [Feature]: 如何添加4omini的配置 HOT 5
- [Bug]: 模型输出同时包含代码和latex格式文本时,latex文本渲染失效
- [Feature]: claude-3.5-sonnet support HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from gpt_academic.