pub struct AdaptiveXlrEngine { /* private fields */ }Expand description
Adaptive XLR noise cancellation engine. Dual propagation: hot from seeds, cold from anti-seeds. Spectral overlap modulation, density-adaptive strength, sigmoid gating. Replaces: xlr_v2.py AdaptiveXLREngine
Implementations§
Source§impl AdaptiveXlrEngine
impl AdaptiveXlrEngine
pub fn new(params: XlrParams) -> Self
pub fn with_defaults() -> Self
Sourcepub fn query(
&self,
graph: &Graph,
seeds: &[(NodeId, FiniteF32)],
config: &PropagationConfig,
) -> M1ndResult<XlrResult>
pub fn query( &self, graph: &Graph, seeds: &[(NodeId, FiniteF32)], config: &PropagationConfig, ) -> M1ndResult<XlrResult>
Run full XLR pipeline on a set of seed nodes. Steps: pick anti-seeds -> compute immunity -> propagate hot -> propagate cold -> spectral overlap -> density modulation -> sigmoid gating -> rescale. Replaces: xlr_v2.py AdaptiveXLREngine.query()
Sourcepub fn pick_anti_seeds(
&self,
graph: &Graph,
seeds: &[NodeId],
) -> M1ndResult<Vec<NodeId>>
pub fn pick_anti_seeds( &self, graph: &Graph, seeds: &[NodeId], ) -> M1ndResult<Vec<NodeId>>
Pick anti-seeds: structurally similar (degree), semantically different (Jaccard). Replaces: xlr_v2.py pick_anti_seeds() FM-XLR-008 fix: immunity computed from BFS reach, not seed count.
Sourcepub fn compute_immunity(
&self,
graph: &Graph,
seeds: &[NodeId],
) -> M1ndResult<Vec<bool>>
pub fn compute_immunity( &self, graph: &Graph, seeds: &[NodeId], ) -> M1ndResult<Vec<bool>>
Compute seed neighborhood immunity set via BFS. Returns bitset of immune nodes (within immunity_hops of any seed). Replaces: xlr_v2.py compute_seed_neighborhood() FM-XLR-008 fix: BFS-based distance, not seed count threshold.
Sourcepub fn propagate_spectral(
&self,
graph: &Graph,
origins: &[(NodeId, FiniteF32)],
frequency: PosF32,
config: &PropagationConfig,
budget: u64,
) -> M1ndResult<Vec<SpectralPulse>>
pub fn propagate_spectral( &self, graph: &Graph, origins: &[(NodeId, FiniteF32)], frequency: PosF32, config: &PropagationConfig, budget: u64, ) -> M1ndResult<Vec<SpectralPulse>>
Propagate spectral pulses (hot or cold) from origins. Budget-limited (FM-RES-004). Replaces: xlr_v2.py SpectralPropagator.propagate() FM-XLR-014 fix: inhibitory edges do NOT flip cold phase.
Sourcepub fn spectral_overlap(
hot_freqs: &[FiniteF32],
cold_freqs: &[FiniteF32],
) -> FiniteF32
pub fn spectral_overlap( hot_freqs: &[FiniteF32], cold_freqs: &[FiniteF32], ) -> FiniteF32
Compute spectral overlap between hot and cold signals at each node. DEC-003: bucket-based overlap for O(B) per node. Replaces: xlr_v2.py adaptive_differential() spectral overlap section
Sourcepub fn sigmoid_gate(net_signal: FiniteF32) -> FiniteF32
pub fn sigmoid_gate(net_signal: FiniteF32) -> FiniteF32
Sigmoid gating: activation = sigmoid(x * SIGMOID_STEEPNESS). Replaces: xlr_v2.py sigmoid gating in adaptive_differential()