Skip to content

Add agentic workflow for labelling azd extension PRs#8192

Open
JeffreyCA wants to merge 1 commit into
Azure:mainfrom
JeffreyCA:agentic-extension-pr-labeler
Open

Add agentic workflow for labelling azd extension PRs#8192
JeffreyCA wants to merge 1 commit into
Azure:mainfrom
JeffreyCA:agentic-extension-pr-labeler

Conversation

@JeffreyCA
Copy link
Copy Markdown
Contributor

@JeffreyCA JeffreyCA commented May 14, 2026

This PR introduces a GitHub Agentic Workflow and adds an extension-focused PR labeler for first-party azd extensions under cli/azd/extensions/** and closely related Azure AI design docs.

Note

This workflow uses safe-outputs.add-labels.allowed: [area/extensions, ext-*] so new extension labels can be picked up without editing the workflow each time. Runtime glob matching for allowed was added in github/gh-aw#32027, and this PR now pins and compiles with gh-aw v0.74.4 to pick up that fix.

What changes

  • Adds an Agentic Workflow that runs for PRs touching cli/azd/extensions/** or cli/azd/docs/**.
  • Infers related extension IDs from extension folder names, explicit IDs in docs, and strongly related doc topics.
  • Applies the matching ext-* label for mapped extension IDs.
  • Applies multiple ext-* labels when a PR relates to multiple mapped extension IDs.
  • Falls back to area/extensions when extension-related changes do not match a current ext-* mapping.

Agentic Workflow setup

Because this is the first Agentic Workflow in the repository, this PR also includes the required gh-aw setup artifacts generated from gh aw init:

  • Agent instructions/configuration
  • MCP configuration
  • Action pin metadata
  • Lock-file Git attributes
  • Copilot setup changes to install the gh-aw CLI

These files support compiling and maintaining the generated workflow lock file and make future Agentic Workflow changes reproducible for reviewers and agents.

Safety and references

The workflow follows gh-aw guidance for Markdown-based workflows, compiled lock files, read-only agent permissions, and GitHub writes through safe-outputs.add-labels:

Operational note: the default Copilot engine uses the COPILOT_GITHUB_TOKEN GitHub Actions secret for Copilot CLI authentication. The current PAT expires on August 12, 2026 and should be renewed/rotated before then using the gh-aw AI engine secret guidance:

Validation

Tested and verified on fork repo PR

image image

Copilot AI review requested due to automatic review settings May 14, 2026 21:52
@JeffreyCA JeffreyCA marked this pull request as draft May 14, 2026 22:07
@JeffreyCA JeffreyCA force-pushed the agentic-extension-pr-labeler branch 3 times, most recently from 90c78d4 to d6f7f90 Compare May 15, 2026 00:55
@JeffreyCA JeffreyCA marked this pull request as ready for review May 15, 2026 01:17
@JeffreyCA JeffreyCA linked an issue May 15, 2026 that may be closed by this pull request
@JeffreyCA JeffreyCA force-pushed the agentic-extension-pr-labeler branch 2 times, most recently from fedc3c7 to 7127ad5 Compare May 15, 2026 22:28
Copy link
Copy Markdown
Member

@jongio jongio left a comment

Choose a reason for hiding this comment

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

The security model here is solid - read-only agent permissions, safe-outputs constrained to add_labels with an allowlist, team membership gating in pre_activation, and AWF firewall sandboxing. pull_request_target is the right trigger since this needs to label fork PRs too.

One question on the doc version references in the agent instructions file - see inline comment.

nit: .github/mcp.json is missing a trailing newline.

Comment thread .github/agents/agentic-workflows.agent.md Outdated
Comment thread .github/mcp.json Outdated
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@JeffreyCA JeffreyCA force-pushed the agentic-extension-pr-labeler branch from 7127ad5 to bca9303 Compare May 18, 2026 19:01
@JeffreyCA JeffreyCA requested a review from jongio May 18, 2026 19:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Housekeeping - auto-label extension PRs

2 participants