Files
crypto_monitor/docs/strategy/README.md
T
dekun a268a93027 feat: show force-close badge and countdown when FORCE_CLOSE is enabled
Add shared lib/UI for midnight force-close indicator on instance and hub pages, and document Gate intraday 0-point exit alignment.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-06 02:17:47 +08:00

35 lines
2.1 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# 策略文档
各交易实例的人工下单策略,供 UI / 复盘对齐。
| 文档 | 实例 | 状态 |
|------|------|------|
| [binance-alt-trend-long.md](./binance-alt-trend-long.md) | 币安山寨·多头趋势 | v0.2 |
| [okx-trend-both.md](./okx-trend-both.md) | OKX·多空趋势 | v0.2 |
| [gate-intraday.md](./gate-intraday.md) | Gate·BTC 日内 | v0.2 |
## 约定
- **不写盈亏比(趋势户)**:币安/OKX 止盈/止损随行情人工设定,趋势 MD 不量化 RR。
- **日内例外**Gate 日内 **最低 1:1** 才开仓,持仓目标可动态调整(见 [gate-intraday.md](./gate-intraday.md))。
- **界面短标签(趋势户)**`大分歧A` / `大分歧B` / `小分歧`;全称在 option `title` / 策略 MD。
- **界面短标签(日内户)**`假破` / `结构突破`
- **多空共用三字**:方向由「做多/做空」表达,不复用为「大分歧A多」等。
- **自动联动**:大分歧 A/B → 趋势单;**小分歧 → 波段单**;平仓写入交易记录 `entry_reason`;复盘「填入」自动带入。
- **杠杆默认**BTC/ETH **10x**,其它 **5x**;与开仓类型无关(env `BTC_LEVERAGE` / `ALT_LEVERAGE`)。
- **日内 profile 独立**env 启用 `TRADE_SYMBOL_WHITELIST=BTC,ETH` 且限制开启时,**不显示** 大分歧三项(Gate);开仓类型为 **假破 / 结构突破**(见 gate-intraday.md)。
- **日内 0 点出场**:策略称「0 点平仓」;程序为 `FORCE_CLOSE_ENABLED` + `FORCE_CLOSE_BJ_HOUR=0`,交易记录 `result=强制清仓`(与表单 1h/2h/4h `time_close` 无关)。
- **策略模块独立**:趋势回调、顺势加仓不走上述三项。
## 系统实现
- 库:`lib/trade/entry_model_lib.py`
- 趋势户表单:`lib/instance/templates/order_entry_model_fields.html`
- 日内判定:`is_intraday_trading_profile()`(白名单仅含 BTC/ETH
- 0 点强平:`force_close_before_reset()`(三所 `app.py`);env `FORCE_CLOSE_ENABLED` / `FORCE_CLOSE_BJ_HOUR`
## 相关文档
- [计仓模式](../position-sizing-mode.md)
- [趋势回调策略](../trend-pullback-strategy.md)