- Extract redeliver_missed(tx, db, log) helper into cluster_transport.rs - heal_region now removes partition then immediately ships any missed batch-log entries to the healed follower's channel - await_convergence refactored to call the same helper (no logic change) - tidal-server: reload_text_index before search in cluster mode - tidal-server: write_signal returns Result instead of panicking on unknown signal - tidal-server: leader shows lag_events=0 (writes directly, no receiver thread) - tidal-server: fix cluster mode error propagation (ServerError::from) - docs/runbooks/cluster.md: add full cluster operations runbook - docker/: add Dockerfile for containerised cluster deployment - README.md: add tidal-server HTTP API getting-started section - Split oversized source files per CODING_GUIDELINES §9 Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
33 lines
808 B
Rust
33 lines
808 B
Rust
use iknowyou_engine::run_pg1_eval;
|
|
|
|
#[test]
|
|
fn pg1_metrics_meet_floor() {
|
|
let dir = tempfile::tempdir().expect("tempdir");
|
|
let metrics = run_pg1_eval(dir.path()).expect("pg1 eval should run");
|
|
|
|
assert!(
|
|
metrics.hard_negative_leak_rate <= 0.0,
|
|
"hard negatives leaked: {:?}",
|
|
metrics
|
|
);
|
|
|
|
// This runs entirely in-process on local storage; adaptation should be immediate.
|
|
assert!(
|
|
metrics.adaptation_p95_ms <= 200,
|
|
"adaptation p95 too high: {:?}",
|
|
metrics
|
|
);
|
|
|
|
assert!(
|
|
metrics.useful_item_uplift > 0.0,
|
|
"expected useful-item uplift over baseline: {:?}",
|
|
metrics
|
|
);
|
|
|
|
assert!(
|
|
metrics.repeated_unwanted_rate <= 0.01,
|
|
"unwanted items repeated too often: {:?}",
|
|
metrics
|
|
);
|
|
}
|