import type { RetrievalLevel } from '../../contracts/retrieval-gate.js'; export interface RetrievalExpansionPolicy { level: RetrievalLevel; seed_limit: number; predecessor_mode: 'none' | 'same-community' | 'all'; hop1_relations: ReadonlySet | null; hop2_relations: ReadonlySet | null; max_second_hop_adds: number; include_peripheral: boolean; } export declare function expansionPolicyForLevel(level: RetrievalLevel, budget: number): RetrievalExpansionPolicy; export declare function relationAllowedForPolicy(relations: ReadonlySet | null, relation: string): boolean; export declare function predecessorAllowedForPolicy(mode: RetrievalExpansionPolicy['predecessor_mode'], seedCommunity: number | null | undefined, neighborCommunity: number | null | undefined): boolean; /** * Extractors model a declaration owner as an incoming edge to its member. * That ownership is structural evidence, so community clustering must not * separate a matched member from the class or file that declares it. */ export declare function predecessorIsStructuralOwner(relation: string): boolean; export declare function relationIsPrimaryForPolicy(level: RetrievalLevel, relation: string): boolean;