Hk-Gosuto / ChatGPT-Next-Web-LangChain

一键拥有你自己的 ChatGPT 网页服务。 One-Click to deploy your own ChatGPT web UI.(基于 langchain 实现的插件版本 Plugin version implemented based on langchain)
https://n3xt.chat
MIT License
1.14k stars 396 forks source link

[Bug] 使用DALL.E进行绘画时,出现图片未成功写入R2存储桶,图片无法显示 #39

Closed s181462537 closed 11 months ago

s181462537 commented 11 months ago

使用DALL.E进行绘画时,出现图片无法显示情况如下图 image 查看cloudflare中的R2中,没有出现新的图片,应该是未成功写入,尝试使用来显示R2中已有的图片,图片能过正常显示出来。所以问题应该是出在不能成功将图片写入到R2,请问这要怎么解决?

Issues-translate-bot commented 11 months ago

Bot detected the issue body's language is not English, translate it automatically.


Title: [Bug] When using DALL.E to draw, the image was not successfully written to the R2 bucket and the image could not be displayed.

s181462537 commented 11 months ago

修改/api/file/xxx.png为已有的图片,是可以正常显示的

Issues-translate-bot commented 11 months ago

Bot detected the issue body's language is not English, translate it automatically.


Modify /api/file/xxx.png to the existing picture, and it can be displayed normally.

Hk-Gosuto commented 11 months ago

可以尝试按以下步骤检查:

  1. R2 服务的 token 是否具有写入权限
  2. 确认当前的 openai token 可以正常使用 dall-e 服务
  3. 检查日志中的 dall-e 返回的图片 url 是否可以在你当前的网络环境正常访问
Issues-translate-bot commented 11 months ago

Bot detected the issue body's language is not English, translate it automatically.


You can try following these steps to check:

  1. Whether the token of the R2 service has write permissions
  2. Confirm that the current openai token can use the dall-e service normally
  3. Check whether the image URL returned by dall-e in the log can be accessed normally in your current network environment
s181462537 commented 11 months ago

1、R2的密钥权限设置的是管理员读和写; 2、能正常反回图片的url,说明能正常使用dall-e服务 3、反回的url路径是指向R2的,但R2中未正常写入图片 我的R2存储桶设为开放后,用那个公共url打开网页还是会显示无权访问,会不会是这个原因,R2存储桶并未成功开放权限,导致无法写入?是否还有什么设置被遗漏了呢

Issues-translate-bot commented 11 months ago

Bot detected the issue body's language is not English, translate it automatically.


  1. The key permissions of R2 are set to administrator read and write;
  2. The URL of the picture can be returned normally, indicating that the dall-e service can be used normally.
  3. The returned URL path points to R2, but the image is not written normally in R2. After my R2 bucket is set to open, when I open the webpage using the public URL, it still shows that I have no access. Is it possible that for this reason, the R2 bucket has not successfully opened the permissions, resulting in the inability to write? Are there any settings that have been missed?
Hk-Gosuto commented 11 months ago

使用的是 openai 官方的接口和 key 么,还是其它的中转服务?

Issues-translate-bot commented 11 months ago

Bot detected the issue body's language is not English, translate it automatically.


Are you using openai’s official interface and key, or other transfer services?

s181462537 commented 11 months ago

使用的是GPT_API_free项目获得的免费api,接口是https://api.chatanywhere.com.cn

Hk-Gosuto commented 11 months ago

这个转发服务的免费版本并不支持 DALL-E 服务

https://github.com/chatanywhere/GPT_API_free?tab=readme-ov-file#%E7%89%B9%E7%82%B9

支持Models, Embedding, text-davinci, GPT-3.5-Turbo, GPT-3.5-Turbo-16K(免费版不支持), GPT-4(免费版不支持), DALLE(免费版不支持), Whisper(免费版不支持)。(免费版就可以支持AutoGPT, gpt_academic, langchain等)

s181462537 commented 11 months ago

原来如此,我没注意去看项目细节,非常感谢,我回头用官网api试试

Issues-translate-bot commented 11 months ago

Bot detected the issue body's language is not English, translate it automatically.


It turns out that’s the case. I didn’t pay attention to the project details. Thank you very much. I’ll try it later using the official website API.