Repository navigation
fix(neural): the learning cycle crashed on every run — retune and first real training - #925
Merged
Merged
Conversation
…st real training
Two defects kept the neural layer untrained since March (health
snapshot 2026-03-06: 6914 outcomes processed, 0 confidence updates,
neural-states/ empty):
1. LearningScheduler.run_learning_cycle crashed at the state map
update: %{state | total_strategy_shifts: …} raises KeyError on a
missing key even though the value used Map.get/3 — the update
itself is the guard, and init never set the key (same for
proof_model_retrain_count). The scheduler died on each :poll and
restarted, so no cycle ever completed. Both keys now exist in
init.
2. config.exs baked in a machine-specific verisim path
(~/Documents/hyperpolymath-repos/...), so TrainingPipeline found
no outcomes and no pattern registry anywhere else. Same migration
as #918: HYPATIA_VERISIM_DATA_PATH / HYPATIA_FLEET_PATH env
overrides, repo-relative defaults (data/verisim, ../gitbot-fleet).
With both fixed, the cycle runs end to end (verified 2026-10-15):
6964 outcomes ingested, 2 Bayesian confidence updates landed,
RBF trained on 39 vectors (9 real + 30 synthetic, MSE 0.019),
ESN trained on 3656 time steps, Graph of Trust built 292 nodes /
45814 edges (25126 cross-repo, 18 repos needing attention), and
neural-states/ carries persisted trained state for all networks for
the first time. The refreshed health snapshot and updated recipe
confidences are committed with it, as verisim-data is git-backed.
Generated by Mistral Vibe.
Co-Authored-By: Mistral Vibe <vibe@mistral.ai>
Contributor
|
Warning Review limit reachedYou've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Next included review available in 54 minutes. View limit details
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What this changes
The neural layer has been untrained since March — the health snapshot from 2026-03-06 records 6,914 outcomes processed with zero confidence updates, and
data/verisim/neural-states/was empty. Two defects, both found by running the system and reading its own logs:run_learning_cycle's state update uses%{state | total_strategy_shifts: …}— a map update raisesKeyErroron a missing key even when the value expression usesMap.get/3.initnever settotal_strategy_shifts(norproof_model_retrain_count), so the GenServer died on each:polland restarted. Both keys now exist ininit.config.exsbaked in~/Documents/hyperpolymath-repos/...(the old Mac), soTrainingPipelinefound no outcomes and no pattern registry. Migrated the same way as fix(config): require HYPATIA_VERISIM_URL / HYPATIA_ECHIDNABOT_URL, no localhost defaults #918:HYPATIA_VERISIM_DATA_PATH/HYPATIA_FLEET_PATHenv overrides with repo-relative defaults (data/verisim,../gitbot-fleet).How to run its tests
mix compile mix run -e 'Application.ensure_all_started(:hypatia); Hypatia.LearningScheduler.run_now(); Process.sleep(30000); IO.inspect(Hypatia.Neural.Coordinator.health_report())'Verified (2026-10-15)
After both fixes, the cycle completes end to end:
neural-states/now carries persisted trained state for all networksrecipe-shell-quote-varsannealed to stageveteran(outcome_count 18,640, success rate 1.0, max_tierauto_execute)The refreshed health snapshot, updated recipe confidences, and the persisted neural states are committed with the fix — verisim-data is the git-backed store.
Note: the commit is unsigned (the signing key's passphrase is unavailable to the session); amend to sign if required.
Generated by Mistral Vibe.
Co-Authored-By: Mistral Vibe vibe@mistral.ai