trading-signals
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
Chinese<objective>
Provide standardized technical analysis patterns for trading projects, combining Elliott Wave, Wyckoff, Fibonacci, Markov Regime, and Turtle Trading methodologies. Enables confluence detection through regime-weighted methodology fusion and cost-effective multi-LLM consensus.
</objective>
<quick_start>
Confluence analysis (methodologies agree = high-probability setup):
python
score = sum(signal.strength * weights[signal.method] for signal in signals)
action = 'BUY' if score >= 0.7 else 'WAIT'Score interpretation:
- 0.7-1.0: High conviction entry
- 0.4-0.7: Wait for more confluence
- 0.0-0.4: No trade
Cost-effective routing: DeepSeek-V3 for pattern detection → Claude Sonnet for critical decisions
</quick_start>
<success_criteria>
Analysis is successful when:
- Multiple methodologies provide signals (not just one)
- Regime identified (trending/ranging/volatile) before analysis
- Confluence score calculated with regime-weighted methodology fusion
- Cost-optimized: bulk processing on DeepSeek, critical decisions on Claude
- Clear action (BUY/SELL/WAIT) with supporting rationale
- NO OPENAI used in model routing </success_criteria>
<core_patterns>
Standardized patterns for technical analysis across trading projects.
<objective>
为交易项目提供标准化技术分析模式,整合Elliott Wave、Wyckoff、Fibonacci、Markov Regime和Turtle Trading方法论。通过机制加权方法融合和高性价比的多LLM共识实现汇合检测。
</objective>
<quick_start>
汇合分析(多种方法论达成一致=高概率交易机会):
python
score = sum(signal.strength * weights[signal.method] for signal in signals)
action = 'BUY' if score >= 0.7 else 'WAIT'分数解读:
- 0.7-1.0:高信心入场
- 0.4-0.7:等待更多汇合信号
- 0.0-0.4:不进行交易
高性价比路由:使用DeepSeek-V3进行模式检测 → 使用Claude Sonnet做关键决策
</quick_start>
<success_criteria>
满足以下条件时分析成功:
- 多种方法论提供信号(而非单一方法)
- 分析前已识别市场机制(趋势/盘整/波动)
- 通过机制加权方法融合计算汇合分数
- 成本优化:批量处理使用DeepSeek,关键决策使用Claude
- 给出清晰的操作建议(BUY/SELL/WAIT)及支持理由
- 模型路由中未使用OPENAI </success_criteria>
<core_patterns>
适用于各类交易项目的标准化技术分析模式。
Quick Reference
快速参考
| Methodology | Purpose | When to Use |
|---|---|---|
| Elliott Wave | Wave position + targets | Trend structure, cycle timing |
| Turtle Trading | Breakout system | Trend following |
| Fibonacci | Support/resistance | Entry/exit zones, golden pocket |
| Wyckoff | Accumulation/distribution | Institutional activity |
| Markov Regime | Market state classification | Position sizing, strategy selection |
| Pattern Recognition | Candlestick + chart patterns | Entry confirmation |
| Swarm Consensus | Multi-LLM voting | High-conviction decisions |
| 方法论 | 用途 | 适用场景 |
|---|---|---|
| Elliott Wave | 波浪定位 + 目标点位 | 趋势结构、周期时机 |
| Turtle Trading | 突破系统 | 趋势跟踪 |
| Fibonacci | 支撑/阻力位 | 入场/离场区间、黄金口袋 |
| Wyckoff | 积累/派发阶段 | 机构行为分析 |
| Markov Regime | 市场状态分类 | 仓位管理、策略选择 |
| Pattern Recognition | K线 + 图表形态 | 入场确认 |
| Swarm Consensus | 多LLM投票 | 高信心决策 |
Confluence Detection
汇合检测
When methodologies agree = high-probability setup.
python
class ConfluenceAnalyzer:
"""Regime-weighted methodology fusion"""
REGIME_WEIGHTS = {
'trending_up': {'elliott': 0.30, 'turtle': 0.30, 'fib': 0.20, 'wyckoff': 0.15},
'trending_down': {'elliott': 0.30, 'turtle': 0.30, 'fib': 0.20, 'wyckoff': 0.15},
'ranging': {'fib': 0.35, 'wyckoff': 0.30, 'elliott': 0.20, 'turtle': 0.05},
'volatile': {'fib': 0.30, 'wyckoff': 0.30, 'elliott': 0.20, 'turtle': 0.10},
}
def analyze(self, df, regime: str) -> dict:
weights = self.REGIME_WEIGHTS[regime]
signals = self._collect_signals(df)
score = sum(s.strength * weights[s.method] for s in signals)
return {
'score': score, # 0-1.0
'action': 'BUY' if score >= 0.7 else 'WAIT',
'confluence': self._calc_agreement(signals)
}Score Interpretation:
- 0.7-1.0: High conviction entry
- 0.4-0.7: Wait for more confluence
- 0.0-0.4: No trade
当多种方法论达成一致时,即为高概率交易机会。
python
class ConfluenceAnalyzer:
"""Regime-weighted methodology fusion"""
REGIME_WEIGHTS = {
'trending_up': {'elliott': 0.30, 'turtle': 0.30, 'fib': 0.20, 'wyckoff': 0.15},
'trending_down': {'elliott': 0.30, 'turtle': 0.30, 'fib': 0.20, 'wyckoff': 0.15},
'ranging': {'fib': 0.35, 'wyckoff': 0.30, 'elliott': 0.20, 'turtle': 0.05},
'volatile': {'fib': 0.30, 'wyckoff': 0.30, 'elliott': 0.20, 'turtle': 0.10},
}
def analyze(self, df, regime: str) -> dict:
weights = self.REGIME_WEIGHTS[regime]
signals = self._collect_signals(df)
score = sum(s.strength * weights[s.method] for s in signals)
return {
'score': score, # 0-1.0
'action': 'BUY' if score >= 0.7 else 'WAIT',
'confluence': self._calc_agreement(signals)
}分数解读:
- 0.7-1.0:高信心入场
- 0.4-0.7:等待更多汇合信号
- 0.0-0.4:不进行交易
File Structure
文件结构
trading-project/
├── methodologies/
│ ├── elliott_wave.py # Wave detection + halving cycle
│ ├── turtle_system.py # Donchian breakouts
│ ├── fibonacci.py # Levels + golden pocket
│ ├── wyckoff.py # Phase detection + VSA
│ └── markov_regime.py # State classification
├── patterns/
│ ├── candlestick.py # Engulfing, hammer, doji
│ └── chart_patterns.py # H&S, double bottom, triangles
├── aggregator.py # Regime-weighted fusion
└── swarm/
├── consensus.py # Multi-LLM voting
└── adapters/ # Claude, DeepSeek, Geminitrading-project/
├── methodologies/
│ ├── elliott_wave.py # Wave detection + halving cycle
│ ├── turtle_system.py # Donchian breakouts
│ ├── fibonacci.py # Levels + golden pocket
│ ├── wyckoff.py # Phase detection + VSA
│ └── markov_regime.py # State classification
├── patterns/
│ ├── candlestick.py # Engulfing, hammer, doji
│ └── chart_patterns.py # H&S, double bottom, triangles
├── aggregator.py # Regime-weighted fusion
└── swarm/
├── consensus.py # Multi-LLM voting
└── adapters/ # Claude, DeepSeek, GeminiCost-Effective Model Routing
高性价比模型路由
| Task | Model | Cost |
|---|---|---|
| Pattern detection | DeepSeek-V3 | $0.27/1M |
| Confluence scoring | Qwen-72B | $0.40/1M |
| Critical decisions | Claude Sonnet | $3.00/1M |
| Swarm consensus | Mixed tier | ~$1.50/1M avg |
| 任务 | 模型 | 成本 |
|---|---|---|
| 模式检测 | DeepSeek-V3 | $0.27/1M |
| 汇合评分 | Qwen-72B | $0.40/1M |
| 关键决策 | Claude Sonnet | $3.00/1M |
| 群体共识 | 混合层级 | ~$1.50/1M 平均 |
Integration Notes
集成说明
- Data Sources: yfinance, CCXT, Alpaca API
- Pairs with: runpod-deployment-skill (model serving)
- Projects: ThetaRoom, swaggy-stacks, alpha-lens
- 数据来源: yfinance, CCXT, Alpaca API
- 搭配技能: runpod-deployment-skill(模型部署)
- 关联项目: ThetaRoom, swaggy-stacks, alpha-lens
Reference Files
参考文件
Core Methodologies:
- - Wave rules, halving supercycle, targets
reference/elliott-wave.md - - Donchian channels, ATR sizing, pyramiding
reference/turtle-trading.md - - Levels, golden pocket, on-chain enhanced
reference/fibonacci.md - - Phase state machines, VSA, composite operator
reference/wyckoff.md - - 7-state model, transition probabilities
reference/markov-regime.md
Advanced Patterns:
- - Candlestick + chart patterns
reference/pattern-recognition.md - - Multi-LLM voting system
reference/swarm-consensus.md - - Cost-optimized Chinese LLMs for trading
reference/chinese-llm-stack.md
核心方法论:
- - 波浪规则、减半超级周期、目标点位
reference/elliott-wave.md - - 唐奇安通道、ATR仓位管理、金字塔加仓
reference/turtle-trading.md - - 水平位、黄金口袋、链上数据增强
reference/fibonacci.md - - 阶段状态机、VSA、复合操作者
reference/wyckoff.md - - 7状态模型、转换概率
reference/markov-regime.md
进阶模式:
- - K线 + 图表形态
reference/pattern-recognition.md - - 多LLM投票系统
reference/swarm-consensus.md - - 适用于交易场景的高性价比中文LLM栈
reference/chinese-llm-stack.md