aurora-develop / aurora Goto Github PK
View Code? Open in Web Editor NEWfree
License: MIT License
free
License: MIT License
编译错误Error: please put HAR files in harPool directory!arm64的机器
Is it free on render?
root@vm3:~/chatgpt-qq# curl --location 'http://127.0.0.1:8080/v1/chat/completions' --header 'Content-Type: application/json' --data '{
"model": "gpt-3.5-turbo",
"messages": [{"role": "user", "content": "Say this is a test!"}],
"stream": true
}'
{"code":500,"message":"error sending request","param":{},"type":"InitTurnStile_request_error"}
https://planned-lorianna-yunfeiyang.koyeb.app/
使用返回500错误码。尝试更换过环境变量中的baseurl
控制台log有以下报错出现
2024/04/06 08:30:35 [Recovery] 2024/04/06 - 08:30:35 panic recovered:
runtime error: invalid memory address or nil pointer dereference
/layers/heroku_go/shim/go1.21.5/go/src/runtime/panic.go:261 (0x44def7)
/layers/heroku_go/shim/go1.21.5/go/src/runtime/signal_unix.go:861 (0x44dec5)
/workspace/internal/chatgpt/request.go:225 (0x8cbe5d)
InitTurnStile: defer response.Body.Close()
/workspace/handlers.go:173 (0x8e4524)
(*Handler).nightmare: turnStile, status, err := chatgpt.InitTurnStile(client, secret, proxyUrl, 5)
/layers/heroku_go/shim/go-path/pkg/mod/github.com/gin-gonic/[email protected]/context.go:174 (0x8e6baf)
[GIN] 2024/04/06 - 08:30:35 | 500 | 9.144953309s | 193.122.113.204 | POST "/v1/chat/completions"
/workspace/middleware.go:33 (0x8e6af4)
Authorization: c.Next()
/layers/heroku_go/shim/go-path/pkg/mod/github.com/gin-gonic/[email protected]/context.go:174 (0x8e6955)
/workspace/middleware.go:14 (0x8e6943)
cors: c.Next()
/layers/heroku_go/shim/go-path/pkg/mod/github.com/gin-gonic/[email protected]/context.go:174 (0x8b4599)
/layers/heroku_go/shim/go-path/pkg/mod/github.com/gin-gonic/[email protected]/recovery.go:102 (0x8b4587)
/layers/heroku_go/shim/go-path/pkg/mod/github.com/gin-gonic/[email protected]/context.go:174 (0x8b373d)
/layers/heroku_go/shim/go-path/pkg/mod/github.com/gin-gonic/[email protected]/logger.go:240 (0x8b3700)
/layers/heroku_go/shim/go-path/pkg/mod/github.com/gin-gonic/[email protected]/context.go:174 (0x8b27fa)
/layers/heroku_go/shim/go-path/pkg/mod/github.com/gin-gonic/[email protected]/gin.go:620 (0x8b248d)
/layers/heroku_go/shim/go-path/pkg/mod/github.com/gin-gonic/[email protected]/gin.go:576 (0x8b213c)
/layers/heroku_go/shim/go1.21.5/go/src/net/http/server.go:2938 (0x6ac48d)
/layers/heroku_go/shim/go1.21.5/go/src/net/http/server.go:2009 (0x6a9133)
/layers/heroku_go/shim/go1.21.5/go/src/runtime/asm_amd64.s:1650 (0x46a3e0)
2024/04/06 08:30:44 [Recovery] 2024/04/06 - 08:30:44 panic recovered:
[GIN] 2024/04/06 - 08:30:44 | 500 | 14.685266049s | 193.122.113.204 | POST "/v1/chat/completions"
runtime error: invalid memory address or nil pointer dereference
/layers/heroku_go/shim/go1.21.5/go/src/runtime/panic.go:261 (0x44def7)
/layers/heroku_go/shim/go1.21.5/go/src/runtime/signal_unix.go:861 (0x44dec5)
/workspace/internal/chatgpt/request.go:225 (0x8cbe5d)
InitTurnStile: defer response.Body.Close()
/workspace/handlers.go:173 (0x8e4524)
(*Handler).nightmare: turnStile, status, err := chatgpt.InitTurnStile(client, secret, proxyUrl, 5)
/layers/heroku_go/shim/go-path/pkg/mod/github.com/gin-gonic/[email protected]/context.go:174 (0x8e6baf)
/workspace/middleware.go:33 (0x8e6af4)
Authorization: c.Next()
/layers/heroku_go/shim/go-path/pkg/mod/github.com/gin-gonic/[email protected]/context.go:174 (0x8e6955)
/workspace/middleware.go:14 (0x8e6943)
cors: c.Next()
/layers/heroku_go/shim/go-path/pkg/mod/github.com/gin-gonic/[email protected]/context.go:174 (0x8b4599)
/layers/heroku_go/shim/go-path/pkg/mod/github.com/gin-gonic/[email protected]/recovery.go:102 (0x8b4587)
/layers/heroku_go/shim/go-path/pkg/mod/github.com/gin-gonic/[email protected]/context.go:174 (0x8b373d)
/layers/heroku_go/shim/go-path/pkg/mod/github.com/gin-gonic/[email protected]/logger.go:240 (0x8b3700)
/layers/heroku_go/shim/go-path/pkg/mod/github.com/gin-gonic/[email protected]/context.go:174 (0x8b27fa)
/layers/heroku_go/shim/go-path/pkg/mod/github.com/gin-gonic/[email protected]/gin.go:620 (0x8b248d)
/layers/heroku_go/shim/go-path/pkg/mod/github.com/gin-gonic/[email protected]/gin.go:576 (0x8b213c)
/layers/heroku_go/shim/go1.21.5/go/src/net/http/server.go:2938 (0x6ac48d)
/layers/heroku_go/shim/go1.21.5/go/src/net/http/server.go:2009 (0x6a9133)
/layers/heroku_go/shim/go1.21.5/go/src/runtime/asm_amd64.s:1650 (0x46a3e0)
[GIN] 2024/04/06 - 08:30:53 | 500 | 20.395820899s | 193.122.113.204 | POST "/v1/chat/completions"
2024/04/06 08:30:53 [Recovery] 2024/04/06 - 08:30:53 panic recovered:
runtime error: invalid memory address or nil pointer dereference
/layers/heroku_go/shim/go1.21.5/go/src/runtime/panic.go:261 (0x44def7)
/layers/heroku_go/shim/go1.21.5/go/src/runtime/signal_unix.go:861 (0x44dec5)
/workspace/internal/chatgpt/request.go:225 (0x8cbe5d)
InitTurnStile: defer response.Body.Close()
/workspace/handlers.go:173 (0x8e4524)
(*Handler).nightmare: turnStile, status, err := chatgpt.InitTurnStile(client, secret, proxyUrl, 5)
/layers/heroku_go/shim/go-path/pkg/mod/github.com/gin-gonic/[email protected]/context.go:174 (0x8e6baf)
/workspace/middleware.go:33 (0x8e6af4)
Authorization: c.Next()
/layers/heroku_go/shim/go-path/pkg/mod/github.com/gin-gonic/[email protected]/context.go:174 (0x8e6955)
/workspace/middleware.go:14 (0x8e6943)
cors: c.Next()
/layers/heroku_go/shim/go-path/pkg/mod/github.com/gin-gonic/[email protected]/context.go:174 (0x8b4599)
/layers/heroku_go/shim/go-path/pkg/mod/github.com/gin-gonic/[email protected]/recovery.go:102 (0x8b4587)
/layers/heroku_go/shim/go-path/pkg/mod/github.com/gin-gonic/[email protected]/context.go:174 (0x8b373d)
/layers/heroku_go/shim/go-path/pkg/mod/github.com/gin-gonic/[email protected]/logger.go:240 (0x8b3700)
/layers/heroku_go/shim/go-path/pkg/mod/github.com/gin-gonic/[email protected]/context.go:174 (0x8b27fa)
/layers/heroku_go/shim/go-path/pkg/mod/github.com/gin-gonic/[email protected]/gin.go:620 (0x8b248d)
/layers/heroku_go/shim/go-path/pkg/mod/github.com/gin-gonic/[email protected]/gin.go:576 (0x8b213c)
/layers/heroku_go/shim/go1.21.5/go/src/net/http/server.go:2938 (0x6ac48d)
/layers/heroku_go/shim/go1.21.5/go/src/net/http/server.go:2009 (0x6a9133)
/layers/heroku_go/shim/go1.21.5/go/src/runtime/asm_amd64.s:1650 (0x46a3e0)
2024/04/06 08:32:04 [Recovery] 2024/04/06 - 08:32:04 panic recovered:
runtime error: invalid memory address or nil pointer dereference
/layers/heroku_go/shim/go1.21.5/go/src/runtime/panic.go:261 (0x44def7)
/layers/heroku_go/shim/go1.21.5/go/src/runtime/signal_unix.go:861 (0x44dec5)
/workspace/internal/chatgpt/request.go:225 (0x8cbe5d)
InitTurnStile: defer response.Body.Close()
/workspace/handlers.go:173 (0x8e4524)
(*Handler).nightmare: turnStile, status, err := chatgpt.InitTurnStile(client, secret, proxyUrl, 5)
/layers/heroku_go/shim/go-path/pkg/mod/github.com/gin-gonic/[email protected]/context.go:174 (0x8e6baf)
/workspace/middleware.go:33 (0x8e6af4)
Authorization: c.Next()
/layers/heroku_go/shim/go-path/pkg/mod/github.com/gin-gonic/[email protected]/context.go:174 (0x8e6955)
/workspace/middleware.go:14 (0x8e6943)
cors: c.Next()
/layers/heroku_go/shim/go-path/pkg/mod/github.com/gin-gonic/[email protected]/context.go:174 (0x8b4599)
/layers/heroku_go/shim/go-path/pkg/mod/github.com/gin-gonic/[email protected]/recovery.go:102 (0x8b4587)
/layers/heroku_go/shim/go-path/pkg/mod/github.com/gin-gonic/[email protected]/context.go:174 (0x8b373d)
/layers/heroku_go/shim/go-path/pkg/mod/github.com/gin-gonic/[email protected]/logger.go:240 (0x8b3700)
/layers/heroku_go/shim/go-path/pkg/mod/github.com/gin-gonic/[email protected]/context.go:174 (0x8b27fa)
/layers/heroku_go/shim/go-path/pkg/mod/github.com/gin-gonic/[email protected]/gin.go:620 (0x8b248d)
/layers/heroku_go/shim/go-path/pkg/mod/github.com/gin-gonic/[email protected]/gin.go:576 (0x8b213c)
/layers/heroku_go/shim/go1.21.5/go/src/net/http/server.go:2938 (0x6ac48d)
/layers/heroku_go/shim/go1.21.5/go/src/net/http/server.go:2009 (0x6a9133)
/layers/heroku_go/shim/go1.21.5/go/src/runtime/asm_amd64.s:1650 (0x46a3e0)
[GIN] 2024/04/06 - 08:32:04 | 500 | 8.808112068s | 193.122.113.204 | POST "/v1/chat/completions"
我看是支持stream=ture的。请问如何流式打印返回的内容?请大侠指导。
我使用的python代码是这样的:
import requests
import json
url = "http://127.0.0.1:8080/v1/chat/completions"
headers = {"Content-Type": "application/json"}
data = {
"model": "gpt-3.5-turbo",
"messages": [{
"role": "user",
"content": "Hi"
}],
"stream":True
}
response = requests.post(url, headers=headers, data=json.dumps(data))
以及其他可能需要的
查了一下,好像比较容易🥹
import (
"github.com/gin-gonic/autotls"
"github.com/gin-gonic/gin"
"golang.org/x/crypto/acme/autocert"
)
.gitattributes
文件可以用于定义项目中文件的属性,以优化项目的版本控制。定义行尾风格:,.gitattributes
文件可以用于定义行尾风格。你可以设置所有的 .go
和 .html
文件在提交时自动转换为 LF 行尾,而在检出时转换为 CRLF 行尾。
*.go text eol=lf
*.html text eol=lf
定义文件的合并策略:.gitattributes
文件可以用于定义特定文件的合并策略。可以设置所有的 .json
文件使用 merge=ours
策略,这意味着在合并冲突时,总是选择当前分支的版本。
*.json merge=ours
请求支持手动配置过盾代理 proxy
是不是被禁了?
最新的镜像出现401错误。这个镜像(sha256:0b7131bc7abd455bfc531a6350be01cb64c6309647c76c7a173519014ad552c7)及以前的可以正常使用。
韩国春川一直401 部署了几遍 是ip问题?
{"code":401,"message":"response status code is not 200","param":{},"type":"InitTurnStile_request_error"}
I tried the example in the README.
curl --location 'http://127.0.0.1:8080/v1/chat/completions' \
--header 'Content-Type: application/json' \
--data '{
"model": "gpt-3.5-turbo",
"messages": [{"role": "user", "content": "Say this is a test!"}],
"stream": true
}'
The response is as following:
{"id":"xxxx","object":"chat.completion","created":0,"model":"gpt-3.5-turbo-0125","usage":{"prompt_tokens":0,"completion_tokens":0,"total_tokens":0},"choices":[{"index":0,"message":{"role":"assistant","content":"\"This is a test!\""},"finish_reason":null}]}
The tokens in the "usage" are all zero.
Can you fix it.
Thank for your great work.
{
"code": 401,
"message": "response status code is not 200",
"param": {},
"type": "InitTurnStile_request_error"
}
有另外一台ip可以正常运行,这台KR的就不行,但是在KR的chatgptnext上面填我另外一条的api就可以
报告佬: 有错误,不知道如何解决
$docker ps
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
baa2171b690f ghcr.io/aurora-develop/aurora:latest "./aurora" About a minute ago Up About a minute 0.0.0.0:8080->8080/tcp naughty_bartik
$curl --location 'http://127.0.0.1:8080/v1/chat/completions' --header 'Content-Type: application/json' --data '{
"model": "gpt-3.5-turbo",
"messages": [{"role": "user", "content": "Say this is a test!"}]
}'
{"error":"unable to check chat requirement"}
咋整 直接拉取的镜像部署后 使用 提示未经授权...
如题,昨天晚上还是可以的,今天就总是500了,拼命重试可以刷新出几次可以正常回答。
例如ip限制或者key之类的
测试了一下,用中文提问,返回的text是乱码。如果用英文,一切正常。大家是这种情况吗?
curl --location 'http://127.0.0.1:8080/v1/chat/completions' \
--header 'Content-Type: application/json'
--data '{
"model": "gpt-3.5-turbo",
"messages": [{"role": "user", "content": "Say this is a test!"}],
"stream": true
}'
data: {"id":"chatcmpl-QXlha2FBbmROaXhpZUFyZUF3ZXNvbWUK","object":"chat.completion.chunk","created":0,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"role":"assistant"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-QXlha2FBbmROaXhpZUFyZUF3ZXNvbWUK","object":"chat.completion.chunk","created":0,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":"This"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-QXlha2FBbmROaXhpZUFyZUF3ZXNvbWUK","object":"chat.completion.chunk","created":0,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":" is"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-QXlha2FBbmROaXhpZUFyZUF3ZXNvbWUK","object":"chat.completion.chunk","created":0,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":" a"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-QXlha2FBbmROaXhpZUFyZUF3ZXNvbWUK","object":"chat.completion.chunk","created":0,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":" test"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-QXlha2FBbmROaXhpZUFyZUF3ZXNvbWUK","object":"chat.completion.chunk","created":0,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":"!"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-QXlha2FBbmROaXhpZUFyZUF3ZXNvbWUK","object":"chat.completion.chunk","created":0,"model":"gpt-3.5-turbo-0125","choices":[{"delta":{},"index":0,"finish_reason":"stop"}]}
data: [DONE]
[root@instance-20221012-2111 ~]# curl --location 'http://127.0.0.1:8080/v1/chat/completions' \
--header 'Content-Type: application/json'
--data '{
"model": "gpt-3.5-turbo",
"messages": [{"role": "user", "content": "Say this is a test!"}],
"stream": true
}'
data: {"id":"chatcmpl-QXlha2FBbmROaXhpZUFyZUF3ZXNvbWUK","object":"chat.completion.chunk","created":0,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"role":"assistant"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-QXlha2FBbmROaXhpZUFyZUF3ZXNvbWUK","object":"chat.completion.chunk","created":0,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":"This"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-QXlha2FBbmROaXhpZUFyZUF3ZXNvbWUK","object":"chat.completion.chunk","created":0,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":" is"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-QXlha2FBbmROaXhpZUFyZUF3ZXNvbWUK","object":"chat.completion.chunk","created":0,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":" a"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-QXlha2FBbmROaXhpZUFyZUF3ZXNvbWUK","object":"chat.completion.chunk","created":0,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":" test"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-QXlha2FBbmROaXhpZUFyZUF3ZXNvbWUK","object":"chat.completion.chunk","created":0,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":"!"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-QXlha2FBbmROaXhpZUFyZUF3ZXNvbWUK","object":"chat.completion.chunk","created":0,"model":"gpt-3.5-turbo-0125","choices":[{"delta":{},"index":0,"finish_reason":"stop"}]}
data: [DONE]
使用nextchat也报错{
"error": true,
"message": "Failed to fetch"
}
接口地址写入的http://127.0.0.1:8080/v1/chat/completions
postman 请求http://127.0.0.1:8080/v1/chat/completions 也是404 page not found
出啥情况了? 早上还好好的 现在403了
三台服务器都403
部署后打开网址只有提示{"message":"Hello, world!"},在vps上用curl输出结果如下:
curl --location 'http://127.0.0.1:8080/v1/chat/completions'
--header 'Content-Type: application/json'
--data '{
"model": "gpt-3.5-turbo",
"messages": [{"role": "user", "content": "Say this is a test!"}],
"stream": true
}
data: {"id":"chatcmpl-QXlha2FBbmROaXhpZUFyZUF3ZXNvbWUK","object":"chat.completion.chunk","created":0,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"role":"assistant"},"index":0,"finish_reason":null}]}data: {"id":"chatcmpl-QXlha2FBbmROaXhpZUFyZUF3ZXNvbWUK","object":"chat.completion.chunk","created":0,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":"This"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-QXlha2FBbmROaXhpZUFyZUF3ZXNvbWUK","object":"chat.completion.chunk","created":0,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":" is"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-QXlha2FBbmROaXhpZUFyZUF3ZXNvbWUK","object":"chat.completion.chunk","created":0,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":" a"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-QXlha2FBbmROaXhpZUFyZUF3ZXNvbWUK","object":"chat.completion.chunk","created":0,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":" test"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-QXlha2FBbmROaXhpZUFyZUF3ZXNvbWUK","object":"chat.completion.chunk","created":0,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":"!"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-QXlha2FBbmROaXhpZUFyZUF3ZXNvbWUK","object":"chat.completion.chunk","created":0,"model":"gpt-3.5-turbo-0125","choices":[{"delta":{},"index":0,"finish_reason":"stop"}]}
data: [DONE]
Can you support python? thank you
可以使用api,但是网页对话不了?
https://aurora-la
使用镜像:#122 (comment)
http://172.233.137.
使用最新镜像
ghcr.io/aurora-develop/aurora latest c4ea1f094830 About an hour ago 23.9MB
用F12看了一下,好像是请求url的问题?
http://172.233.137.23
个人的小服务器不经薅,希望加点防护 🥹
之前我一直使用: ChatGPT-to-API
后来这个不能用,目前这个aurora是我用过最好的同类应用,可以直接用api !!!希望再接再厉!
BASE_URL=“https://auroraxf.glitch.me/api” (CN网络无法使用)
BASE_URL="https://api.angelxf.cf/api" (快速)
环境变量已支持自定义base_url,使用代理的url可以绕过限制
由于滥用严重 服务器苦不受堪 故关闭免费网关
UI界面管理账号、指纹等功能
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.