ClawHub
SkillsPluginsTemplatesDocsSupport
K
SkillsA Share Pro

A Share Pro

wran93409@wran93409
Install in OpenClaw
Requires OpenClaw desktop app
A 股专业监控工具 - 轻量级自选股管理 + 多数据源实时行情。支持腾讯财经/雪球/百度/Tushare 自动切换,纯文本存储,无需数据库依赖。用于日常股票跟踪、自选股管理和投资组合监控。
Security check
Review
Version
1.0.0
Updated
May 11, 2026

Latest: v1.0.0

  • 首发版本,功能完整,专为 A 股用户设计的自选股监控与管理工具
  • 支持多数据源智能切换(腾讯财经/雪球/百度/Tushare),主要使用免费接口
  • 纯文本本地存储,无需数据库,轻松安装与迁移
  • 提供自选股添加、列表查看、行情汇总、持仓导出等基础功能
  • 支持命令行批量操作及定时任务
  • 配置灵活,便于自定义与拓展
FinanceIntegrations
#数据库#投资组合#投资#股票

A-Share Pro - A 股投资监控终极版

🎯 核心特性

特性说明
✅ 轻量级纯文本存储,无需数据库
✅ 多数据源腾讯/雪球/百度/Tushare 自动切换
✅ 持久化自选股/交易记录本地保存
✅ 易维护统一配置 + 模块化脚本
✅ 无 Token 依赖主要使用免费数据源

🚀 快速开始

1️⃣ 安装

bash
cd ~/.openclaw/workspace/skills/a-share-pro/scripts
chmod +x install.sh
./install.sh

会自动完成:

  • ✅ 创建 ~/.openclaw/a_share/ 数据目录
  • ✅ 安装 Python 依赖(requests, beautifulsoup4)
  • ✅ 测试基本功能

2️⃣ 添加股票

bash
# 方式一:只输入代码(名称默认"未知")
python3 add_stock.py 600919

# 方式二:指定股票名称
python3 add_stock.py 600919 江苏银行

3️⃣ 查看自选股列表

bash
python3 list_stocks.py

输出示例:

text
📋 你的自选股:
==================================================
序号   代码         名称
--------------------------------------------------
1      600919       江苏银行
2      600926       杭州银行
3      159681       创业板 ETF
==================================================
共计 3 只股票

4️⃣ 获取行情汇总

bash
python3 summarize_performance.py

输出示例:

text
======================================================================
💼 A-Share Pro - 自选股实时行情
======================================================================
✅ 600919 - 江苏银行
   💰 ¥10.59  +0.10  (+0.95% ) [🐧 腾讯财经]
✅ 600926 - 杭州银行
   💰 ¥16.57  +0.08  (+0.49% ) [🐧 腾讯财经]
...

======================================================================
📊 持仓概览:3 只 | 上涨:3 只 | 下跌:0 只
📉 平均涨跌幅:+1.46%
💡 整体趋势:📈 整体偏强
======================================================================

📁 文件结构

text
a-share-pro/
├── SKILL.md                    # 主文档
├── README.md                   # 使用说明
└── scripts/
    ├── config.py               # ⭐ 统一配置
    ├── monitor.py              # ⭐ 核心监控模块
    │
    ├── add_stock.py            # 添加股票
    ├── remove_stock.py         # 删除股票
    ├── list_stocks.py          # 查看列表
    ├── clear_watchlist.py      # 清空列表
    ├── summarize_performance.py# ⭐ 行情汇总
    │
    └── install.sh / uninstall.sh

🔧 高级用法

从命令行导入多个股票

bash
# 批量添加
for code in 600919 600926 600025; do
    python3 add_stock.py $code
done

每日定时检查

bash
# 添加到 crontab(每天收盘后 15:30)
# crontab -e
30 15 * * * cd ~/.openclaw/workspace/skills/a-share-pro/scripts && python3 summarize_performance.py

导出数据到 Excel

python
# 自定义脚本导出
import pandas as pd

stocks = ['600919', '600926']
data = []

for code in stocks:
    from monitor import AShareMonitor
    monitor = AShareMonitor()
    quote = monitor.get_quote(code)
    data.append(quote)

df = pd.DataFrame(data)
df.to_excel('持仓报告.xlsx', index=False)

📊 数据存储格式

watchlist.txt(自选股列表)

text
600919|江苏银行
600926|杭州银行
159681|创业板 ETF

每行格式:代码 | 名称


transactions.txt(交易记录)

text
2026-03-05|600919|buy|7.80|5000|备注
2026-03-01|600926|sell|8.50|1000|部分止盈

每行格式:日期 | 代码 | 买卖 | 价格 | 数量 | 备注


🎨 数据源优先级

系统会自动按以下顺序尝试获取数据:

  1. 🐧 腾讯财经 - 最快最稳定(首选)
  2. 📱 雪球 - 有市值/市盈率信息
  3. 🔍 百度股市通 - JSON 格式易解析
  4. 📈 Tushare - 需要积分(备选)

❓ 常见问题

Q1: 如何修改配置文件?

编辑 scripts/config.py:

python
WATCHLIST_FILE = "~/.openclaw/a_share/watchlist.txt"
DATA_SOURCES_PRIORITY = ["tencent", "xueqiu"]  # 只用腾讯和雪球
REQUEST_DELAY = 0.5  # 请求间隔改为 0.5 秒

Q2: 如何重置自选股?

直接编辑数据文件:

bash
nano ~/.openclaw/a_share/watchlist.txt
# 手动添加/删除股票,或使用 clear_watchlist.py 清空

Q3: 能否查询港股/美股?

目前仅支持 A 股(沪市/深市/科创板)。如需港股/美股,建议增加 Yahoo Finance 或新浪财经接口。


🔮 未来扩展方向

  • 技术指标计算(MA/MACD/KDJ)
  • K 线图表绘制
  • 智能提醒(突破价位推送)
  • 持仓盈亏计算(需要成本价)
  • 新闻资讯聚合
  • Web 可视化界面(Streamlit)

A-Share Pro ✨
让 AI 成为你的得力投资助手 📈🤖

Related skills

More in Finance
ClawHub

Skills and plugins for OpenClaw agents. Part of the wider OpenClaw ecosystem.

Explore docs

SkillsPluginsTemplatesOfficialAudits

Publish SkillPublish PluginCreate org

OverviewOpenClawDocsBlog

SupportGitHubDiscord

Built alongside the OpenClaw ecosystem

LobsterCrabboxClickClackCrabfleetOctopoolClawSweeperagent-skillsdiscrawlgitcrawlslacrawlnotcrawltelecrawlgraincrawlcrawlkitcrawlbaracpxmcporterTachikomaclawpatchclawbenchPeekaboocookbookplugin-inspectorwacrawlcrabpotAll projectsLobsterCrabboxClickClackCrabfleetOctopoolClawSweeperagent-skillsdiscrawlgitcrawlslacrawlnotcrawltelecrawlgraincrawlcrawlkitcrawlbaracpxmcporterTachikomaclawpatchclawbenchPeekaboocookbookplugin-inspectorwacrawlcrabpotAll projects

© 2026 OpenClaw Foundation

Privacy policy·Status·Deployed on Vercel·Powered by Convex

....:: clawhub/openclaw ::....  skills plugins publishers trust signals   :::: signed manifests ::::: moderated releases ::::: version history ::::   openclaw ecosystem    crabbox clickclack crawler packs gateway plugins
>>> install scan publish verify    @@ gateway @@ registry @@ agents @@     hooks runners slash-commands skill.md templates scanners review-bots   ---- downloads installs stars lineage ownership docs package integrity
  30 skills 12 plugins    /api/v1/skills   /owners   /audit   /ship   openclaw ecosystem    crabbox clickclack crawler packs gateway plugins     safe browse paths   official gateways   publisher handles   org trust
:::: signed manifests ::::: moderated releases ::::: version history ::::   ---- downloads installs stars lineage ownership docs package integrity   ....:: clawhub/openclaw ::....  skills plugins publishers trust signals
  hooks runners slash-commands skill.md templates scanners review-bots     safe browse paths   official gateways   publisher handles   org trust   >>> install scan publish verify    @@ gateway @@ registry @@ agents @@
openclaw ecosystem    crabbox clickclack crawler packs gateway plugins   ....:: clawhub/openclaw ::....  skills plugins publishers trust signals     30 skills 12 plugins    /api/v1/skills   /owners   /audit   /ship
---- downloads installs stars lineage ownership docs package integrity   >>> install scan publish verify    @@ gateway @@ registry @@ agents @@   :::: signed manifests ::::: moderated releases ::::: version history ::::
  safe browse paths   official gateways   publisher handles   org trust     30 skills 12 plugins    /api/v1/skills   /owners   /audit   /ship     hooks runners slash-commands skill.md templates scanners review-bots
....:: clawhub/openclaw ::....  skills plugins publishers trust signals   :::: signed manifests ::::: moderated releases ::::: version history ::::   openclaw ecosystem    crabbox clickclack crawler packs gateway plugins
>>> install scan publish verify    @@ gateway @@ registry @@ agents @@     hooks runners slash-commands skill.md templates scanners review-bots   ---- downloads installs stars lineage ownership docs package integrity
  30 skills 12 plugins    /api/v1/skills   /owners   /audit   /ship   openclaw ecosystem    crabbox clickclack crawler packs gateway plugins     safe browse paths   official gateways   publisher handles   org trust
:::: signed manifests ::::: moderated releases ::::: version history ::::   ---- downloads installs stars lineage ownership docs package integrity   ....:: clawhub/openclaw ::....  skills plugins publishers trust signals
  hooks runners slash-commands skill.md templates scanners review-bots     safe browse paths   official gateways   publisher handles   org trust   >>> install scan publish verify    @@ gateway @@ registry @@ agents @@
openclaw ecosystem    crabbox clickclack crawler packs gateway plugins   ....:: clawhub/openclaw ::....  skills plugins publishers trust signals     30 skills 12 plugins    /api/v1/skills   /owners   /audit   /ship
---- downloads installs stars lineage ownership docs package integrity   >>> install scan publish verify    @@ gateway @@ registry @@ agents @@   :::: signed manifests ::::: moderated releases ::::: version history ::::
  safe browse paths   official gateways   publisher handles   org trust     30 skills 12 plugins    /api/v1/skills   /owners   /audit   /ship     hooks runners slash-commands skill.md templates scanners review-bots
....:: clawhub/openclaw ::....  skills plugins publishers trust signals   :::: signed manifests ::::: moderated releases ::::: version history ::::   openclaw ecosystem    crabbox clickclack crawler packs gateway plugins
>>> install scan publish verify    @@ gateway @@ registry @@ agents @@     hooks runners slash-commands skill.md templates scanners review-bots   ---- downloads installs stars lineage ownership docs package integrity
  30 skills 12 plugins    /api/v1/skills   /owners   /audit   /ship   openclaw ecosystem    crabbox clickclack crawler packs gateway plugins     safe browse paths   official gateways   publisher handles   org trust
:::: signed manifests ::::: moderated releases ::::: version history ::::   ---- downloads installs stars lineage ownership docs package integrity   ....:: clawhub/openclaw ::....  skills plugins publishers trust signals
  hooks runners slash-commands skill.md templates scanners review-bots     safe browse paths   official gateways   publisher handles   org trust   >>> install scan publish verify    @@ gateway @@ registry @@ agents @@
openclaw ecosystem    crabbox clickclack crawler packs gateway plugins   ....:: clawhub/openclaw ::....  skills plugins publishers trust signals     30 skills 12 plugins    /api/v1/skills   /owners   /audit   /ship
---- downloads installs stars lineage ownership docs package integrity   >>> install scan publish verify    @@ gateway @@ registry @@ agents @@   :::: signed manifests ::::: moderated releases ::::: version history ::::
  safe browse paths   official gateways   publisher handles   org trust     30 skills 12 plugins    /api/v1/skills   /owners   /audit   /ship     hooks runners slash-commands skill.md templates scanners review-bots
....:: clawhub/openclaw ::....  skills plugins publishers trust signals   :::: signed manifests ::::: moderated releases ::::: version history ::::   openclaw ecosystem    crabbox clickclack crawler packs gateway plugins
>>> install scan publish verify    @@ gateway @@ registry @@ agents @@     hooks runners slash-commands skill.md templates scanners review-bots   ---- downloads installs stars lineage ownership docs package integrity
  30 skills 12 plugins    /api/v1/skills   /owners   /audit   /ship   openclaw ecosystem    crabbox clickclack crawler packs gateway plugins     safe browse paths   official gateways   publisher handles   org trust
:::: signed manifests ::::: moderated releases ::::: version history ::::   ---- downloads installs stars lineage ownership docs package integrity   ....:: clawhub/openclaw ::....  skills plugins publishers trust signals
  hooks runners slash-commands skill.md templates scanners review-bots     safe browse paths   official gateways   publisher handles   org trust   >>> install scan publish verify    @@ gateway @@ registry @@ agents @@
openclaw ecosystem    crabbox clickclack crawler packs gateway plugins   ....:: clawhub/openclaw ::....  skills plugins publishers trust signals     30 skills 12 plugins    /api/v1/skills   /owners   /audit   /ship
---- downloads installs stars lineage ownership docs package integrity   >>> install scan publish verify    @@ gateway @@ registry @@ agents @@   :::: signed manifests ::::: moderated releases ::::: version history ::::
  safe browse paths   official gateways   publisher handles   org trust     30 skills 12 plugins    /api/v1/skills   /owners   /audit   /ship     hooks runners slash-commands skill.md templates scanners review-bots
....:: clawhub/openclaw ::....  skills plugins publishers trust signals   :::: signed manifests ::::: moderated releases ::::: version history ::::   openclaw ecosystem    crabbox clickclack crawler packs gateway plugins
>>> install scan publish verify    @@ gateway @@ registry @@ agents @@     hooks runners slash-commands skill.md templates scanners review-bots   ---- downloads installs stars lineage ownership docs package integrity
  30 skills 12 plugins    /api/v1/skills   /owners   /audit   /ship   openclaw ecosystem    crabbox clickclack crawler packs gateway plugins     safe browse paths   official gateways   publisher handles   org trust
:::: signed manifests ::::: moderated releases ::::: version history ::::   ---- downloads installs stars lineage ownership docs package integrity   ....:: clawhub/openclaw ::....  skills plugins publishers trust signals
  hooks runners slash-commands skill.md templates scanners review-bots     safe browse paths   official gateways   publisher handles   org trust   >>> install scan publish verify    @@ gateway @@ registry @@ agents @@
openclaw ecosystem    crabbox clickclack crawler packs gateway plugins   ....:: clawhub/openclaw ::....  skills plugins publishers trust signals     30 skills 12 plugins    /api/v1/skills   /owners   /audit   /ship
---- downloads installs stars lineage ownership docs package integrity   >>> install scan publish verify    @@ gateway @@ registry @@ agents @@   :::: signed manifests ::::: moderated releases ::::: version history ::::
  safe browse paths   official gateways   publisher handles   org trust     30 skills 12 plugins    /api/v1/skills   /owners   /audit   /ship     hooks runners slash-commands skill.md templates scanners review-bots
....:: clawhub/openclaw ::....  skills plugins publishers trust signals   :::: signed manifests ::::: moderated releases ::::: version history ::::   openclaw ecosystem    crabbox clickclack crawler packs gateway plugins
>>> install scan publish verify    @@ gateway @@ registry @@ agents @@     hooks runners slash-commands skill.md templates scanners review-bots   ---- downloads installs stars lineage ownership docs package integrity
  30 skills 12 plugins    /api/v1/skills   /owners   /audit   /ship   openclaw ecosystem    crabbox clickclack crawler packs gateway plugins     safe browse paths   official gateways   publisher handles   org trust
:::: signed manifests ::::: moderated releases ::::: version history ::::   ---- downloads installs stars lineage ownership docs package integrity   ....:: clawhub/openclaw ::....  skills plugins publishers trust signals