@Gin @Gin Thanks for getting back. The past_messages
parameter is no longer part of the official Azure OpenAI SDK or API specification as of the latest available versions. The same is removed from the REST API specifications also.
.
Azure OpenAI's chat completions typically rely on the messages
array to pass the full conversation history, including both user inputs and assistant responses. There is no separate past_messages
parameter. Instead, the conversation context is maintained by including previous messages directly in the messages
array. You can either rely on the above environment variable AZURE_OPENAI_SYSTEM_MESSAGE
which I have shared in my above comment OR you should ensure that past messages are included manually in the messages
array when making requests.
Hope this answers.
**
Please do not forget to "Accept the answer” and “up-vote” wherever the information provided helps you, this can be beneficial to other community members.