Stock Analysis Agent: A-Share Quantitative Technical Analysis

Preface

In environments like Cursor and Claude Code, asking “How is this stock?” often leads models to piece together conclusions based on impressions, lacking verifiable data and a unified standard. Manually running akshare and then organizing MA, MACD, and news keywords involves multiple steps and is difficult to reproduce.

Below is an introduction to the community skill on SkillHub: “Stock Analysis Crayfish” (Coordinates: @user_756344a1/stock-analysis-openclaw). It uses a general SKILL.md to define trigger methods, data sources, and output discipline, accompanied by Python scripts that link single-stock analysis, batch stock selection scoring, and intraday time-sharing analysis into an executable process. The SkillHub page marks requires_api_key=false, meaning it does not rely on additional API keys.

What is this

“Stock Analysis Crayfish” is a technical quantitative analysis Skill for A-shares (Chinese mainland stocks), maintained by the community publisher user_756344a1. It is categorized as professional on SkillHub, with the current store version being 1.0.0 (Source: community). The skill description self-reports the analysis framework as V4.x (including V4.3 adjustments to stop-loss and arbitrage formulas).

It solves the problem of allowing an Agent to invoke scripts based on fixed data sources and scoring models when users ask about individual stocks, trading references, batch Excel stock selection, or intraday time-sharing scenarios. It outputs structured conclusions with timeliness declarations and risk warnings, rather than making empty judgments.

Core Features

The following capabilities are derived from the SKILL.md and scripts/ directory within the installed package and can be verified against the official package.

Single Stock Analysis

When a user provides a stock code or name, the system interprets it item by item according to the technical analysis framework and fetches news for sentiment scoring. The script analyze.py supports single-stock analysis, multi-stock comparison, and viewing floating profits based on holding costs.

Comprehensive Scoring Model (Total 100 points)

  • Technical Aspect (85%): MA, MACD, KDJ, RSI, WR, CCI, BOLL, BIAS, VR, CR, OBV, volume-price relationship, and momentum, etc.
  • Sentiment Aspect (15%): Eastmoney individual stock news (akshare.stock_news_em), with keyword hierarchical weighting and time decay.

Grade Classification: ≥70 Strong Bullish; 40–69 Bullish; 0–39 Oscillating; <0 Bearish.

Batch Selection & TOP 10 Arbitrage Recommendation

When a user provides a wolffy1 stock selection Excel file, run_fast.py is used for multi-threaded batch scoring (documented as 10 threads). It outputs the TOP 10 based on arbitrage filtering conditions, including reasons for selection, risks, and trading plans (entry/target/stop-loss/risk-reward ratio); results can be saved as analysis_result.csv.

Intraday Time-Sharing Analysis

Uses intraday_analysis.py to obtain minute-level K-lines for intraday analysis.

Data Sources (Skill Specifications)

Data Type Source Usage
Historical K-lines akshare.stock_zh_a_hist / stock_zh_a_daily Technical indicators
Today’s Real-time Quotes Tencent qt.gtimg.cn Current price, change %, volume ratio, etc.
Sentiment akshare.stock_news_em News/announcement keywords
Market Index Tencent API SSE/SZSE/ChiNext Individual stock relative strength

Note: The documentation mentions Capital Flow in the table, but the scripts do not access it, so it should not be referenced during analysis. This skill does not perform fundamental analysis such as PE/PB.

Agent Output Discipline

The skill requires the model to declare the historical data cutoff date and real-time quote time, distinguish between facts and suggestions, label “Not investment advice,” and prohibit fabricating numbers not output by the script. When technical and sentiment aspects conflict, the technical aspect prevails (weight 85%).

Installation and Activation

1. Install SkillHub CLI (if not installed)

command -v skillhub && skillhub --version

If not installed, run:

curl -fsSL https://skillhub-1388575217.cos.ap-guangzhou.myqcloud.com/install/install.sh | bash -s -- --cli-only

2. Install the skill to the current Agent’s skills directory

You must use --dir during installation; otherwise, it defaults to ./skills/, which the Agent may fail to load.

skillhub install @user_756344a1/stock-analysis-openclaw --dir <skills directory>

Common path examples (from SkillHub installation docs):

  • Cursor: ~/.cursor/skills/
  • Claude Code: ~/.claude/skills/
  • Codex: ~/.codex/skills/ or .agents/skills/ under the project

Alternatively, provide the prompt from the official page to your AI and ask it to complete the installation according to the SkillHub Installation Instructions:

Please install `@user_756344a1/stock-analysis-openclaw` based on https://skillhub.cn/install/skillhub.md.

3. Python Dependencies

The scripts depend on akshare, pandas, numpy, requests, etc. (see imports in scripts/run_fast.py). You need to install the corresponding packages in an environment that can execute python; the skill does not declare a mandatory uv or brew formula.

Restart or refresh the Agent after installation to activate the skills directory.

Typical Usage

Paths are based on the scripts/ inside the skill package; if installed to ~/.cursor/skills/ in Cursor, please switch the working directory to the skill directory or write the full script path.

Single / Multiple Stocks / With Cost

python scripts/analyze.py 300706
python scripts/analyze.py 300706 34.403
python scripts/analyze.py 300706 000633 600519

Batch Excel Arbitrage Recommendation

python scripts/run_fast.py "Excel file path"

Intraday Time-Sharing

python scripts/intraday_analysis.py <code> [cost]

In conversations, when a user directly asks about a stock, asks for trading references, or uploads a wolffy1 selection table, the Agent should select the above scripts or equivalent processes according to the trigger conditions in SKILL.md, rather than skipping the data steps.

Use Cases and Notes

Who it is for

  • R&D personnel, quantitative enthusiasts, or investment research assistants who need to perform Technical + News Keyword auxiliary analysis for A-shares within an Agent.
  • Scenarios where a wolffy1 stock selection Excel is already available, and the user wants batch scoring and a TOP 10 arbitrage list.

Limitations and Notes

  • Historical K-lines are cut off at the last trading day’s close; real-time quotes have a delay of approximately 1–3 minutes, and data during non-trading hours is the most recent closing data.
  • Sentiment analysis relies on keyword matching and may be prone to misjudgment; the skill requires explaining this limitation to the user.
  • Indicators may be distorted under extreme market conditions such as limit-up/limit-down or suspension; the documentation states that uniform weighting and correlation of some indicators are model limitations.
  • Output must strictly adhere to the skill’s red lines: do not issue “Buy/Sell” instructions for users, do not predict specific price points, and do not fabricate data not present in the script output.

SkillHub Statistics (based on crawled data): Rating 100000, Downloads 12457, Installs 604.

Conclusion

“Stock Analysis Crayfish” integrates A-share data sources, the V4.x scoring framework, batch arbitrage, and output discipline into SKILL.md, making it suitable as a reproducible stock technical analysis skill on the Agent side. For installation and details, see SkillHub:

  • Skill Page: https://www.skillhub.cn/skills/user_756344a1/stock-analysis-openclaw
  • Coordinate Reference: https://api.skillhub.cn/user_756344a1/stock-analysis-openclaw
羽毛球分组比赛记分
小程序二维码

欢迎使用《羽毛球分组比赛记分》微信小程序

Xiaoye