[GH-ISSUE #515] WebUI API请求URL问题 #368

Closed
opened 2026-10-29 14:38:35 +00:00 by bsakaguchi · 24 comments
Owner

Originally created by @ArSrNa on GitHub (Feb 19, 2025).
Original GitHub issue: https://github.com/kvcache-ai/ktransformers/issues/515

使用KTransformer启动WebUI模式的时候,控制台里面大部分请求都失败,原因是走了localhost的地址,这个地方应该换成/而非localhost:port/

Image

Originally created by @ArSrNa on GitHub (Feb 19, 2025). Original GitHub issue: https://github.com/kvcache-ai/ktransformers/issues/515 使用KTransformer启动WebUI模式的时候,控制台里面大部分请求都失败,原因是走了`localhost`的地址,这个地方应该换成`/`而非`localhost:port/` ![Image](https://github.com/user-attachments/assets/f0cab1cb-74a0-4af1-9585-e5b48b33081e)
Author
Owner

@SongXiaoMao commented on GitHub (Feb 20, 2025):

是的 只能本机服务器上使用 其他IP访问端口只显示页面 不能对话 我也发现这个BUG了

<!-- gh-comment-id:2670294933 --> @SongXiaoMao commented on GitHub (Feb 20, 2025): 是的 只能本机服务器上使用 其他IP访问端口只显示页面 不能对话 我也发现这个BUG了
Author
Owner

@SongXiaoMao commented on GitHub (Feb 20, 2025):

还有个问题你发现了么 使用webUI对话 没有思考过程 think标签都是空的

<!-- gh-comment-id:2670295395 --> @SongXiaoMao commented on GitHub (Feb 20, 2025): 还有个问题你发现了么 使用webUI对话 没有思考过程 think标签都是空的
Author
Owner

@chenxianpeng1998 commented on GitHub (Feb 20, 2025):

原因应该是每次启动时会将host和port参数重新注入config.js,我的解决方法是重新将index.html中引入的 github.com/kvcache-ai/ktransformers@b4fb633991/ktransformers/website/public/index.html (L7) 替换为自己重新建立的<script src="./config_remote.js"></script>,config_remote.js中将config.js中的 github.com/kvcache-ai/ktransformers@b4fb633991/ktransformers/website/public/config.js (L2) 修改为apiUrl: '/v1',
如果用nginx配置反代要注意把host改一下,改为自己的域名,不然依旧是localhost。

<!-- gh-comment-id:2670401096 --> @chenxianpeng1998 commented on GitHub (Feb 20, 2025): 原因应该是每次启动时会将host和port参数重新注入config.js,我的解决方法是重新将index.html中引入的 https://github.com/kvcache-ai/ktransformers/blob/b4fb633991bae29a26a81dc486a0b1920ff18519/ktransformers/website/public/index.html#L7 替换为自己重新建立的`<script src="./config_remote.js"></script>`,config_remote.js中将config.js中的 https://github.com/kvcache-ai/ktransformers/blob/b4fb633991bae29a26a81dc486a0b1920ff18519/ktransformers/website/public/config.js#L2 修改为`apiUrl: '/v1',` 如果用nginx配置反代要注意把host改一下,改为自己的域名,不然依旧是localhost。
Author
Owner

@SongXiaoMao commented on GitHub (Feb 20, 2025):

原因应该是每次启动时会将host和port参数重新注入config.js,我的解决方法是重新将index.html中引入的

ktransformers/ktransformers/website/public/index.html

Line 7 in b4fb633

替换为自己重新建立的<script src="./config_remote.js"></script>,config_remote.js中将config.js中的
ktransformers/ktransformers/website/public/config.js

Line 2 in b4fb633

apiUrl: 'http://119.255.238.12:15670/v1',
修改为apiUrl: '/v1',
如果用nginx配置反代要注意把host改一下,改为自己的域名,不然依旧是localhost。

请问你用webUI使用的时候 模型会思考么 我用这个为什么后台的think都是空标签了 使用默认的local_chat可以正确思考

<!-- gh-comment-id:2670458618 --> @SongXiaoMao commented on GitHub (Feb 20, 2025): > 原因应该是每次启动时会将host和port参数重新注入config.js,我的解决方法是重新将index.html中引入的 > > [ktransformers/ktransformers/website/public/index.html](https://github.com/kvcache-ai/ktransformers/blob/b4fb633991bae29a26a81dc486a0b1920ff18519/ktransformers/website/public/index.html#L7) > > Line 7 in [b4fb633](/kvcache-ai/ktransformers/commit/b4fb633991bae29a26a81dc486a0b1920ff18519) > > <script src="./config.js"></script> > 替换为自己重新建立的`<script src="./config_remote.js"></script>`,config_remote.js中将config.js中的 > [ktransformers/ktransformers/website/public/config.js](https://github.com/kvcache-ai/ktransformers/blob/b4fb633991bae29a26a81dc486a0b1920ff18519/ktransformers/website/public/config.js#L2) > > Line 2 in [b4fb633](/kvcache-ai/ktransformers/commit/b4fb633991bae29a26a81dc486a0b1920ff18519) > > apiUrl: 'http://119.255.238.12:15670/v1', > 修改为`apiUrl: '/v1',` > 如果用nginx配置反代要注意把host改一下,改为自己的域名,不然依旧是localhost。 请问你用webUI使用的时候 模型会思考么 我用这个为什么后台的think都是空标签了 使用默认的local_chat可以正确思考
Author
Owner

@chenxianpeng1998 commented on GitHub (Feb 20, 2025):

原因应该是每次启动时会将host和port参数重新注入config.js,我的解决方法是重新将index.html中引入的
ktransformers/ktransformers/website/public/index.html
Line 7 in b4fb633

替换为自己重新建立的<script src="./config_remote.js"></script>,config_remote.js中将config.js中的
ktransformers/ktransformers/website/public/config.js
Line 2 in b4fb633
apiUrl: 'http://119.255.238.12:15670/v1',
修改为apiUrl: '/v1',
如果用nginx配置反代要注意把host改一下,改为自己的域名,不然依旧是localhost。

请问你用webUI使用的时候 模型会思考么 我用这个为什么后台的think都是空标签了 使用默认的local_chat可以正确思考

我的设备运行R1模型时候会出现问题 #216 ,没法测试这个情况。

<!-- gh-comment-id:2670530247 --> @chenxianpeng1998 commented on GitHub (Feb 20, 2025): > > 原因应该是每次启动时会将host和port参数重新注入config.js,我的解决方法是重新将index.html中引入的 > > [ktransformers/ktransformers/website/public/index.html](https://github.com/kvcache-ai/ktransformers/blob/b4fb633991bae29a26a81dc486a0b1920ff18519/ktransformers/website/public/index.html#L7) > > Line 7 in [b4fb633](/kvcache-ai/ktransformers/commit/b4fb633991bae29a26a81dc486a0b1920ff18519) > > <script src="./config.js"></script> > > 替换为自己重新建立的`<script src="./config_remote.js"></script>`,config_remote.js中将config.js中的 > > [ktransformers/ktransformers/website/public/config.js](https://github.com/kvcache-ai/ktransformers/blob/b4fb633991bae29a26a81dc486a0b1920ff18519/ktransformers/website/public/config.js#L2) > > Line 2 in [b4fb633](/kvcache-ai/ktransformers/commit/b4fb633991bae29a26a81dc486a0b1920ff18519) > > apiUrl: 'http://119.255.238.12:15670/v1', > > 修改为`apiUrl: '/v1',` > > 如果用nginx配置反代要注意把host改一下,改为自己的域名,不然依旧是localhost。 > > 请问你用webUI使用的时候 模型会思考么 我用这个为什么后台的think都是空标签了 使用默认的local_chat可以正确思考 我的设备运行R1模型时候会出现问题 #216 ,没法测试这个情况。
Author
Owner

@SongXiaoMao commented on GitHub (Feb 20, 2025):

Image

你好,请教一下 我index文件没有修改 config.js 文件修改如下

window.configWeb = {
apiUrl: 'http://192.168.66.15:15670/v1',
port: 8080,
};

为什么启动对话还是这样呢 ?我还需要修改什么地方吗 ?

<!-- gh-comment-id:2670537040 --> @SongXiaoMao commented on GitHub (Feb 20, 2025): ![Image](https://github.com/user-attachments/assets/78e95c11-0b8d-41d4-8e70-0208b7db2a5f) 你好,请教一下 我index文件没有修改 config.js 文件修改如下 window.configWeb = { apiUrl: 'http://192.168.66.15:15670/v1', port: 8080, }; 为什么启动对话还是这样呢 ?我还需要修改什么地方吗 ?
Author
Owner

@chenxianpeng1998 commented on GitHub (Feb 20, 2025):

Image

你好,请教一下 我index文件没有修改 config.js 文件修改如下

window.configWeb = { apiUrl: 'http://192.168.66.15:15670/v1', port: 8080, };

为什么启动对话还是这样呢 ?我还需要修改什么地方吗 ?

每次启动ktransformers会重新修改config.js文件的,修改index.html是为了让网页不引入config.js文件,而是改用自己配置的js。

<!-- gh-comment-id:2670546786 --> @chenxianpeng1998 commented on GitHub (Feb 20, 2025): > ![Image](https://github.com/user-attachments/assets/78e95c11-0b8d-41d4-8e70-0208b7db2a5f) > > 你好,请教一下 我index文件没有修改 config.js 文件修改如下 > > window.configWeb = { apiUrl: 'http://192.168.66.15:15670/v1', port: 8080, }; > > 为什么启动对话还是这样呢 ?我还需要修改什么地方吗 ? 每次启动ktransformers会重新修改config.js文件的,修改index.html是为了让网页不引入config.js文件,而是改用自己配置的js。
Author
Owner

@SongXiaoMao commented on GitHub (Feb 20, 2025):

Image
你好 我这里按照你的修改完毕了 为什么对话的时候还是调用的原来的js?

<!-- gh-comment-id:2670584663 --> @SongXiaoMao commented on GitHub (Feb 20, 2025): ![Image](https://github.com/user-attachments/assets/8efd52ed-b564-47c8-8152-3312625c3ba0) 你好 我这里按照你的修改完毕了 为什么对话的时候还是调用的原来的js?
Author
Owner

@DengxiaoHong999 commented on GitHub (Feb 20, 2025):

请教一下:为什么我的网页版对话都是request error,而且只能本机访问

<!-- gh-comment-id:2670692488 --> @DengxiaoHong999 commented on GitHub (Feb 20, 2025): 请教一下:为什么我的网页版对话都是request error,而且只能本机访问
Author
Owner

@DengxiaoHong999 commented on GitHub (Feb 20, 2025):

请教一下:为什么我的网页版对话都是request error,而且只能本机访问

按照大佬的方法改了config和index.html

<!-- gh-comment-id:2670701723 --> @DengxiaoHong999 commented on GitHub (Feb 20, 2025): > 请教一下:为什么我的网页版对话都是request error,而且只能本机访问 按照大佬的方法改了config和index.html
Author
Owner

@yimisiyang commented on GitHub (Feb 20, 2025):

远程IP可以访问了。我的后台启动命令如下:

ktransformers --model_path /data/model/models--deepseek-ai--DeepSeek-R1/snapshots/8a58a132790c9935686eb97f042afa8013451c9f/ --gguf_path /data/gguf_model/DeepSeek-R1-Q4_K_M --optimize_config_path /data/ktransformers/ktransformers/optimize/optimize_rules/DeepSeek-R1-Chat.yaml --cpu_infer 30 --max_new_tokens 1000 --host 172.17.110.105 --web True --port 9016

~/website/dist/config.js 配置如下,这里的port端口没有用到:

window.configWeb = {
    apiUrl: 'http://localhost:9016/v1',
    port: 9016,
  };

~/website/public/config.js配置如下,这里的port端口没有用到:

window.configWeb = {
    //apiUrl: 'http://119.255.238.12:15670/v1',
    apiUrl: 'http://172.17.110.105:9016/v1',
    port: 9016,
  };
~      

~/website/vue.config.js配置如下:

proxy: {
        '/api': {
         // target: 'http://localhost:9016/v1', // 你的后端服务器地址
          target: 'http://172.17.110.105:9016/v1', // 你的后端服务器地址
          changeOrigin: true, // 是否允许跨域
          pathRewrite: {
            '/api': '' // 将 '/api' 前缀替换为空,如果你的后端不需要这个前缀
          }
        }
      }

最后为了解决其它电脑能够IP访问需要解决跨域问题,修改源码中的~/website/src/api/api-client.ts 中的 withCredentials: true 值为 false 然后启动前后端即可。

但是现在有个问题就是只能回答一个问题,不能连续对话。有没有其他人遇到的?

<!-- gh-comment-id:2670703656 --> @yimisiyang commented on GitHub (Feb 20, 2025): 远程IP可以访问了。我的后台启动命令如下: ``` ktransformers --model_path /data/model/models--deepseek-ai--DeepSeek-R1/snapshots/8a58a132790c9935686eb97f042afa8013451c9f/ --gguf_path /data/gguf_model/DeepSeek-R1-Q4_K_M --optimize_config_path /data/ktransformers/ktransformers/optimize/optimize_rules/DeepSeek-R1-Chat.yaml --cpu_infer 30 --max_new_tokens 1000 --host 172.17.110.105 --web True --port 9016 ``` ~/website/dist/config.js 配置如下,这里的port端口没有用到: ``` window.configWeb = { apiUrl: 'http://localhost:9016/v1', port: 9016, }; ``` ~/website/public/config.js配置如下,这里的port端口没有用到: ``` window.configWeb = { //apiUrl: 'http://119.255.238.12:15670/v1', apiUrl: 'http://172.17.110.105:9016/v1', port: 9016, }; ~ ``` ~/website/vue.config.js配置如下: ``` proxy: { '/api': { // target: 'http://localhost:9016/v1', // 你的后端服务器地址 target: 'http://172.17.110.105:9016/v1', // 你的后端服务器地址 changeOrigin: true, // 是否允许跨域 pathRewrite: { '/api': '' // 将 '/api' 前缀替换为空,如果你的后端不需要这个前缀 } } } ``` 最后为了解决其它电脑能够IP访问需要解决跨域问题,修改源码中的~/website/src/api/api-client.ts 中的 `withCredentials: true` 值为 `false` 然后启动前后端即可。 **但是现在有个问题就是只能回答一个问题,不能连续对话。有没有其他人遇到的?**
Author
Owner

@DengxiaoHong999 commented on GitHub (Feb 20, 2025):

远程IP可以访问了。我的后台启动命令如下:

ktransformers --model_path /data/model/models--deepseek-ai--DeepSeek-R1/snapshots/8a58a132790c9935686eb97f042afa8013451c9f/ --gguf_path /data/gguf_model/DeepSeek-R1-Q4_K_M --optimize_config_path /data/ktransformers/ktransformers/optimize/optimize_rules/DeepSeek-R1-Chat.yaml --cpu_infer 30 --max_new_tokens 1000 --host 172.17.110.105 --web True --port 9016

~/website/dist/config.js 配置如下,这里的port端口没有用到:

window.configWeb = {
    apiUrl: 'http://localhost:9016/v1',
    port: 9016,
  };

~/website/public/config.js配置如下,这里的port端口没有用到:

window.configWeb = {
    //apiUrl: 'http://119.255.238.12:15670/v1',
    apiUrl: 'http://172.17.110.105:9016/v1',
    port: 9016,
  };
~      

~/website/vue.config.js配置如下:

proxy: {
        '/api': {
         // target: 'http://localhost:9016/v1', // 你的后端服务器地址
          target: 'http://172.17.110.105:9016/v1', // 你的后端服务器地址
          changeOrigin: true, // 是否允许跨域
          pathRewrite: {
            '/api': '' // 将 '/api' 前缀替换为空,如果你的后端不需要这个前缀
          }
        }
      }

最后为了解决其它电脑能够IP访问需要解决跨域问题,修改源码中的~/website/src/api/api-client.ts 中的 withCredentials: true 值为 false 然后启动前后端即可。

但是现在有个问题就是只能回答一个问题,不能连续对话。有没有其他人遇到的?

Image 我按照这个改了,局域网确实能访问了,但是对话还是request error Image
<!-- gh-comment-id:2670723789 --> @DengxiaoHong999 commented on GitHub (Feb 20, 2025): > 远程IP可以访问了。我的后台启动命令如下: > > ``` > ktransformers --model_path /data/model/models--deepseek-ai--DeepSeek-R1/snapshots/8a58a132790c9935686eb97f042afa8013451c9f/ --gguf_path /data/gguf_model/DeepSeek-R1-Q4_K_M --optimize_config_path /data/ktransformers/ktransformers/optimize/optimize_rules/DeepSeek-R1-Chat.yaml --cpu_infer 30 --max_new_tokens 1000 --host 172.17.110.105 --web True --port 9016 > ``` > > ~/website/dist/config.js 配置如下,这里的port端口没有用到: > > ``` > window.configWeb = { > apiUrl: 'http://localhost:9016/v1', > port: 9016, > }; > ``` > > ~/website/public/config.js配置如下,这里的port端口没有用到: > > ``` > window.configWeb = { > //apiUrl: 'http://119.255.238.12:15670/v1', > apiUrl: 'http://172.17.110.105:9016/v1', > port: 9016, > }; > ~ > ``` > > ~/website/vue.config.js配置如下: > > ``` > proxy: { > '/api': { > // target: 'http://localhost:9016/v1', // 你的后端服务器地址 > target: 'http://172.17.110.105:9016/v1', // 你的后端服务器地址 > changeOrigin: true, // 是否允许跨域 > pathRewrite: { > '/api': '' // 将 '/api' 前缀替换为空,如果你的后端不需要这个前缀 > } > } > } > ``` > > 最后为了解决其它电脑能够IP访问需要解决跨域问题,修改源码中的~/website/src/api/api-client.ts 中的 `withCredentials: true` 值为 `false` 然后启动前后端即可。 > > **但是现在有个问题就是只能回答一个问题,不能连续对话。有没有其他人遇到的?** <img width="134" alt="Image" src="https://github.com/user-attachments/assets/88747b79-a3dc-4449-8cea-d7f05d27f821" /> 我按照这个改了,局域网确实能访问了,但是对话还是request error <img width="134" alt="Image" src="https://github.com/user-attachments/assets/c09deb51-97cc-4539-8b70-b68fbf3d218e" />
Author
Owner

@DengxiaoHong999 commented on GitHub (Feb 20, 2025):

Image 应该是这个地方有问题?

<!-- gh-comment-id:2670735335 --> @DengxiaoHong999 commented on GitHub (Feb 20, 2025): ![Image](https://github.com/user-attachments/assets/dabfcd4a-1890-405c-b2a7-73eee7dba76e) 应该是这个地方有问题?
Author
Owner

@yimisiyang commented on GitHub (Feb 20, 2025):

不能连续对话,感觉前端代码有问题,如果可以的话直接部署一个 openwebui 。然后 把后端生成的URL 给进去就可以直接多轮对话,我这边亲侧可行 ,我输入的是 http://172.17.110.105:9016/v1 , 密钥没有随便填就行

<!-- gh-comment-id:2670757614 --> @yimisiyang commented on GitHub (Feb 20, 2025): 不能连续对话,感觉前端代码有问题,如果可以的话直接部署一个 **openwebui** 。然后 把后端生成的URL 给进去就可以直接多轮对话,我这边亲侧可行 ,我输入的是 `http://172.17.110.105:9016/v1` , 密钥没有随便填就行
Author
Owner

@ArSrNa commented on GitHub (Feb 20, 2025):

不能连续对话,感觉前端代码有问题,如果可以的话直接部署一个 openwebui 。然后 把后端生成的URL 给进去就可以直接多轮对话,我这边亲侧可行 ,我输入的是 http://172.17.110.105:9016/v1 , 密钥没有随便填就行

v0.2.0的版本用OpenWebui请求获取openai标准Model的接口404,ollama的也不行,v0.2.1的启用WebUI有问题

<!-- gh-comment-id:2670798388 --> @ArSrNa commented on GitHub (Feb 20, 2025): > 不能连续对话,感觉前端代码有问题,如果可以的话直接部署一个 **openwebui** 。然后 把后端生成的URL 给进去就可以直接多轮对话,我这边亲侧可行 ,我输入的是 `http://172.17.110.105:9016/v1` , 密钥没有随便填就行 v0.2.0的版本用OpenWebui请求获取openai标准Model的接口404,ollama的也不行,v0.2.1的启用WebUI有问题
Author
Owner

@maaaxinfinity commented on GitHub (Feb 20, 2025):

不能连续对话,感觉前端代码有问题,如果可以的话直接部署一个 openwebui 。然后 把后端生成的URL 给进去就可以直接多轮对话,我这边亲侧可行 ,我输入的是 http://172.17.110.105:9016/v1 , 密钥没有随便填就行

v0.2.0的版本用OpenWebui请求获取openai标准Model的接口404,ollama的也不行,v0.2.1的启用WebUI有问题

我main分支最新编译的,dify对接没有问题 但是api在使用时出现了core dumped #505

<!-- gh-comment-id:2670831256 --> @maaaxinfinity commented on GitHub (Feb 20, 2025): > > 不能连续对话,感觉前端代码有问题,如果可以的话直接部署一个 **openwebui** 。然后 把后端生成的URL 给进去就可以直接多轮对话,我这边亲侧可行 ,我输入的是 `http://172.17.110.105:9016/v1` , 密钥没有随便填就行 > > v0.2.0的版本用OpenWebui请求获取openai标准Model的接口404,ollama的也不行,v0.2.1的启用WebUI有问题 我main分支最新编译的,dify对接没有问题 但是api在使用时出现了core dumped #505
Author
Owner

@ArSrNa commented on GitHub (Feb 20, 2025):

还有个问题你发现了么 使用webUI对话 没有思考过程 think标签都是空的

启动的时候加上--force-think true看看,localchat能思考,但是WebUI我没有办法对接,用fastapi在apifox请求能够思考

<!-- gh-comment-id:2670854725 --> @ArSrNa commented on GitHub (Feb 20, 2025): > 还有个问题你发现了么 使用webUI对话 没有思考过程 think标签都是空的 启动的时候加上`--force-think true`看看,localchat能思考,但是WebUI我没有办法对接,用fastapi在apifox请求能够思考
Author
Owner

@maaaxinfinity commented on GitHub (Feb 20, 2025):

webui只用改 config.js就能跑了

Image

我dify的配置 apikey随便写

<!-- gh-comment-id:2670861171 --> @maaaxinfinity commented on GitHub (Feb 20, 2025): webui只用改 config.js就能跑了 ![Image](https://github.com/user-attachments/assets/ca22f70b-4ed7-493c-a893-044a2f375873) 我dify的配置 apikey随便写
Author
Owner

@SongXiaoMao commented on GitHub (Feb 21, 2025):

我还是觉得这个API有问题 你们能连续对话么 ?我这个对话一次 后台还会输出其他东西 似乎默认传进了回车之类的字符

<!-- gh-comment-id:2672993607 --> @SongXiaoMao commented on GitHub (Feb 21, 2025): 我还是觉得这个API有问题 你们能连续对话么 ?我这个对话一次 后台还会输出其他东西 似乎默认传进了回车之类的字符
Author
Owner

@maaaxinfinity commented on GitHub (Feb 21, 2025):

我还是觉得这个API有问题 你们能连续对话么 ?我这个对话一次 后台还会输出其他东西 似乎默认传进了回车之类的字符

偶尔可以 挺玄学的就

<!-- gh-comment-id:2673978313 --> @maaaxinfinity commented on GitHub (Feb 21, 2025): > 我还是觉得这个API有问题 你们能连续对话么 ?我这个对话一次 后台还会输出其他东西 似乎默认传进了回车之类的字符 偶尔可以 挺玄学的就
Author
Owner

@xieabc1991 commented on GitHub (Feb 21, 2025):

我还是觉得这个API有问题 你们能连续对话么 ?我这个对话一次 后台还会输出其他东西 似乎默认传进了回车之类的字符

偶尔可以 挺玄学的就

你好,请问下为啥我openai按照这个填了就是base model not found,config.js是怎么改的,改成apiUrl: '/v1'吗,感谢

<!-- gh-comment-id:2673991808 --> @xieabc1991 commented on GitHub (Feb 21, 2025): > > 我还是觉得这个API有问题 你们能连续对话么 ?我这个对话一次 后台还会输出其他东西 似乎默认传进了回车之类的字符 > > 偶尔可以 挺玄学的就 你好,请问下为啥我openai按照这个填了就是base model not found,config.js是怎么改的,改成apiUrl: '/v1'吗,感谢
Author
Owner

@maaaxinfinity commented on GitHub (Feb 21, 2025):

我还是觉得这个API有问题 你们能连续对话么 ?我这个对话一次 后台还会输出其他东西 似乎默认传进了回车之类的字符

偶尔可以 挺玄学的就

你好,请问下为啥我openai按照这个填了就是base model not found,config.js是怎么改的,改成apiUrl: '/v1'吗,感谢

对

<!-- gh-comment-id:2673994592 --> @maaaxinfinity commented on GitHub (Feb 21, 2025): > > > 我还是觉得这个API有问题 你们能连续对话么 ?我这个对话一次 后台还会输出其他东西 似乎默认传进了回车之类的字符 > > > > > > 偶尔可以 挺玄学的就 > > 你好,请问下为啥我openai按照这个填了就是base model not found,config.js是怎么改的,改成apiUrl: '/v1'吗,感谢 对
Author
Owner

@ArSrNa commented on GitHub (Feb 24, 2025):

git标签v0.2.1.post1之后的版本已经修复了,#506 相关API已经彻底修复且稳定,如果用的是编译安装的,在编译时通过git rev-parse --short HEAD获取实际提交哈希,并始终基于main分支的最新代码(即未发布正式版本的修复内容)进行构建。

可优先使用前文指南中提到的预编译whl二进制包。

<!-- gh-comment-id:2677696123 --> @ArSrNa commented on GitHub (Feb 24, 2025): git标签`v0.2.1.post1`之后的版本已经修复了,#506 相关API已经彻底修复且稳定,如果用的是编译安装的,在编译时通过`git rev-parse --short HEAD`获取实际提交哈希,并始终基于main分支的最新代码(即未发布正式版本的修复内容)进行构建。 可优先使用前文指南中提到的预编译whl二进制包。
Author
Owner

@lhtpluto commented on GitHub (Mar 13, 2025):

还有个问题你发现了么 使用webUI对话 没有思考过程 think标签都是空的

启动的时候加上--force-think true看看,localchat能思考,但是WebUI我没有办法对接,用fastapi在apifox请求能够思考

--force-think 就可以。 不用+ ture

<!-- gh-comment-id:2720987397 --> @lhtpluto commented on GitHub (Mar 13, 2025): > > 还有个问题你发现了么 使用webUI对话 没有思考过程 think标签都是空的 > > 启动的时候加上`--force-think true`看看,localchat能思考,但是WebUI我没有办法对接,用fastapi在apifox请求能够思考 --force-think 就可以。 不用+ ture
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
kvcache-ai/ktransformers#368
No description provided.