Tooluck logoTooluck
SKILL.md

alphaear-stock

Agent skill fromRKiding/Awesome-finance-skills

Search A-Share/HK/US finance stock tickers and retrieve finance stock price history. Use when user asks about finance stock codes, recent price changes, or specific company finance stock info.

How to install alphaear-stock

install alphaear-stock
# install the Awesome-finance-skills pack with the skills CLI
npx skills add RKiding/Awesome-finance-skills

# or add only this skill to Claude Code: copy the folder

skills/alphaear-stock/

# into

~/.claude/skills/alphaear-stock/ (all projects)

.claude/skills/alphaear-stock/ (one project)

skills/alphaear-stock/SKILL.md

Apache-2.0Full file
1# AlphaEar Stock Skill
2
3## Overview
4
5Search A-Share/HK/US stock tickers and retrieve historical price data (OHLCV).
6
7## Capabilities
8
9### 1. Stock Search & Data
10
11Use `scripts/stock_tools.py` via `StockTools`.
12
13- **Search**: `search_ticker(query)`
14 - Fuzzy search by code or name (e.g., "Moutai", "600519").
15 - Returns: List of `{code, name}`.
16- **Get Price**: `get_stock_price(ticker, start_date, end_date)`
17 - Returns DataFrame with OHLCV data.
18 - Dates format: "YYYY-MM-DD".
19- **Get Fundamentals**: `get_stock_fundamentals(ticker)`
20 - Returns dict with sector, industry, market cap, PE ratio, and summary.
21 - Supports A-Share/HK/US stocks.
22
23## Dependencies
24
25- `pandas`, `requests`, `akshare`, `yfinance`
26- `scripts/database_manager.py` (stock tables)
27
28## Notes
29
30- **Proxy**: For US stock data (via `yfinance`), you may need to set environment variables if your network cannot reach Yahoo Finance directly:
31 ```bash
32 export HTTP_PROXY="http://<proxy_ip>:<port>"
33 export HTTPS_PROXY="http://<proxy_ip>:<port>"
34 ```
35- **A-Share/HK**: Data is primarily fetched via `akshare` (EastMoney), which usually works best with a direct connection in China. The tool automatically detects proxy issues and attempts direct connection for these markets.

Excerpt shown under the repository's Apache-2.0 license.

More skills in Awesome-finance-skills

Newsletter

Join the Community

Subscribe to our newsletter for the latest news and updates