fix emojies
This commit is contained in:
@@ -817,7 +817,7 @@ class TradingOrchestrator:
|
||||
'status': 'loaded'
|
||||
}
|
||||
|
||||
logger.info(f"✅ Loaded transformer checkpoint: {os.path.basename(checkpoint_path)}")
|
||||
logger.info(f"Loaded transformer checkpoint: {os.path.basename(checkpoint_path)}")
|
||||
logger.info(f" Epoch: {epoch}, Loss: {loss:.6f}, Accuracy: {accuracy:.2%}, LR: {learning_rate:.6f}")
|
||||
checkpoint_loaded = True
|
||||
else:
|
||||
@@ -1154,7 +1154,7 @@ class TradingOrchestrator:
|
||||
|
||||
logger.info("Orchestrator session data cleared")
|
||||
logger.info("🧠 Model states preserved for continued training")
|
||||
logger.info("📊 Prediction history cleared")
|
||||
logger.info("Prediction history cleared")
|
||||
logger.info("💼 Position tracking reset")
|
||||
|
||||
except Exception as e:
|
||||
@@ -1711,10 +1711,10 @@ class TradingOrchestrator:
|
||||
self.dashboard, "update_cob_data_from_orchestrator"
|
||||
):
|
||||
self.dashboard.update_cob_data_from_orchestrator(symbol, cob_data)
|
||||
logger.debug(f"📊 Sent COB data for {symbol} to dashboard")
|
||||
logger.debug(f"Sent COB data for {symbol} to dashboard")
|
||||
else:
|
||||
logger.debug(
|
||||
f"📊 No dashboard connected to receive COB data for {symbol}"
|
||||
f"No dashboard connected to receive COB data for {symbol}"
|
||||
)
|
||||
|
||||
except Exception as e:
|
||||
@@ -2811,6 +2811,25 @@ class TradingOrchestrator:
|
||||
self.trading_executor = trading_executor
|
||||
logger.info("Trading executor set for position tracking and P&L feedback")
|
||||
|
||||
def get_latest_transformer_prediction(self, symbol: str = 'ETH/USDT') -> Optional[Dict]:
|
||||
"""
|
||||
Get latest transformer prediction with next_candles data for ghost candle display
|
||||
Returns dict with predicted OHLCV for each timeframe
|
||||
"""
|
||||
try:
|
||||
if not self.primary_transformer:
|
||||
return None
|
||||
|
||||
# Get recent predictions from storage
|
||||
if symbol in self.recent_transformer_predictions and self.recent_transformer_predictions[symbol]:
|
||||
return dict(self.recent_transformer_predictions[symbol][-1])
|
||||
|
||||
return None
|
||||
|
||||
except Exception as e:
|
||||
logger.debug(f"Error getting latest transformer prediction: {e}")
|
||||
return None
|
||||
|
||||
def store_transformer_prediction(self, symbol: str, prediction: Dict):
|
||||
"""Store a transformer prediction for visualization and tracking"""
|
||||
try:
|
||||
|
||||
Reference in New Issue
Block a user