forked from kent/consciousness
neuro: split into scoring, prompts, and rewrite modules
neuro.rs was 1164 lines wearing three hats: - scoring.rs (401 lines): pure analysis — priority, replay queues, interference detection, consolidation planning - prompts.rs (396 lines): agent prompt generation and formatting - rewrite.rs (363 lines): graph topology mutations — hub differentiation, triangle closure, orphan linking The split follows safety profiles: scoring never mutates, prompts only reads, rewrite takes &mut Store. All public API re-exported from neuro/mod.rs so callers don't change.
This commit is contained in:
parent
4747004b36
commit
2f455ba29d
5 changed files with 1178 additions and 1163 deletions
29
src/neuro/mod.rs
Normal file
29
src/neuro/mod.rs
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
// Neuroscience-inspired memory algorithms, split by concern:
|
||||
//
|
||||
// scoring — pure analysis: priority, replay queues, interference, plans
|
||||
// prompts — agent prompt generation and formatting
|
||||
// rewrite — graph topology mutations: differentiation, closure, linking
|
||||
|
||||
mod scoring;
|
||||
mod prompts;
|
||||
mod rewrite;
|
||||
|
||||
// Re-export public API so `neuro::` paths continue to work.
|
||||
|
||||
pub use scoring::{
|
||||
replay_queue, detect_interference,
|
||||
consolidation_plan, format_plan,
|
||||
daily_check,
|
||||
};
|
||||
|
||||
pub use prompts::{
|
||||
load_prompt,
|
||||
consolidation_batch, agent_prompt,
|
||||
};
|
||||
|
||||
pub use rewrite::{
|
||||
refine_target, LinkMove,
|
||||
differentiate_hub,
|
||||
apply_differentiation, find_differentiable_hubs,
|
||||
triangle_close, link_orphans,
|
||||
};
|
||||
Loading…
Add table
Add a link
Reference in a new issue