kvazarbit's picture
страница которая детално проанализирует поведение торгового бота по лог файлу в том же корене... {"component": "strategy", "symbol": "BTCUSDT", "bar_time": "2025-10-23T14:30:00+00:00", "blocking_reason": "NO_SIGNAL", "score": "0.354", "threshold": "0.500", "delta_score": "-0.146", "edge_net": "-0.0010", "min_edge": "0.0007", "confluence": "3/5", "reasons": "price_up,inertia_up,normal_vol", "vol_ratio": "1.18", "effective_min_vol_ratio": "0.45", "effective_max_vol_ratio": "3.50", "hurst": "0.973", "adx": "17.6", "trend_dir": -1, "market_regime": "RANGING", "h1_trend": "UP", "lagrangian_osc": "-0.895", "strong_uptrend": false, "unhealthy": false, "streak": "0/2", "will_buy": false, "volume_confirm_ok": true, "not_local_breakout": true, "is_momentum": false, "is_reversal": false, "momentum_data": null, "reversal_data": null, "event": "entry_evaluation", "logger": "strategy", "level": "info", "timestamp": "2025-10-27T12:58:58.402047Z"}
a48b488 verified
Raw History Blame Contribute Delete
4.42 kB
class LogStats extends HTMLElement {
connectedCallback() {
this.attachShadow({ mode: 'open' });
this.shadowRoot.innerHTML = `
<style>
.stats-card {
background: white;
border-radius: 0.5rem;
box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
padding: 1.5rem;
height: 100%;
}
.stats-title {
font-size: 1rem;
font-weight: 600;
color: #4b5563;
margin-bottom: 1rem;
display: flex;
align-items: center;
gap: 0.5rem;
}
.stats-title-icon {
width: 20px;
height: 20px;
color: #3b82f6;
}
.stats-grid {
display: grid;
grid-template-columns: repeat(2, 1fr);
gap: 1rem;
}
.stat-item {
background: #f9fafb;
border-radius: 0.375rem;
padding: 0.75rem;
}
.stat-label {
font-size: 0.75rem;
color: #6b7280;
margin-bottom: 0.25rem;
}
.stat-value {
font-size: 1.25rem;
font-weight: 700;
color: #111827;
}
.stat-change {
font-size: 0.75rem;
display: flex;
align-items: center;
gap: 0.25rem;
margin-top: 0.25rem;
}
.stat-change.up {
color: #10b981;
}
.stat-change.down {
color: #ef4444;
}
.stat-change-icon {
width: 14px;
height: 14px;
}
</style>
<div class="stats-card">
<div class="stats-title">
<svg class="stats-title-icon" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
<line x1="12" y1="20" x2="12" y2="10"></line>
<line x1="18" y1="20" x2="18" y2="4"></line>
<line x1="6" y1="20" x2="6" y2="16"></line>
</svg>
Log Statistics
</div>
<div class="stats-grid">
<div class="stat-item">
<div class="stat-label">Total Log Entries</div>
<div class="stat-value">0</div>
<div class="stat-change up">
<svg class="stat-change-icon" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
<polyline points="23 6 13.5 15.5 8.5 10.5 1 18"></polyline>
<polyline points="17 6 23 6 23 12"></polyline>
</svg>
<span>0%</span>
</div>
</div>
<div class="stat-item">
<div class="stat-label">Evaluation Events</div>
<div class="stat-value">0</div>
<div class="stat-change down">
<svg class="stat-change-icon" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
<polyline points="23 18 13.5 8.5 8.5 13.5 1 6"></polyline>
<polyline points="17 18 23 18 23 12"></polyline>
</svg>
<span>0%</span>
</div>
</div>
<div class="stat-item">
<div class="stat-label">Avg Score</div>
<div class="stat-value">0.000</div>
<div class="stat-change up">
<svg class="stat-change-icon" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
<polyline points="23 6 13.5 15.5 8.5 10.5 1 18"></polyline>
<polyline points="17 6 23 6 23 12"></polyline>
</svg>
<span>0%</span>
</div>
</div>
<div class="stat-item">
<div class="stat-label">Avg Vol Ratio</div>
<div class="stat-value">0.00</div>
<div class="stat-change down">
<svg class="stat-change-icon" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
<polyline points="23 18 13.5 8.5 8.5 13.5 1 6"></polyline>
<polyline points="17 18 23 18 23 12"></polyline>
</svg>
<span>0%</span>
</div>
</div>
</div>
</div>
`;
}
}
customElements.define('log-stats', LogStats);