技能创建器
skill-creator
创建、改进和评估自定义技能,把专业流程转化为可重复使用的 AI 能力。
stock-signal-analyzer【数据与研究】Analyzes OHLCV data to compute 15+ technical indicators (including MA, MACD, RSI, Bollinger Bands, KDJ) and generates a bullish/bearish signal summary with an overall assessment. Triggered when users request technical analysis, ask to calculate indicators like MACD or RSI, mention candlestick analysis, or discuss signals from moving average crossover…
独立 GitHub 快照 · 自动分类 · 以原作者文档为准
Computes 15+ technical indicators from OHLCV data and generates a bullish/bearish signal summary with an overall assessment. Simply provide a CSV file containing OHLCV columns to get a complete technical analysis report.
python3 scripts/compute_indicators.py data.csv
Output as a text report:
python3 scripts/compute_indicators.py data.csv --format text
Output indicator data for the last 5 rows:
python3 scripts/compute_indicators.py data.csv --last-n 5
Save results to a file:
python3 scripts/compute_indicators.py data.csv -o result.json
The CSV file must contain the following columns (column names are case-insensitive and common aliases are supported):
| Column | Aliases | Description |
|---|---|---|
Open | o | Opening price |
High | h | Highest price |
Low | l | Lowest price |
Close | c, adj close | Closing price |
Volume | vol, v | Trading volume |
Date | datetime, time | Date (optional) |
Example CSV:
Date,Open,High,Low,Close,Volume
2025-01-02,100.0,105.0,99.0,103.5,1500000
2025-01-03,103.5,108.0,102.0,106.0,1800000
...
| Indicator | Bullish Signal | Bearish Signal |
|---|---|---|
| MA Cross | SMA5 > SMA20 | SMA5 < SMA20 |
| MACD | Histogram > 0 | Histogram < 0 |
| RSI | RSI < 30 (oversold) | RSI > 70 (overbought) |
| Bollinger Bands | Price < Lower Band | Price > Upper Band |
| KDJ | J < 20 or K > D | J > 80 or K < D |
| CCI | CCI < −100 | CCI > 100 |
| Williams %R | %R < −80 | %R > −20 |
| ADX/DMI | ADX > 25 and +DI > −DI | ADX > 25 and −DI > +DI |
| ROC | ROC > 0 | ROC < 0 |
| MFI | MFI < 20 | MFI > 80 |
| OBV | 5-day uptrend | 5-day downtrend |
| TRIX | TRIX > 0 | TRIX < 0 |
The overall assessment is based on the proportion of bullish vs. bearish signals.
{
"metadata": { "input_file": "...", "total_rows": 100, "indicators_computed": 27 },
"indicators": [ { "date": "...", "close": 103.5, "SMA_5": 102.1, ... } ],
"signals": { "MA_Cross": "bullish", "MACD": "bearish", ... },
"summary": { "verdict": "bullish", "bullish_count": 7, "bearish_count": 4, "neutral_count": 1 }
}
A structured analysis report containing all indicator values and a bullish/bearish signal summary.
pip install pandas numpy
null/N/A without affecting other indicators