Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Jan 22, 2026

This repository maintains four SDK implementations (Node.js, Python, Go, .NET) that must maintain feature parity. When PRs modify one SDK, there's no automated check to ensure equivalent functionality exists or is being updated in the others.

Changes

  • Created .github/workflows/sdk-consistency-review.md: Agentic workflow that reviews PRs touching SDK code

    • Triggers on PRs modifying nodejs/, python/, go/, or dotnet/ directories
    • Cross-references equivalent functionality across all SDK implementations
    • Analyzes API design patterns accounting for language idioms (camelCase vs snake_case vs PascalCase)
    • Posts inline review comments on inconsistencies with specific remediation suggestions
    • Configured with roles: all to run on PRs from any contributor (not just maintainers)
  • Compiled to .github/workflows/sdk-consistency-review.lock.yml: Executable GitHub Actions workflow

Behavior

The agent identifies which SDK(s) are modified, analyzes the feature/fix being implemented, and checks for equivalent functionality in other implementations. It distinguishes between:

  • Features requiring cross-SDK consistency
  • Bug fixes that may reveal issues elsewhere
  • Language-specific optimizations that don't need mirroring

Uses safe-outputs for write operations (max 10 inline comments, 1 summary per run) with read-only permissions. Runs on all PRs regardless of contributor role to ensure comprehensive consistency checking across the codebase.

Original prompt

This section details on the original issue you should resolve

<issue_title>Add a Code Review Agent to enforce SDK consistency</issue_title>
<issue_description>When a new PR that touches one of the clients is opened we need to check whether the feature that is implement is implemented consistently across all different languages.</issue_description>

Comments on the Issue (you are @copilot in this section)

Custom agent used: create-agentic-workflow
Design agentic workflows using GitHub Agentic Workflows (gh-aw) extension with interactive guidance on triggers, tools, and security best practices.


💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

Copilot AI and others added 2 commits January 22, 2026 19:12
Co-authored-by: friggeri <106686+friggeri@users.noreply.github.com>
…workflow

Co-authored-by: friggeri <106686+friggeri@users.noreply.github.com>
Copilot AI changed the title [WIP] Add a code review agent for SDK consistency Add agentic workflow for cross-SDK consistency enforcement Jan 22, 2026
Copilot AI requested a review from friggeri January 22, 2026 19:16
@friggeri
Copy link
Collaborator

@copilot we need this to work on any PR, not just those that have been authored by maintainers, so you might need to adjust roles (set to "all") maybe?

Co-authored-by: friggeri <106686+friggeri@users.noreply.github.com>
Copy link
Contributor Author

Copilot AI commented Jan 22, 2026

@copilot we need this to work on any PR, not just those that have been authored by maintainers, so you might need to adjust roles (set to "all") maybe?

Added roles: all to the workflow configuration. This allows the workflow to run on PRs from any contributor, not just maintainers. (b10c57c)

@friggeri friggeri marked this pull request as ready for review January 22, 2026 23:11
@friggeri friggeri requested a review from a team as a code owner January 22, 2026 23:11
Copilot AI review requested due to automatic review settings January 22, 2026 23:11
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR introduces an agentic workflow to enforce cross-SDK consistency across the Node.js, Python, Go, and .NET clients, and updates the existing issue triage workflow to the latest gh-aw tooling and safe-outputs patterns.

Changes:

  • Add .github/workflows/sdk-consistency-review.md defining an SDK Consistency Review Agent that inspects PRs touching any SDK directory and checks for cross-language API and feature parity.
  • Add the compiled .github/workflows/sdk-consistency-review.lock.yml GitHub Actions workflow that runs the Copilot-based agent with safe-outputs, threat detection, and artifact logging.
  • Regenerate and upgrade .github/workflows/issue-triage.lock.yml to gh-aw v0.37.10, adopting the same safe-outputs/MCP gateway patterns and updated tooling.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

File Description
.github/workflows/sdk-consistency-review.md Defines the high-level agentic workflow: triggers, permissions, safe-output limits, and detailed review instructions for enforcing cross-SDK consistency.
.github/workflows/sdk-consistency-review.lock.yml Compiled, executable workflow wiring the SDK consistency agent into GitHub Actions, including activation gating, Copilot CLI execution, safe-outputs processing, and threat detection.
.github/workflows/issue-triage.lock.yml Updates the Issue Triage Agent to the newer gh-aw release, aligning it with the same safe-outputs, MCP gateway, and Copilot CLI install patterns used by the new SDK consistency workflow.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.


jobs:
activation:
if: (github.event_name != 'pull_request') || (github.event.pull_request.head.repo.id == github.repository_id)
Copy link

Copilot AI Jan 22, 2026

Choose a reason for hiding this comment

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

The activation job condition (github.event_name != 'pull_request') || (github.event.pull_request.head.repo.id == github.repository_id) means this workflow will not run for PRs opened from forks, only for PRs whose head branch is in this repository. The PR description claims the agent "runs on all PRs regardless of contributor role"/"roles: all", but that is not accurate given this gating. If the intent is to review PRs from external contributors working from forks, you’ll need to adjust this condition and/or restructure how secrets like COPILOT_GITHUB_TOKEN are used so that the agent can run safely on forked PRs, or otherwise update the description to match the actual behavior.

Copilot uses AI. Check for mistakes.
@SteveSandersonMS SteveSandersonMS added this pull request to the merge queue Jan 23, 2026
Merged via the queue into main with commit c8fee95 Jan 23, 2026
28 checks passed
@SteveSandersonMS SteveSandersonMS deleted the copilot/add-code-review-agent branch January 23, 2026 11:14
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.

Add a Code Review Agent to enforce SDK consistency

5 participants