consciousness/src/mind
Kent Overstreet e5dd8312c7 learn: F6 screen — scoring stats, ActivityGuard, configurable threshold
Three changes that together reshape the F6 fine-tune-review screen:

1. Finetune scoring reports through the standard agent activity system
   instead of a separate finetune_progress String. The previous design
   ran an independent progress field that forced a cross-lock dance and
   bespoke UI plumbing. start_finetune_scoring now uses start_activity
   + activity.update, so the usual status line and notifications
   capture scoring progress uniformly with other background work.

2. MindState gains a FinetuneScoringStats snapshot (responses seen,
   above threshold, max divergence, error). The F6 empty screen shows
   this instead of a loading message — so after a scoring run that
   produced zero candidates, you can see *why* (e.g., max_divergence
   below threshold).

3. The divergence threshold is configurable from F6 via +/- hotkeys
   (scales by 10×) and persisted to ~/.consciousness/config.json5 via
   config_writer::set_learn_threshold. AppConfig grows a learn section
   with a threshold field (default 1e-7).

Also: user/mod.rs no longer uses try_lock() for the per-tick
unconscious/mind state sync — we fixed the locking hot paths that
made try_lock necessary, so lock().await is now the right choice.
And subconscious::learn::score_finetune_candidates now returns
(candidates, max_divergence) so the stats can be populated.

Co-Authored-By: Proof of Concept <poc@bcachefs.org>
2026-04-16 11:49:26 -04:00
..
identity.rs Remove find_context_files — identity comes from memory nodes 2026-04-15 03:11:27 -04:00
log.rs learn: nanosecond timestamps, token ranges for /score 2026-04-16 11:48:37 -04:00
mod.rs learn: F6 screen — scoring stats, ActivityGuard, configurable threshold 2026-04-16 11:49:26 -04:00
subconscious.rs DMN: wire dream hours reminder into Foraging state 2026-04-15 21:52:20 -04:00
unconscious.rs unconscious: event-driven loop via tokio::select! 2026-04-13 22:38:01 -04:00