"""Top-K Proposer component — the strict SEARCH/REPLACE diff operator (no full-rewrite fallback)."""
from __future__ import annotations

from ...components.proposer import DiffProposer


class TopKProposer(DiffProposer):
    """One LLM call -> a SEARCH/REPLACE diff applied to the parent (SkyDiscover's solution generator),
    with mandatory no-op detection. Diffs apply by whole-line matching (SkyDiscover ``apply_diff``); a
    response with no matching diff block is a NO_DIFF (retried/discarded), never a full rewrite or a
    substring edit — SkyDiscover never accepts a rewrite in diff mode."""

    diff_wholeline = True
