Sheaf Consensus Gate
Files:
- Module:
src/harmonic/sheaf_consensus_gate.py - CLI:
scripts/sheaf_consensus_gate.py
Purpose
Operational lattice-sheaf gate for SCBE pipelines:
- Takes temporal signals (
fast,memory,governance) - Computes Tarski sheaf obstruction/stability
- Produces
ALLOW | QUARANTINE | DENYvia omega gate - Supports single-shot mode or JSONL batch mode
Single-shot usage
python scripts/sheaf_consensus_gate.py \
--fast 0.12 \
--memory 0.18 \
--governance 0.20 \
--harm-score 0.92 \
--drift-factor 0.90 \
--spectral-score 0.88
Batch JSONL usage
Input JSONL rows may include:
fast_signalmemory_signalgovernance_signal- optional gate factors:
pqc_valid,harm_score,drift_factor,spectral_score
python scripts/sheaf_consensus_gate.py \
--input-jsonl training/intake/web_research/sample.jsonl \
--output-jsonl artifacts/sheaf_gate/sample_out.jsonl
Each output row receives:
sheaf_gate.decisionsheaf_gate.omegasheaf_gate.triadic_stablesheaf_gate.sheaf_obstructionssheaf_gate.assignmentsheaf_gate.projected