FastGPT icon indicating copy to clipboard operation
FastGPT copied to clipboard

想问下离线环境下自己用ChatGLM 和FastGPT部署了对话系统,如何使用function calling功能

Open liyuan3970 opened this issue 2 years ago • 3 comments

您好,想问下我在离线环境下用FastGPT的外接中的API秘钥创建了接口,这个接口可以用openai的function calling功能吗?可不可以出个类似查天气的案例,方便开发应用

liyuan3970 avatar Dec 26 '23 14:12 liyuan3970

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


Hello, I would like to ask if I created an interface using the API key in the FastGPT add-on in an offline environment. Can this interface use the function calling function of openai? Can you come up with a case similar to checking the weather to facilitate the development of applications?

c121914yu avatar Dec 26 '23 14:12 c121914yu

我也同样碰到这个问题,使用的chatglm和fastgpt,我发现通过fastgpt转发的api接口不会将functions,或tools转发到chatglm里面,在request里面,没有这两个参数 同样的我尝试过阅读过文档,文档里面里面有介绍支持openai标准的functions_call,只需要将配置模型的toolChoice改为true,我同意的也设置了

YC04-23 avatar Dec 27 '23 01:12 YC04-23

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


I also encountered this problem. I used chatglm and fastgpt. I found that the api interface forwarded through fastgpt would not forward functions or tools to chatglm. In the request, there are no these two parameters. I have also tried reading the documentation. The documentation introduces functions_call that supports the openai standard. You only need to change the toolChoice of the configuration model to true. I agree with it and set it.

c121914yu avatar Dec 27 '23 01:12 c121914yu

为什么不直接用oneapi转发。fastgpt的接口不是中转接口,是为了调用应用,与functioncall没有任何关系。

c121914yu avatar Jan 01 '24 06:01 c121914yu

我也遇到同样的问题,如何解决!

swingsun888 avatar Jan 14 '24 14:01 swingsun888

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


I also encountered the same problem, how to solve it!

c121914yu avatar Jan 14 '24 14:01 c121914yu