Skip to content

ChatClientAutoConfiguration should back off if there are multiple ChatModels #3429

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

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

filiphr
Copy link
Contributor

@filiphr filiphr commented Jun 3, 2025

If for whatever reason I have multiple ChatModel beans available, the ChatClientAutoConfiguration is going to fail because no ChatClient.Builder can be created.

This PR adds the @ConditionalOnSingleCandidate for the chatClientBuilder bean, which allows for smooth startup without the need to manually exclude the ChatClientAutoConfiguration

…tModels

Signed-off-by: Filip Hrisafov <filip.hrisafov@gmail.com>
Signed-off-by: Filip Hrisafov <filip.hrisafov@gmail.com>
@filiphr filiphr force-pushed the multiple-chat-clients branch from 3131e19 to 427ed57 Compare June 3, 2025 15:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants