module-boundaries

module-boundaries is a cursor rule for Cursor from jterratsdev/ableton-live-mcp. It costs 623 tokens per session, scanned A, original, MIT.

A set of rules for keeping code modules focused and defining clear boundaries between models, business logic, services, data access, and adapters.

In plain words
What is it for?
Use it before editing an existing file or deciding where new behavior belongs. It helps split work into focused modules and keeps adapters thin.
Why use it?
It reduces “god files”—large files that handle many unrelated jobs—and prevents business logic from being hidden inside controllers or command-line entry points.

Cursor rule for Cursor

Written for Cursor: a Cursor rule (.mdc).

Good fit Use it before editing an existing file or deciding where new behavior belongs. It helps split work into focused modules and keeps adapters thin.

Compare 6 cursor rules from other repositories ↓
Install with agentmods
npx agentmods add rules/jterratsdev/ableton-live-mcp/module-boundaries
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.

Clone the repo
git clone --depth 1 https://github.com/jterratsdev/ableton-live-mcp

Made for: Cursor.

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 module-boundaries

README.md
[![agentmods](https://agentmods.dev/badge/rules/jterratsdev/ableton-live-mcp/module-boundaries/github.svg)](https://agentmods.dev/rules/jterratsdev/ableton-live-mcp/module-boundaries)
Your own site
<a href="https://agentmods.dev/rules/jterratsdev/ableton-live-mcp/module-boundaries"><img src="https://agentmods.dev/badge/rules/jterratsdev/ableton-live-mcp/module-boundaries/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.

agentmods 80×15 button for module-boundaries

Your own site · 80×15
<a href="https://agentmods.dev/rules/jterratsdev/ableton-live-mcp/module-boundaries"><img src="https://agentmods.dev/badge/rules/jterratsdev/ableton-live-mcp/module-boundaries.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 623 This file is loaded in full into every session.
When invoked 623 The same file — it is already loaded in full.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
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.1 $0.00623 $0.00623
Opus 5.5 $0.00249 $0.00249
Sonnet 5.5 $0.00125 $0.00125
Haiku 4.5 $0.00062 $0.00062

Measured 1mo ago against content hash f39eeb5e20d6, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

module-boundaries 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 1mo 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.

rules/module-boundaries.mdc · 72 lines

How it starts

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

Module Boundaries

Every code change must preserve clear ownership boundaries. Before adding code to an existing file, check whether the file is already large, multi-purpose, or adapter-shaped. If the change would make the file harder to review, create or reuse the correct domain, model, service, repository, or adapter module instead.

Pre-Write Check

  • Inspect the target file's current responsibility, exported surface, and size before editing.
  • Treat files over 300 lines, functions over 30 lines, and command/controller files with business logic as god-file risk.
  • A large existing file is not a reason to keep adding to it. If the new change is separable, extract the new behavior into a focused module and wire it from the existing entry point.
  • If extraction is unsafe in the current task, record a follow-up debt task with the reason, affected file, and proposed boundary.

Expected Layers

  • model or types: narrow public data contracts, discriminated unions, schemas, and DTOs.
  • domain: pure invariants, policy decisions, validation rules, state transitions, and calculations.
  • service or use-case: orchestration of domain logic, repositories, clients, and side effects for one workflow.
  • repository, store, or gateway: persistence, file I/O, network I/O, and external system adapters.
  • commands: CLI adapter only. Parse arguments, call services, format output, and convert errors to user-safe messages.
  • web or api: HTTP/UI adapter only. Parse requests, call services, serialize responses, and map errors.

Logicless Commands

Command modules must remain nearly logicless. They may:

  • parse flags and positional arguments;
  • choose output format;
  • call one service/use-case function;
  • map expected errors to CLI messages and exit codes.

Command modules must not:

  • own business rules or workflow policy;
  • perform direct persistence when a repository/service should own it;
  • contain repeated hardcoded registries, option lists, status sets, or provider matrices;
  • implement complex loops, joins, retries, or batching;
  • become the primary test target for domain behavior.

Read the full file on GitHub · 72 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. 1mo ago First seen · 72 lines · 623 tokens per session scan A f39eeb5e20d6

Subscribe to this mod's changes

module-boundaries is a cursor rule published in the GitHub repository jterratsdev/ableton-live-mcp (0 stars, last pushed 1mo ago), licensed MIT. It adds 623 tokens to every session, about $0.0025 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.