feat(runtime): port engram_load_merge to released runtime + missing WM headers #62

Closed
will.anderson wants to merge 0 commits from fix/runtime-load-merge-2026-06-30 into main
Owner

Summary

  • Ports engram_load_merge from el-compiler/runtime (added in 35c1897) to lang/releases/v1.0.0-20260501/el_runtime.c — the released runtime used by Engram and the soul daemon build
  • Adds missing header declarations for engram_wm_count, engram_wm_avg_weight, engram_wm_top_json, and engram_load_merge in el_runtime.h (implementations were added in da116b2 / 35c1897 but prototypes were missing)
  • Rebuilds Engram binary with the complete runtime

Why

awareness.el calls engram_load_merge in its sync refresh cycle. Without this function in the released runtime, the soul daemon fails to compile. The missing header declarations caused implicit-function-declaration warnings and potential ABI breakage.

Identified during self-review 2026-06-30.

## Summary - Ports `engram_load_merge` from `el-compiler/runtime` (added in `35c1897`) to `lang/releases/v1.0.0-20260501/el_runtime.c` — the released runtime used by Engram and the soul daemon build - Adds missing header declarations for `engram_wm_count`, `engram_wm_avg_weight`, `engram_wm_top_json`, and `engram_load_merge` in `el_runtime.h` (implementations were added in `da116b2` / `35c1897` but prototypes were missing) - Rebuilds Engram binary with the complete runtime ## Why `awareness.el` calls `engram_load_merge` in its sync refresh cycle. Without this function in the released runtime, the soul daemon fails to compile. The missing header declarations caused implicit-function-declaration warnings and potential ABI breakage. Identified during self-review 2026-06-30.
will.anderson added 3 commits 2026-06-30 13:59:55 +00:00
Port critical WM fixes from self-review 2026-06-26 branch (f7bd99a) that were
never merged to HEAD. Running binary had these fixes; source did not — rebuild
would have silently regressed all three improvements.

1. ENGRAM_BREAKTHROUGH_WEIGHT 0.25→0.10
   With 0.25, naturally-promoted nodes (threshold ≥0.15) decayed below the
   breakthrough floor within one activation call and lost their WM slot to
   fresh breakthrough candidates. All 524/525 WM nodes were at floor = useless.
   Invariant: BREAKTHROUGH_WEIGHT < min(type_thresholds = 0.15 Canonical).

2. ENGRAM_WM_CAP=24 with Pass 4 (per-call) + Pass 5 (global) enforcement
   Without cap, broad curiosity seeds promote 500+ nodes simultaneously.
   wm_avg_weight collapses, goal-bias differentiation is lost. Verified:
   "knowledge" query now promotes exactly 24 nodes (was 525). Cowan (2001)
   cognitive basis: WM capacity ~4 chunks; 24 allows rich multi-topic context.

3. ISE exclusion from WM (Pass 2 guard)
   InternalStateEvent JSON content ("knowledge", "memory", etc.) triggered
   lexical seeding → suppression accumulation → breakthrough at floor. ISEs
   are observability-only and must never surface in context compilation.
   suppression_count cleared so ISEs never build toward breakthrough.

4. route_create_ise importance fix (0.5→0.3)
   Corrects mismatch between HTTP route and awareness.el in-process fallback.
   Also adds body comment clarifying auth-exempt rationale.

SYNAPSE (arXiv 2601.02744) validates WM cap design and ISE exclusion principle.
Next priority: cosine similarity seeding to complement lexical BFS.
engram_load_merge was added to el-compiler/runtime in 35c1897 but never
ported to the released runtime used by Engram and the soul daemon.

awareness.el calls engram_load_merge in its sync refresh cycle; without
this function in lang/releases/v1.0.0-20260501/el_runtime.c the soul
daemon fails to compile.

Also adds header declarations for engram_wm_count, engram_wm_avg_weight,
engram_wm_top_json, and engram_load_merge — all four were added as
implementations (da116b2 / 35c1897) but their prototypes were missing from
el_runtime.h, causing implicit-function-declaration warnings and potential
ABI breakage on stricter compilers.

Identified during self-review 2026-06-30.
build(engram): rebuild binary with engram_load_merge runtime (deb0520)
El SDK Release / build-and-release (pull_request) Failing after 19s
59cea116c5
Runtime now includes engram_load_merge — soul daemon awareness.el calls
this function during its periodic sync refresh cycle. Binary rebuilt from
server.el (unchanged source) + updated el_runtime.c.
will.anderson closed this pull request 2026-07-01 16:38:42 +00:00

Pull request closed

Please reopen this pull request to perform a merge.
Sign in to join this conversation.
No Reviewers
No labels
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: neuron-technologies/el#62