From a9ac81a7754f5d2fdc6cf3574870c0939e3f1a03 Mon Sep 17 00:00:00 2001 From: Ronald Tse Date: Wed, 7 Oct 2026 07:01:51 +0800 Subject: [PATCH] fix: two-tier parity bounds (tight default, smoke via SECRYST_E2E_SMOKE) --- spec/interscript/ml/golden_spec.rb | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/spec/interscript/ml/golden_spec.rb b/spec/interscript/ml/golden_spec.rb index 6fdbacf2..3cf95cb2 100644 --- a/spec/interscript/ml/golden_spec.rb +++ b/spec/interscript/ml/golden_spec.rb @@ -42,9 +42,11 @@ got = out.chars d = (0...[exp.length, got.length].min).count { |j| exp[j] != got[j] } total_diffs += d - expect(d.to_f / exp.length).to be < 0.02, row["input"][0, 60] + row_bound = ENV["SECRYST_E2E_SMOKE"] == "1" ? 0.05 : 0.02 + expect(d.to_f / exp.length).to be < row_bound, row["input"][0, 60] end - expect(total_diffs.to_f / total_chars).to be < 0.005 + corpus_bound = ENV["SECRYST_E2E_SMOKE"] == "1" ? 0.02 : 0.005 + expect(total_diffs.to_f / total_chars).to be < corpus_bound end end end