Borrowing it
Nothing to install: this file belongs to Softtor/nestjs-hexagonal. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/Softtor/nestjs-hexagonal/main/CLAUDE.mdgit clone --depth 1 https://github.com/Softtor/nestjs-hexagonalWrote 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/instructions/softtor/nestjs-hexagonal/claude-md)<a href="https://agentmods.dev/instructions/softtor/nestjs-hexagonal/claude-md"><img src="https://agentmods.dev/badge/instructions/softtor/nestjs-hexagonal/claude-md/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/instructions/softtor/nestjs-hexagonal/claude-md"><img src="https://agentmods.dev/badge/instructions/softtor/nestjs-hexagonal/claude-md.svg" alt="Reviewed on agentmods" width="80" 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.03180 | $0.03180 |
| Opus 5.5 | $0.01272 | $0.01272 |
| Sonnet 5.5 | $0.00636 | $0.00636 |
| Haiku 4.5 | $0.00318 | $0.00318 |
Grade A, and why
nestjs-hexagonal CLAUDE.md 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 9d 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 — 139 lines — stays where its author put it; the contents beside it link to each section on GitHub.
NestJS Hexagonal Plugin — Instructions
Plugin for building NestJS bounded contexts with Hexagonal Architecture + DDD + CQRS. Compatible with GSD workflow.
Entry Point
nestjs-hexagonal:using-nestjs-hexagonal — meta-skill that routes any NestJS task to the correct skill or agent. Check this FIRST when working in a hexagonal NestJS project.
Architecture Rules (enforced by all skills and agents)
- Entity is pure TypeScript — uses
this.apply(event)for domain events - Repository is PURE persistence — save, find, search, delete. NO event dispatch
- EventDispatcher lives in the Handler, NEVER in UseCase — UseCase returns entity, Handler calls
await events.from(entity).publish()after the actual transaction commit - No NestJS imports in domain — no exceptions
- Module exports ONLY Port tokens — never use cases or repositories
- class-validator ONLY in presentation request DTOs — never in domain or application
- Write operations return void or
{ id: string }— CQRS strict - No over-engineering — no use case for simple
findById, no abstraction for single use, no generic relay patterns
Rulebook (machine-readable rules)
rulebooks/hexagonal.rulebook.yaml encodes the rules above; scripts/check.ts (entry scripts/run.sh, bin nestjs-hexagonal-check) runs the static ones offline and, with --classes semantic and TYPESAFE_API_KEY, asks Jev the semantic ones (scripts/lib/{jev-client,state-builder,decide,semantic-engine}.ts). Runtime rules are still inert. Projects opt in with .claude/rulebook.yaml (extends with sha256 stamps, own rules, overrides by id); NESTJS_HEXAGONAL_DISABLE=1 turns everything off. The same rulebook drives the hooks in hooks/hooks.json (scripts/hooks/*.ts, shared code in scripts/hooks/lib/, state in scripts/lib/session-store.ts, log in scripts/lib/hook-log.ts).
| Hook | Matcher | Gate | Effect (v1) |
|---|---|---|---|
SubagentStart |
^nestjs-hexagonal:.* |
opt-in project, plugin agent | rulebook slice of the agent's layer as additionalContext (<= 1,500 tokens); records HEAD sha and start time |
PreToolUse |
Write|Edit |
plugin agent, path in project and in a static scope | only findings the current file does not already have: new static FAIL -> permissionDecision: deny (3 findings max); new WARN -> additionalContext, no permission decision; no network, no external checks |
PostToolUse |
Write|Edit |
any agent (path recorded per agent_id) |
static for all; semantic only for plugin agent with key; additionalContext only with findings, 8 KB cap per agent and session |
SubagentStop |
the six pipeline agents | plugin agent | files = store paths + (git diff/untracked since start minus the baseline recorded at start); static FAIL -> decision: block at once, no Jev; clean stop -> semantic advisory under a 17 s deadline stored for the Agent hook; after 2 blocks -> release with systemMessage |
PostToolUse |
Agent |
completed plugin subagent | unresolved FAILs and the last semantic advisory of that agentId from the store as additionalContext |
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.
- 9d ago Changed · +4 lines · +66 tokens per session 646b839ee577
- 25d ago Changed · +8 tokens per session aa8aa6e6a7d0
- 27d ago Changed · +59 lines · +2,105 tokens per session 25239676a9ff
- 1mo ago First seen · 76 lines · 1,001 tokens per session scan A f1d277122823
nestjs-hexagonal CLAUDE.md is an instructions file published in the GitHub repository Softtor/nestjs-hexagonal (5 stars, last pushed 10d ago), licensed MIT. It adds 3,180 tokens to every session, about $0.0127 per session on Opus 5.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 instructions, from other repositories
vscode buildNext.instructions.md
Working notes and architecture documentation for the new esbuild-based build system in build/next. Use when making changes to the new build pipeline (transpile/bundle commands, NLS plugin, source-map handling, resource copying, or self-hosting watch tasks).
next.js AGENTS.md
AGENTS.md instructions for vercel/next.js, covering next.js development guide, codebase structure, monorepo overview, core package: packages/next and other important packages.
vscode oss-third-party-notices.instructions.md
Instructions for microsoft/vscode, covering vs code oss third-party-notices pipeline, architecture, pipeline flow in ci, cache eligibility and rollout and applying the notice (cutover).
langchain AGENTS.md
AGENTS.md instructions for langchain-ai/langchain, covering global development guidelines for the langchain monorepo, corridor security analysis, project architecture and context, monorepo structure and development tools & commands.
vscode copilot-instructions.md
Copilot instructions for microsoft/vscode, covering vs code copilot instructions, project overview, root folders, core architecture (src/ folder) and built-in extensions (extensions/ folder).
deepseek-harness AGENTS.md
AGENTS.md instructions for deepseek-ai/deepseek-harness, covering agents.md, pre-stable apis and released session data, repository layout, commands and host sandbox failures.