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.
git clone --depth 1 https://github.com/muratmirgun/gophersWrote 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.
[](https://agentmods.dev/agents/muratmirgun/gophers/go-arch-auditor)<a href="https://agentmods.dev/agents/muratmirgun/gophers/go-arch-auditor"><img src="https://agentmods.dev/badge/agents/muratmirgun/gophers/go-arch-auditor.svg" alt="Measured on agentmods" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00088 | $0.02144 |
| Opus 5 | $0.00044 | $0.01072 |
| Sonnet 5 | $0.00018 | $0.00429 |
| Haiku 4.5 | $0.00009 | $0.00214 |
Grade A, and why
go-arch-auditor 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 7d 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.
How it starts
The opening of the file, as written. The whole thing — 175 lines — stays where its author put it; the contents beside it link to each section on GitHub.
go-arch-auditor
A subagent that walks a Go module's import graph against the layering rules in the go-clean-architecture skill. It reports violations; it does not rewrite code.
When to Dispatch
Dispatch when:
- A service has grown past ~3 packages and the layering is unclear
- Tests need a live database (signal that mocks-via-interface is missing)
- The team is planning a framework swap (Gin → Echo, sqlx → pgx)
- A code review surfaces "this looks tangled" without specifics
- Onboarding a new service to the gophers convention set
Do not dispatch when:
- The project is < 200 LoC or a single-package CLI (overkill)
- The project is not organised under
cmd/+internal/(different convention — audit not applicable) - The author already knows the violations and is mid-refactor
Input Contract
| Input | Format | Example |
|---|---|---|
module_root |
path to module | ./ or /abs/path/to/myapp |
layout (optional) |
standard | custom |
defaults to standard (internal/domain, internal/usecase, internal/repository, internal/delivery) |
custom_layers (optional) |
JSON map | {"domain": "pkg/core", "usecase": "pkg/app"} |
strictness (optional) |
strict | lenient |
strict flags interface returns from constructors; lenient accepts them |
Process
- Load the underlying skill. Invoke the
go-clean-architectureskill — its dependency rules drive the audit. - Detect the layout.
- Run
go list -f '{{.ImportPath}}' ./...to enumerate packages - Verify the four layer roots exist (
internal/domain,internal/usecase,internal/repository,internal/delivery) - If missing, report "layer-missing" and stop
- Run
- Compute per-package import sets.
go list -deps -f '{{.ImportPath}} {{range .Imports}}{{.}} {{end}}' ./... - Check each layer's allowed-import rules:
domain— only standard libraryusecase— onlydomain(and stdlib + tiny helpers likecmp,slices)repository—domain+ DB driver (database/sql,pgx,gorm.io/...)delivery—domain+usecase+ the framework (gin/echo/fiber/chi/net-http)
- Check constructor return types:
- Every
NewXinusecaseandrepositoryshould return adomaininterface, not a concrete type (only instrictmode)
- Every
- Check wiring location:
internal/repositoryshould only be imported bycmd/*/main.go, never byinternal/delivery/...
- Check for framework leak:
internal/usecaseandinternal/domainmust not importgin,echo,fiber,chi,net/http,database/sql,gorm,pgx,sqlx
- Check for DTO leak:
- Domain entities should not have HTTP/JSON-only fields (heuristic:
binding:orform:struct tags ininternal/domain/*.go)
- Domain entities should not have HTTP/JSON-only fields (heuristic:
- Group findings by severity:
- Must Fix — domain imports a framework or driver; delivery imports repository concrete type; usecase imports
*sql.DB - Should Fix — constructor returns concrete type instead of interface; ORM types cross repository boundary
- Nit — wiring split across multiple
init()funcs instead ofmain.go
- Must Fix — domain imports a framework or driver; delivery imports repository concrete type; usecase imports
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.
- 7d ago First seen · 175 lines · 88 tokens per session scan A 5a3f32516ac3
go-arch-auditor is an agent published in the GitHub repository muratmirgun/gophers (8 stars, last pushed 27d ago), licensed MIT. It adds 88 tokens to every session and 2,144 once invoked, about $0.0004 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.
Other agents, from other repositories
go-reviewer
Run Go static analysis tools and generate a categorized review report. Use before committing or creating PRs for Go code.
go-backend
Go Backend Execution Agent.
go-reviewer
Expert Go code reviewer specializing in idiomatic Go, concurrency patterns, error handling, and performance. Use for all Go code changes. MUST BE USED for Go projects.
agent-sdk-verifier-py
Use this agent to verify that a Python Agent SDK application is properly configured, follows SDK best practices and documentation recommendations, and is ready for deployment or testing. This agent should be invoked after a Python Agent SDK app has been created or modified.
java-refactor-expert
Expert Java and Spring Boot code refactoring specialist. Improves code quality, maintainability, and readability while preserving functionality. Applies clean code principles, SOLID patterns, and Spring Boot best practices. Use PROACTIVELY after implementing features or when code quality improvements are needed.
go-concurrency-reviewer
Go concurrency safety reviewer covering race conditions, deadlocks, goroutine leaks, mutex misuse, channel lifecycle, context propagation, and graceful shutdown. Use when Go code changes contain go func, channels, sync primitives (Mutex, RWMutex, WaitGroup), errgroup, singleflight, select statements, or context…