Asi bidirectional-navigator
Safe proof ↔ theorem navigation with non-backtracking constraint.
install
source · Clone the upstream repo
git clone https://github.com/plurigrid/asi
Claude Code · Install into ~/.claude/skills/
T=$(mktemp -d) && git clone --depth=1 https://github.com/plurigrid/asi "$T" && mkdir -p ~/.claude/skills && cp -r "$T/skills/bidirectional-navigator" ~/.claude/skills/plurigrid-asi-bidirectional-navigator-27e894 && rm -rf "$T"
manifest:
skills/bidirectional-navigator/SKILL.mdsource content
Bidirectional Navigator
Category: Proof Navigation + Caching Type: Graph Index Structure Language: Julia Status: Production Ready Version: 1.0.0 Date: December 22, 2025
Overview
Safe proof ↔ theorem navigation with non-backtracking constraint. Implements Friedman's B operator to enable linear homotopy type theory (LHoTT) resource-aware evaluation where proofs are consumed exactly once.
Key Data Structures
struct Theorem id::Int name::String end struct Proof id::Int theorem_id::Int name::String end struct BidirectionalMap forward::Dict{Int, Int} # Proof ID → Theorem ID backward::Dict{Int, Vector{Int}} # Theorem ID → [Proof IDs] non_backtracking_ok::Bool end
Key Functions
: Build bidirectional mappingcreate_index(theorems, proofs)
: O(1) proof → theorem lookupevaluate_forward(index, proof_id)
: Cached theorem → proofs lookupevaluate_backward(index, theorem_id)
: Verify B operator constraint (no u→v→u)check_non_backtracking()
: Check LHoTT compatibilitylinear_evaluation_possible()
Mathematical Foundation
Friedman's Non-Backtracking Operator (B)
No u→v→u cycles ⟺ Linear resource-aware evaluation possible
Enables:
- Automatic proof consumption tracking
- Linear type system integration (LHoTT)
- Memory-efficient navigation (no revisits)
Usage
using BidirectionalIndex # Create index index = create_index(theorems, proofs) # Forward navigation (Proof → Theorem) theorem_id = evaluate_forward(index, proof_42) # Backward navigation (Theorem → Proofs) related_proofs = evaluate_backward(index, theorem_5) # Verify constraints if check_non_backtracking(index) println("✓ B operator satisfied, linear evaluation ok") end
Integration Points
- Agent-based proof discovery with caching
- Linear homotopy type theory resource tracking
- Efficient theorem-proof lookup in large catalogs
Performance
- Index creation: < 0.1 seconds
- Forward lookup: O(1)
- Backward lookup: O(1) cached after first access
- Scalable to 5,652+ theorems
References
- Friedman (2008): Non-backtracking operator theory
- Linear Homotopy Type Theory (LHoTT) semantics