Skip to content

GH-981: Use OpenAIAsyncClient for streaming in AzureOpenAiChatModel #1447

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 3 commits into from

Conversation

sobychacko
Copy link
Contributor

Resolves #981

  • Switch to OpenAIAsyncClient for streaming operations
  • Modify AzureOpenAiChatModel constructor to accept OpenAIClientBuilder
  • Update getChatCompletionsStream to use non-blocking async client
  • Refactor related classes and tests to support OpenAIClientBuilder
  • Revise AzureOpenAiAutoConfiguration to provide OpenAIClientBuilder
  • Add AzureOpenAiChatClientTest to verify streaming functionality
  • Adjust existing tests for compatibility with OpenAIClientBuilder

…enAiChatModel

Resolves spring-projects#981

- Switch to OpenAIAsyncClient for streaming operations
- Modify AzureOpenAiChatModel constructor to accept OpenAIClientBuilder
- Update getChatCompletionsStream to use non-blocking async client
- Refactor related classes and tests to support OpenAIClientBuilder
- Revise AzureOpenAiAutoConfiguration to provide OpenAIClientBuilder
- Add AzureOpenAiChatClientTest to verify streaming functionality
- Adjust existing tests for compatibility with OpenAIClientBuilder

This change improves support for asynchronous streaming operations
in the AzureOpenAiChatModel, addressing potential issues in reactive environments.
@markpollack
Copy link
Member

merged in ef3d43c

@markpollack markpollack closed this Oct 3, 2024
@markpollack markpollack self-assigned this Oct 3, 2024
@markpollack markpollack added this to the 1.0.0-M3 milestone Oct 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[BUG] [Azure OpenAI] block()/blockFirst()/blockLast() are blocking, which is not supported in thread reactor-http-nio-2
2 participants