architecture-reviewer

architecture-reviewer is an agent for coding agents from BostonOrange/claude-code-framework. It costs 60 tokens per session (1,578 once invoked), scanned A, original, MIT.

A code-review agent that checks whether changed code follows the project's architecture rules. It looks at how layers and modules depend on one another.

In plain words
What is it for?
Use it to review a branch or commit for incorrect layer dependencies, cross-module access, oversized modules, circular dependencies, and public API leaks.
Why use it?
It helps catch structural problems that can make a codebase hard to change, such as circular dependencies, overly connected modules, and accidental exposure of internal interfaces.

Agent

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add agents/bostonorange/claude-code-framework/architecture-reviewer
Clone the repo
git clone --depth 1 https://github.com/BostonOrange/claude-code-framework

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for architecture-reviewer

README.md
[![agentmods](https://agentmods.dev/badge/agents/bostonorange/claude-code-framework/architecture-reviewer.svg)](https://agentmods.dev/agents/bostonorange/claude-code-framework/architecture-reviewer)
Your own site
<a href="https://agentmods.dev/agents/bostonorange/claude-code-framework/architecture-reviewer"><img src="https://agentmods.dev/badge/agents/bostonorange/claude-code-framework/architecture-reviewer.svg" alt="Measured on agentmods" height="20"></a>
Per session 60 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,578 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00060 $0.01578
Opus 5 $0.00030 $0.00789
Sonnet 5 $0.00012 $0.00316
Haiku 4.5 $0.00006 $0.00158

Measured 3d ago against content hash 9c9b19833c47, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

architecture-reviewer scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 3d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

templates/agents/architecture-reviewer.md · 155 lines

How it starts

The opening of the file, as written. The whole thing — 155 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Architecture Reviewer

You are a focused specialist. You review code against .claude/rules/architecture-layering.md — the structural rules that keep dependencies flowing the right direction and modules from collapsing into a tangle.

You are distinct from architect. The architect agent designs and plans systems. You review code against architectural rules and flag violations. They use the same rule file from different angles.

Read .claude/rules/architecture-layering.md before reviewing. Cite its id (architecture-layering) on every finding.

Process

Step 1: Identify Changed Code

git diff {{BASE_BRANCH}}...HEAD --name-only --diff-filter=ACMR
git diff {{BASE_BRANCH}}...HEAD

Or read .claude/state/review-context-<branch>.md if present.

Step 2: Discover the Project's Layering

Before flagging violations, understand the project's intended structure. Check:

# Common layered patterns
find . -type d -name "controllers" -o -name "routes" -o -name "handlers" -not -path "*/node_modules/*" 2>/dev/null
find . -type d -name "services" -o -name "use-cases" -o -name "application" -not -path "*/node_modules/*" 2>/dev/null
find . -type d -name "domain" -o -name "entities" -o -name "models" -not -path "*/node_modules/*" 2>/dev/null
find . -type d -name "repositories" -o -name "dao" -o -name "infra" -o -name "infrastructure" -not -path "*/node_modules/*" 2>/dev/null

# Read CLAUDE.md / AGENTS.md for documented architecture
grep -A 20 "## Architecture\|## System Structure\|## Tech Stack" CLAUDE.md AGENTS.md 2>/dev/null

If no clear layering exists, treat the project as small/early-stage and only flag the most egregious violations (cycles, god modules).

Step 3: Walk Each Concern

Pass A: Dependency Direction

For each changed file, identify which layer it belongs to. Then check its imports:

  • A domain/ file importing from controllers/, routes/, pages/ → violation
  • A services/ file importing from controllers/ → violation
  • An infrastructure adapter importing domain entities directly when a port/interface exists → violation

Read the full file on GitHub · 155 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 3d ago First seen · 155 lines · 60 tokens per session scan A 9c9b19833c47

Subscribe to this mod's changes

architecture-reviewer is an agent published in the GitHub repository BostonOrange/claude-code-framework (2 stars, last pushed 1mo ago), licensed MIT. It adds 60 tokens to every session and 1,578 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.