tangle


git clone https://radroots.dev/git/tangle.git
Log | Files | Refs | README | LICENSE

commit 96acdc483d84ba70565f7c7f943b45efb4e46c72
parent 58a171478cdeb59579141e7df8780338adf4c032
Author: triesap <tyson@radroots.org>
Date:   Sun, 14 Jun 2026 19:26:20 -0700

bench: rename production benchmark profile

Diffstat:
Mcrates/tangle_bench/src/bin/tangle_benchmark_report.rs | 25+++++++++++++++++++------
Mcrates/tangle_bench/src/lib.rs | 68+++++++++++++++++++++++++++++++++-----------------------------------
2 files changed, 52 insertions(+), 41 deletions(-)

diff --git a/crates/tangle_bench/src/bin/tangle_benchmark_report.rs b/crates/tangle_bench/src/bin/tangle_benchmark_report.rs @@ -214,7 +214,7 @@ fn path_string(path: &Path) -> String { fn help_text() -> String { [ - "usage: tangle-benchmark-report [--output-root PATH] [--run-id ID] [--profile smoke|medium|production]", + "usage: tangle-benchmark-report [--output-root PATH] [--run-id ID] [--profile smoke|medium|large-smoke]", " [--thresholds-json PATH] [--target-hardware-evidence TEXT]", " [--group-count COUNT] [--public-events-per-group COUNT]", " [--private-events-per-group COUNT] [--public-note-count COUNT]", @@ -268,19 +268,32 @@ mod tests { } #[test] - fn benchmark_report_args_accept_production_target_hardware_evidence() { + fn benchmark_report_args_accept_large_smoke_target_hardware_evidence_without_proof_claim() { let args = BenchmarkReportArgs::parse([ "--profile".to_owned(), - "production".to_owned(), + "large-smoke".to_owned(), "--target-hardware-evidence".to_owned(), - "target-hardware:prod-node-001".to_owned(), + "target-hardware:bench-node-001".to_owned(), "--run-id".to_owned(), "unit".to_owned(), ]) .expect("parse") .expect("args"); - assert_eq!(args.profile.name(), BenchmarkProfileName::Production); - assert!(args.profile.production_claim_eligible()); + assert_eq!(args.profile.name(), BenchmarkProfileName::LargeSmoke); + assert!(!args.profile.proof_claim_eligible()); + } + + #[test] + fn benchmark_report_args_reject_production_profile_alias() { + let error = BenchmarkReportArgs::parse([ + "--profile".to_owned(), + "production".to_owned(), + "--run-id".to_owned(), + "unit".to_owned(), + ]) + .expect_err("production profile removed"); + + assert!(error.contains("unknown benchmark profile")); } } diff --git a/crates/tangle_bench/src/lib.rs b/crates/tangle_bench/src/lib.rs @@ -70,7 +70,7 @@ impl BenchDatasetConfig { Self::new(24, 8, 6, 24, 5) } - pub fn production() -> Self { + pub fn large_smoke() -> Self { Self::new(120, 24, 16, 120, 12) } @@ -95,7 +95,7 @@ impl BenchDatasetConfig { pub enum BenchmarkProfileName { Smoke, Medium, - Production, + LargeSmoke, } impl BenchmarkProfileName { @@ -103,9 +103,9 @@ impl BenchmarkProfileName { match value { "smoke" => Ok(Self::Smoke), "medium" => Ok(Self::Medium), - "production" => Ok(Self::Production), + "large-smoke" => Ok(Self::LargeSmoke), _ => Err(format!( - "unknown benchmark profile `{value}`; expected smoke, medium, or production" + "unknown benchmark profile `{value}`; expected smoke, medium, or large-smoke" )), } } @@ -114,12 +114,12 @@ impl BenchmarkProfileName { match self { Self::Smoke => "smoke", Self::Medium => "medium", - Self::Production => "production", + Self::LargeSmoke => "large-smoke", } } pub fn all() -> [Self; 3] { - [Self::Smoke, Self::Medium, Self::Production] + [Self::Smoke, Self::Medium, Self::LargeSmoke] } } @@ -137,7 +137,7 @@ impl BenchmarkProfile { match name { BenchmarkProfileName::Smoke => Self::smoke(), BenchmarkProfileName::Medium => Self::medium(), - BenchmarkProfileName::Production => Self::production(), + BenchmarkProfileName::LargeSmoke => Self::large_smoke(), } } @@ -157,11 +157,11 @@ impl BenchmarkProfile { ) } - pub fn production() -> Self { + pub fn large_smoke() -> Self { Self::new( - BenchmarkProfileName::Production, - BenchDatasetConfig::production(), - BenchmarkThresholds::production(), + BenchmarkProfileName::LargeSmoke, + BenchDatasetConfig::large_smoke(), + BenchmarkThresholds::large_smoke(), ) } @@ -230,8 +230,8 @@ impl BenchmarkProfile { Ok(self) } - pub fn production_claim_eligible(&self) -> bool { - self.name == BenchmarkProfileName::Production && self.target_hardware_evidence.is_some() + pub fn proof_claim_eligible(&self) -> bool { + false } } @@ -631,7 +631,7 @@ impl BenchmarkThresholds { } } - pub fn production() -> Self { + pub fn large_smoke() -> Self { Self { pocket_query_p95_micros: 5_000_000, read_gate_p95_micros: 5_000_000, @@ -794,9 +794,9 @@ impl BenchmarkRunReport { "threshold_source": self.profile.threshold_source(), "thresholds": self.profile.thresholds().to_json(), "validation_summary": self.validation_summary, - "production_claim": { - "eligible": self.profile.production_claim_eligible(), - "profile_required": "production", + "proof_claim": { + "eligible": self.profile.proof_claim_eligible(), + "profile_required": "proof-*", "target_hardware_evidence": self .profile .target_hardware_evidence() @@ -1878,7 +1878,7 @@ mod tests { .iter() .map(|profile| profile.as_str()) .collect::<Vec<_>>(), - vec!["smoke", "medium", "production"] + vec!["smoke", "medium", "large-smoke"] ); assert_eq!( BenchmarkProfileName::parse("smoke") @@ -1893,11 +1893,12 @@ mod tests { "medium" ); assert_eq!( - BenchmarkProfileName::parse("production") - .expect("production") + BenchmarkProfileName::parse("large-smoke") + .expect("large-smoke") .as_str(), - "production" + "large-smoke" ); + assert!(BenchmarkProfileName::parse("production").is_err()); assert!( BenchmarkProfileName::parse("local") .expect_err("unknown") @@ -1912,8 +1913,8 @@ mod tests { BenchDatasetConfig::medium() ); assert_eq!( - BenchmarkProfile::production().dataset_config(), - BenchDatasetConfig::production() + BenchmarkProfile::large_smoke().dataset_config(), + BenchDatasetConfig::large_smoke() ); } @@ -1970,20 +1971,20 @@ mod tests { } #[test] - fn production_claim_eligibility_requires_production_profile_and_hardware_evidence() { - assert!(!BenchmarkProfile::smoke().production_claim_eligible()); + fn proof_claim_eligibility_requires_manual_proof_profile() { + assert!(!BenchmarkProfile::smoke().proof_claim_eligible()); assert!( !BenchmarkProfile::smoke() .with_target_hardware_evidence("target-hardware:ci") .expect("evidence") - .production_claim_eligible() + .proof_claim_eligible() ); - assert!(!BenchmarkProfile::production().production_claim_eligible()); + assert!(!BenchmarkProfile::large_smoke().proof_claim_eligible()); assert!( - BenchmarkProfile::production() - .with_target_hardware_evidence("target-hardware:prod-node-001") + !BenchmarkProfile::large_smoke() + .with_target_hardware_evidence("target-hardware:bench-node-001") .expect("evidence") - .production_claim_eligible() + .proof_claim_eligible() ); } @@ -2028,11 +2029,8 @@ mod tests { assert_eq!(summary["run_id"], "unit-run"); assert_eq!(summary["profile"], "smoke"); assert_eq!(summary["threshold_source"], "builtin:smoke"); - assert_eq!(summary["production_claim"]["eligible"], false); - assert_eq!( - summary["production_claim"]["target_hardware_evidence"], - "absent" - ); + assert_eq!(summary["proof_claim"]["eligible"], false); + assert_eq!(summary["proof_claim"]["target_hardware_evidence"], "absent"); assert_eq!( summary["dataset"]["fixture_family"], "synthetic repo-owned fixtures"