Commit Graph

149 Commits

Author SHA1 Message Date
dekun 64b24fd6a6 Add repository code statistics snapshot doc.
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-21 10:48:10 +08:00
dekun 426afb8dbe Make options review detail a modal and fix screenshot display.
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-19 16:11:45 +08:00
dekun 38ac258497 Color 期期 preview PnL and show RR vs full premium loss.
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-19 15:43:01 +08:00
dekun 7938628485 Fix 期期 sheets bias: split total 2n from same-sheets, not n.
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-19 15:33:00 +08:00
dekun e3cd2a75de Replace 期期 equal-split with long/short bias sizing and env ratio controls.
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-19 15:25:10 +08:00
dekun 0ed2eabf0d Expand system guide with live trade, strategy, and key monitor chapters.
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-19 09:29:56 +08:00
dekun 5e0ce43415 Add instance system guide nav (default off) with overview/options/hedge manual.
EOF

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-19 09:23:30 +08:00
dekun 3119486105 Add 期期 close mode (全平/到期平) with scheme-C env toggle.
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-19 08:06:27 +08:00
dekun b3548240cc Auto-fill 期期 sheets from trading balance with same-sheets default.
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-19 00:56:35 +08:00
dekun f21e4d1166 Add env toggles to show/hide perp and options hedge plan tabs.
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-19 00:43:04 +08:00
dekun 041692a763 Retry pip installs during deploy to tolerate flaky mirrors.
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-17 16:02:51 +08:00
dekun 572239f69c Fix pip --progress-bar for pip 26+ so instance deploy can install deps.
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-17 15:47:33 +08:00
dekun 0f12e0a8ea Add single-exchange instance-only deploy menu options.
Manage menu 4/5/6 install OKX/Binance/Gate Flask only without hub or agents; reuse setup_env --only and narrowed PM2 verify.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-17 15:40:25 +08:00
dekun 2269bc51ff Deduct round-trip taker fees from estimated perp PnL.
Unify hub/instance TP profit, calc_pnl, and push/accounting to net of 0.05% per side; leave exchange floating PnL unchanged.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-17 15:12:52 +08:00
dekun c7aae67881 Add instance data dashboard (default off).
Read-only overview of live orders, key monitors, and strategy; show options/hedge only when present. Toggle via system settings nav prefs.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-17 12:09:29 +08:00
dekun 48afc8ebe3 Load options review from local records with compact journal UI.
Drop exchange sync for the review page, auto-import closed local options and hedge plans, and match contract-style multi-timeframe upload styling with smaller fonts.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-17 09:54:35 +08:00
dekun edcc04e88c Improve options review tabs and multi-timeframe uploads.
Add source-type tabs, open an inline journal form from list rows, and match contract-style 5m/15m/1h/4h screenshot slots.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-17 09:45:44 +08:00
dekun 10128d18bc Add OKX options review module with hedge plan entries.
Import closed OKX option history and closed hedge plans into one list for journaling, images, and stats without mixing contract reviews.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-17 09:35:19 +08:00
dekun e280220951 Move desktop calculator tabs left.
Compress wide-screen calculator inputs into three rows while preserving mobile layout.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-16 14:50:42 +08:00
dekun c9d40e5e52 Add desktop calculator tabs.
Show one strategy calculator at a time while preserving the existing mobile tab experience.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-16 14:44:36 +08:00
dekun b30129f83f Remove duplicate funds PnL banner.
Keep cumulative PnL in summary cards and free toolbar space after snapshot sync.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-16 14:36:37 +08:00
dekun 4e86595f2a Collapse daily stats by default.
Show only total floating PnL until expanded; enlarge details and lower exchange headers.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-16 14:31:00 +08:00
dekun 35b23836e3 Restore strategy chips and 1080p side margins.
Stick expand hint to card bottom; drop mistaken key-monitor slot; keep ultrawide content width.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-16 14:11:29 +08:00
dekun 0540b585c7 Refine monitor 2x2 slots and drop tablet CSS.
Add options target column, reserve pos/monitor rows, equal columns, and remove hub-tablet densify path.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-16 14:03:59 +08:00
dekun 018b4d5601 Split OKX monitor into perp and options cards.
Align four exchange cards in a 2x2 grid so 1080p layout stays balanced.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-16 13:47:21 +08:00
dekun bde8c517e0 Tighten empty monitor cards on 1080p.
Size no-position blocks to content and give remaining height to options/positions.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-16 13:42:26 +08:00
dekun 480f6d78e8 Fix desktop blur from false tablet layout.
Stop classifying short desktop viewports as tablets so densify fonts do not apply.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-16 13:35:41 +08:00
dekun 57dad1ffdf Fit tablet hub to one screen with denser type.
Keep full card content readable; shrink fonts/spacing and use in-table scroll only when positions overflow.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-16 13:22:57 +08:00
dekun 7d6f0ac55b Fix tablet hub cards clipping content.
Prefer visible card content over forced one-screen crop; auto row heights and page scroll on hub-tablet.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-16 13:13:17 +08:00
dekun 2777419a10 Add tablet viewport fit for hub one-screen layout.
Hi-DPI tablets like 2560x1600 map to ~1280x800 CSS; broaden fit breakpoints and densify for hub-tablet.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-16 13:09:29 +08:00
dekun 836b37cc7e Fit hub monitor, market, and funds to one 1080p screen.
Constrain desktop shell to 100dvh with flex fill so OKX perp+option plus peer cards, chart, and equity overview avoid page scroll.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-16 13:01:17 +08:00
dekun 4686cf049a Require real ask depth for options and hedge opens.
Block mark-as-ask opens, show reference mark when no depth, cap sheets to ask size; leave close paths unchanged. Document in docs/更新文档.md.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-16 12:48:53 +08:00
dekun f0d5b47f50 Fix options add-on premium to sum all open legs for the contract.
Display, close gate, alerts, and full-close accounting no longer use only the latest fill row.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-16 11:11:32 +08:00
dekun 19a4a5194d Use per-exchange PWA names and logos for instance app installs.
Show Binance/OKX/Gate 交易系统 with distinct exchange icons in manifests, apple titles, and login branding.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-16 08:44:07 +08:00
dekun 6f934ecbbf Clarify 2x recycle is a target-close gate, not auto-close.
Rename UI copy from auto-close to target gate so 2x alone is not read as a close trigger.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-15 22:16:06 +08:00
dekun cbb7f954f5 Auto-cancel stale option close limits after pending TTL.
Default 10m via OKX_OPTIONS_PENDING_TTL_SECONDS; show age/countdown in pending panel; monitor loop cancels sell closes.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-15 22:06:24 +08:00
dekun 1909eea654 Use bid1-only option closes with hard-disabled market exits.
Manual close checks liquidity only; target auto still requires 2x recycle hold once, then reuses the shared bid1 executor. Add /options/guide doc and update hedge-plan refs.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-15 21:49:06 +08:00
dekun 1fa98425e7 Add OKX hedge-plan P0: env group, preview page, and PnL scenario math.
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-14 11:00:15 +08:00
dekun d27ccbea8f Add OKX options hedge strategy guide for manual perp and options pairing.
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-13 11:20:03 +08:00
dekun 58c9f36a75 Add interactive deploy manager with install, uninstall, and update menus.
Provides curl-friendly manage.sh so production servers can bootstrap without a prior clone, then configure API and risk settings in the browser.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-12 12:23:29 +08:00
dekun b733e551a0 Normalize fullwidth punctuation to ASCII across codebase.
Add scripts/normalize_ambiguous_unicode.py; fix corrupted patch_instance_theme_templates.py. Preserves curly quotes in string literals; removes Git homoglyph warnings on .env.example.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-08 23:42:26 +08:00
dekun 823aeda42a Add hub AI config tab with sync to instances and deploy secret bootstrap.
Wire bootstrap_deploy_secrets into setup_env.sh (one-time HUB_BRIDGE_TOKEN, FLASK_SECRET_KEY, HUB_SESSION_SECRET). Remove AI section from instance env UI; hub saves OPENAI settings to all four .env files. SSO unchanged.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-08 22:50:58 +08:00
dekun 0d2ce9c126 Add curated env config UI with Chinese labels and deploy secret bootstrap
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-08 21:03:00 +08:00
dekun 806bb074ab feat: add OKX options module with dual API, USDT/USDC convert, and docs
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-07 08:17:27 +08:00
dekun ff1bcd69d2 feat: two-level entry model UI for trend accounts (reversal/trend/swing)
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-06 19:02:18 +08:00
dekun eb6788091d docs: OKX reversal launch A/B strategy v0.4 with short mirror
Align OKX strategy MD and checklist with binance v0.4; document long reversal and mirrored short rules.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-06 18:50:04 +08:00
dekun 96ab7e997c docs: binance reversal launch A/B strategy v0.4 draft
Document MACD divergence, reference-high two-touch rules, launch A (A1/A2) and B; update hub checklist. UI implementation still pending.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-06 18:44:17 +08:00
dekun 0d5b20c0db feat: strategy page scroll layout, OKX standalone docs, split print
Right checklist drives card height with left doc scroll; rewrite OKX strategy MD and checklist as standalone; add per-column print buttons.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-06 03:25:56 +08:00
dekun 7223b54ec4 feat: add hub strategy docs page with MD and checklists
Central /strategy page shows per-exchange strategy markdown and read-only entry checklists; nav toggle in settings, print and HTML export per tab.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-06 03:12:09 +08:00
dekun df99eb5fb5 chore: gate-only force-close policy and deploy pull script
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-06 02:32:35 +08:00