pr-architecture-check

Reviews pull request diffs against documented architecture constraints and posts advisory comments.

32.7k|4.9k|Updated Feb 13, 2026
One-click install
npx skills add https://github.com/zeroclaw-labs/zeroclaw --skill pr-architecture-check
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: pr-architecture-check
Source: https://github.com/zeroclaw-labs/zeroclaw/tree/main/.claude/skills/pr-architecture-check
Command: npx skills add https://github.com/zeroclaw-labs/zeroclaw --skill pr-architecture-check

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

Reviewing pull requests for architectural consistency is time-consuming and easy to overlook, especially in multi-crate Rust projects with strict dependency direction and trait boundary rules. This Skill automates an advisory architecture review of any PR diff against the project's documented constraints.

Core Features & Use Cases

  • Dependency Direction Validation: Checks Cargo.toml changes and use statements to ensure dependencies flow inward toward the API crate, never outward.
  • Trait Boundary and Extension Pattern Checks: Detects hardcoding around trait abstractions, downcasting, and implementations that bypass the factory registration pattern.
  • Advisory-Only Reporting: Writes a structured review artifact to tmp/arch-review-<N>.md and posts it as a non-blocking PR comment only after explicit human approval.
  • Use Case: A contributor opens a PR adding a new channel implementation. Run the check to verify it registers via the factory pattern, lives in the correct crate, and does not violate any of the seven core engineering constraints before human review.

Quick Start

Ask the assistant to run an architecture check on a pull request by saying: run arch-check on PR number 1234 and show me the advisory review.

Frequently Asked Questions about pr-architecture-check

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I run an architecture review on a GitHub pull request?

Invoke the check with 'arch-check #N' or 'architecture check #N' where N is the PR number. The skill fetches the diff via the GitHub CLI, analyzes it against the architecture checklist, and writes a review artifact for your approval before posting.

What architecture rules does the PR check validate?

It validates dependency direction toward the API crate, trait boundary compliance, factory-based extension patterns, correct crate placement, and seven core constraints including single static binary, minimal footprint, and secure-by-default posture.

Does the architecture check block merging a pull request?

No, the check is advisory only and never gates merges. It posts a non-blocking comment, does not approve or request changes, and does not modify labels, per the project's governance rule that AI belongs in the development loop, not the merge gate.

Can the skill post the review comment automatically?

No, posting requires explicit human approval. The skill writes the artifact to tmp/arch-review-<N>.md, shows it to the reviewer, and only runs the gh pr comment command after the reviewer confirms.

What tools are required to run the PR architecture check?

The skill requires the GitHub CLI (gh) to fetch PR diffs and metadata and to post comments. It also reads repository documents such as AGENTS.md and the FND-001 architecture RFC as authoritative references.