1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
//! `lean-ctx cognitive` — display science-driven context intelligence status.
use crate::core::anti_interrupt;
use crate::core::cognitive_gate::full_science_enabled;
use crate::core::config::CognitiveMode;
/// Run the cognitive status display.
pub(crate) fn run() {
let config = crate::core::config::Config::load_global();
let mode = config.cognitive_mode;
println!("Science-Driven Context Intelligence");
println!("====================================");
println!("Mode: {mode}");
println!();
match mode {
CognitiveMode::Off => {
println!("All science features are disabled.");
println!("Enable with: lean-ctx config set cognitive_mode basic");
return;
}
CognitiveMode::Basic | CognitiveMode::Full => {}
}
if full_science_enabled() {
let events = anti_interrupt::session_interruptions();
let impact = anti_interrupt::compute_impact();
println!("Anti-Interruption Score: {:.0}%", impact.score * 100.0);
println!(" Session events tracked: {}", events.len());
println!(
" Interruptions prevented: {}",
impact.interruptions_prevented
);
println!(
" Focus time saved: {:.0} min",
impact.focus_time_saved_minutes
);
println!(" Echo tokens saved: {}", impact.echo_tokens_saved);
} else {
println!("Anti-Interruption Score: n/a (requires 'full' cognitive mode)");
}
println!();
println!("Features:");
println!(" [F1] Information Bottleneck Engine ✓ active");
println!(" [F2] Predictive Context Prefetch ✓ active");
println!(" [F3] Cognitive Budget Allocator ✓ active");
println!(" [F4] Wasserstein Token Allocator ✓ active");
println!(" [F5] FSRS Memory Scheduler ✓ active");
if mode == CognitiveMode::Full {
println!(" [F6] On-Demand Graph Expansion ✓ active");
println!(" [F7] Anti-Interruption Score ✓ active");
println!(" [F8] MDL Read Mode ✓ active");
println!(" [F9] Stigmergic Agent Coordination ✓ active");
println!(" [F10] Behavioral Verbosity Learning ✓ active");
} else {
println!(" [F6-F10] Advanced features - (enable with 'full' mode)");
}
}