Active Interleave Skill
/plugin marketplace add plurigrid/asi/plugin install asi-skills@asi-skillsThis skill inherits all available tools. When active, it can use any tool Claude has access to.
active.bbInterleaves context from recently active Claude/Amp threads into current activity via random walk.
"all is bidirectional" — @bmorphism, Play/Coplay gist
Active Inference Pattern: The interleave implements Active Inference in String Diagrams epistemic foraging — actively sampling from recent contexts to minimize uncertainty about the current task. Each random walk step is an epistemic action that gathers information.
Play/Coplay Duality: The interleave embodies bmorphism's bidirectional principle:
GF(3) Balanced Exploration: The triadic structure (MINUS/ERGODIC/PLUS) ensures balanced exploration — validation filters (MINUS), random walk explores (ERGODIC), and colored emission generates (PLUS). Conservation Σ = 0 maintains coherence.
Load when context from recent work would help current task.
# Interleave from last 24 hours
bb ~/.claude/skills/active-interleave/active.bb
# Interleave from last N hours
bb ~/.claude/skills/active-interleave/active.bb --hours 6
# Query-focused interleave
bb ~/.claude/skills/active-interleave/active.bb --query "aptos blockchain"
# JSON output
bb ~/.claude/skills/active-interleave/active.bb --json
Each interleave batch maintains Σ trits ≡ 0 (mod 3).
Call from current thread to surface relevant recent context:
;; In any bb script
(require '[babashka.process :refer [shell]])
(def context (-> (shell {:out :string} "bb" (str (System/getProperty "user.home")
"/.claude/skills/active-interleave/active.bb") "--json")
:out))
Reads from ~/worldnet/cognition.duckdb:
messages - Content with timestampssessions - Session metadataawareness_edges - Play/coplay graphtemporal_index - Time-ordered indexThis skill connects to the K-Dense-AI/claude-scientific-skills ecosystem:
general: 734 citations in bib.duckdbThis skill maps to Cat# = Comod(P) as a bicomodule in the equipment structure:
Trit: 0 (ERGODIC)
Home: Prof
Poly Op: ⊗
Kan Role: Adj
Color: #26D826
The skill participates in triads satisfying:
(-1) + (0) + (+1) ≡ 0 (mod 3)
This ensures compositional coherence in the Cat# equipment structure.