/**
 * Normalise rule: `drop-trivial-passthrough`.
 *
 * Phase 4 of `2026-05-13-NORMALISE-PHASE.md` §5 Rule 3. Removes
 * Controller.cured operations whose declared body is just the framework
 * default — a single look-up / insert / update / delete with no
 * preconditions, no published events, and no branching.
 *
 * Rationale: SpecVerse's realize phase auto-emits standard CURVED
 * implementations for every Model. When an explicit `cured.retrieve:`
 * block exists in the spec, realize uses it INSTEAD of the framework
 * default. If the explicit body is semantically identical to the
 * default ("Look up X by id, return X or null"), declaring it is
 * noise — drop it and let inference fill in the default at realize
 * time.
 *
 * Before (post-Rule-2):
 *
 *   ClubController:
 *     model: Club
 *     cured:
 *       retrieve:
 *         steps:
 *           - Look up Club by id
 *           - Return Club or null
 *         requires: [id is provided]
 *
 * After:
 *
 *   (Whole ClubController removed — synthesised by Rule 2,
 *    body was trivial, no other content remains.)
 *
 * Triviality criteria (ALL must hold):
 *   - `steps:` has ≤ 2 entries
 *   - No `publishes:` field, or `publishes: []`
 *   - Step text matches the operation's verb pattern:
 *       retrieve  →  look up / find / fetch / retrieve / select
 *       create    →  create / insert / store / persist
 *       update    →  update / set / modify
 *       delete    →  delete / remove
 *
 * Cleanup after dropping ops:
 *   - If `cured` becomes empty, delete it
 *   - If the Controller is now empty except for `model:` (i.e. we
 *     synthesised it via Rule 2 and there's nothing else), drop the
 *     whole controller. Be conservative: keep controllers that have
 *     `actions:`, `subscriptions:`, `path:`, or other content the user
 *     might have added.
 *   - If the component's controllers map is empty, delete it.
 *
 * NOT in scope:
 *   - Service operations (would require knowing the inference default
 *     applies, which it doesn't for filtered/predicate queries)
 *   - retrieve_many / list operations (default inference may or may not
 *     match the explicit body)
 *   - Bodies with non-trivial preconditions/postconditions (those carry
 *     real spec intent worth preserving even when steps look default)
 */
import type { NormaliseRule, NormaliseSpec } from '../normalise-rules.js';
interface DropMatchData {
    componentName: string;
    controllerName: string;
    curvedOp: string;
}
/**
 * Is the body of a cured op trivial enough to drop? Examines steps +
 * publishes + the keyword match for the curved op.
 *
 * Trivial rules:
 *   - No `publishes:` (event-driven side effect = non-trivial)
 *   - ≤2 steps
 *   - 0 steps → trivial (already minimal)
 *   - 1 step → trivial as long as it doesn't contain FORBIDDEN keywords
 *     (a single step IS the operation; verb-keyword check is meaningless
 *     because LLMs often collapse "look up X / return X" into one step
 *     like "Return Club by id")
 *   - 2 steps → require at least one step matches the verb keyword AND
 *     the other matches TRIVIAL_FOLLOWUP (e.g. "Return X or null"); no
 *     step may match FORBIDDEN
 */
declare function isTrivialBody(body: unknown, curvedOp: string): boolean;
/**
 * Detect drop candidates by walking spec.components[*].controllers[*].cured[*].
 */
declare function detectDropMatches(spec: NormaliseSpec): DropMatchData[];
export declare const DROP_TRIVIAL_PASSTHROUGH_RULE: NormaliseRule;
export declare const __internal: {
    isTrivialBody: typeof isTrivialBody;
    detectDropMatches: typeof detectDropMatches;
};
export {};
//# sourceMappingURL=drop-trivial-passthrough.d.ts.map