Propagate IModel API changes across Python, JS, Rust SDKs and update C# docs#565
Draft
Propagate IModel API changes across Python, JS, Rust SDKs and update C# docs#565
Conversation
…to Catalog, use IModel return types Agent-Logs-Url: https://github.com/microsoft/Foundry-Local/sessions/8082508c-1338-48b2-bdd3-6c2c8e35e195 Co-authored-by: baijumeswani <12852605+baijumeswani@users.noreply.github.com>
…log, use IModel return types Agent-Logs-Url: https://github.com/microsoft/Foundry-Local/sessions/8082508c-1338-48b2-bdd3-6c2c8e35e195 Co-authored-by: baijumeswani <12852605+baijumeswani@users.noreply.github.com>
…docs Agent-Logs-Url: https://github.com/microsoft/Foundry-Local/sessions/8082508c-1338-48b2-bdd3-6c2c8e35e195 Co-authored-by: baijumeswani <12852605+baijumeswani@users.noreply.github.com>
Agent-Logs-Url: https://github.com/microsoft/Foundry-Local/sessions/8082508c-1338-48b2-bdd3-6c2c8e35e195 Co-authored-by: baijumeswani <12852605+baijumeswani@users.noreply.github.com>
…, Model uses IModel variants Agent-Logs-Url: https://github.com/microsoft/Foundry-Local/sessions/8082508c-1338-48b2-bdd3-6c2c8e35e195 Co-authored-by: baijumeswani <12852605+baijumeswani@users.noreply.github.com>
…iants in Catalog Agent-Logs-Url: https://github.com/microsoft/Foundry-Local/sessions/8082508c-1338-48b2-bdd3-6c2c8e35e195 Co-authored-by: baijumeswani <12852605+baijumeswani@users.noreply.github.com>
Copilot created this pull request from a session on behalf of
baijumeswani
March 30, 2026 23:05
View session
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Mirrors the C# changes from #556 across all language bindings: public APIs use the
IModelinterface instead of concreteModel/ModelVarianttypes,GetLatestVersionmoves fromModeltoCatalog, andModelVariantbecomes an implementation detail.IModel interface extended (Python, JS)
info,variants,selected_variant/selectedVariant,select_variant/selectVariantto the abstract interfaceModelVariantimplements these as self-referential (variants=[self],selected_variant=self,select_variantthrows)Catalog return types changed (Python, JS)
list_models()→List[IModel](wasList[Model])get_model()→Optional[IModel](wasOptional[Model])get_model_variant()→Optional[IModel](wasOptional[ModelVariant])get_cached_models()/get_loaded_models()→List[IModel](wasList[ModelVariant])get_latest_versionadded to Catalog (Python, JS, Rust)Moved from
ModeltoCatalogsinceModelVariantlacks sufficient context to implement it. Takes anyIModeland resolves the latest version by name matching against the variant list.Rust SDK
Model::info()(delegates to selected variant)Catalog::get_latest_version(&self, model: &Arc<Model>) -> Result<Arc<ModelVariant>>C# docs and samples updated
ICatalog,IModel,Model,ModelVariant) updated to reflectIModelreturn typesModelVariantdocs marked as internalModelVarianttype referencesGetLatestVersionAsyncadded toICatalogdocs