Skip to content

Avoid adding providers if not requested - #1464

Merged
Baiju Meswani (baijumeswani) merged 3 commits into
mainfrom
baijumeswani/fix-bug
May 8, 2025
Merged

Avoid adding providers if not requested#1464
Baiju Meswani (baijumeswani) merged 3 commits into
mainfrom
baijumeswani/fix-bug

Conversation

@baijumeswani

Copy link
Copy Markdown
Collaborator

In a previous PR: #1454 I added support for the providers to persist the provider options across clearprovider->appendprovider. A bug was introduced where the providers always got built to include every provider in the provider options.

This PR fixes it. So, if the user clears the providers , and then appends a provider, only the new provider should be present in the providers list (not all the ones in the provider options).

@RyanUnderhill

Copy link
Copy Markdown
Contributor

So the issue is that the OnComplete() was adding all providers back to the list from the provider options. The fix is to do it higher up to avoid SetProviderOption from doing it again?

@baijumeswani

Copy link
Copy Markdown
Collaborator Author

Yes, exactly. :)

@RyanUnderhill

Copy link
Copy Markdown
Contributor

Hmm, I think moving it up just moves the problem a little and would still be a surprise if we allow dynamic session options. If you move it into the Config constructor it'll happen once at load time.

@baijumeswani
Baiju Meswani (baijumeswani) deleted the baijumeswani/fix-bug branch May 8, 2025 23:00
@baijumeswani

Copy link
Copy Markdown
Collaborator Author

Thanks for the review. :)

Baiju Meswani (baijumeswani) added a commit that referenced this pull request May 14, 2025
Address previous PR review comments from #1470 (#1473)
Address QNN specific regressions (#1470)
Fix array eos_token_id handling (#1463)
Constrained decoding integration (#1381)
Remove BF16 CPU from valid GQA configuration (#1469)
Avoid adding providers if not requested (#1464)
Persist provider options across ClearProviders, AppendProvider where
possible (#1454)
Fix accuracy issues with Gemma models (#1448)
Add bfloat16 support in model builder (#1447)
Add final norm for LoRA models (#1446)

Update version to 0.8.0-rc3

---------

Co-authored-by: kunal-vaishnavi <115581922+kunal-vaishnavi@users.noreply.github.com>
Co-authored-by: Nenad Banfic <46795300+nenad1002@users.noreply.github.com>
Co-authored-by: Nenad Banfic <nebanfic@microsoft.com>
Co-authored-by: Baiju Meswani <bmeswani@microsoft.com>
Co-authored-by: Abhishek Jindal <abjindal@microsoft.com>
Co-authored-by: Ying Xiong <yingxiong@microsoft.com>
Co-authored-by: Michał Moskal <michal@moskal.me>
Co-authored-by: Kunal Vaishnavi <kvaishnavi@microsoft.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants