a-share-sector-ta
Installation
Review the source and dependencies with a prompt. A package is available to download.
Install with an AI assistant
Copy the prompt so your assistant can review the pinned revision and dependencies first.
View promptHide prompt
Check whether SkillPI Skill Finder is installed for your current agent. If it is missing, install and enable it using the official instructions at https://github.com/Findskills/skillpi. Then use Skill Finder to locate and install "a-share-sector-ta" from this exact SkillPI detail page: https://skillpi.com/skills/deepskill-92ece561cc768d656a7b36932853fcf4f1a2ec9631c2fd00db16f920b7519627. Verify the upstream source and version against https://skillhub.cn/skills/user_dd2b06bc/a-share-sector-ta before installing. If they do not match, stop and report the mismatch. Report the installed path and source version.
Source and setup
skillhub.cn
Setup guidance pending
See the original source for supported tools, dependencies, and permissions.
Installation test pending
A-share single-stock technical analysis tool: fetches daily, weekly, and monthly K-line data for a single A-share stock and computes technical indicators such as MACD, KDJ, RSI, BOLL, and moving averages. After the script outputs structured data, an Agent writes the Chinese technical analysis. Data source is Eastmoney (akshare). When asked about stock technical analysis, K-lines, MACD, KDJ, RSI, Bollinger Bands, moving averages, golden/death crosses, etc., scripts/query.py must be executed first; manual scraping or independent indicator calculations are prohibited.
Introduction source: third_party · user_dd2b06bc · 1.0.0 Reference
SkillPi interpretation
- Tasks
- Translation pending; see source documentation.
- Inputs and outputs
- Translation pending; see source documentation.
- Software, accounts and paid services
- Translation pending; see source documentation.
- Testing
- Not tested
Browse files
Frontmatter
name: a-share-stock-ta
description:
查询 A 股单只股票日线/周线/月线 K 线,并计算 MACD、KDJ、RSI、BOLL、均线等技术指标;
脚本输出结构化数据后由 Agent 撰写中文技术分析。数据来自东方财富(akshare)。
当用户问个股技术分析、K线、周线、日线、MACD、KDJ、RSI、布林带、均线、超买超卖、
金叉死叉、某股票走势时使用;须优先执行 scripts/query.py,禁止手写爬虫或自行算指标。A股个股技术分析
查询单只 A 股的 K 线 + 技术指标,脚本负责拉数据、算指标、出表格;Agent 负责读数据、写分析。
数据来源:东方财富(经 akshare)。仅供研究参考,不构成投资建议。
前置条件
pip install -r {skill}/requirements.txt
需要 Python 3.9+ 与网络访问。
路径约定
{skill}= 本 skill 根目录的绝对路径(SKILL.md所在目录)- Cursor Agent 加载本 skill 时应使用该路径;勿在工作区根目录直接运行
python {skill}/scripts/query.py - 脚本固定位于:
{skill}/scripts/query.py
工作流(必须遵守)
用户提问 → 执行 query.py → 将脚本 Markdown 输出呈现给用户 → Agent 基于同一份数据撰写分析
- 先跑脚本,禁止手写 akshare 或临时算 MACD/KDJ
- 完整呈现脚本输出的 K 线表、指标表、快照
- 再写分析:趋势、信号、共振、风险(见下文「Agent 分析模板」)
- 免责声明:指标滞后、非投资建议
命令
python {skill}/scripts/query.py <代码或名称> [options]
常用示例
# 默认:日线 + 周线,MACD/KDJ/RSI/BOLL/均线,前复权
python {skill}/scripts/query.py 600118
python {skill}/scripts/query.py 中国卫星
# 仅日线
python {skill}/scripts/query.py 600118 --period daily
# 仅周线
python {skill}/scripts/query.py 600118 --period weekly
# 指定指标
python {skill}/scripts/query.py 600118 --indicators macd,kdj
# 展示更多期数
python {skill}/scripts/query.py 600118 --show 20 --bars 250
# 不复权 / 后复权
python {skill}/scripts/query.py 600118 --adjust ""
python {skill}/scripts/query.py 600118 --adjust hfq
参数说明
| 参数 | 说明 |
|---|---|
symbol |
6 位代码或股票名称(可模糊匹配) |
--period |
daily / weekly / monthly / both(默认 both) |
--bars |
拉取 K 线根数,用于指标计算(默认 120) |
--show |
表格展示最近 N 期(默认 10) |
--adjust |
复权:qfq 前复权(默认)、hfq 后复权、"" 不复权 |
--indicators |
macd,kdj,rsi,boll,ma(逗号分隔,默认全开) |
脚本输出结构
- 快照:最新收盘、MACD 金叉/死叉提示、KDJ 超买超卖、RSI、BOLL 位置
- K 线表:日期、OHLC、涨跌幅、成交量、换手率
- 指标表:近 N 期 MACD / KDJ / RSI / BOLL / 均线
- Agent 分析任务:脚本末尾列出 Agent 应完成的分析项
Agent 分析模板
脚本跑完后,Agent 必须在数据下方补充如下结构(可根据数据删减,但需覆盖核心项):
## 技术分析解读
### 趋势与均线
- 价格与 MA5/MA10/MA20/MA60 关系…
- 短期/中期趋势判断…
### MACD
- DIF/DEA 位置、红柱/绿柱变化…
- 是否出现金叉/死叉…
### KDJ / RSI
- 是否超买(J>100、RSI>70)或超卖(J<0、RSI<30)…
- 与价格是否背离(若明显)…
### 布林带
- 价格在上/中/下轨附近的意义…
### 多周期共振(若查了日线+周线)
- 日线与周线方向是否一致…
### 风险提示
- 指标滞后、单一指标局限性;不构成投资建议。
分析原则
- 只依据脚本输出的数字,不臆造 K 线或指标
- 多指标矛盾时如实说明(如 MACD 多头但 KDJ 超买)
- 避免绝对化用语(「一定涨/跌」)
- 用户只问某一指标时,可侧重该项,但仍需带风险提示
常见问题
| 现象 | 处理 |
|---|---|
| 名称匹配多个 | 用 6 位代码重查,或更精确的名称 |
| 新股/停牌数据少 | 说明样本不足,指标参考性下降 |
ModuleNotFoundError |
pip install akshare pandas |
| 接口报错 | 清代理后重试;查阅 akshare 文档 |
与 a-share-sector 的分工
| Skill | 用途 |
|---|---|
a-share-sector |
板块涨跌、板块内个股、资金流 |
a-share-stock-ta |
单只股票 K 线、MACD/KDJ 等技术指标 |
两者可同时使用:先用 sector 找强势板块与个股,再用 stock-ta 对目标股做技术分析。
Current listing version
1.0.0
Safety and assessment details
Quality assessment
Out of 100 · Assessment report from SkillPi LAB.
Highlights
- 解决A股个股技术分析高频刚需
- 工具链完整形成数据+分析闭环
- 数据来源明确实用性强
Highlights
- 触发词覆盖全面且边界清晰
- 支持多种用户表达方式
Highlights
- 结构完整规范清晰
- 提供完整端到端示例
- 包含常见问题与风险提示
Highlights
- 工具来源明确参数完整
- 有异常处理指引
- 执行顺序要求清晰
The arithmetic mean of the first four original scores, rounded to a whole number.
Static text checks
100 / 100 · skillpi-20261123-no-r3-v1
No current rules matched the text.
This score reflects rule matches in the text and is provided for reference before use. It excludes attachments and runtime behavior.
Permissions and checks before use
Automatically summarized from this main document. Matches may be examples or defensive advice; they are not actual permission declarations. Attachments, external dependencies and runtime behavior are not covered.
-
Install or fetch external dependencies
Use official sources and pin versions. Check install scripts in an isolated environment. This document check does not cover code downloaded later.
Mentioned in main document · lines 19, 131
Domains or addresses referenced in the document
These addresses may be documentation links or examples, not an approved network allowlist. Verify actual destinations and outgoing data before use.
- github.com
- quote.eastmoney.com
Security rating and access scope
safe · Static evidence review; not a runtime safety guarantee.
Translation pending; see source documentation.
Before use, confirm and authorize actual file access, external services and network destinations in your host. This review grants no runtime permissions.
User discussion
No verified reviews yet.