Comments (15)
理论上完全没问题,可以尝试观察下 clash 的日志,确认下 api.openai.com
请求是否走了 clash 的代理,如果没有的需要在 clash 中添加规则
from chatgpt-proxy.
这是我服务端的日志信息,没有timeout之类的报错信息,但是客户端就是连接超时
from chatgpt-proxy.
clash的日志也没有来自openai.com的流量
from chatgpt-proxy.
尝试下 clash 设置为全局代理
from chatgpt-proxy.
尝试下 clash 设置为全局代理
我觉得不是clash的问题,我使用curl能够访问到openai,clash也有记录
[root@localhost /]# curl -x http://localhost:7890 https://api.openai.com/v1/engines/davinci/completions { "error": { "message": "You didn't provide an API key. You need to provide your API key in an Authorization header using Bearer auth (i.e. Authorization: Bearer YOUR_KEY), or as the password field (with blank username) if you're accessing the API from your browser and are prompted for a username and password. You can obtain an API key from https://platform.openai.com/account/api-keys.", "type": "invalid_request_error", "param": null, "code": null } }
from chatgpt-proxy.
如果你用的是 SSE 链接,那么请求失败会有一个报错输出,可以在程序日志搜索下 catch:
看看有没有报错信息
报错代码见:https://github.com/imyuanx/chatgpt-proxy/blob/main/src/pages/api/proxy-sse.js#L31
from chatgpt-proxy.
另外部署完这个应用后得到的 http://.../proxy
、http://.../proxy-sse
链接代理的地址是 https://api.openai.com
,确保你构建的请求路径是正确的
from chatgpt-proxy.
另外部署完这个应用后得到的
http://.../proxy
、http://.../proxy-sse
链接代理的地址是https://api.openai.com
,确保你构建的请求路径是正确的
如果你用的是 SSE 链接,那么请求失败会有一个报错输出,可以在程序日志搜索下
catch:
看看有没有报错信息报错代码见:https://github.com/imyuanx/chatgpt-proxy/blob/main/src/pages/api/proxy-sse.js#L31
好的,我找到了chatgpt-proxy的报错信息
Error: connect ETIMEDOUT 128.242.240.180:443 at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1278:16) { errno: -110, code: 'ETIMEDOUT', syscall: 'connect', address: '128.242.240.180', port: 443 }
该项目得到的链接是不会经过clash代理吗,clash没有这个代理项目的日志信息
from chatgpt-proxy.
理论上来说你服务器上的所有流量都是会走 clash 的规则的
from chatgpt-proxy.
服务器和有没有clash没关系吧 只要服务器是海外的vps就行。
我vps是香港阿里云的。搭建后 啥都没设置
from chatgpt-proxy.
服务器和有没有clash没关系吧 只要服务器是海外的vps就行。 我vps是香港阿里云的。搭建后 啥都没设置
没有香港的服务器,想自己搭个项目玩玩,按理来说有代理可以翻墙也行,卡在这了
from chatgpt-proxy.
服务器和有没有clash没关系吧 只要服务器是海外的vps就行。 我vps是香港阿里云的。搭建后 啥都没设置
没有香港的服务器,想自己搭个项目玩玩,按理来说有代理可以翻墙也行,卡在这了
香港服务器是个隐喻,海外服务器都可以,因为openai是在国内屏蔽了访问,但海外的ip不受国内墙的限制(主要这个服务器ip没有被墙)。
如果你是国内的服务器,搭建的这个项目,例如国内服务器绑定的域名(ip)是xxx1。
那么,你clash上要设置的应该是,xxx1,走clash的代理。
不过,你用国内的vps了,而且有clash了,为啥要搭建这个反代。直接用 api.openai.com 这个挂代理,就行了啊。
我用UP主这个服务,主要就是为了海外vps挂个反代api.openai.com的服务,在国内使用,不用挂代理了。
from chatgpt-proxy.
服务器和有没有clash没关系吧 只要服务器是海外的vps就行。 我vps是香港阿里云的。搭建后 啥都没设置
没有香港的服务器,想自己搭个项目玩玩,按理来说有代理可以翻墙也行,卡在这了
香港服务器是个隐喻,海外服务器都可以,因为openai是在国内屏蔽了访问,但海外的ip不受国内墙的限制(主要这个服务器ip没有被墙)。
如果你是国内的服务器,搭建的这个项目,例如国内服务器绑定的域名(ip)是xxx1。
那么,你clash上要设置的应该是,xxx1,走clash的代理。
不过,你用国内的vps了,而且有clash了,为啥要搭建这个反代。直接用 api.openai.com 这个挂代理,就行了啊。
我用UP主这个服务,主要就是为了海外vps挂个反代api.openai.com的服务,在国内使用,不用挂代理了。
我的不是云服务器,是安装的虚拟机,只是想部署一个应用玩玩,主要是我对js不怎么懂,用的别人的项目,不然就自己改代码了。
from chatgpt-proxy.
服务器和有没有clash没关系吧 只要服务器是海外的vps就行。 我vps是香港阿里云的。搭建后 啥都没设置
没有香港的服务器,想自己搭个项目玩玩,按理来说有代理可以翻墙也行,卡在这了
香港服务器是个隐喻,海外服务器都可以,因为openai是在国内屏蔽了访问,但海外的ip不受国内墙的限制(主要这个服务器ip没有被墙)。
如果你是国内的服务器,搭建的这个项目,例如国内服务器绑定的域名(ip)是xxx1。
那么,你clash上要设置的应该是,xxx1,走clash的代理。
不过,你用国内的vps了,而且有clash了,为啥要搭建这个反代。直接用 api.openai.com 这个挂代理,就行了啊。
我用UP主这个服务,主要就是为了海外vps挂个反代api.openai.com的服务,在国内使用,不用挂代理了。
我的不是云服务器,是安装的虚拟机,只是想部署一个应用玩玩,主要是我对js不怎么懂,用的别人的项目,不然就自己改代码了。
😂😂 那你应该部署个chatgptweb项目。
这个是代理用的。😂😂
from chatgpt-proxy.
Related Issues (18)
- 请问这个是作为chatgpt接口代理吗? HOT 17
- 请教,https无法访问怎么办 HOT 7
- 请问自部署的话对VPS的IP有没有要求? HOT 2
- 部署后,无法打开网址。 HOT 5
- VPS部署的是不是不支持SSE呢 HOT 6
- 如何手动部署 HOT 1
- 使用SSE有报错 HOT 4
- 流式输出,不够丝滑 HOT 2
- openai-translator配置代理url后无法使用 HOT 1
- 似乎不支持转发 TTS api 的接口?Invalid URL (POST /audio/speech)
- 我已经部署在zeabur,但是还是不会用 HOT 10
- 🔴 可用在「ChatGPTUnofficialProxyAPI」的「API_REVERSE_PROXY」吗? HOT 2
- 成功部署后无法使用。 HOT 1
- 搭建这个API反代 是不是可以国内使用这个API反代 HOT 3
- zeabur部署成功了,非SSE模式也成功了,但是SSE 模式不成功 HOT 4
- 不支持代理聊天页面吗? HOT 1
- 构建失败了 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 chatgpt-proxy.