{AKS}: agent-init replaces model name with deployment name for Azure OpenAI service#9391
Conversation
️✔️Azure CLI Extensions Breaking Change Test
|
|
Thank you for your contribution! We will review the pull request and get back to you soon. |
|
The git hooks are available for azure-cli and azure-cli-extensions repos. They could help you run required checks before creating the PR. Please sync the latest code with latest dev branch (for azure-cli) or main branch (for azure-cli-extensions). pip install azdev --upgrade
azdev setup -c <your azure-cli repo path> -r <your azure-cli-extensions repo path>
|
|
There was a problem hiding this comment.
Pull Request Overview
This PR updates the Azure OpenAI provider configuration to use DEPLOYMENT_NAME instead of MODEL_NAME for better clarity when configuring Azure OpenAI deployments. The version is bumped to 1.0.0b9.
- Renamed parameter from
MODEL_NAMEtoDEPLOYMENT_NAMEin Azure provider schema - Updated the hint text to be more descriptive
- Updated version and changelog
Reviewed Changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| src/aks-agent/setup.py | Bumped version from 1.0.0b8 to 1.0.0b9 |
| src/aks-agent/azext_aks_agent/agent/llm_providers/azure_provider.py | Renamed MODEL_NAME to DEPLOYMENT_NAME in parameter schema and updated hint text |
| src/aks-agent/HISTORY.rst | Added changelog entry for version 1.0.0b9 describing the parameter name change |
Comments suppressed due to low confidence (2)
src/aks-agent/azext_aks_agent/agent/llm_providers/azure_provider.py:65
- The parameter name was changed from
MODEL_NAMEtoDEPLOYMENT_NAMEin the schema (line 35), but this line still referencesMODEL_NAME. This will cause the validation to fail because the parameter won't be found. Update this toparams.get(\"DEPLOYMENT_NAME\").
model_name = params.get("MODEL_NAME")
src/aks-agent/azext_aks_agent/agent/llm_providers/azure_provider.py:71
- [nitpick] After fixing the parameter retrieval on line 65, consider renaming the local variable from
model_nametodeployment_namethroughout this method (lines 65, 71, 77) to better reflect that it represents the Azure deployment name, not the model name. This aligns with the schema change and improves code clarity.
url = urljoin(api_base, f"openai/deployments/{model_name}/chat/completions")
96a534a to
f1e9705
Compare
f1e9705 to
38fa9a7
Compare
|
[Release] Update index.json for extension [ aks-agent-1.0.0b9 ] : https://dev.azure.com/msazure/One/_build/results?buildId=142828754&view=results |
This checklist is used to make sure that common guidelines for a pull request are followed.
Related command
General Guidelines
azdev style <YOUR_EXT>locally? (pip install azdevrequired)python scripts/ci/test_index.py -qlocally? (pip install wheel==0.30.0required)For new extensions:
About Extension Publish
There is a pipeline to automatically build, upload and publish extension wheels.
Once your pull request is merged into main branch, a new pull request will be created to update
src/index.jsonautomatically.You only need to update the version information in file setup.py and historical information in file HISTORY.rst in your PR but do not modify
src/index.json.