azure-typespec-author skill, switch to the new KB endpoint and update evals - #16264
Merged
Conversation
Switch the azure-typespec-author code-quality benchmark from the locally-built qa-bot backend (localhost:8088) to the new remote KB agent test endpoint. - .vally.yaml: repoint the azsdk-mcp environment's AZURE_SDK_KB_ENDPOINT to the new test endpoint and add AZURE_SDK_KB_CLIENT_ID (the endpoint is MSAL-protected; azsdk-cli requests a token for <client-id>/.default). - benchmark pipeline: set StartQaBotBackend=false for the code-quality job (no local Go backend), run each Vally suite inside an authenticated AzureCLI@2 context, and drop the now-unused qa-bot backend log artifact. - run-suite template: add optional AzureSubscription param; when set the eval runs under AzureCLI@2 so azsdk-cli can obtain a bearer token for the remote KB. Trigger/mock runs (no subscription) are unchanged. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
The test KB agent endpoint rejects tokens minted for the production client id (899da762): azsdk-cli returned 'Unauthorized: Invalid or missing AI completion service client id or scope', so the remote KB never saw valid traffic. Use the test backend's registered app instead (values validated by the qa-bot owner in issue #15675): - AZURE_SDK_KB_CLIENT_ID: 674414e1-152b-41ac-b0d2-763535edea6c - AZURE_SDK_KB_SCOPE: api://azure-sdk-qa-bot-test/user_impersonation - drop the trailing slash on AZURE_SDK_KB_ENDPOINT. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
The authenticated run-suite branch relies on AzureCLI@2 logging az in via the service connection so azsdk-cli's AzureCliCredential can mint a bearer token for the remote KB. Add an explicit 'az account show' at the top of the inline script to confirm the login context and fail fast if it is missing or expired before the long eval starts. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…b-15675 # Conflicts: # eng/pipelines/azure-typespec-author-benchmark.yml # eng/pipelines/templates/steps/typespec-author-eval-run-suite.yml
3 tasks
Re-apply the code-quality benchmark edits that were clobbered by the Vally 0.6.0 merge (#16260): - run-suite template: add optional AzureSubscription param; when set, run the vally eval inside AzureCLI@2 (verifying 'az account show' first) so azsdk-cli can obtain a bearer token for the remote KB. Empty default keeps trigger/mock runs on the plain script path. - benchmark (RunEvalsForCodeQuality): set StartQaBotBackend: false, pass AzureSubscription: 'azuresdkqabot-dev' to all 5 forced suites, and drop the now-unused qa-bot-service-log-code-quality artifact. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Both benchmark jobs now call the remote KB, so drop the if/else and the duplicate script block: always run vally under AzureCLI@2 and make AzureSubscription required. Pass AzureSubscription to the trigger job too. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…_generate_authoring_plan' tool grader
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: d4912c91-426b-4cb5-8bd2-5ef89f4158fc
…b-15675 # Conflicts: # eng/pipelines/azure-typespec-author-benchmark.yml
Member
Author
|
benchmark pipeline runs:
It aligns with our previous tests. And the pass rate looks acceptable. |
haolingdong-msft
marked this pull request as ready for review
July 23, 2026 07:10
haolingdong-msft
requested review from
a team and
catalinaperalta
as code owners
July 23, 2026 07:10
|
Azure Pipelines: Successfully started running 1 pipeline(s). 64 pipeline(s) were filtered out due to trigger conditions. There may be pipelines that require an authorized user to comment /azp run to run. |
Contributor
There was a problem hiding this comment.
Pull request overview
Updates the azure-typespec-author skill evaluation/benchmarking flow to use the new remote Knowledge Base (KB) agent test endpoint (MSAL-protected), adjusting pipelines and eval cases to run in an authenticated Azure CLI context and tightening eval graders.
Changes:
- Repoints KB defaults/overrides to the new agent endpoints and configures required auth environment variables for the remote KB.
- Updates the TypeSpec author benchmark pipeline and run-suite template to run Vally under
AzureCLI@2and removes the local QA bot backend dependency for these eval jobs. - Expands eval coverage/robustness by adding a Node dependency check script and updating graders/patterns across multiple eval cases.
Reviewed changes
Copilot reviewed 35 out of 35 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| tools/azsdk-cli/Azure.Sdk.Tools.Cli/Services/AzureSdkKnowledgeBaseService.cs | Updates the default KB service endpoint used by azsdk-cli. |
| eng/pipelines/templates/steps/typespec-author-eval-run-suite.yml | Runs each Vally suite inside AzureCLI@2 to enable token acquisition for remote KB. |
| eng/pipelines/azure-typespec-author-benchmark.yml | Disables local backend startup for benchmark jobs, adds Azure subscription context, removes backend log artifact. |
| .github/skills/azure-typespec-author/evaluate/scripts/check-node-dependencies.js | Adds a script to validate node_modules and required TypeSpec packages exist before compiling. |
| .github/skills/azure-typespec-author/evaluate/evals/005001.eval.yaml | Adds dependency checks; loosens required tool calls to allow bash; keeps validation/tool-call requirements. |
| .github/skills/azure-typespec-author/evaluate/evals/004003.eval.yaml | Adds dependency checks; loosens required tool calls to allow bash; keeps validation/tool-call requirements. |
| .github/skills/azure-typespec-author/evaluate/evals/004002.eval.yaml | Adds dependency checks to ensure fixture node deps are present before compilation. |
| .github/skills/azure-typespec-author/evaluate/evals/004001.eval.yaml | Adds dependency checks to ensure fixture node deps are present before compilation. |
| .github/skills/azure-typespec-author/evaluate/evals/003002.eval.yaml | Adds dependency checks to ensure fixture node deps are present before compilation. |
| .github/skills/azure-typespec-author/evaluate/evals/003001.eval.yaml | Adds dependency checks to ensure fixture node deps are present before compilation. |
| .github/skills/azure-typespec-author/evaluate/evals/002011.eval.yaml | Adds dependency checks to ensure fixture node deps are present before compilation. |
| .github/skills/azure-typespec-author/evaluate/evals/002010.eval.yaml | Adds dependency checks to ensure fixture node deps are present before compilation. |
| .github/skills/azure-typespec-author/evaluate/evals/002009.eval.yaml | Adds dependency checks to ensure fixture node deps are present before compilation. |
| .github/skills/azure-typespec-author/evaluate/evals/002008.eval.yaml | Adds dependency checks and tightens regex expectations for ARM top/skip parameter patterns. |
| .github/skills/azure-typespec-author/evaluate/evals/002007.eval.yaml | Adds dependency checks to ensure fixture node deps are present before compilation. |
| .github/skills/azure-typespec-author/evaluate/evals/002006.eval.yaml | Adds dependency checks to ensure fixture node deps are present before compilation. |
| .github/skills/azure-typespec-author/evaluate/evals/002005.eval.yaml | Adds dependency checks to ensure fixture node deps are present before compilation. |
| .github/skills/azure-typespec-author/evaluate/evals/002004.eval.yaml | Adds dependency checks to ensure fixture node deps are present before compilation. |
| .github/skills/azure-typespec-author/evaluate/evals/002003.eval.yaml | Adds dependency checks to ensure fixture node deps are present before compilation. |
| .github/skills/azure-typespec-author/evaluate/evals/002002.eval.yaml | Adds dependency checks to ensure fixture node deps are present before compilation. |
| .github/skills/azure-typespec-author/evaluate/evals/002001.eval.yaml | Adds dependency checks to ensure fixture node deps are present before compilation. |
| .github/skills/azure-typespec-author/evaluate/evals/001013.eval.yaml | Adds dependency checks and relaxes versioning decorator matchers to allow optional namespace qualifiers. |
| .github/skills/azure-typespec-author/evaluate/evals/001011.eval.yaml | Adds dependency checks and relaxes versioning decorator matchers to allow optional namespace qualifiers. |
| .github/skills/azure-typespec-author/evaluate/evals/001010.eval.yaml | Adds dependency checks and relaxes versioning decorator matchers to allow optional namespace qualifiers. |
| .github/skills/azure-typespec-author/evaluate/evals/001009.eval.yaml | Adds dependency checks and relaxes versioning decorator matchers to allow optional namespace qualifiers. |
| .github/skills/azure-typespec-author/evaluate/evals/001008.eval.yaml | Adds dependency checks and allows either web_fetch or the MCP authoring-plan tool for version info. |
| .github/skills/azure-typespec-author/evaluate/evals/001007.eval.yaml | Adds dependency checks, allows either web_fetch or MCP authoring-plan tool, relaxes regex matchers. |
| .github/skills/azure-typespec-author/evaluate/evals/001006.eval.yaml | Adds dependency checks and allows either web_fetch or the MCP authoring-plan tool for version info. |
| .github/skills/azure-typespec-author/evaluate/evals/001005.eval.yaml | Adds dependency checks and allows either web_fetch or the MCP authoring-plan tool; relaxes regex matchers. |
| .github/skills/azure-typespec-author/evaluate/evals/001004.eval.yaml | Adds dependency checks to ensure fixture node deps are present before compilation. |
| .github/skills/azure-typespec-author/evaluate/evals/001003.eval.yaml | Adds dependency checks to ensure fixture node deps are present before compilation. |
| .github/skills/azure-typespec-author/evaluate/evals/001002.eval.yaml | Adds dependency checks and relaxes versioning decorator matchers to allow optional namespace qualifiers. |
| .github/skills/azure-typespec-author/evaluate/evals/001001.eval.yaml | Adds dependency checks to ensure fixture node deps are present before compilation. |
| .github/skills/azure-typespec-author/evaluate/.vally.yaml | Switches the azsdk-mcp environment to the remote KB endpoint and supplies client ID/scope env vars. |
| .github/skills/.gitignore | Ignores result/ output directory used by local Vally runs. |
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
lirenhe
reviewed
Jul 23, 2026
lirenhe
approved these changes
Jul 23, 2026
chunyu3
approved these changes
Jul 24, 2026
This was referenced Jul 27, 2026
Member
Author
|
Fix #16425 |
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.
Fix #16015
Fix #16425
Switch the azure-typespec-author code-quality benchmark from the locally-built qa-bot backend (localhost:8088) to the new remote KB agent test endpoint.