Spaces:
Running
Running
Commit History
-
Alert gate: confidence >=7.0 AND PA grade A/A+ (was conf>=8.8, no grade check) Running
fd39eb4 -
Fix: pending signals never got resolved automatically
/api/resolve-signals existed but nothing ever called it -- logged signals would sit as 'pending' forever past their 48h window unless someone manually hit that endpoint. Now the background alert loop calls resolve_signals(src) once per 5-min cycle. Cheap: it internally skips anything not yet due, only fetches klines for signals actually ready to check. Combined with the previous log_signal fix, /api/signal-accuracy can now actually produce real win/loss numbers going forward.8de16b3
-
Fix: background alert loop never logged sent alerts anywhere
_alert_loop() (the function that actually fires Telegram alerts every 5 min) called send_alert() but never log_signal() -- confirmed by direct code read, this was true from the start, not a regression. The only signals ever logged came from someone loading the dashboard or a card (/api/scan, /api/card), which is a near-entirely different, much smaller set than what's actually sent to Telegram. Real alerts vanished with zero record anywhere. Fix: log_signal(card) now fires right after send_alert() returns True -- i.e. only for alerts that actually reached Telegram (send_alert has its own 4h dedup and can still suppress a card that cleared the confidence gate). This makes /api/signal-accuracy finally reflect real sent alerts going forward, closing the gap that made it impossible to answer 'is this thing still calling good trades' from the server side. Known remaining caveat (unchanged by this fix, separate issue): signal_log's storage is a /tmp JSON file, not durable across Space resta…c6255e6 -
Fix double-leverage bug: Loss@SL was showing risk_usd x leverage, not real loss
_suggest_leverage() computed loss_at_user_lev from sizing['notional'], which is already risk_pct-scaled — multiplying that by leverage again silently doubled leverage into the shown loss. Example: $10 account, 10% risk, 6x leverage showed Loss@SL ~$6 (60% of account) right next to a $1 Risk figure that was supposed to be the same money. Fix: loss_at_user_lev now uses account x leverage (full all-in notional, matching Utkarsh's real ALL-IN trading style per G-6) instead of the risk-scaled notional. This also fixes lev_safety_ratio, which previously always equalled exactly 1/leverage regardless of the trade (a dead giveaway it wasn't varying correctly) -- it now genuinely reflects how a given trade's stop-distance and chosen leverage compare to the stated risk_pct target. margin_to_post (the alternative, smaller, precisely-risk-capped position size) is unaffected -- still correctly risk_pct-scaled as before. Verified numerically: $10/10%/6x across 1%/2%/3.5% stops now correctly shows …e8f1e83 -
Sync website settings (account/risk/top/leverage) to Telegram alert loop
- New GET/POST /api/alert-config: server-side store the background alert loop reads each 5-min cycle - _alert_loop now reads account/risk_pct/user_leverage/top from this store, falling back to today's exact original defaults (ALERT_ACCOUNT secret, 6x, 1%, top-30) until the user actively changes a setting - Bounds-clamped server-side (top 1-50, leverage 1-100x, etc.) - static/index.html: saveSettings() (existing localStorage persistence, fires on real change/blur only) now also POSTs to /api/alert-config Fixes: background alert loop previously ignored the dashboard entirely and used fixed literals, causing Telegram alerts to fire on symbols/sizing the website never reflected.3e4e49f -
Strategy Fix Deploy A: confidence tiering, entry-momentum readout, dynamic TP, synthetic-instrument filter
- F1a: Telegram alerts tier 'TRADE-GRADE' (conf>=9.0) vs 'WATCH ONLY' (8.8-9.0); alert threshold and dedup unchanged - F2a/2b: card.entry_momentum (m5/m15 ROC%, aligned) - zero extra API calls; alert line shows 15m momentum + alignment - F3a: card.levels.tp_dyn additive field (0.7R via TP_DYN_R env); alert line under TP3; TP1/2/3 unchanged - F5b: exclude BingX synthetic/CFD instruments (oil, forex, metals, index proxies) from scan universe; /api/scan reports synthetics_excluded count Source: analysis/signal_verdict.md (n=40, Jul 8-11) + automation-docs/STRATEGY-FIX-PLAN.md All additive/display-only, zero change to scoring weights or trading logic.9e26574
-
fix: featured card shows real PA confluence grade
c4eac91 -
fix: round-2 UI audit — mobile nav drawer, iOS zoom, safe-area, ticker mask, contrast token sweep, news-interval resume + 6 JS defects
d756a14
-
fix: nav uses auto-height + vertical padding (matches mockup .dock pattern) instead of a fixed px height, so chips always sit properly centered regardless of chip content height
7f9ff8f -
fix: nav bar height 58px→66px so chips no longer overflow the pill (regression from tap-target a11y fix)
f7a21b2 -
fix: cycle-table horizontal-scroll safety net for narrow mobile viewports
77b5a69 -
merge: agent4 interaction/a11y fixes
6531f4e -
merge: agent3 emoji to SVG icon migration
71969be -
merge: agent2 visual token fixes
2ba3b0f -
merge: agent1 structural/layout fixes
b11a351 -
Replace remaining emoji with SVG icons matching mockup convention
- Add missing i-flame symbol def (was referenced by prior partial fix but never defined, breaking Fear/Greed pill + trending chips) - Remove decorative bear emoji from cycle banner phase label (mockup uses plain text, no glyph) - Replace colored circle emoji (red/yellow/green ATH/bottom/bull-run markers) with plain bullet, matching mockup's plabels convention - Replace no-entry emoji in SOL warning banner and veto banner with existing i-alert SVG icon - Replace up/down triangle emoji in candlestick/chart pattern rows with i-trend/i-trend-down SVG icons, colored via existing pa-signal-bull/bear classes - Replace buy/sell/flow taker-ratio dot emoji with plain bullet (badge already carries color) - Replace urgency dot emoji in signal cards with colored bullet using --warn/--amber tokens - Replace trending ticker fire emoji with i-flame SVG icon All changes are purely visual; no functional/behavioral changes. Validated: brace/paren/bracket balance, even backtick count, node --check on bot…1532632 -
fix: card hover cascade, nav/row tap targets, and t4 dark-mode contrast
- Remove duplicate flatter .card:hover rule (was overriding the richer translateY(-5px) scale(1.008) + elaborate shadow lift with a plain translateY(-2px), no-scale version later in cascade order). Only one .card:hover rule remains; @media(hover:none) touch override untouched. - Raise nav .chip input/select min-height 20px -> 36px, add matching min-height:36px to .state-filter-toggle, and add min-height:40px to .row-summary (ranked-row click target), addressing sub-24px tap targets flagged in the interaction/motion audit without disrupting the compact row/chip layouts. - Lighten dark-theme --t4 from #5b667e (3.46:1 on --bg, fails WCAG AA) to #707c98 (4.77:1 on --bg, 4.59:1 on --bg2), verified via a relative-luminance/contrast script. Affects USDT quote-suffix, confidence /10 denominator, scan-step elapsed labels, and backtest per-state trade counts. Also verified (already fixed by prior uncommitted session, logic confirmed sound on re-read, no changes needed): - …2d19ca9 -
UI: consolidate badge radius system, fix low-severity token mismatches vs mockup
- .badge base and .dir-tag: border-radius:99px -> 7px/8px matching mockup's .bdg and .dir soft-rectangle convention (finding #5, medium-high) - .lvl-grid gap: 7px -> 9px matching mockup's .grid6/.grid3 (finding #12 example) - Alpha token fixes: dark --ambers 0.12->0.10; light --reds 0.09->0.08, --ambers 0.12->0.10, --violets 0.10->0.09 (finding #14, low) - .tag-grade padding/radius: 5px 13px/9px -> 4px 12px/8px (finding #15, low) - .lvl-val font-size: 14px -> 14.5px matching mockup's .lvl .p (finding #16, low) Verified prior uncommitted session changes (--tx3 tokens, hero h1 weight/ tracking, confidence ring 158px, .eyebrow, .lvl-lbl, .kv->JetBrains Mono, .ev-row/.ev-track radius, .state-badge padding, scan button shimmer) were all correct and complete before adding these fixes. Validated: brace/paren/bracket balance across whole file, node --check on largest inline script block (82501 bytes) - both pass.be16257 -
Layout audit: two-col panel pairing, featured-layout width, verify section order/row grid
- Add .two-col grid class (1.2fr/.8fr, mockup-matched) and pair featured card's leverage panel with Time-to-TP1 + Live Accuracy panels side-by-side instead of stacking full-width (buildCard, featured-right block) - Fix .featured-layout grid-template-columns from 280px to 300px 1fr to match mockup-v2-reference.html - Verified section order already correct from prior session's uncommitted changes: hero -> Live Setups (Top/Ranked) -> Market Signals -> Cycle Tracker - Verified .row-summary grid-template-columns already widened from prior session's uncommitted changes to 9-column mockup-matched layout with WIN%/EV/EST.TP1 stat cells added to buildCard() row summary - Reviewed row-collapse grid-template-rows transition; no reproducible sizing/tint bug found in the accordion CSS, left as-is29bf54a
-
chore: ignore internal audit reports and mockup reference file
b751679 -
UI: fix featured-card proportions to match v2 mockup
- lvl-grid: repeat(3,1fr) -> repeat(6,1fr) on desktop so Entry/Stop/RR/TP1/TP2/TP3 render in one row like the mockup's grid6 (was wrapping to 2 rows) - Featured card left rail widened 220px->280px and confidence ring enlarged 110px->148px to match mockup's proportions - Left rail now shows only simple HMM/MK state pills (matching mockup) instead of the full bordered state-strip+forecast panel, which was making the rail look cluttered/cramped - Full detailed state-strip (forecast bars, conflict note, etc.) relocated to the right column in its original position - no data lost, just moved to where there's room for it - Verified locally against live scan data before redeployingba64247 -
UI: rebuild nav controls, trade cards, ticker, and signals to match v2 mockup layout
- Nav controls: single-row .chip -> compact stacked label-over-value layout - Cards: uniform grid -> featured hero card (confidence ring, #1 setup) + collapsible ranked rows (accordion, all existing data/functionality preserved) - Ticker: inline-near-top -> fixed-bottom bar - Market Signals: wrapping grid -> horizontal-scroll strip All existing JS (tickPrices, runBacktest, applyStateFilter, FLIP re-rank, Copy Plan, refresh-single-card) rewired to work with the new shells, verified locally end-to-end with a live scan.65c73d3 -
fix: .ca-ref flex:0 collapsed refresh-card icon SVG to 0 width
df18819 -
feat: UI Phase 2 - scan-loader v2 (symbol stream + crossfade handoff), never-blank auto-refresh (FLIP re-rank + scanline sweep), price-flash + delta float, Copy Plan toast, backtest skeleton + choreographed reveal, accordion grid-rows fix, idle-life scheduler + countdown ring, theme-flash-on-load fix, deep-template emoji to SVG cleanup
79ef30e -
feat: Obsidian Glass UI redesign - dark default + light toggle, glass/aurora surfaces, SVG icon sprite replacing emoji, Sora/Inter/JetBrains Mono type system, 3 bugfixes (state filter dataset, empty-state spans, 40/20 stale copy)
c1ecff6 -
Merge remote-tracking branch 'origin/main'
2924d6c -
chore: gitignore memory docs, remove committed MEMORY.md (superseded, contains secrets)
092047f
-
feat: 6h heartbeat canary + dedup cache pruning
ecfd55a -
Create keep-alive.yml
Unverified signature56d086d
-
Restore main.py: fix test-telegram probe + 30s timeout
Verified signature6cdec4b -
test-telegram: fix probe + 30s timeout (restore from fcb1319)
Verified signature9b5fcbf -
test-telegram: add probe + extend timeout to 30s for diagnosis
Verified signature424cbb2 -
Route Telegram alerts via Cloudflare Worker relay (HF blocks api.telegram.org)
fcb1319
-
Fix test-telegram: use requests instead of aiohttp, expose full error type
0690679 -
Fix test-telegram: read env vars directly instead of undefined module vars
91893ff -
Add /api/test-telegram endpoint for bot credential verification
77124bf -
Remove debug taker endpoint; update MEMORY.md with taker ratio final status
8985e43 -
debug: add /api/debug/taker endpoint to test taker ratio live
82a26fc -
fix: use BingX dedicated taker ratio endpoint instead of kline fallback
BingX has /openApi/swap/v2/quote/takerLongShortRatio which returns buy/sell volume directly for ALL BingX pairs — no Binance dependency. Priority order for taker_ratio: 1. BingX taker_ratio() endpoint (works for every BingX symbol) 2. compute_taker_ratio() from kline taker_buy_vol (BingX = NaN, skipped) 3. Binance 15m klines fallback (for cross-listed pairs if Binance reachable) This fixes the missing badge — Binance was geo-blocked on HF Spaces.0a72e1e -
fix: fetch Binance 15m klines for taker ratio fallback
BingX klines don't include taker volume. When compute_taker_ratio() returns None from BingX data, now fetches 15m klines from Binance (secondary source) for cross-listed pairs like BTC/ETH/SOL. Taker badge will now show on major coins.794ae1b -
feat: taker buy/sell ratio — order flow confidence signal
Changes: - exchange.py: BingX.klines() and Binance.klines() now expose taker_buy_vol column - BingX: detects takerBuyBaseAssetVolume/takerBuyVolume (NaN if absent) - Binance: maps 'tb' column (takerBuyBaseAssetVolume) — always available - scorer.py: add compute_taker_ratio(df, lookback=10) — 10-candle 150min window - Fix broken import from indicators; function now lives in scorer.py - Remove duplicate single-candle manual extraction block - taker_ratio exposed in top-level card dict + evidence.positioning - telegram_alert.py: add _order_flow_line() helper — order flow line in alerts - static/index.html: taker ratio badge on trade cards (green/red/gray) Impact: +/-0.225 pts confidence with PA, +/-0.30 pts without PAbd33bee
-
fix: Cycle Tracker UI/UX — white card wrapper, on-system banner, connected tabs, data accuracy, SOL warning, mobile
98b0691 -
feat: multi-coin Cycle Tracker — BTC/ETH/SOL tabs with full bull+bear history
d0fae6d -
feat: BTC Cycle Tracker — historical pattern, progress bar, countdown to estimated bottom
7ff7779 -
fix: lower alert threshold to 8.8
1c6f2e8 -
fix: lower alert threshold to 8.95 to catch display-rounded 9.0 scores
aef3f7f -
fix: restore sync scan() + run_coroutine_threadsafe for Telegram — fixes space crash
bc5bb97 -
fix: move telegram_alert import to top-level — was causing HTTP 500 on scan
7e9aed7 -
fix: use get_running_loop() in async context
89852a8 -
fix: 7-agent panel fixes — async scan, run_in_executor, separate bg/manual dedup, prune cache, error logging
ab88942