Closes #021-hotfix - Dynamic feedback loop logging ticker alignment
This commit is contained in:
@@ -533,22 +533,23 @@ export default function CryptoDemo() {
|
||||
|
||||
// Manual logging of active forecast for all 15 models & horizons
|
||||
const handleLogManualForecast = () => {
|
||||
const entryPrice = parseFloat(activeCoin.price.replace(/[^0-9.]/g, ''));
|
||||
const logCoin = customCoins[feedbackFilterAsset] || coins[feedbackFilterAsset] || defaultCoins[feedbackFilterAsset];
|
||||
const entryPrice = parseFloat(logCoin.price.replace(/[^0-9.]/g, ''));
|
||||
|
||||
// Save snapshot of all predictions
|
||||
const predictionsMap: Record<string, Record<string, number>> = {};
|
||||
ESTIMATORS.forEach((est) => {
|
||||
predictionsMap[est.id] = {
|
||||
T1: getPredictionProb(activeCoin.ticker, est.id, 'T1'),
|
||||
T5: getPredictionProb(activeCoin.ticker, est.id, 'T5'),
|
||||
T10: getPredictionProb(activeCoin.ticker, est.id, 'T10')
|
||||
T1: getPredictionProb(logCoin.ticker, est.id, 'T1'),
|
||||
T5: getPredictionProb(logCoin.ticker, est.id, 'T5'),
|
||||
T10: getPredictionProb(logCoin.ticker, est.id, 'T10')
|
||||
};
|
||||
});
|
||||
|
||||
const now = Date.now();
|
||||
const newForecast: Forecast = {
|
||||
id: 'fc-' + now,
|
||||
ticker: activeCoin.ticker,
|
||||
ticker: logCoin.ticker,
|
||||
entryPrice,
|
||||
resolved: false,
|
||||
timestamp: now,
|
||||
@@ -564,7 +565,7 @@ export default function CryptoDemo() {
|
||||
setForecasts(nextForecasts);
|
||||
localStorage.setItem('crypto_bayes_forecasts', JSON.stringify(nextForecasts));
|
||||
|
||||
setLearningLoopLog(`Registered active multi-model forecast for ${activeCoin.ticker} at $${entryPrice}. Evaluating T+1 (24h), T+5 (5d), and T+10 (10d).`);
|
||||
setLearningLoopLog(`Registered active multi-model forecast for ${logCoin.ticker} at $${entryPrice}. Evaluating T+1 (24h), T+5 (5d), and T+10 (10d).`);
|
||||
setTimeout(() => setLearningLoopLog(''), 8000);
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user