functions support
mrahmadt opened this issue · comments
Aft commented
Describe the feature
Hello
Just wanted to say that functions is supported in chatgpt-api :)
It's not documented in https://github.com/transitive-bullshit/chatgpt-api/blob/main/docs/interfaces/openai.CreateChatCompletionRequest.md
But it will work
const completionParamsOptions = {
functions: functions,
function_call: "auto"
};
chatgptAPI = new ChatGPTAPI({
apiKey: openAIAPIKey,
debug: true,
completionParams: completionParamsOptions
})