Skip to content

feat: /coding:architecture-review — deep whole-codebase review#59

Merged
bborbe merged 1 commit into
masterfrom
feature/architecture-review-command
Jun 25, 2026
Merged

feat: /coding:architecture-review — deep whole-codebase review#59
bborbe merged 1 commit into
masterfrom
feature/architecture-review-command

Conversation

@bborbe

@bborbe bborbe commented Jun 25, 2026

Copy link
Copy Markdown
Owner

Summary

Adds /coding:architecture-review [directory] — a deep whole-codebase architectural review at a different altitude from existing commands:

  • /coding:code-review — diff-scoped, per-PR
  • /coding:audit-architecture — single-agent quick scan
  • /coding:architecture-review (new) — two parallel agents, dimensions coverage, Must/Should/Could consolidation

What it does

Spawns in parallel:

  1. Top-down structuralcoding:go-architecture-assistant (or coding:python-architecture-assistant per project type): entry point → packages, SRP at package level, layering, dependency direction, abstraction seams, notable good patterns.
  2. Dimensions pass — generic claude (open-ended behavioral exploration; documented in-place why generic agent is correct here): data flow end-to-end, failure & resilience, concurrency & lifecycle, observability, cross-cutting consistency, config/blast radius, evolvability test, architectural drift.

Consolidates into Must Fix / Should Fix / Could Fix with file:line citations and Top 5 highest-leverage fixes.

When to use

  • Quarterly architectural health audit
  • Before scaling a service (team, traffic, complexity)
  • When persistent friction signals "the design is fighting us"
  • Onboarding a codebase you didn't write

Test plan

  • make precommit green (30 checks)
  • Local self-review loop converged (3 passes; 2 Should Fix + 3 Could Fix found and fixed)
  • Manual end-to-end run against a real codebase (deferred until merge — the command itself only ships agent invocations + framing, no executable code to dry-run)

Different altitude from /coding:code-review (diff-scoped) and
/coding:audit-architecture (single-agent). Spawns two parallel agents:
top-down structural + dimensions pass (data flow, failure, concurrency,
observability, drift). Consolidates into Must Fix / Should Fix / Could Fix
with file:line citations and Top 5 highest-leverage fixes.
@bborbe bborbe marked this pull request as ready for review June 25, 2026 20:12

@ben-s-pull-request-reviewer ben-s-pull-request-reviewer Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Based on my analysis, here's my review:

{
  "verdict": "approve",
  "summary": "The `/coding:architecture-review` command is well-designed: thin wrapper (~109 lines), correct frontmatter, minimal allowed-tools, delegates all deep work to parallel agents. Two concerns noted below are Should Fix / Nice to Have, not blockers.",
  "comments": [
    {
      "file": "commands/architecture-review.md",
      "line": 2,
      "severity": "major",
      "message": "allowed-tools 'Bash(git status:+)','Bash(git log:+)','Bash(git branch:+)' are marked with '+' suffix but the Context section (lines 9-11) uses `!git ...` syntax which is a Claude Code variable expansion, not a Bash tool call — the '+' suffix may not be needed. However since 'git status' and 'git log' without '+' could be unsafe, keeping the '+' variants is the conservative choice. Verify this works as intended in a live test."
    },
    {
      "file": "commands/architecture-review.md",
      "line": 61,
      "severity": "minor",
      "message": "Step 3 spawns 2-3 parallel Task agents with no explicit concurrency limit or timeout. For large codebases this could consume significant resources. Consider documenting the expected resource envelope or adding a note that users should ensure their Claude Code session has sufficient context window."
    },
    {
      "file": "commands/architecture-review.md",
      "line": 64,
      "severity": "minor",
      "message": "The dimensions pass (Agent B) routes to the generic 'claude' subagent with a detailed prompt. The PR body acknowledges that validation against a real codebase is deferred. Consider adding a NOTE in the command that first-run validation against a real codebase is pending."
    }
  ],
  "concerns_addressed": [
    "correctness: allowed-tools list is intentionally minimal — verified. The '+' suffix on git tools is conservative but may not match `!git` variable syntax; needs live verification.",
    "correctness: Step 3 parallel Task agents — no timeout/concurrency limit is a known trade-off for deep reviews, not a bug. Consider documenting resource expectations.",
    "tests: e2e validation deferred — acknowledged as a limitation in the PR body. Acceptable for a plugin repo; should be validated before first stable release."
  ]
}

@bborbe bborbe merged commit 6f4da90 into master Jun 25, 2026
1 check passed
@bborbe bborbe deleted the feature/architecture-review-command branch June 25, 2026 20:16
bborbe added a commit that referenced this pull request Jun 25, 2026
Closes PR #59's MAJOR finding ("dimensions pass routes to generic claude
with inline agent role"). The 8-dimension behavioral review checklist is
now a maintainable doc-paired agent:

- docs/architecture-dimensions-guide.md — source of truth for the 8
  dimensions, severity rubric, output contract
- agents/architecture-dimensions-assistant.md — agent that reads the
  guide and applies it (no rule duplication)
- commands/architecture-review.md — Agent B now a true thin wrapper,
  one-line prompt routing to the new agent

Indexed in README, llms.txt, CLAUDE.md Doc↔Agent table.
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.

1 participant