Closed jave closed 1 year ago
... or maybe it actually works, if I make sure the 0.7.0 version is loaded? seems cider stubbornly loaded 0.5.1 instead. I will try some more and get back
Hi there. Yes, support for functions was added in v0.7.0
then this can be closed. tnx
I tried the following, but it didnt seem to work, its adapted from https://platform.openai.com/docs/guides/gpt/function-calling
(api/create-chat-completion {:model "gpt-3.5-turbo-0613" :messages [ {:role "user" :content "Whats the weather like in Boston?"}] :functions [ { :name "get_current_weather" :description "Get the current weather in a given location" :parameters { :type "object", :properties { :location { :type "string", :description "The city and state, e.g. San Francisco, CA" } :unit {:type "string" :enum ["celsius", "fahrenheit"]} } :required ["location"] } }] :function-call "auto" } {:api-key KEY})