A-Share Stock Analysis & Portfolio Manager for Openclaw

A comprehensive tool for real-time A-Share market data, volume energy analysis, and portfolio profit/loss tracking.

cnyezi
v1.0.0
Jan 27, 2026
74
14.5k
0

Install & Download

1. ClawHub CLI

The fastest way to install a skill directly from the registry.

npx clawhub@latest install a-stock-analysis

2. Manual Installation

Copy the skill folder to one of these locations

Global
~/.openclaw/skills/
Workspace
<project>/skills/

Priority: Workspace > Local > Bundled

3. Prompt Installation

Copy this prompt to OpenClaw to install it automatically.

Help me install a-stock-analysis using Clawhub. If Clawhub is not installed, install it first (npm i -g clawhub).

Prefer to download?

Get the raw skill files in a ZIP archive.

What is A-Share Stock Analysis & Portfolio Manager?

The A-Share Stock Analysis skill provides developers and traders with deep insights into the Shanghai, Shenzhen, and Beijing stock markets. By integrating real-time data from Sina Finance, it offers detailed price movements, turnover rates, and sophisticated volume energy distribution analysis. This skill is a vital addition to your collection of Openclaw Skills for monitoring market volatility and identifying institutional movements.

Beyond simple price checks, it specializes in detecting main force signals during critical trading windows, such as the opening 30 minutes and the closing auction. Users can manage their investment portfolios directly through the CLI, calculating real-time profit and loss while analyzing the volume profile of their holdings to make informed trading decisions.

A-Share Stock Analysis & Portfolio Manager Use Cases

  • Query real-time quotes and price changes for specific A-Share stock symbols.
  • Analyze institutional capital flows and main force buying or selling signals based on volume distribution.
  • Monitor time-sharing K-line data to identify intraday high-volume breakouts.
  • Manage a personal stock portfolio with cost basis and quantity tracking.
  • Generate comprehensive P&L reports and volume analysis for all current holdings.

How A-Share Stock Analysis & Portfolio Manager Works

  1. The user provides a 6-digit stock code (e.g., 600789 for Shanghai or 002446 for Shenzhen).
  2. The skill fetches real-time market data from the Sina Finance API, ensuring low latency (~3 seconds for quotes).
  3. It processes time-sharing data to segment volume into specific periods such as Morning Opening, Mid-day, and Closing Auction.
  4. It calculates the percentage of daily volume occurring in key intervals to identify institutional entry or exit signals.
  5. For portfolio tasks, it reads and writes to a local JSON database to calculate real-time gains and losses based on current market prices.

A-Share Stock Analysis & Portfolio Manager Setup

Install the skill into your environment and use the following commands to get started with Openclaw Skills:

# Analyze a specific stock
uv run scripts/analyze.py 600789

# Analyze multiple stocks with time-sharing volume data
uv run scripts/analyze.py 600789 002446 --minute

# Add a stock to your portfolio tracking
uv run scripts/portfolio.py add 600789 --cost 10.416 --qty 3400

# View and analyze all portfolio holdings
uv run scripts/portfolio.py analyze

A-Share Stock Analysis & Portfolio Manager Data Schema & Taxonomy

The skill organizes its data efficiently using a local JSON structure for persistence and real-time API calls for market state.

Component Data Source Storage / Format
Real-time Quotes hq.sinajs.cn Live Fetch (3s delay)
Time-sharing Data MarketDataService 1-minute K-line
Portfolio Data portfolio.json ~/.clawdbot/skills/a-stock-analysis/

Portfolio Metadata:

  • code: 6-digit stock identifier.
  • cost: Average purchase price per share.
  • qty: Total number of shares held.
  • market: Automatically identified based on prefix (Shanghai, Shenzhen, or Beijing).

A-Share Stock Analysis & Portfolio Manager Advanced Features

  • Automated market identification for Shanghai (6xx), Shenzhen (0xx, 3xx), and Beijing (8xx, 4xx) exchanges.
  • Main force movement detection, such as identifying early "chip grabbing" when morning volume exceeds 30%.
  • TOP 10 high-volume minute identification for pinpointing exact moments of institutional entry or major news impact.
  • Bulk stock analysis support to query and compare multiple symbols in a single command execution.
  • JSON output mode for seamless integration with other Openclaw Skills or external automated trading scripts.

SKILL.md


Loading

Related Openclaw Skills

METADATA

Github Stars: 0
forks: 0

Featured*