azure-sdk-for-js icon indicating copy to clipboard operation
azure-sdk-for-js copied to clipboard

Setting temperature for azure openai assistant in nodejs

Open gokulsathyan-ulai opened this issue 10 months ago • 6 comments

How do I set the temperature of a model in @azure/openai-assistants while creating an assistant.

gokulsathyan-ulai avatar Apr 25 '24 11:04 gokulsathyan-ulai

Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc @glharper.

github-actions[bot] avatar Apr 25 '24 11:04 github-actions[bot]

@gokulsathyan-ulai Thank you for using the Azure OpenAI Assistants SDK for JS, and for writing this issue up. The ability to set temperature is not available in the v1 Beta API for Assistants, but was recently released in the v2 Beta API. Azure Assistants support for the v2 Beta API is being implemented, and I'll update this issue once that support reaches the JS SDK.

glharper avatar Apr 25 '24 13:04 glharper

@glharper What is the default temperature for models in azure openai assistants?

gokulsathyan-ulai avatar Apr 26 '24 05:04 gokulsathyan-ulai

@glharper What is the default temperature for models in azure openai assistants?

I'd assume the same default as for OpenAI Assistant models, 1, but I can't find any Azure specific ref docs to back that up.

glharper avatar Apr 26 '24 17:04 glharper

@glharper Is there any other way for me to make the temperature 0?

gokulsathyan-ulai avatar May 01 '24 12:05 gokulsathyan-ulai

@glharper Is there any other way for me to make the temperature 0?

gokulsathyan-ulai avatar May 02 '24 05:05 gokulsathyan-ulai

any updates on this one @glharper ?

chahalinder0007 avatar May 13 '24 18:05 chahalinder0007

Hello, @chahalinder0007!

We've quite recently achieved one of our partnership goals with OpenAI and released dedicated Azure sub-client support in the official OpenAI node.js package. Converged support via that library will be our strategy moving forward, including for ensuring timely availability of things like this temperature setting in Assistants.

You can read more about the Azure sub-client configuration process in the readme, here: https://github.com/openai/openai-node/tree/master?tab=readme-ov-file#microsoft-azure-openai

Apologies for the whiplash, and we're working to get all of our docs and samples migrated ASAP. But the good news is that you can definitely configure temperature today with the new sub-client!

trrwilson avatar May 14 '24 17:05 trrwilson

Hey @trrwilson, thanks for the heads up, will/has this been published anywhere else? I'm mildly concerned about how this will look for the MS first party features such as the "On your data" extensions. Are there plans for the OpenAI library to contain the APIs for managing deployments & content filters?

codylittle avatar Jun 11 '24 10:06 codylittle

Hi @codylittle, we strongly recommend that you migrate to use the AzureOpenAI client exported by the official OpenAI client library for JavaScript. Checkout the migration guide for how to do so while maintaining typing for Azure features.

Please let us know if you have any other questions!

deyaaeldeen avatar Jul 23 '24 05:07 deyaaeldeen