About
a-share-mcp is a financial data service that provides comprehensive access to China's A-share stock market data through the Baostock data platform. Key features of a-share-mcp: - Historical K-line price data for individual stocks and market indices - Stock fundamental information and financial indicator queries - Macroeconomic data and broad market analytics - Support for both specific stock analysis and overall market trend questions - Integration with the Baostock financial data API for real-time and historical data retrieval
README
📊 a-share-mcp 📈
[](https://opensource.org/licenses/MIT) [](https://www.python.org/downloads/) [](https://github.com/astral-sh/uv) [](https://github.com/model-context-protocol/mcp-spec)
A股mcp。
本项目是一个基于专注于 A 股市场的 MCP 服务器,它提供股票基本信息、历史 K 线数据、财务指标、宏观经济数据等多种查询功能,理论上来说,可以回答有关 A 股市场的任何问题,无论是针对大盘还是特定股票。
项目结构
a_share_mcp/
│
├── mcp_server.py # 主服务器入口文件
├── pyproject.toml # 项目依赖配置
├── README.md # 项目说明文档
│
├── src/ # 源代码目录
│ ├── __init__.py
│ ├── baostock_data_source.py # Baostock数据源实现
│ ├── data_source_interface.py # 数据源接口定义
│ ├── utils.py # 通用工具函数
│ │
│ ├── formatting/ # 数据格式化模块
│ │ ├── __init__.py
│ │ └── markdown_formatter.py # Markdown格式化工具
│ │
│ └── tools/ # MCP工具模块
│ ├── __init__.py
│ ├── base.py # 基础工具函数
│ ├── stock_market.py # 股票市场数据工具
│ ├── financial_reports.py # 财务报表工具
│ ├── indices.py # 指数相关工具
│ ├── market_overview.py # 市场概览工具
│ ├── macroeconomic.py # 宏观经济数据工具
│ ├── date_utils.py # 日期工具
│ └── analysis.py # 分析工具
│
└── resource/ # 资源文件
└── img/ # 图片资源
├── img_1.png # CherryStudio配置示例
└── img_2.png # CherryStudio配置示例
功能特点
股票基础数据 历史行情数据 财务报表数据 宏观经济数据 指数成分股 数据分析报告
先决条件
1. Python 环境: Python 3.10+
2. 依赖管理: 使用 uv 包管理器安装依赖
3. 数据来源: 基于 Baostock 数据源,无需付费账号。在此感谢 Baostock。
4. 提醒:本项目于 Windows 环境下开发。
数据更新时间
> 以下是 Baostock 官方数据更新时间,请注意查询最新数据时的时间点 Baostock 官网
每日数据更新时间:
Related MCP Servers
AI Research Assistant
hamid-vakilzadeh
AI Research Assistant provides comprehensive access to millions of academic papers through the Semantic Scholar and arXiv databases. This MCP server enables AI coding assistants to perform intelligent literature searches, citation network analysis, and paper content extraction without requiring an API key. Key features include: - Advanced paper search with multi-filter support by year ranges, citation thresholds, field of study, and publication type - Title matching with confidence scoring for finding specific papers - Batch operations supporting up to 500 papers per request - Citation analysis and network exploration for understanding research relationships - Full-text PDF extraction from arXiv and Wiley open-access content (Wiley TDM token required for institutional access) - Rate limits of 100 requests per 5 minutes with options to request higher limits through Semantic Scholar
Linkup
LinkupPlatform
Linkup is a real-time web search and content extraction service that enables AI assistants to search the web and retrieve information from trusted sources. It provides source-backed answers with citations, making it ideal for fact-checking, news gathering, and research tasks. Key features of Linkup: - Real-time web search using natural language queries to find current information, news, and data - Page fetching to extract and read content from any webpage URL - Search depth modes: Standard for direct-answer queries and Deep for complex research across multiple sources - Source-backed results with citations and context from relevant, trustworthy websites - JavaScript rendering support for accessing dynamic content on JavaScript-heavy pages
Math-MCP
EthanHenrickson
Math-MCP is a computation server that enables Large Language Models (LLMs) to perform accurate numerical calculations through the Model Context Protocol. It provides precise mathematical operations via a simple API to overcome LLM limitations in arithmetic and statistical reasoning. Key features of Math-MCP: - Basic arithmetic operations: addition, subtraction, multiplication, division, modulo, and bulk summation - Statistical analysis functions: mean, median, mode, minimum, and maximum calculations - Rounding utilities: floor, ceiling, and nearest integer rounding - Trigonometric functions: sine, cosine, tangent, and their inverses with degrees and radians conversion support