增强回测引擎第二版策略与快照层

This commit is contained in:
zsb
2026-04-07 00:34:52 -07:00
parent 334864cbc5
commit d039c4e741
10 changed files with 244 additions and 86 deletions

View File

@@ -41,6 +41,7 @@ pub struct DailyEquityPoint {
pub total_equity: f64,
pub benchmark_close: f64,
pub notes: String,
pub diagnostics: String,
}
#[derive(Debug, Clone)]
@@ -126,6 +127,7 @@ where
date: execution_date,
})?;
let notes = decision.notes.join(" | ");
let diagnostics = decision.diagnostics.join(" | ");
result.equity_curve.push(DailyEquityPoint {
date: execution_date,
@@ -134,6 +136,7 @@ where
total_equity: portfolio.total_equity(),
benchmark_close: benchmark.close,
notes,
diagnostics,
});
}