agentleFS
tamesystemstamesystems/intent-engineering-skills/skills/harden-boundary/SKILL.md

harden-boundary

Skill0 starsChanged 40 days agoMITView on GitHub

Turn a documented architectural dependency boundary into executable enforcement. Use when certain modules, layers, packages, runtimes, or capabilities must not depend on each other or bypass an owning abstraction.

The file

We split this skill into the rules it gives an agent

1 rule. About 0 are common, 1 is distinctive, and 0 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈1

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 0

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Recover the intended topology: Read architecture docs/ADRs and current source.

    line 12

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Harden Boundary

Make invalid dependency arrows mechanically difficult or impossible while keeping the intended dependency path obvious.

Work

  1. Recover the intended topology. Read architecture docs/ADRs and current source. State allowed and forbidden dependency arrows. Do not invent layering merely because a directory name suggests it.
  2. Measure current reality. Find existing violations, aliases, barrels, generated paths, tests, and runtime-specific exceptions. Separate migration debt from the target invariant.
  3. Choose the cheapest adequate enforcement. Prefer existing linter restricted-import/path rules for direct source→destination constraints. Use dependency-graph tooling only when the property genuinely requires graph semantics such as cycles, transitive relationships, or depth-based package privacy. Use types/API design when they can remove the invalid capability entirely.
  4. Encode helpful diagnostics. State why the edge is forbidden and what abstraction/entry point should be used instead; link nearby architecture documentation when stable.
  5. Preserve legitimate exceptions narrowly. Scope tests, generated code, platform adapters, or migrations explicitly rather than broad ignores.
  6. Prove the boundary bites. Clean PASS → add a representative forbidden import/dependency → FAIL for the intended rule → revert → PASS.
  7. Wire it. Route to wire-check if the boundary is not already exercised by the authoritative check/CI path.

Return

  • Topology/invariant
  • Mechanism
  • Allowed path
  • Exceptions
  • Negative proof
  • Wiring status
  • Known blind spots

Failure signals

Cargo-cult layering, adding dependency-graph tooling for a rule simple restricted imports can express, broad glob ignores, barrel creation that obscures ownership, or a boundary that forbids an action without exposing the supported route.

Done when

The intended dependency boundary is explicit, enforced by the smallest adequate repository mechanism, proven with a forbidden edge, and part of normal verification when consequential.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.