BlogsGitHubAgentic Workflows for Cross-Repo Automation

Agentic Workflows for Cross-Repo Automation

Agentic Workflows for Cross-Repo Automation

3
posts
2026

This feature thread tracks the evolution of using agentic workflows to automate cross-repository tasks, specifically for documentation generation and code review. Initially, the focus was on enabling AI to assist in code development and review. This post details the implementation of GitHub Stacked Pull Requests to manage AI-generated code changes, enabling the decomposition of large features into smaller, reviewable units. It covers the use of the `gh stack` CLI for managing these stacks, agentic workflows for creating and managing individual layers, and the review process for stacked pull requests.

2026

Turn one giant AI-generated pull request to a reviewable stack

8/4/2026

This post introduces and details the application of GitHub Stacked Pull Requests as a mechanism to manage AI-generated code changes. It explains how to decompose large features into smaller, reviewable layers using the `gh stack` CLI, including setting a stack base, identifying foundational units of work, and layering dependent work. The post outlines a workflow for agents to create and manage these stacked pull requests, and describes the reviewer's journey through reading top-down and reviewing bottom-up. It also covers the process of updating and rebasing stacks when changes are requested.

Better tools made Copilot code review worse. Here's how we actually improved it.

7/10/2026

This post details the engineering effort to improve Copilot code review by optimizing the instructions for shared code exploration tools (grep, glob, view). It describes how the initial migration to these tools led to a regression in performance and effectiveness, characterized by a 'browsing loop' rather than focused investigation. The core contribution is the redesign of tool instructions to align with a reviewer's workflow: starting from the diff, narrowing the search with grep and glob, and using view only for specific evidence. This involved batching discovery and reads, and refining error recovery strategies. The post emphasizes the use of internal benchmarks to debug agent behavior and validate the effectiveness of these instruction changes, resulting in approximately 20% lower average review costs.

Automating cross-repo documentation with GitHub Agentic Workflows

7/8/2026

This post details the implementation of GitHub Agentic Workflows for automating cross-repo documentation. It introduces the concept of agentic workflows with a markdown-based prompt and a compiled GitHub Actions workflow. Key technical contributions include the 'safe-outputs handler' for materialized intent, a GitHub App with scoped permissions for secure cross-repo writes, and a deterministic target branch resolver using pull request milestones. The post also outlines the end-to-end pipeline, the 'safe-outputs contract' with specific tools and allowed actions, and metrics demonstrating the efficiency gains in documentation generation.