Agent skill

AKShare Financial Data

by HKUDS in HKUDS/Vibe-Trading

Pulls free market data from the AKShare Python library: A-share, US and Hong Kong prices, futures, China macro series and forex, with notes on symbol formats and Chinese column names.

MITAuto-check passedBusiness, Finance & HR

Install AKShare Financial Data

skills CLI
$ npx skills add HKUDS/Vibe-Trading --skill akshare -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install HKUDS/Vibe-Trading akshare --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/HKUDS/Vibe-Trading.git skills-src && mkdir -p .claude/skills && cp -r skills-src/agent/src/skills/akshare .claude/skills/akshare && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
akshare
GitHub stars
35k
Token cost
~777 tokens
SKILL.md length
246 words
Files
1
Skills in repo
89
Repo updated
First seen
Licence
MIT

At a glance

Pulls free market data from the AKShare Python library: A-share, US and Hong Kong prices, futures, China macro series and forex, with notes on symbol formats and Chinese column names.

  • Fetching daily A-share price history without an API key
  • SKILL.md covers Overview, Quick Start, Top 10 High-Frequency Interfaces and Column Names, plus 4 more sections
  • Calls pip
  • Pulling US or Hong Kong stock history through AKShare

What it does

AKShare is a free, open-source Python library that needs no registration or API key and gathers data from public Chinese sources. The skill lists its most used functions: stock_zh_a_hist and stock_zh_a_spot_em for A-shares, stock_us_hist and stock_hk_hist for US and Hong Kong stocks, macro functions for China GDP and CPI, a futures main-contract function and a forex rates function.

It also records the quirks that trip people up. Data frames come back with Chinese column names that map to date, open, high, low, close and volume, dates go in as YYYYMMDD strings, A-share symbols are plain digits, US symbols carry an exchange prefix such as 105.AAPL and Hong Kong symbols are zero-padded to five digits. In the project's backtest runner, AKShare is the automatic fallback when tushare or yfinance are unavailable.

When your agent uses it

  • Fetching daily A-share price history without an API key
  • Pulling US or Hong Kong stock history through AKShare
  • Getting China GDP, CPI, futures or forex data
  • Falling back to AKShare when tushare or yfinance is unavailable

Example prompts

  • “Download daily prices for 000001 from 20240101 to today with AKShare.”
  • “Get China's CPI series with AKShare and plot it.”
  • “Fetch Tencent's Hong Kong price history using symbol 00700.”
  • “Translate the Chinese column names in this AKShare data frame to English.”

Requirements

  • Python with the akshare package (pip install akshare)
  • Network access to public data sources

What it can do on your machine

Read from SKILL.md and the folder at commit e532650. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • pip

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    Links to these hosts (documentation or services it may open):

    • github.com
    • akshare.akfamily.xyz

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

AKShare Financial Data loads about 777 tokens when it runs. Until then it costs about 41 tokens; SKILL.md has 246 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~41
When it runs · the whole SKILL.md, loaded when a task matches
~777

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from HKUDS/Vibe-Trading at commit e532650, republished under its MIT licence (© HKUDS). 246 words, ~777 tokens.

Download SKILL.mdSave it as .claude/skills/akshare/SKILL.md (or your agent's skills folder).
name
akshare
description
AKShare financial data aggregator (18k+ stars). Free, no API key. Covers A-shares, US, HK, futures, macro, forex. Primary fallback for tushare and yfinance.
category
data-source

Overview

AKShare is a completely free, open-source Python financial data library. No registration or API key required. It aggregates data from public sources (Sina, East Money, etc.) covering Chinese and global markets.

Quick Start

python
import akshare as ak

# A-share daily OHLCV (前复权)
df = ak.stock_zh_a_hist(symbol="000001", period="daily",
                         start_date="20240101", end_date="20260101", adjust="qfq")

# US stock daily
df = ak.stock_us_hist(symbol="105.AAPL", period="daily",
                       start_date="20240101", end_date="20260101", adjust="qfq")

# HK stock daily
df = ak.stock_hk_hist(symbol="00700", period="daily",
                       start_date="20240101", end_date="20260101", adjust="qfq")

Top 10 High-Frequency Interfaces

A-shares
FunctionDescriptionKey Params
stock_zh_a_hist()A-share OHLCVsymbol, period, start_date, end_date, adjust
stock_zh_a_spot_em()Real-time A-share quotes(none)
stock_individual_info_em()Stock basic infosymbol
stock_zh_a_hist_min_em()Intraday barssymbol, period(1/5/15/30/60)
US / HK
FunctionDescriptionKey Params
stock_us_hist()US stock OHLCVsymbol (e.g. "105.AAPL"), period, start_date, end_date
stock_hk_hist()HK stock OHLCVsymbol (e.g. "00700"), period, start_date, end_date
Macro / Forex / Futures
FunctionDescription
macro_china_gdp()China GDP data
macro_china_cpi()China CPI data
futures_main_sina()Futures main contract quotes
currency_boc_sina()BOC forex rates

Column Names

AKShare returns Chinese column names by default:

ChineseEnglishDescription
日期dateTrade date
开盘openOpen price
最高highHigh price
最低lowLow price
收盘closeClose price
成交量volumeVolume
成交额amountTurnover
涨跌幅pct_change% change
换手率turnover_rateTurnover rate

Date Format

  • Input: YYYYMMDD string (e.g. "20240101")
  • Output: 日期 column as string, convert with pd.to_datetime()

Symbol Format

  • A-shares: pure digits "000001" (no .SZ suffix)
  • US stocks: "105.AAPL" (NASDAQ prefix 105), "106.BABA" (NYSE prefix 106)
  • HK stocks: "00700" (5-digit zero-padded)

Built-in Loader

The project has a built-in AKShare DataLoader at backtest/loaders/akshare_loader.py. When backtesting, the runner automatically falls back to AKShare when tushare/yfinance are unavailable.

Reference Docs

For less common interfaces, see the references/ subdirectory or the official docs at https://akshare.akfamily.xyz/

© HKUDS, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in agent/src/skills/akshare of HKUDS/Vibe-Trading.

Open the folder on GitHubat commit e532650

Compare with similar skills

AKShare Financial Data next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

AKShare Financial Data compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
AKShare Financial Data this skillHKUDS/Vibe-Trading35k—~777Automated safety check: PassMIT
US Market Data ToolkitGeeksfino/finskills283—~1.2kAutomated safety check: PassApache-2.0
Value Stock Screenerokikusan-public/stock_skills135—~2.4kAutomated safety check: PassNone
Yfinance Datahimself65/finance-skills3.4k—~1.3kAutomated safety check: PassMIT
Fin Yfinance Datacriptogus/agent-evolve-network288—~806Automated safety check: PassMIT
A-Share Daily Reviewqusong0627/QuantMind1.7k—~1.9kAutomated safety check: PassAGPL-3.0

Similar skills

  • US Market Data Toolkit

    Geeksfino/finskills

    Free Python scripts that fetch US stock data, SEC filings, insider trades and macro indicators, and run financial score calculators and portfolio analytics.

    283 GitHub stars~1.2k tokensUpdated 7 mo ago
    Business, Finance & HRAuto-check passed
  • Value Stock Screener

    okikusan-public/stock_skills

    Screens for undervalued stocks across about 60 regions with yfinance's EquityQuery, using ratios such as PER, PBR, dividend yield and ROE, with optional theme filters.

    135 GitHub stars~2.4k tokensUpdated 5 mo ago
    Business, Finance & HRAuto-check passed
  • Yfinance Data

    himself65/finance-skills

    Fetch financial and market data with the yfinance Python library (Yahoo Finance).

    3.4k GitHub stars~1.3k tokensUpdated 4 days ago
    Business, Finance & HRAuto-check passed
  • Fin Yfinance Data

    criptogus/agent-evolve-network

    Fetch market and fundamental data via the yfinance Python library — quotes, OHLC history, financial statements, holders, dividends, options, and more.

    288 GitHub stars~806 tokensUpdated today
    Business, Finance & HRAuto-check passed
  • A-Share Daily Review

    qusong0627/QuantMind

    Produces a post-market review report for the China A-share market from local QuantDB data, news sentiment and model signals, ending in a next-day direction call.

    1.7k GitHub stars~1.9k tokensUpdated today
    Business, Finance & HRAuto-check passed
  • Financial Research

    firecrawl/web-agent

    Pulls a public company's latest 10-K or 10-Q figures and analyst consensus from SEC EDGAR and Yahoo Finance, then cross-checks the two sources.

    1.2k GitHub stars~1.1k tokensUpdated 5 mo ago
    Business, Finance & HRAuto-check passed

More from HKUDS/Vibe-Trading

All 89 skills in this repo
  • Eastmoney Market Data

    HKUDS/Vibe-Trading

    Index of Eastmoney's free, no-token market data interfaces for China A-shares and Hong Kong stocks: fund flows, dragon-tiger lists, margin trading, reports and news.

    35k GitHub stars~1k tokensUpdated today
    Auto-check passed
  • OKX Market Data

    HKUDS/Vibe-Trading

    Retrieves public OKX cryptocurrency market data such as spot prices, candlesticks, funding rates and open interest through the OKX V5 REST API, with no authentication.

    35k GitHub stars~1.3k tokensUpdated today
    Auto-check passed
  • SEC EDGAR Filings Fetcher

    HKUDS/Vibe-Trading

    Fetches U.S. SEC EDGAR data: resolves tickers to CIK numbers, lists recent 10-K, 10-Q and 8-K filings with document URLs, and pulls XBRL financial series.

    35k GitHub stars~1.4k tokensUpdated today
    Auto-check passed
  • A-Share ST Risk Screener

    HKUDS/Vibe-Trading

    Predicts whether a mainland China A-share company risks an ST or *ST warning after its next annual report, using financial thresholds and Sina penalty records.

    35k GitHub stars~4.9k tokensUpdated today
    Auto-check passed
  • Breaks a structural trend such as AI infrastructure into its physical supply chain and ranks lesser-known listed companies sitting on each bottleneck.

    35k GitHub stars~2.7k tokensUpdated today
    Auto-check passed
  • Plans and drafts an eight-part, roughly 120k-word investigative series on one company, built around a strict fact-check pass rather than fast drafting.

    35k GitHub stars~2.4k tokensUpdated today
    Auto-check passed

Works with

Questions about AKShare Financial Data

What does AKShare Financial Data do?

Pulls free market data from the AKShare Python library: A-share, US and Hong Kong prices, futures, China macro series and forex, with notes on symbol formats and Chinese column names. AKShare is a free, open-source Python library that needs no registration or API key and gathers data from public Chinese sources. The skill lists its most used functions: stock_zh_a_hist and stock_zh_a_spot_em for A-shares, stock_us_hist and stock_hk_hist for US and Hong Kong stocks, macro functions for China GDP and CPI, a futures main-contract function and a forex rates function.

When should I use AKShare Financial Data?

AKShare Financial Data fits situations like: fetching daily A-share price history without an API key; pulling US or Hong Kong stock history through AKShare; getting China GDP, CPI, futures or forex data; falling back to AKShare when tushare or yfinance is unavailable.

How do I install AKShare Financial Data in Claude Code?

Run `npx skills add HKUDS/Vibe-Trading --skill akshare -a claude-code`. Or copy the skill folder (agent/src/skills/akshare in HKUDS/Vibe-Trading) into .claude/skills/akshare in your project. Claude Code loads it when a task matches its description.

How do I install AKShare Financial Data in Codex?

Run `npx skills add HKUDS/Vibe-Trading --skill akshare -a codex`. Or copy the skill folder (agent/src/skills/akshare in HKUDS/Vibe-Trading) into .agents/skills/akshare in your project. Codex loads it when a task matches its description.

Can I use AKShare Financial Data in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add HKUDS/Vibe-Trading --skill akshare -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/akshare, .gemini/skills/akshare, .github/skills/akshare and .opencode/skills/akshare in your project.

What does AKShare Financial Data need to run?

Going by SKILL.md and its folder, AKShare Financial Data needs the command-line tools its instructions call (pip). Our summary lists: Python with the akshare package (pip install akshare); Network access to public data sources.

Does AKShare Financial Data access the network?

SKILL.md names 2 domains. As links in the text: github.com and akshare.akfamily.xyz. This is read from the text; nothing was executed.

Is AKShare Financial Data safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does AKShare Financial Data use?

AKShare Financial Data is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does AKShare Financial Data use?

About 777 tokens (SKILL.md is roughly 3.1k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to AKShare Financial Data?

Skills that share tags, products or a category with AKShare Financial Data: US Market Data Toolkit (Geeksfino/finskills, 283 stars), Value Stock Screener (okikusan-public/stock_skills, 135 stars), Yfinance Data (himself65/finance-skills, 3.4k stars) and Fin Yfinance Data (criptogus/agent-evolve-network, 288 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains AKShare Financial Data?

HKUDS (a GitHub organization) maintains it in HKUDS/Vibe-Trading, which has 35,043 GitHub stars. The repository holds 89 skills in this directory. The repository was last updated on October 8, 2026.

Source: HKUDS/Vibe-Trading on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.