Skip to content

feat: Add az aiinfraoptimization initial setup - #10540

Merged
Naga Nandyala (naga-nandyala) merged 6 commits into
Azure:mainfrom
kkarmakarMS:user/kkarmakarMS/aiinfraoptimization-new-rp-extension
Nov 3, 2026
Merged

Naga Nandyala (naga-nandyala) merged 6 commits into
Azure:mainfrom
kkarmakarMS:user/kkarmakarMS/aiinfraoptimization-new-rp-extension

Conversation

@kkarmakarMS

@kkarmakarMS Kunal Karmakar (kkarmakarMS) commented Oct 30, 2026 •

Copy link
Copy Markdown
Member

This checklist is used to make sure that common guidelines for a pull request are followed.

Related command

az aiinfraoptimization
aaz PR: Azure/aaz#1150

General Guidelines

  • Have you run azdev style <YOUR_EXT> locally? (pip install azdev required)
  • Have you run python scripts/ci/test_index.py -q locally? (pip install azdev required)
  • My extension version conforms to the Extension version schema

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.json automatically.
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.

Copilot AI balanced review requested due to automatic review settings October 30, 2026 04:21
@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
There may be pipelines that require an authorized user to comment /azp run to run.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

The new VM recommendation command lacks executable scenario coverage, and its published summary does not describe the functionality as required by the linked guidelines.

2 open issues
What changed in this PR

Introduces the aiinfraoptimization Azure CLI extension with an experimental command for recommending Azure virtual machine sizes for AI inference workloads.

Changes:

  • Adds az aiinfraoptimization recommendvmsku with model, workload, deployment, and optimization inputs.
  • Implements request serialization and response handling for the 2026-06-01-preview API.
  • Adds extension packaging, loader integration, documentation scaffolding, and a placeholder scenario test.
File Description
src/​aiinfraoptimization/​setup.py Defines package metadata and initial beta version.
src/​aiinfraoptimization/​setup.cfg Adds a configuration placeholder.
src/​aiinfraoptimization/​README.md Introduces the extension with a usage placeholder.
src/​aiinfraoptimization/​HISTORY.rst Records the initial release.
src/​aiinfraoptimization/​azext_aiinfraoptimization/​tests/​latest/​test_aiinfraoptimization.py Adds an empty scenario-test class.
src/​aiinfraoptimization/​azext_aiinfraoptimization/​tests/​latest/​__init__.py Initializes the latest-version test package.
src/​aiinfraoptimization/​azext_aiinfraoptimization/​tests/​__init__.py Initializes the test package.
src/​aiinfraoptimization/​azext_aiinfraoptimization/​custom.py Adds custom-command scaffolding.
src/​aiinfraoptimization/​azext_aiinfraoptimization/​commands.py Adds a custom command-registration hook.
src/​aiinfraoptimization/​azext_aiinfraoptimization/​azext_metadata.json Marks preview status and minimum CLI version.
src/​aiinfraoptimization/​azext_aiinfraoptimization/​aaz/​latest/​aiinfraoptimization/​_recommendvmsku.py Implements recommendation arguments, HTTP requests, and response schemas.
src/​aiinfraoptimization/​azext_aiinfraoptimization/​aaz/​latest/​aiinfraoptimization/​__init__.py Exports the generated command and group.
src/​aiinfraoptimization/​azext_aiinfraoptimization/​aaz/​latest/​aiinfraoptimization/​__cmd_group.py Registers the experimental command group.
src/​aiinfraoptimization/​azext_aiinfraoptimization/​aaz/​latest/​__init__.py Initializes the latest generated-command package.
src/​aiinfraoptimization/​azext_aiinfraoptimization/​aaz/​__init__.py Initializes the generated-command package.
src/​aiinfraoptimization/​azext_aiinfraoptimization/​_params.py Adds a custom argument-loading hook.
src/​aiinfraoptimization/​azext_aiinfraoptimization/​_help.py Adds help-registration scaffolding.
src/​aiinfraoptimization/​azext_aiinfraoptimization/​__init__.py Connects the extension loader to generated commands.

Review effort: Balanced

Comment thread src/aiinfraoptimization/setup.py Resolved
@a0x1ab

Copy link
Copy Markdown
Member

/azp run

@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
Successfully started running 2 pipeline(s).

@kkarmakarMS

Copy link
Copy Markdown
Member Author

/azp run

@azure-pipelines

Copy link
Copy Markdown
Commenter does not have sufficient privileges for PR 10540 in repo Azure/azure-cli-extensions

@kkarmakarMS

Copy link
Copy Markdown
Member Author

Aditya Pujara (@a0x1ab) please could you execute /azp run again?

@a0x1ab

Copy link
Copy Markdown
Member

/azp run

@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
Successfully started running 2 pipeline(s).

@kkarmakarMS

Kunal Karmakar (kkarmakarMS) commented Oct 30, 2026 •

Copy link
Copy Markdown
Member Author

Aditya Pujara (@a0x1ab) please could you execute /azp run again?

@a0x1ab

Copy link
Copy Markdown
Member

/azp run

@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
Successfully started running 2 pipeline(s).

@JaysonTaiMicrosoft

Copy link
Copy Markdown
Contributor

aaz: Azure/aaz#1150

@a0x1ab

Copy link
Copy Markdown
Member

/azp run

@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
Successfully started running 2 pipeline(s).

@x-engineering-agent

x-engineering-agent Bot commented Nov 3, 2026 •

Copy link
Copy Markdown

X Engineering Agent Pull request review: Ready for human review

Kunal Karmakar (@kkarmakarMS) No confirmed semantic findings at this head. The existing Copilot description concern is resolved: src/aiinfraoptimization/setup.py:41 now describes VM-size recommendations for AI inference workloads.

Reviewed command registration, request/output mappings, error propagation, packaging, help and release history. The author-provided scenarios in src/aiinfraoptimization/azext_aiinfraoptimization/tests/latest/test_aiinfraoptimization.py exercise the real command path with request-body matching, zero/false boundaries and service-error assertions; the three accompanying recordings match those cases.

Not verified: live execution, independent recording provenance, generator reproducibility, minimum-core runtime compatibility or sovereign-cloud availability. Owning-squad review remains required.

Check Status Detail
Upstream CI Passed CI reports six completed checks, five passed, zero failed and none pending.
Agent live tests Not run This is a review-only PR.
Regression coverage Not applicable Not applicable to the changed files.
Risk Risk 94/100 Critical Critical; owner review required
Review details

Upstream CI

CI reports six completed checks, five passed, zero failed and none pending. Committed scenarios and recordings are author-provided evidence, not Agent live-test results.

Test validation

  • Agent live test: Not run; this is a review-only PR. Check author-provided test evidence and upstream CI separately.
  • Regression coverage: Not applicable to the changed files.

Risk assessment

94/100 · Critical

The Critical rating is driven by security-sensitive behavior, public CLI behavior, dependency or supply chain and 2 additional signal(s).

  • Change scope: 22 changed files, 1219 changed lines (+1219 / -0), including 11 production files.
  • Affected components: aiinfraoptimization
  • Risk drivers: security-sensitive behavior (+28); public CLI behavior (+18); dependency or supply chain (+18); failure-handling behavior (+12); generated output (+12)
  • Regression evidence: Changed regression tests are included, reducing risk.
  • Confidence: High because changed-line patches were available for every production file.
  • Required review: Owning-squad review is required for aiinfraoptimization before merge.

Ask the Agent

Tick a box to queue an action. Requires write access to this repository.

  • Re-review this PR
  • Run Agent live tests on this PR

X Engineering Agent · Reviewer · React with +1 or -1 to train the agent

@x-engineering-agent x-engineering-agent Bot added the X Engineering Agent Reviewed Agent reviewed this PR label Nov 3, 2026
@a0x1ab

Copy link
Copy Markdown
Member

/azp run

@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
Successfully started running 2 pipeline(s).

@kkarmakarMS

Copy link
Copy Markdown
Member Author

Naga Nandyala (@naga-nandyala) Addressed all the comments raised by x-engineering-agent please review.

x-engineering-agent[bot]

This comment was marked as outdated.

@kkarmakarMS

Copy link
Copy Markdown
Member Author

Naga Nandyala (@naga-nandyala) last PR comment has been addressed.
Aditya Pujara (@a0x1ab) please could you execute /azp run again?

@x-engineering-agent x-engineering-agent Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@x-engineering-agent x-engineering-agent Bot removed the Request X Engineering Agent Ask the agent to triage this issue or review this PR label Nov 3, 2026
@a0x1ab

Copy link
Copy Markdown
Member

/azp run

@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
Successfully started running 2 pipeline(s).

@naga-nandyala
Naga Nandyala (naga-nandyala) merged commit 5809f88 into Azure:main Nov 3, 2026
30 checks passed
@kkarmakarMS
Kunal Karmakar (kkarmakarMS) deleted the user/kkarmakarMS/aiinfraoptimization-new-rp-extension branch November 3, 2026 06:02
@azclibot

Copy link
Copy Markdown
Collaborator

[Release] Update index.json for extension [ aiinfraoptimization-1.0.0b1 ] : https://dev.azure.com/msazure/One/_build/results?buildId=189100094&view=results

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

X Engineering Agent Reviewed Agent reviewed this PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

8 participants