Commit 941f05a
Add agentic-workflow infrastructure for code review and onboarding
This change adds a code-review surface, test-quality enforcement,
self-improving guidance plumbing, and supporting infrastructure for
agentic workflows in aspnetcore. Builds on patterns proven in other
.NET org repos (runtime, msbuild, maui) and the cross-agent AGENTS.md
convention.
## Files added (16 plus PROPOSAL-README.md reviewer notes)
### Cross-cutting infrastructure
- .github/workflows/shared/pat_pool.md — shared PAT-pool import used
by new agentic workflows (avoids duplicating the case() expression
per workflow).
- .github/workflows/shared/pat_pool.README.md — operator docs for
the PAT pool.
- .github/workflows/validate-pat-pool.yml — daily PAT health check
that catches expired tokens before they break a real workflow.
- .github/AGENTIC-WORKFLOWS.md — one-page rubric for adding new
gh-aw workflows (tenets, required structure, references to public
reference implementations).
### Code-review surface (Blazor-aware)
- .github/workflows/code-review.md — thin dispatcher workflow. On
PR open or sync, routes to area-specific reviewer agents in
parallel and aggregates findings into a single review submission.
- .github/skills/code-review/SKILL.md — routing table + general
aspnetcore conventions fallback for areas without a dedicated
agent. Follows the skill-as-shim pattern: the skill is for
discoverability; the agent is the source of truth for content.
- .github/agents/blazor-expert-reviewer.agent.md — 12 principles
+ 12 review dimensions covering render-mode parity, pre-rendering
+ PersistentComponentState, trim/AOT safety, disposal contracts,
JS interop discipline, public API surface, server-circuit
thread safety, accessibility, localization, Razor source
generator, and hot-reload determinism. Four-wave review process
(Discover → Validate → Post → Summary) with proof-or-disprove
validation before posting to minimize false positives. Severity
ladder: BLOCKING / MAJOR / MODERATE / MINOR. Inline review
comments for diff-line findings via create_pull_request_review_comment;
design-level concerns via add_comment. Never APPROVE (the agent
must not count as a PR approval).
### Test-contract enforcement
- .github/workflows/evaluate-pr-tests.md — slash-command (/evaluate-tests)
and workflow_dispatch triggered. Pre-gates deterministically in bash
on "no test files in diff = exit early" before the agent activates.
- .github/skills/evaluate-pr-tests/SKILL.md — 8-dimension rubric for
assessing whether tests added in a PR actually exercise the change.
Includes Blazor-specific dimensions for render-mode coverage at the
E2E level. Calls out the TestRenderer pattern (shared infra from
src/Components/Shared/test/) as the canonical component-unit-test
approach. Selenium is the incumbent E2E framework; prefer Playwright
for new E2E projects (reference pattern in
src/ProjectTemplates/test/Templates.Blazor.Tests/).
- .github/skills/verify-tests-fail-without-fix/SKILL.md — reverts the
production change in a PR, reruns the new tests, and verifies they
fail. Strongest objective signal that a regression test exercises
the bug it claims to fix.
### Compatibility & breaking-change discipline
- .github/skills/assessing-breaking-changes/SKILL.md — blast-radius
checklist, deprecation protocol, decision framework. aspnetcore-
specific: API review board (not ChangeWave); render-mode parity as
a compat dimension; wire-compat considerations for SignalR /
DataProtection / Antiforgery / Authentication / PersistentComponentState;
WASM trim-safety + NativeAOT regression checks. The Warnings-as-
Errors rule (new warnings break consumers that set
<TreatWarningsAsErrors>true</TreatWarningsAsErrors>).
### Self-improving guidance
- .github/workflows/learn-from-pr.md — manual dispatch with apply:
false (report only) or apply: true (open draft PR with applied
guidance updates). allowed-files restricted to .github/.
- .github/skills/learn-from-pr/SKILL.md — analysis pass: extract
reusable lessons from a completed PR, classify them by destination
(general copilot-instructions.md, per-area AGENTS.md, area
instructions.md shim, skill enhancement, agent dimension addition),
and prioritize High / Medium / Low.
- .github/agents/learn-from-pr.agent.md — apply pass: takes the
skill's High/Medium recommendations and opens a single draft PR
with the matching edits.
### Skill validation
- .github/workflows/skill-validation.yml — validates skills and
agents on every PR touching .github/skills/** or .github/agents/**.
Downloads the skill-validator binary from dotnet/skills releases,
caches daily, smart-filters to only validate changed skills.
- .github/workflows/skill-validation-comment.yml — workflow_run-
triggered companion that posts results as a PR comment. Safe for
fork PRs (never checks out PR code).
## Conventions adopted
### Per-area guidance: AGENTS.md is the canonical destination
Follows the cross-agent AGENTS.md convention (https://agents.md)
already used in this repo at src/Components/AGENTS.md and
eng/common/AGENTS.md. Closest-to-the-edited-file wins; works with
Copilot, Claude Code, Cursor, Codex, and others. When Copilot needs
to auto-load guidance via applyTo: glob, the
.github/instructions/<area>.instructions.md shim delegates to the
AGENTS.md (the existing aspnetcore pattern).
### Test frameworks
- Razor component unit logic uses the TestRenderer pattern from
src/Components/Shared/test/, brought in via
$(ComponentsSharedSourceRoot)test/**/*.cs. bUnit is not used in
aspnetcore source.
- Selenium is the incumbent E2E framework for components
(src/Components/test/E2ETest/, imports
$(SharedSourceRoot)E2ETesting/E2ETesting.props). For new E2E
projects or surfaces, prefer Playwright (reference pattern in
src/ProjectTemplates/test/Templates.Blazor.Tests/). Don't mix
frameworks within an existing Selenium project.
- Render-mode parity (Server / WASM / Auto) is proven at the E2E
level — TestRenderer is in-process and does not model render modes.
## Not included (intentional)
- .lock.yml files for the new workflows — must be regenerated with
'gh aw compile' before push.
- Changes to existing workflows (community-pr-issue-check,
issue-triage-agent, cswin32-update, browsertesting-deps-update,
test-quarantine) — kept stable; augmentation is a separate follow-up.
- .github/copilot/settings.json and .github/copilot-instructions.md
— kept stable; the learn-from-pr agent will extend the latter over
time.
- .github/agents/aspnetcore-expert-reviewer.agent.md for non-Blazor
areas — left as forward-reference for the maintainer to author.
## See PROPOSAL-README.md for reviewer notes including open questions.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>1 parent 4637df8 commit 941f05a
17 files changed
Lines changed: 2511 additions & 0 deletions
File tree
- .github
- agents
- skills
- assessing-breaking-changes
- code-review
- evaluate-pr-tests
- learn-from-pr
- verify-tests-fail-without-fix
- workflows
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
0 commit comments