You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix: update module placement — BNN/SPO are first-class, use existing types
- spo_harvest.rs → src/search/ (next to hdr_cascade.rs, not extensions/)
- shift_detector.rs → src/search/ (next to distribution.rs)
- harvest_to_nars() returns crate::nars::TruthValue (not new type)
- CausalTrajectory edges compatible with src/search/causal.rs Pearl ladder
- Note two gestalt.rs files (qualia/Buber vs extensions/spo/Bundling)
- spo feature is default-on, rustynum-bnn is unconditional dep
Copy file name to clipboardExpand all lines: .claude/prompts/00_SESSION_A_META.md
+49-32Lines changed: 49 additions & 32 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -14,34 +14,45 @@ Your job: wire the SPO distance harvest, stripe shift detector, CLAM path encodi
14
14
15
15
---
16
16
17
-
## DIRECTORY STRUCTURE
17
+
## MODULE PLACEMENT
18
+
19
+
SPO and BNN are default-on, first-class dependencies (not experimental). New modules integrate with existing top-level modules — don't duplicate types that already exist.
18
20
19
21
```
20
-
src/
21
-
core/
22
-
simd.rs ← 348-line duplicate SIMD (DELETE after rustynum port lands)
**File: `ladybug-rs/src/search/spo_harvest.rs` (NEW — next to hdr_cascade.rs)**
119
130
120
131
This is the cosine replacement. 238× fewer cycles, 7.3× more information per computation. The detailed spec is in `spo_distance_harvest_cosine_replacement_prompt.md`. Key deliverables:
121
132
@@ -141,13 +152,15 @@ impl SpoDistanceResult {
141
152
### 2.2 Functions to Build
142
153
143
154
```
144
-
spo_distance(a, b) → SpoDistanceResult — the core 13-cycle computation
145
-
harvest_to_nars(result) → NarsTruth — frequency from core ratio, confidence from entropy
AccumulatedHarvest::accumulate(result) — EMA + nars::TruthValue revision across searches
159
+
feed_sigma_graph(result) → Vec<SigmaEdge> — emit typed edges from harvest
149
160
```
150
161
162
+
**CRITICAL**: `harvest_to_nars()` returns `crate::nars::TruthValue`, NOT a new NarsTruth type. The existing type already has `revision()`, `from_evidence()`, `deduction()`, etc. — use them.
163
+
151
164
### 2.3 Key Constraint
152
165
153
166
The XOR bitmasks (`x_xor`, `y_xor`, `z_xor`) computed for distance are the SAME bitmasks used for `cross_plane_vote()`. The halo extraction is FREE — no extra compute. Do not compute XOR twice.
@@ -156,7 +169,7 @@ The XOR bitmasks (`x_xor`, `y_xor`, `z_xor`) computed for distance are the SAME
**Extends: `src/extensions/spo/spo_harvest.rs` + new `src/extensions/spo/shift_detector.rs`**
172
+
**Extends: `src/search/spo_harvest.rs` + new `src/search/shift_detector.rs`**
160
173
161
174
Detailed specs in `spo_distance_granularity_investigation.md` and `sigma_stripe_shift_detector_addendum.md`.
162
175
@@ -198,7 +211,7 @@ impl ShiftDetector {
198
211
}
199
212
```
200
213
201
-
**Wire into CollapseGate (already exists in src/extensions/spo/gestalt.rs):
214
+
**Wire into CollapseGate** (already exists in `src/extensions/spo/gestalt.rs`, also connects to `src/search/distribution.rs`):
202
215
- Shift toward noise → bias HOLD
203
216
- Shift toward foveal → bias FLOW
204
217
- Bimodal → speciation event
@@ -256,6 +269,8 @@ One u16. Three query types. O(log n + k):
256
269
257
270
Detailed spec in `nars_causal_trajectory_hydration_prompt.md`. This is the biggest new module.
258
271
272
+
**NOTE**: `src/search/causal.rs` (37KB) already implements Pearl's 3-rung causal ladder (Correlate/Intervene/Counterfact). The causal trajectory recorder should produce edges compatible with that system — Rung 1 from halo correlations, Rung 2 from BPReLU intervention asymmetry, Rung 3 from ClamPath sibling (counterfactual) queries.
273
+
259
274
### 6.1 Core Structures
260
275
261
276
```rust
@@ -306,6 +321,8 @@ FullSimultaneous — all three at once → Gestalt snap (rare)
306
321
307
322
**Extends existing: `ladybug-rs/src/extensions/spo/gestalt.rs` (DO NOT rewrite — add to it)**
308
323
324
+
**NOTE**: There are TWO gestalt modules — `src/qualia/gestalt.rs` (Buber I/Thou/It, 19KB) and `src/extensions/spo/gestalt.rs` (BundlingProposal, 34KB). Phase 7 extends the SPO one. The qualia one maps Buber roles to Xyz geometry — it's complementary, not redundant.
325
+
309
326
### 7.1 Wire detect_bundling() Into CLAM Harvest Loop
310
327
311
328
When `AccumulatedHarvest` SO/SP/PO evidence crosses `CollapseMode` threshold → auto-create `BundlingProposal`.
0 commit comments