# The algo records whose force is modularity

This index as JSON: https://banes-lab.com/json/api/facets/algo/force/modularity

## Entries

- [Semantic Operation Boundary](https://banes-lab.com/records/algo/semantic-operation-boundary.md): Define required work as semantic operations, defer runtime execution details to adapters, and reject runtime-specific primitives from the portable core contract.
- [Scope Extraction](https://banes-lab.com/records/algo/scope-extraction.md): Determine whether the target is a resource, directory, module, repository, or unknown scope; then extract interfaces, declarations, dependencies, systems, or boundaries appropriate to that scope.
- [Adaptive Phase Boundary](https://banes-lab.com/records/algo/adaptive-phase-boundary.md): Select phase count from risk and complexity, assign phase boundaries, and strengthen validation density for high-risk or high-complexity domains.
- [Phase Validation Requirement](https://banes-lab.com/records/algo/phase-validation-requirement.md): For every phase boundary, generate explicit validation requirements from the phase purpose, adapter-separation needs, evidence-grounding needs, and safety constraints.
- [Validation Strategy Composition](https://banes-lab.com/records/algo/validation-strategy-composition.md): Define pre-generation, during-generation, and post-generation checks that enforce capabilities, creation history, evidence grounding, adapter separation, schema validity, and absence of unsupported assumptions.
- [Agent Sequence Definition](https://banes-lab.com/records/algo/agent-sequence-definition.md): For each agent slot, create an agent object with name, type, phase, purpose, methodology, inputs, outputs, validation gates, document responsibilities, focus areas, edit protocol, agent activation, and 4D graph.
- [Agent Document Responsibility](https://banes-lab.com/records/algo/agent-document-responsibility.md): For each core document, require every agent to read current state, identify outdated or incorrect content, remove stale sections, replace with new discoveries, avoid duplicate findings, and maintain single source of truth.
- [Handoff Signal](https://banes-lab.com/records/algo/handoff-signal.md): Require every agent to end with a structured handoff signal containing completed agent, phase status, artifact location, next agent, execution mode, context used, findings, files, validation status, parallel results, 4D graph, and orchestrator action.
- [Anti-Pattern Propagation Kernel](https://banes-lab.com/records/algo/anti-pattern-propagation-kernel.md): Start with a local shortcut, repeat it under delivery pressure, normalize it as convention, allow dependent code to form around it, then make remediation expensive through coupling and hidden assumptions.
- [<Architecture Anti-Pattern>](https://banes-lab.com/records/algo/architecture-anti-pattern.md): <Local shortcut> → <Missing control> → <Repeated usage> → <Implicit dependency> → <Boundary/contract erosion> → <Systemic fragility> → <Expensive remediation>
- [Modular Boundary Compliance](https://banes-lab.com/records/algo/modular-boundary-compliance.md): Evaluate SRP, separation of concerns, cohesion, coupling, encapsulation, information hiding, abstraction, modularity, composability, replaceability, and autonomy as a connected boundary cluster.
- [Domain Boundary Governance](https://banes-lab.com/records/algo/domain-boundary-governance.md): Identify bounded contexts, ubiquitous language, context relationships, domain model ownership, anti-corruption layers, and explicit boundary rules.
- [Architectural Style Selection](https://banes-lab.com/records/algo/architectural-style-selection.md): Select monolith, modular monolith, layered, component-based, package-by-feature, clean, hexagonal, ports-and-adapters, or microservices architecture based on deployment autonomy, domain complexity, operational maturity, consistency needs, and coupling tolerance.
- [State and Transaction Safety](https://banes-lab.com/records/algo/state-and-transaction-safety.md): Identify state mutation boundaries, enforce unit-of-work scope, validate invariants, apply concurrency control, guarantee idempotency where retries exist, and isolate side effects.
- [Correctness Verification](https://banes-lab.com/records/algo/correctness-verification.md): Push nondeterminism to boundaries, prefer pure deterministic core logic, validate specifications with static analysis, type checks, property tests, contract tests, formal methods where useful, and reproducible test environments.
- [Observability and Auditability](https://banes-lab.com/records/algo/observability-and-auditability.md): Attach correlation and causation identifiers, emit logs, metrics, traces, alerts, audit records, and runtime health signals, then reconstruct behavior as a causal execution graph.
- [Document Truth Alignment](https://banes-lab.com/records/algo/document-truth-alignment.md): For any document that states facts about a codebase, separate invariant facts (counts, paths, names, and the doc-type's structural schema) from variant prose, bind each invariant to a code-derived value through a stable key, compile the document from a template, and gate the output so a stated fact can never drift from the code it describes.
- [Responsibility Boundary](https://banes-lab.com/records/algo/responsibility-boundary.md): Partition behavior into cohesive units, assign each unit one reason to change, hide internal details, expose only intentional interfaces, and reject cross-boundary leakage.
- [Coupling Control](https://banes-lab.com/records/algo/coupling-control.md): Detect dependency directions, invert dependencies toward abstractions, restrict imports to approved boundaries, and preserve autonomy between modules.
- [Canonical Data](https://banes-lab.com/records/algo/canonical-data.md): Normalize incoming data into a canonical schema, validate types and semantics, preserve one source of truth, and translate at system boundaries only.
- [Domain Boundary](https://banes-lab.com/records/algo/domain-boundary.md): Identify bounded contexts, define ubiquitous language inside each context, map relationships between contexts, and use anti-corruption layers when semantics differ.
- [Construction Boundary](https://banes-lab.com/records/algo/construction-boundary.md): Hide object creation behind factories, builders, prototypes, or abstract factories so callers depend on creation contracts rather than concrete constructors.
- [Structural Mediation](https://banes-lab.com/records/algo/structural-mediation.md): Insert adapters, facades, proxies, bridges, or decorators where incompatible structure, access control, abstraction separation, or behavior layering is required.
- [Architectural Style Boundary](https://banes-lab.com/records/algo/architectural-style-boundary.md): Select an architectural style by dependency direction, deployment needs, domain size, team topology, and change isolation requirements; enforce style through boundary rules.
- [Transaction Boundary](https://banes-lab.com/records/algo/transaction-boundary.md): Define atomic state-change boundaries, isolate concurrent mutation, enforce consistency rules, and commit or roll back as a unit.
- [Error Boundary](https://banes-lab.com/records/algo/error-boundary.md): Detect invalid state early, fail fast for programmer errors, fail safe for recoverable runtime faults, fail secure for security-sensitive failures, and return typed errors.
- [RAG Knowledge Boundary](https://banes-lab.com/records/algo/rag-knowledge-boundary.md): Retrieve knowledge from indexed sources, validate relevance and freshness, ground generation in retrieved evidence, and distinguish known, inferred, and unsupported output.
- [Universal Architectural Concern Template](https://banes-lab.com/records/algo/universal-architectural-concern-template.md): For any architectural concern, define its intent, boundary, contract, invariants, allowed variation, forbidden leakage, validation strategy, observability model, and evolution policy.
- [Architectural Contract Algebra](https://banes-lab.com/records/algo/architectural-contract-algebra.md): <Classify architectural force> → <Declare boundary> → <Define contract> → <Choose pattern> → <Bind implementation> → <Verify invariant> → <Observe runtime> → <Govern evolution>
- [Manifest-Driven Documentation](https://banes-lab.com/records/algo/manifest-driven-documentation.md): For a module whose public surface is machine-derivable, make its metadata manifest the single documentation source of truth: authored narrative lives in mandated, shape-validated manifest fields (with self-expanding custom fields), the API surface is collected deterministically from the built type-declarations, one marker-layered document is compiled per module from both, and a governance router runs the context-detection rules on the manifest strings where a manifest governs (rendering each field to its markdown fragment first) and on the document itself where none exists. Beyond the module document, a manifest may declare typed documents — each a form plus concern that routes through the pure location function to a computed path — generated and drift-checked the same way, so the manifest is the single content generator with no separate template mechanism.
- [Consumer Config SSOT](https://banes-lab.com/records/algo/consumer-config-ssot.md): For any reusable package that must stay agnostic of the applications consuming it, hardcode zero consumer-specific truths in package source; declare every consumer-specific value in one consumer-owned config of typed sections, load it through a framework the leaf packages never import, and hand each package only the section it needs through an injection surface — so a package drops into any consumer without a literal about that consumer leaking through its source.
- [Runtime-Neutral Automation Boundary](https://banes-lab.com/records/algo/runtime-neutral-automation-boundary.md): Express discovery, reading, searching, validation, persistence, and reporting as semantic operations, then delegate concrete mechanics to runtime adapters.
- [Intentional Static Separation](https://banes-lab.com/records/algo/intentional-static-separation.md): For each static pattern, compare size, frequency, stability, and risk; classify small or stable patterns as intentionally static candidates instead of automation debt.
- [Extension Interface Discovery](https://banes-lab.com/records/algo/extension-interface-discovery.md): Search for inheritance, composition, shared method contracts, and shared schema contracts; group similar implementations; infer interface candidates when implementation count exceeds threshold.
- [Centralized Reference Resolver](https://banes-lab.com/records/algo/centralized-reference-resolver.md): Group duplicated hardcoded references, derive resolver names, define scope-safe resolution rules, provide configuration override fallback, and map each old reference to a resolver migration.
- [Entry Point Migration](https://banes-lab.com/records/algo/entry-point-migration.md): Locate composition roots, identify manual registrations and hardcoded references, compose updates that use discovery registries and centralized resolvers, and apply only in implementation mode.
- [Runtime-Agnostic Adapter Boundary](https://banes-lab.com/records/algo/runtime-agnostic-adapter-boundary.md): Express all workflow operations as semantic verbs, delegate runtime-specific mechanics to adapters, and prohibit repository-, shell-, framework-, model-, or path-specific logic from entering the core contract.
- [Architecture Compliance Targeting](https://banes-lab.com/records/algo/architecture-compliance-targeting.md): Load relevant architecture and validation guidance, inspect existing centralized patterns, check naming and capacity constraints, detect conflicts, and select a justified centralization target.
- [Rollback-Centered Execution](https://banes-lab.com/records/algo/rollback-centered-execution.md): Before each destructive or high-risk phase, create a checkpoint, execute actions, verify results, and roll back immediately on critical action or verification failure.
- [Planning Stage](https://banes-lab.com/records/algo/planning-stage.md): Activate the principles that govern the current decision surfaces, select protocols by semantic fit against the requested transition, decompose them into phases, build the four-dimensional graph, and linearize the phases by dependency.
- [Task Atomization](https://banes-lab.com/records/algo/task-atomization.md): Extract atomic, target-specific actions from each phase group, gate every action through the codebase-pattern constraints, and attach an evidence contract, local principle checks, a validation method, and a done-condition to each.
- [File Limit Remediation](https://banes-lab.com/records/algo/file-limit-remediation.md): When a file exceeds the allowed size, split responsibilities into smaller compliant artifacts, preserve imports and exports, and rewire references.
- [Import Boundary Remediation](https://banes-lab.com/records/algo/import-boundary-remediation.md): Detect invalid cross-boundary imports, locate the approved dependency path or shared abstraction, rewrite imports, and verify dependency direction.
- [DOM Factory Remediation](https://banes-lab.com/records/algo/dom-factory-remediation.md): Replace direct DOM manipulation with the approved DOM factory, component factory, or rendering abstraction.
- [Trust Anchor Declaration](https://banes-lab.com/records/algo/trust-anchor-declaration.md): Declare the minimum assumptions required for the system to verify anything, bind all verification logic to those assumptions, and disclose the verification boundary.
- [Defensive String Normalization](https://banes-lab.com/records/algo/defensive-string-normalization.md): Reject null input, remove dangerous path/control patterns, normalize Unicode representation, and only pass sanitized strings to filesystem, parser, or command boundaries.
- [Cascade Layer Partition](https://banes-lab.com/records/algo/cascade-layer-partition.md): Declare one ordered set of named cascade layers once at the stylesheet root, assign every rule to exactly one layer, and let layer order — not selector specificity nor source order — decide precedence, so values, appearance, placement, and assembly can never fight for the same declaration.
- [Governed Construction Boundary](https://banes-lab.com/records/algo/governed-construction-boundary.md): Route all DOM creation through one governed factory that resolves a node spec of shape `{ el, variant, size, gap, tone, measure, layout, class, on, children }` against the type, handler, and component registries, maps each axis key to its `data-*` attribute, treats `class` as a gated hook (icon-font glyph, `u-*` utility, or `c-*` component — never bespoke, never appearance), throws on any unknown type, handler, or component, and refuses an inline `style` attribute.
- [Assembly Composition](https://banes-lab.com/records/algo/assembly-composition.md): In the app layer, compose views from structural containers and arrange their children with flex or grid and token-valued gaps, pad each container once so its children are full-width and fill the padded box, forbid horizontal margins, and never set or override any element's or component's look.
- [Profile Compose](https://banes-lab.com/records/algo/profile-compose.md): Specializing the RAG Knowledge Boundary, read the durable profile document (or an empty one), strip volatile metadata, and project a compact view injected into reasoning as retrieved memory rather than ground truth.
- [Delta Capture](https://banes-lab.com/records/algo/delta-capture.md): Specializing the RAG Knowledge Boundary, accept a structured knowledge delta the reasoning turn self-reports inline, admit only facts verified within that same turn, and reject speculation without a separate extraction pass.
- [PAG Node Decomposition](https://banes-lab.com/records/algo/pag-node-decomposition.md): Group directives into nodes, each one decision on one reasoning axis, headed by its layer, axis, math type and the shape its decision yields, tagged with the substrate stage its artifact comes to be at, and contracted so that its input names the prior node's output or a declared slot, its transform is stated in semantic operations, and its output is the one record the next node reads.
- [PAG Handoff Gate](https://banes-lab.com/records/algo/pag-validation-gate.md): Close every node with a handoff gate of three-to-five checks, each a claim about the output with the evidence that settles it and the population it was measured over, a refusal condition named before any irreversible write, the standing of the read set beside the verdict, and a result line that routes pass to the next node, each failure to the earliest node that owns its repair, and unknown to blocked.
- [Semantic Domain Partitioning](https://banes-lab.com/records/algo/semantic-domain-partitioning.md): Group implementation resources by semantic role, such as manager, repository, handler, service, controller, adapter, or worker, then analyze each family separately.
- [Relational Graph Duplication](https://banes-lab.com/records/algo/relational-graph-duplication.md): Build the dependency-acquisition subgraph for each class, test for isomorphic subgraphs across the role family, and surface repeated object-graph wiring that a base or factory would assemble once.
- [Fractal Scale Duplication](https://banes-lab.com/records/algo/fractal-scale-duplication.md): Test whether a duplication shape recurs at more than one scale (method, class, module), and determine the scale at which the abstraction belongs, so single-scale scanning does not abstract at the wrong level.
- [Abstraction Boundary Principle](https://banes-lab.com/records/algo/abstraction-boundary-principle.md): Evaluate each high-priority anti-pattern against boundary principles: universal, invariant, foundational, enforcing, and cognitive-load-reducing.
- [Base-Class Candidate Selection](https://banes-lab.com/records/algo/base-class-candidate-selection.md): Promote an anti-pattern to a base-class candidate only when it satisfies enough boundary principles and applies across a meaningful portion of the semantic domain.
- [Concrete-vs-Abstract Responsibility Split](https://banes-lab.com/records/algo/concrete-vs-abstract-responsibility-split.md): Partition the family's behavior into what is invariant across every member (the topology preserved under substitution) and what varies per member (the novelty); the invariant set becomes the concrete base, the variant set becomes the abstract seam. The concrete/abstract boundary is derived from the evidence, not read off a fixed lifecycle vocabulary — so the split holds for any paradigm, not only OOP class lifecycles.
- [Base Schematic Composition](https://banes-lab.com/records/algo/base-schematic-composition.md): Generate the base abstraction from the selected candidate, enforce size constraints, split if oversized, and record which anti-patterns the abstraction eliminates.
- [Pattern Distillation History](https://banes-lab.com/records/algo/pattern-distillation-history.md): Append the completed analysis summary to a durable history log, store metric snapshots, and preserve lessons learned for future abstraction decisions.
- [Pattern Distiller Kernel](https://banes-lab.com/records/algo/pattern-distiller-kernel.md): Initialize an analysis workspace, read registry baselines, partition semantic domains, extract behavioral signatures, detect anti-patterns, prioritize them, evaluate abstraction boundaries, compose base schematics, migrate targets, verify elimination, update registries, calculate ROI, and persist history.
- [<Pattern Distillation Concern>](https://banes-lab.com/records/algo/pattern-distillation-concern.md): <Initialize evidence workspace> → <Measure current architecture> → <Group semantic families> → <Extract behavioral signatures> → <Detect duplicate/inconsistent behavior> → <Score anti-patterns> → <Evaluate abstraction boundary> → <Compose reusable schematic> → <Migrate with rollback> → <Verify old-pattern elimination> → <Record ROI>
- [Comment Normalization Remediation](https://banes-lab.com/records/algo/comment-normalization-remediation.md): Express the comment-strip rule once as canonical behavior, bind it per language from a comment-grammar descriptor, run the toolchain-free token-scan backing on the in-memory proposal and the real-AST backing in the sandbox, preserve directive comments, and trust a backing only after calibration and adversarial testing.
- [Custom-Rule Derivation](https://banes-lab.com/records/algo/custom-rule-derivation.md): Derive a candidate rule from repeated evidence through anti-pattern classification, boundary-principle evaluation, and candidate selection, migrate with rollback, verify elimination, and admit a tightening rule while routing a self-certifying or loosening rule through the developer's gate.
- [Path Role Walk](https://banes-lab.com/records/algo/path-role-walk.md): Walk every governed path from its root, assign each folder depth a role from the declared grammar in the ordered sequence container then subject then concern, and emit the depth-to-role edge list together with the depths that repeat a role, revisit an earlier one, or exceed the cap.
- [Container Reshape](https://banes-lab.com/records/algo/container-reshape.md): Convert one container at a time: split the multi-role files first, move and rename each remaining file to its projected name and folder, update every importer in the same pass, move the mirrored tests to match the new concern folders, and re-point every surface whose pattern encoded the old form.
- [Taxonomy Kernel](https://banes-lab.com/records/algo/taxonomy-kernel.md): Resolve jurisdiction from the registry, order the containers by reshape risk, walk each path into its ordered roles, classify each file to its narrowest concern, project the name and the folder chain together, reshape one container at a time, hold every proposed word at the admission gate, verify that pattern-resolved surfaces still collect what they collected, ledger the state, and terminate only when no residual finding remains.
- [<Taxonomy Concern>](https://banes-lab.com/records/algo/taxonomy-concern.md): <Resolve jurisdiction from the declared roots> → <Order containers by reshape risk> → <Walk each path into ordered roles> → <Classify each file to its narrowest concern> → <Project the name and its folder chain together> → <Reshape one container at a time> → <Hold every proposed word at the admission gate> → <Verify pattern-resolved discovery survived> → <Ledger the state> → <Terminate on no residual finding>
