各位大佬,有谁知道目前哪个项目可以把Claude官网逆向为API在one-api中使用?
6 Likes
clewd可以
1 Like
clewd可以
1 Like
谢谢,我试试
谢谢大佬,论坛常驻人口
谁出一个逆向教程
1 Like
除了clewd还有啥,3.7thinking貌似没逆向出来
暂时知道的只有clewd,你可以自己改改代码实现。或者来看看我这个你需要吧?普号可用thinking
https://linux.do/t/topic/481687
clewd挺好用,试试呗
希望想来一个2API
clewd就是2api啊
我刚试了下 baseurl+/v1/chat/completions 没成,不兼容OpenAI SDK吗?
我是往new-api添加的
兼容啊,你是报什么错?你是自己部署的吗?
对 自己部署的,报错:
SyntaxError: Unexpected end of JSON input
at JSON.parse (<anonymous>)
at IncomingMessage.<anonymous> (/home/clewd/clewd.js:461:39)
at IncomingMessage.emit (node:events:518:28)
at endReadableNT (node:internal/streams/readable:1698:12)
at process.processTicksAndRejections (node:internal/process/task_queues:90:21) {
[stack]: [Getter/Setter],
[message]: 'Unexpected end of JSON input'
}
SyntaxError: Unexpected end of JSON input
at JSON.parse (<anonymous>)
at IncomingMessage.<anonymous> (/home/clewd/clewd.js:461:39)
at IncomingMessage.emit (node:events:518:28)
at endReadableNT (node:internal/streams/readable:1698:12)
at process.processTicksAndRejections (node:internal/process/task_queues:90:21) {
[stack]: [Getter/Setter],
[message]: 'Unexpected end of JSON input'
}
你试试这个佬的docker-compose,记得配置环境变量
https://linux.do/t/topic/471962/40
好的,我试试,感谢
这个正常就直接启动配置好cookie或者cookiearray环境变量就可以用了。我看你那个报错应该是已经调用接口成功,在获取聊天body时报错的。这个正常在newapi应该可以测试成功的,我在始皇的neoapi都测试过是可以的。
我刚docker可以了,curl通
curl -X POST http://127.0.0.1:30007/v1/chat/completions \
-H "Content-Type: application/json" \
-H "Authorization: Bearer 123456" \
-d '{
"model": "claude-3-7-sonnet-20250219",
"messages": [
{
"role": "user",
"content": "hi"
}
],
"temperature": 0.7
}'
奇怪的加到同一环境的new-api提示 请求上游地址失败
难道中间还不通嘛,麻了···
有时候是这样,中间不通实际可用,能用就行,不要纠结,好像newapi是非流的问题?流式就正常