fix emojies
This commit is contained in:
@@ -39,18 +39,18 @@ async def example_realtime_data():
|
||||
print("\n2. Getting latest real-time data...")
|
||||
inference_data = await data_provider.get_inference_data_unified('ETH/USDT')
|
||||
|
||||
print(f"\n📊 Inference Data:")
|
||||
print(f"\nInference Data:")
|
||||
print(f" Symbol: {inference_data.symbol}")
|
||||
print(f" Timestamp: {inference_data.timestamp}")
|
||||
print(f" Data Source: {inference_data.data_source}")
|
||||
print(f" Query Latency: {inference_data.query_latency_ms:.2f}ms")
|
||||
|
||||
# Check data completeness
|
||||
print(f"\n✓ Complete Data: {inference_data.has_complete_data()}")
|
||||
print(f"\nComplete Data: {inference_data.has_complete_data()}")
|
||||
|
||||
# Get data summary
|
||||
summary = inference_data.get_data_summary()
|
||||
print(f"\n📈 Data Summary:")
|
||||
print(f"\nData Summary:")
|
||||
print(f" OHLCV 1s rows: {summary['ohlcv_1s_rows']}")
|
||||
print(f" OHLCV 1m rows: {summary['ohlcv_1m_rows']}")
|
||||
print(f" OHLCV 1h rows: {summary['ohlcv_1h_rows']}")
|
||||
@@ -64,7 +64,7 @@ async def example_realtime_data():
|
||||
|
||||
# Get technical indicators
|
||||
if inference_data.indicators:
|
||||
print(f"\n📉 Technical Indicators:")
|
||||
print(f"\nTechnical Indicators:")
|
||||
for indicator, value in inference_data.indicators.items():
|
||||
print(f" {indicator}: {value:.4f}")
|
||||
|
||||
@@ -94,21 +94,21 @@ async def example_historical_data():
|
||||
context_window_minutes=5
|
||||
)
|
||||
|
||||
print(f"\n📊 Inference Data:")
|
||||
print(f"\nInference Data:")
|
||||
print(f" Symbol: {inference_data.symbol}")
|
||||
print(f" Timestamp: {inference_data.timestamp}")
|
||||
print(f" Data Source: {inference_data.data_source}")
|
||||
print(f" Query Latency: {inference_data.query_latency_ms:.2f}ms")
|
||||
|
||||
# Show multi-timeframe data
|
||||
print(f"\n📈 Multi-Timeframe Data:")
|
||||
print(f"\nMulti-Timeframe Data:")
|
||||
for tf in ['1s', '1m', '5m', '15m', '1h', '1d']:
|
||||
df = inference_data.get_timeframe_data(tf)
|
||||
print(f" {tf}: {len(df)} candles")
|
||||
|
||||
# Show context data
|
||||
if inference_data.context_data is not None:
|
||||
print(f"\n🔍 Context Data: {len(inference_data.context_data)} rows")
|
||||
print(f"\nContext Data: {len(inference_data.context_data)} rows")
|
||||
|
||||
# Cleanup
|
||||
await data_provider.disable_unified_storage()
|
||||
@@ -134,7 +134,7 @@ async def example_multi_timeframe():
|
||||
limit=100
|
||||
)
|
||||
|
||||
print(f"\n📊 Multi-Timeframe Data:")
|
||||
print(f"\nMulti-Timeframe Data:")
|
||||
for timeframe, df in multi_tf.items():
|
||||
print(f"\n {timeframe}:")
|
||||
print(f" Rows: {len(df)}")
|
||||
@@ -163,7 +163,7 @@ async def example_orderbook():
|
||||
print("\n2. Getting order book data...")
|
||||
orderbook = await data_provider.get_order_book_data_unified('ETH/USDT')
|
||||
|
||||
print(f"\n📊 Order Book:")
|
||||
print(f"\nOrder Book:")
|
||||
print(f" Symbol: {orderbook.symbol}")
|
||||
print(f" Timestamp: {orderbook.timestamp}")
|
||||
print(f" Mid Price: ${orderbook.mid_price:.2f}")
|
||||
@@ -181,7 +181,7 @@ async def example_orderbook():
|
||||
|
||||
# Show imbalances
|
||||
imbalances = orderbook.get_imbalance_summary()
|
||||
print(f"\n📉 Imbalances:")
|
||||
print(f"\nImbalances:")
|
||||
for key, value in imbalances.items():
|
||||
print(f" {key}: {value:.4f}")
|
||||
|
||||
@@ -211,7 +211,7 @@ async def example_statistics():
|
||||
stats = data_provider.get_unified_storage_stats()
|
||||
|
||||
if stats.get('cache'):
|
||||
print(f"\n📊 Cache Statistics:")
|
||||
print(f"\nCache Statistics:")
|
||||
cache_stats = stats['cache']
|
||||
print(f" Hit Rate: {cache_stats.get('hit_rate_percent', 0):.2f}%")
|
||||
print(f" Total Entries: {cache_stats.get('total_entries', 0)}")
|
||||
@@ -219,7 +219,7 @@ async def example_statistics():
|
||||
print(f" Cache Misses: {cache_stats.get('cache_misses', 0)}")
|
||||
|
||||
if stats.get('database'):
|
||||
print(f"\n💾 Database Statistics:")
|
||||
print(f"\nDatabase Statistics:")
|
||||
db_stats = stats['database']
|
||||
print(f" Total Queries: {db_stats.get('total_queries', 0)}")
|
||||
print(f" Failed Queries: {db_stats.get('failed_queries', 0)}")
|
||||
|
||||
Reference in New Issue
Block a user