local-datasource
Provides tools to search and retrieve academic papers from arXiv, including titles, authors, abstracts, and PDF links, with structured CSV output.
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@local-datasourceget AAPL stock data for the past 6 months"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Local Datasource
一个本地运行的 MCP(Model Context Protocol)数据服务器。它让任何支持 MCP 的 Agent(Claude Code、Codex、Cursor、OpenCode 等)都能直接查询金融市场、宏观经济和学术论文数据,而无需第三方账号、不消耗云额度、不经过外部中继。
一句话介绍
local-datasource 把 akshare、yfinance、wbgapi、arxiv 等免费公开接口封装成 16 个标准 MCP tool,覆盖 A股/港股/美股/ETF/期货/指数/期权行情、债券与可转债、全球利率与波动率(美债收益率/美联储利率/美元指数/VIX)、汇率、商品现货、带生效区间的交易规则参数表、多序列对齐合并、世界银行宏观指标与 arXiv 论文,Agent 只需要像调用本地函数一样请求数据,即可获得结构化 CSV 输出。
Related MCP server: MCP Financial Data Gateway
为什么需要这个项目
在日常投研、尽调、学术检索或自动化报告生成中,Agent 经常需要实时数据:
查一只股票过去一年的走势
对比黄金、美股、A股等多资产表现
拉取某个国家的 GDP/CPI 数据
检索某个领域的 arXiv 论文
这些需求本身并不复杂,但常见方案要么需要登录某个平台并消耗额度,要么把查询请求发到云端。local-datasource 希望提供一种透明、可控、低成本的替代方案:
数据请求不出本机:适合对合规、隐私敏感的场景。
无需账号和额度:基于公开接口,安装完就能用。
标准 MCP 协议:不绑定任何特定 Agent,可被多家产品复用。
源码可见、可扩展:增加新数据源或调整输出格式都很直接。
核心特点
✅ A股 / 港股 / 美股:日线行情,支持前复权/后复权。
✅ 美股 / 美股 ETF / 全球资产:默认
akshare美股接口,可回退yfinance(A股场内 ETF 见query_etf)。✅ 世界银行宏观指标:GDP、CPI、人口等。
✅ arXiv 论文搜索:标题、作者、摘要、PDF 链接结构化输出。
✅ 中国境内债券:国债收益率曲线、信用债发行信息(按代码或发行人查)、交易所行情。
✅ 可转债:一览含溢价率、强赎/回售条款、历史K线、发行人正股财务报表。
✅ 国内期货:单合约(全历史)/主连日线与分钟、品种挂牌合约清单。
✅ 国内指数:沪深指数(2014 起)与中证系列日线,沪深指数分钟。
✅ A股场内 ETF:日线(2012 起全历史)与分钟。
✅ 期权:ETF 期权与股指期权(IO/HO/MO)的到期月份、合约清单、单合约日线。
✅ A股个股分钟:
query_stock(period=min),与日线同一入口。✅ 全球利率与波动率:美债收益率曲线、美联储 EFFR、美元指数(东财失败回退 Yahoo)、VIX(CBOE 直连)。
✅ 汇率:央行官方中间价、中行牌价、离岸 USDCNH、主要货币对交叉盘。
✅ 商品现货:上金所贵金属日线、生意社大宗现货(含主力合约价与基差)。
✅ 对齐合并:多份本库产出的 CSV 按日期合并成宽表(支持周/月重采样),纯本地计算。
✅ 交易规则参数表:印花税/过户费/涨跌幅/保证金/T+1 等参数按
as_of取当日生效值(含生效区间、来源与四档置信度标注);商品期货参数不入表、返回查交易所当日结算参数的引导。✅ 金融输入归一化:股票/债券的名称、简称、全称、发行人 → 统一代码(
resolve_stock_code+bond_issue)。✅ 统一 CSV 输出:每个 tool 都把结果写到
file_path,并返回前 5 行预览。✅ 零 API Key:所有默认数据源均免费使用。
✅ 跨 Agent 复用:标准 MCP Server,配置一条
command即可接入。
适用人群
需要在 Agent 工作流里频繁查数据的投研、分析师、开发者。
不希望把查询请求发送到云端的本地优先用户。
想学习/定制 MCP 数据服务器实现的开发者。
快速开始
要求:Python >= 3.10。
# 1. 克隆并安装
git clone https://github.com/jarvislee90s-dot/local-datasource.git
cd local-datasource
pip install -e .
# 2. 启动 MCP 服务
local-datasource
# 3. 在 Agent 的 MCP 配置中添加
{
"mcpServers": {
"local-datasource": {
"command": "local-datasource"
}
}
}覆盖范围
数据类型 | 工具 | 底层接口 | 是否需 API Key |
A股(日线含换手率/流通股本/成交额,分钟)/ 港股 / 美股 历史行情 |
|
| 否 |
美股 / 美股 ETF / 全球资产 |
|
| 否 |
世界银行宏观指标 |
|
| 否 |
arXiv 学术论文 |
|
| 否 |
中国境内债券(国债收益率曲线/信用债发行信息/交易所行情) |
|
| 否 |
可转债(一览/条款/历史K线/发行人财务) |
|
| 否 |
股票名称(简称/全称)→ 代码候选 |
| 新浪 suggest API / | 否 |
国内期货(单合约/主连行情、合约清单) |
|
| 否 |
国内指数(沪深/中证系列,日线/分钟) |
|
| 否 |
A股场内 ETF(日线/分钟) |
|
| 否 |
期权(ETF期权/股指期权:月份/清单/日线) |
|
| 否 |
美债收益率/美联储 EFFR/美元指数/VIX(全球利率与波动率) |
| 东财数据中心 / 新浪 / 纽约联储 / CBOE / yfinance(回退) | 否 |
汇率(官方中间价/中行牌价/离岸 USDCNH/主要货币对) |
| 外汇局 / 新浪 / yfinance | 否 |
商品现货(上金所贵金属/生意社大宗含基差) |
|
| 否 |
多序列对齐合并(宽表/重采样,纯本地) |
| 本地 | 否 |
交易规则参数(税费/涨跌幅/保证金/T+1 等,按生效区间) |
| 包内静态表(附录 B 调研) | 否 |
金融输入归一化
用户给金融标的时可能贴代码、简称、全称或发行人名。本服务支持先把输入归一化为统一代码再查询:
股票:公司简称/全称 →
resolve_stock_code→ 代码候选 →query_stock(新浪 suggest API 支持全称反查)标债:发行人名 →
query_bond(kind=issue_info, bond_issue=...)→ 最新一只债代码 → 继续查基本信息/财务可转债:正股简称 →
query_convertible_bond(kind=overview, keyword=...)→ 该公司转债发行人财务:任意债代码/发行人名 → 先归一化到代码 →
query_convertible_bond(kind=issuer_finance, ...)期货:直接给合约/主连代码(
IM2612/IM0/IM主连自动归一);查挂牌合约用query_futures(kind=contracts, symbol=品种如IM)(合约清单走交易所官方挂牌表,DCE/GFEX 品种忽略trade_date,返回当前挂牌)指数:
000852/sh000300自动补交易所前缀走新浪;中证系列930xxx/950xxx自动走中证官网源(慢约 10 秒,无分钟)ETF:
510300按首位自动补sh/sz前缀期权:先
query_options(kind=months/contracts, underlying=...)拿到期月份/合约代码,再kind=hist查日线;合约代码宽容格式(IO2706-P-5600与io2706p5600等价)
城投/非上市发行人无上市股票,resolve_stock_code 返回空候选;其债券的 issuer_finance 返回引导性提示(免费层无财务,建议查 Wind/企业预警通)。
架构
Agent(Claude Code / Codex / Cursor / OpenCode 等)
↓ MCP stdio
local-datasource(本仓库)
↓ 直接调用
akshare / yfinance / wbgapi / arxiv / requests(HTTP 直连)
↓ 原始数据源
新浪 / 腾讯 / 东财数据中心 / 交易所官网 / 中证指数 / 同花顺 / 外汇局 / 上金所 / 生意社 / 纽约联储 / CBOE / Yahoo Finance / World Bank / arxiv.org文件结构
.
├── SKILL.md # Agent 执行手册
├── README.md # 项目介绍(本文档)
├── CHANGELOG.md # 里程碑变更记录
├── pyproject.toml # Python 包配置与依赖
├── config.yaml # 可选配置文件
├── src/local_datasource/ # MCP server 源码
│ ├── server.py # 服务入口:注册 tools、处理调用
│ ├── cli.py # download 批量下载子命令(唯一写缓存的入口)
│ ├── cache.py # 下载缓存纯函数:key/路径/manifest/新鲜度
│ ├── config.py # 加载 config.yaml / 环境变量
│ ├── formatters.py # 统一 CSV 输出与预览
│ ├── assets/
│ │ └── trading_rules.yaml # 交易规则参数静态表(附录 B 调研,随包分发)
│ └── providers/ # 各数据源适配器
│ ├── common.py # 共享工具:日期过滤、分钟深度守卫、腾讯分钟路径
│ ├── stock.py # A/HK/US 股票(日线/A股分钟)+ resolve_stock_code 名称反查
│ ├── yahoo.py # 美股/全球资产
│ ├── worldbank.py # 世界银行
│ ├── arxiv.py # arXiv 论文
│ ├── bond.py # 中国境内债券(国债收益率/信用债发行/交易所行情)
│ ├── convertible_bond.py # 可转债(一览/条款/历史K线/发行人财务)
│ ├── futures.py # 国内期货(行情/合约清单)
│ ├── index.py # 国内指数(沪深/中证系列)
│ ├── etf.py # A股场内 ETF
│ ├── options.py # 期权(ETF/股指:月份/清单/日线)
│ ├── global_rates.py # 全球利率(美债收益率/美联储 EFFR/美元指数/VIX)
│ ├── fx.py # 外汇(中间价/中行牌价/离岸 USDCNH/交叉盘)
│ ├── spot.py # 现货(上金所贵金属/生意社大宗含基差)
│ ├── align.py # 多序列对齐合并(宽表/重采样,纯本地)
│ └── rules.py # 交易规则参数表(按 as_of 取生效值,纯本地)
└── demos/ # 示例脚本
└── mcp_query_demo.py # 多资产查询 + 归一化走势图依赖
Python >= 3.10
mcp:MCP 服务器框架akshare:A股/港股/美股/ETF/债券/可转债 行情yfinance:Yahoo Finance 备选接口wbgapi:世界银行数据arxiv:arXiv 论文搜索pandas:数据处理pyyaml:配置文件解析requests:新浪 suggest API(股票名称反查)
可选:
matplotlib:运行demos/mcp_query_demo.py绘图
安装
pip install -e .安装完成后,local-datasource 命令会被加入 PATH。
启动 MCP 服务
local-datasource服务通过标准输入输出(stdio)与 Agent 通信。可以用以下命令快速验证是否启动成功:
echo '{"jsonrpc":"2.0","id":1,"method":"initialize","params":{"protocolVersion":"2024-11-05","capabilities":{},"clientInfo":{"name":"test","version":"1.0"}}}' | local-datasource若返回初始化结果,说明服务正常。
批量下载(download 命令)
除了作为 MCP 服务被 Agent 调用,本库还提供一个批量下载子命令,把常用数据在本地预取成 CSV 缓存,供回测、研究复用:
local-datasource download --config FILE [--data-dir DIR] [--force]--config(必填):清单 YAML 路径--data-dir:缓存根目录;优先级 CLI--data-dir> 清单顶层data_dir>config.yaml的cache.data_dir--force:忽略"当天已拉取"的新鲜度判断,强制重新下载
清单 YAML 格式(assets 列表,每条 {tool, args, start_date?, end_date?}):
# batch.yaml
data_dir: ./datasource-cache # 顶层可选;CLI --data-dir 优先
assets:
- tool: query_global_rates
args: {kind: us_treasury, tenure: all}
- tool: query_stock
args: {ticker: "600519", market: a, adjust: qfq, period: daily}
start_date: "2025-01-01" # 可选:合并进 args;与 args 内同名值同时存在时,这里优先
end_date: "2025-12-31"
- tool: query_fx
args: {kind: mid, currency: usd,eur}支持的 tool 白名单为 13 个查询工具(query_stock/query_yfinance/query_worldbank/query_arxiv/query_bond/query_convertible_bond/query_futures/query_index/query_etf/query_options/query_global_rates/query_fx/query_spot)。resolve_stock_code(名称反查)、align_series(本地对齐)、query_trading_rules(M4 静态规则表)不支持出现在清单中——它们不产出待缓存的行情序列。未知 tool 名、缺 args 会在启动时一次性报错并列出合法 tool 名,校验全部通过后才开始下载。
每条目输出一行状态:
SKIP <tool>/<key>:当天已拉取过(manifest 的last_fetched为今天)且未--force,直接复用缓存FETCH <tool>/<key> <rows> rows:调用 provider 下载并写入缓存FAIL <tool>/<key> <error>:该条目失败;单条失败不中断整批,全部条目跑完后只要存在失败,退出码为1(全部成功0,清单/用法错误2)
缓存目录布局:每条目落在 <data_dir>/<tool>/<key>.csv,旁边有同名的 <key>.manifest.json 元信息(含 args、行数、首末日期、last_fetched)。key 由工具名与参数生成,可读且末尾带 8 位哈希,例如:
datasource-cache/
└── query_global_rates/
├── query_global_rates-kind-us_treasury-tenure-all-1a2b3c4d.csv
└── query_global_rates-kind-us_treasury-tenure-all-1a2b3c4d.manifest.json架构说明:MCP 查询路径不做任何缓存,永远直连数据源;
download是唯一写缓存的入口。缓存仅供用户显式预取/复用,不会让 Agent 拿到过期数据。
Agent 配置示例
任何支持 MCP 的 Agent 都可以通过 command 方式调用本服务。
Claude Code
claude_mcp_settings.json:
{
"mcpServers": {
"local-datasource": {
"command": "local-datasource"
}
}
}Codex
.codex/config.json:
{
"mcpServers": {
"local-datasource": {
"command": "local-datasource"
}
}
}Cursor / Windsurf / OpenCode
在对应 MCP 配置中添加:
{
"mcpServers": {
"local-datasource": {
"command": "local-datasource"
}
}
}调用数据案例
查询 A 股:贵州茅台
{
"ticker": "600519",
"market": "a",
"start_date": "2025-06-01",
"end_date": "2026-06-24",
"file_path": "/tmp/moutai.csv"
}Tool:query_stock
查询港股:腾讯
{
"ticker": "00700",
"market": "hk",
"start_date": "2025-06-01",
"end_date": "2026-06-24",
"file_path": "/tmp/tencent.csv"
}Tool:query_stock
查询美股/ETF:黄金 GLD
{
"ticker": "GLD",
"period": "1y",
"file_path": "/tmp/gld.csv"
}Tool:query_yfinance
默认使用 akshare 的美股日线接口;若需要 Yahoo Finance 数据,添加 "use_yfinance": true:
{
"ticker": "AAPL",
"period": "1y",
"use_yfinance": true,
"file_path": "/tmp/aapl_yahoo.csv"
}查询世界银行:中国 GDP 现价
{
"indicator": "NY.GDP.MKTP.CD",
"country": "CHN",
"start_year": 2020,
"end_year": 2023,
"file_path": "/tmp/china_gdp.csv"
}Tool:query_worldbank
搜索 arXiv 论文
{
"query": "large language model retrieval augmented generation",
"max_results": 10,
"sort_by": "relevance",
"file_path": "/tmp/llm_rag.csv"
}Tool:query_arxiv
查询国债收益率曲线
{
"kind": "yield_curve",
"start_date": "2025-01-01",
"end_date": "2025-06-30",
"file_path": "/tmp/bond_yield.csv"
}Tool:query_bond(kind=yield_curve)
查询信用债发行信息
{
"kind": "issue_info",
"bond_code": "2180495.IB",
"file_path": "/tmp/bond_issue.csv"
}Tool:query_bond(kind=issue_info,bond_code 精确匹配单只,支持 2180495.IB / 2180495 格式,避免子串误命中)
按发行人查最新一只债
{
"kind": "issue_info",
"bond_issue": "成都东方广益",
"file_path": "/tmp/bond_by_issuer.csv"
}Tool:query_bond(kind=issue_info,bond_issue 按发行人查,返回发行日期最新的一只债代码;与 bond_code 互斥)
查询可转债一览
{
"kind": "overview",
"file_path": "/tmp/cb_overview.csv"
}Tool:query_convertible_bond(kind=overview,返回全市场转债含转股溢价率/评级/规模,可选 keyword 按简称过滤)
查询发行人财务报表
{
"kind": "issuer_finance",
"stock_code": "sh603938",
"report_type": "资产负债表",
"file_path": "/tmp/issuer_finance.csv"
}Tool:query_convertible_bond(kind=issuer_finance,bond_code/stock_code 二选一;城投/非上市发行人返回引导性提示而非报错)
股票名称反查代码
{
"keyword": "贵州茅台酒股份有限公司",
"file_path": "/tmp/resolve_stock.csv"
}Tool:resolve_stock_code(首选新浪 suggest API,简称精确命中、全称从关联字段提取代码;城投/非上市发行人返回空候选;多候选时择一再调 query_stock)
查询期货:IM 主连日线
{
"symbol": "IM0",
"period": "daily",
"start_date": "2026-06-01",
"end_date": "2026-08-28",
"file_path": "/tmp/im_main.csv"
}Tool:query_futures(单合约改 symbol: IM2612 得全历史;分钟加 period: min,深度约 4 个交易日,超覆盖报错并给补数指引)
查询指数:中证1000 日线
{
"symbol": "000852",
"period": "daily",
"start_date": "2014-10-17",
"end_date": "2026-08-28",
"file_path": "/tmp/csi1000.csv"
}Tool:query_index(中证系列 930xxx 走中证官网源,慢约 10 秒、无分钟数据)
查询 ETF:沪深300ETF 分钟
{
"symbol": "510300",
"period": "min",
"freq": "1",
"start_date": "2026-08-25",
"end_date": "2026-08-27",
"file_path": "/tmp/etf_min.csv"
}Tool:query_etf(日线去 period/freq 加日期区间;日线源无复权)
查询期权:IO 到期月份 → 单合约日线
{
"kind": "months",
"underlying": "IO",
"file_path": "/tmp/io_months.csv"
}Tool:query_options(合约清单 kind: contracts;日线 kind: hist, symbol: "IO2706-P-5600")
查询美债收益率
{
"kind": "us_treasury",
"tenure": "all",
"file_path": "/tmp/us_treasury.csv"
}Tool:query_global_rates(kind=us_treasury,tenure: all 返回 2/5/10/30 年及 10Y-2Y 利差,1990 年起;短端期限如 3m 仅近 1000 交易日;kind=fed_rate/dxy/vix 分别查美联储 EFFR、美元指数(东财失败自动回退 Yahoo)、VIX(CBOE 直连,1990 起))
查询汇率中间价
{
"kind": "mid",
"currency": "usd,eur",
"file_path": "/tmp/fx_mid.csv"
}Tool:query_fx(kind=mid 外汇局官方中间价,1994 年起,单位为 100 外币 = X 人民币;kind=bochina 中行牌价需 symbol 如"美元"且起止日期必填;kind=usdcnh/cross 走 Yahoo,不可达时明确报错)
查询现货黄金:上金所 Au99.99
{
"kind": "sge",
"symbol": "Au99.99",
"file_path": "/tmp/au9999.csv"
}Tool:query_spot(kind=sge 上金所贵金属日线,2016-12 起约 10 年深度;kind=sy 生意社大宗现货含主力合约价与基差,需 symbols: ["CU","RB"] 且起止日期必填、单次区间最长 1 年)
对齐合并多份行情 CSV 为宽表
{
"file_paths": ["/tmp/moutai.csv", "/tmp/gld.csv"],
"columns": ["close", "close"],
"names": ["moutai", "gld"],
"align": "outer",
"fill": "ffill",
"file_path": "/tmp/merged.csv"
}Tool:align_series(纯本地合并不联网;columns/names 与 file_paths 一一对应,缺省各取 close、列名用文件名;resample: "week"/"month" 重采样时每期取最后一个实际交易日)
查询交易规则参数:A 股某历史日期的印花税
{
"market": "a",
"as_of": "2021-06-01",
"file_path": "/tmp/rules_a.csv"
}Tool:query_trading_rules(纯本地读包内静态表;不传 as_of 取现行值;market: "commodity_futures" 返回查交易所当日结算参数的引导性提示而非报错;输出含生效区间/来源/置信度等 12 个字段,可选 parameter: "印花税" 子串过滤)
参考 demos/mcp_query_demo.py:它通过 MCP 调用多个工具,读取生成的 CSV,计算归一化价格,并绘制对比图。
python demos/mcp_query_demo.py输出:
demos/outputs/*.csv:各资产原始行情demos/outputs/normalized_returns.png:归一化走势图demos/outputs/summary.csv:汇总表
配置
项目根目录的 config.yaml:
providers:
yahoo:
# 默认使用 akshare。设为 true 则默认使用 yfinance。
use_yfinance: false
cache:
# download 批量下载的缓存根目录(默认 ./datasource-cache)。
# 仅 download CLI 使用;MCP 查询不读写缓存。
data_dir: ./datasource-cachecache.data_dir 只影响 local-datasource download(见上文"批量下载");清单顶层 data_dir 与 CLI --data-dir 都比它优先。
也可通过环境变量指定配置文件:
LOCAL_DATASOURCE_CONFIG=/path/to/config.yaml local-datasource扩展新数据源
src/local_datasource/providers/ 下的每个文件都是一个独立适配器,新增数据源的步骤:
在
providers/新增一个 Python 文件,实现query_xxx(...)函数,返回tuple[str, str](文件路径 + 预览文本)。在
server.py新增一个@mcp.tool(structured_output=False)薄工具函数:参数注解(Annotated/Literal/Field)即客户端可见 schema,docstring 即工具描述;函数体一行转发_safe_summary。在
_summary_for()中增加对应路由分支。更新
SKILL.md和README.md的 tool 说明。
测试
测试随仓库分发(tests/ 目录)。离线单测不连网;联网冒烟默认开启,设 SKIP_INTEGRATION=1 跳过:
python -m pytest tests/ -v # 全量(含联网冒烟)
SKIP_INTEGRATION=1 python -m pytest tests/ -q # 仅离线包含配置加载、格式化、缓存与 CLI、15 个 provider 的测试、MCP server 工具注册(16 个 tool)。
网络环境已知风险
以下为在本机实测(2026-09)确认的数据源网络情况,也是本轮海外数据源选型的依据(CBOE、纽约联储直连可达):
东财非 A 股端点部分网络被拒:东财的全球指数/期货 K 线等非 A 股端点在部分网络环境下不可达(A 股相关端点不受影响)。美元指数已内置 Yahoo 自动回退。
金十美联储决议源 2025-09 起停更:美联储利率已改用纽约联储官方 EFFR API(免 key 直连)。
FRED / treasury.gov / stooq 在本机实测不可用:美债收益率走东财全表(1990 起,短端走新浪),VIX 走 CBOE 官方 CSV 直连,不依赖上述源。
注意事项
分钟数据深度有限(免费源天花板):期货分钟约 4 个交易日,腾讯源(个股/指数/ETF)约 8 个交易日。请求区间超出覆盖时会明确报错并提示从 Wind/终端导出 Excel 补数,不会静默返回残缺数据。
慢源与已知限制:中证系列指数日线走中证官网(约 10 秒,无分钟);ETF 日线无复权(原始价);期权仅日线。期货主连日线为全历史:自品种上市日(或 2005-01-04,取较早)至今,共 83 个主连品种(IF0 特例仅自 2017-01-17 起)。
query_bond(kind=issue_info)走中国货币网直连(akshare 未适配其改版):站点按 IP 限窗口内请求数,单次查询约 75 秒(30 个债券类型节流遍历);触发限流(HTTP 421)时自动退避 4 分钟重试一次,仍限流则如实报错。同一发行人的重复查询建议走download缓存。yfinance容易被 Yahoo Finance 限流,因此默认优先使用akshare。akshare的接口可能随时间变化,建议定期更新到较新版本。World Bank 和 arXiv 通常稳定且无需 API key。
与 kimi-datasource 的异同
维度 | local-datasource | kimi-datasource |
运行位置 | 本机 | Kimi Code 云端 |
登录/账号 | 不需要 | 需要 Kimi Code 账号 |
费用 | 免费(受公开接口限额影响) | 消耗 Kimi Code 额度 |
数据源 | A/HK/US 股票、境内债券/可转债、期货、指数、A股 ETF、期权、美股/全球资产、全球利率与波动率(美债/EFFR/美元指数/VIX)、汇率、商品现货(贵金属/大宗含基差)、交易规则参数表、多序列对齐合并、World Bank、arXiv | 更多,包括天眼查、Google Scholar、元典法律等 |
数据链路 | Agent → 本地 Server → 公开接口 | Agent → Kimi 云服务 → 后端数据源 |
可定制性 | 源码本地可见,可修改/扩展 | 黑盒,只能使用官方暴露的 tool |
跨 Agent 复用 | 标准 MCP Server,可被多家 Agent 复用 | 仅限 Kimi Code 内部 |
本项目的设计思路是:把常见的免费/公开数据查询能力做成一个本地、透明、可扩展的 MCP 服务。它并不复制 kimi-datasource 的具体实现(其接口实现并不公开),而是基于公开库重新组合出一套可用的本地替代方案。
Available Tools
16 toolsalign_seriesA
把本库产出的多份 CSV 按日期对齐合并成一张宽表(默认各取 close 列),支持并集/交集、前向填充、重采样到周(周五)/月(取期末交易日);纯本地计算,不联网。输出写入 file_path 为 CSV。
| Name | Required | Description | Default |
|---|---|---|---|
| fill | No | Forward-fill value columns after join (leading NaN stays NaN) | none |
| align | No | Join on date: outer (union, missing = NaN) or inner (intersection) | outer |
| names | No | Output column name per input file, aligned with file_paths; default file name stem | |
| columns | No | Value column per input file, aligned with file_paths; default close for each | |
| resample | No | Per-series resample before join: week (W-FRI) or month; keeps each period's last actual trading day | none |
| file_path | Yes | Output CSV file path | |
| file_paths | Yes | Input CSV paths (>= 2) produced by this library; first column must be date/datetime/日期 |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations, the description carries the behavioral disclosure burden. It does disclose local computation, no network access, and output written to file_path as CSV. However, it does not disclose whether an existing output file is overwritten or whether input files are strictly read-only.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single dense sentence that front-loads the core purpose, then efficiently enumerates options and side effects. Every clause adds useful information, with no filler or repetition of the schema.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a 7-parameter tool with no annotations and no output schema, the combination of description and schema covers the input constraints, alignment modes, fill behavior, resampling, defaults, and output path. The main residual gap is overwrite behavior, which is minor.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, so the baseline is 3. The description reinforces defaults like close, union/intersection, forward-fill, and weekly/monthly resampling, but these are essentially also carried by the input schema. It adds little beyond what the schema already provides.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description states the exact operation: aligning multiple library-produced CSVs by date into one wide table, with a default value column of close. This clearly differentiates it from the query_* sibling tools and from the raw name alone.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description specifies when to use it: on CSV files produced by this library, with pure local computation and no network access. It does not name alternatives explicitly or list exclusion rules, but the scope is clear enough to route an agent correctly.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
query_arxivA
Search arXiv papers. Output is written to file_path as CSV.
| Name | Required | Description | Default |
|---|---|---|---|
| query | Yes | Search query | |
| sort_by | No | relevance | |
| file_path | Yes | Output CSV file path | |
| max_results | No | Max number of results |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
There are no annotations, so the description carries the burden of disclosure. It does disclose a key side effect: results are written to a CSV file at the given file path. However, it does not mention overwriting behavior, rate limits, or any other side effects, leaving gaps for a tool with zero annotation coverage.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is exactly two sentences with no filler. The core action ('Search arXiv papers') is front-loaded, followed by the critical output behavior. Every word earns its place.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a tool with no annotations and no output schema, the description covers the main purpose and the output side effect. However, it omits any clarification about the tool's return value, whether the tool creates or overwrites the file, and any limits or edge cases. These are gaps for a tool that writes files, so the description is adequate but not thorough.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The schema covers 75% of parameters with descriptions, so the baseline is 3. The description adds minimal semantic value by specifying that the query targets 'arXiv papers' and that the output is CSV, but this is already partially implied by the schema and tool name. It does not significantly compensate for the undocumented sort_by parameter.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description states a specific verb ('Search') and resource ('arXiv papers'), which clearly distinguishes it from sibling query tools focused on financial instruments. An agent can tell this targets academic literature without opening the schema.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description gives implied usage: it is meant for searching arXiv papers, inferred from the tool name and first sentence. However, it provides no explicit guidance on when to use this tool versus other query tools, no exclusions, and no mention of alternatives.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
query_bondA
Query China onshore bonds. Output is written to file_path as CSV. kind=yield_curve: 国债到期收益率曲线 (bond_china_yield). kind=issue_info: 信用债发行信息含评级 (bond_info_cm). kind=credit_daily: 信用债交易所日行情 (bond_zh_hs_daily). 已知限制(akshare免费层无): 中债估值YTM/全价、赎回回售条款详情、剩余期限、城投发行人财务。
| Name | Required | Description | Default |
|---|---|---|---|
| kind | Yes | Query type | |
| symbol | No | Exchange bond symbol e.g. sh019623 (credit_daily) | |
| end_date | No | End date YYYY-MM-DD (yield_curve/credit_daily) | |
| bond_code | No | Bond code e.g. 2180495.IB or 2180495 (issue_info, mutually exclusive with bond_issue) | |
| file_path | Yes | Output CSV file path | |
| bond_issue | No | Issuer name e.g. 成都东方广益 (issue_info, returns latest bond by issue date, mutually exclusive with bond_code) | |
| start_date | No | Start date YYYY-MM-DD (yield_curve/credit_daily) |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations, so the description carries the burden. It discloses that output is written to a CSV file and lists known limitations (missing YTM, redemption terms, etc.), which is useful. However, it doesn't disclose whether the operation is read-only, error behavior, or any side effects beyond file writing.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Description is structured: main purpose, kind enumeration, limitations. It's slightly verbose but each sentence adds value, and the core purpose is front-loaded.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a 7-param tool with no output schema, the description covers the main purpose, kinds, and known limitations. It doesn't explain return values (but CSV file output is clear) or error handling. Given schema richness, it's reasonably complete.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema covers 100% of parameters, but description adds mapping from kind to specific data source names (e.g., bond_china_yield), enriching meaning beyond schema. Also notes mutual exclusivity in schema, reinforcing the semantic value.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
States specific resource (China onshore bonds) and enumerates three distinct kinds, making the tool's scope clear. Doesn't explicitly differentiate from sibling query_convertible_bond but the name and scope are sufficient for a basic distinction.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Provides per-kind context (what each kind returns) and known limitations, but no explicit guidance on when to use this tool vs alternatives. It implies usage by naming data sources but lacks exclusionary criteria or alternative tool references.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
query_convertible_bondA
Query China convertible bonds. Output is written to file_path as CSV. kind=overview: 全市场一览含转股溢价率/评级/规模 (bond_zh_cov). kind=terms: 强赎/回售/下修条款+剩余期限 (集思录). kind=history: 单只转债历史K线 daily/min (bond_zh_hs_cov_daily/min). kind=issuer_finance: 发行人正股三大报表;城投/非上市发行人返回引导性提示。
| Name | Required | Description | Default |
|---|---|---|---|
| kind | Yes | Query type | |
| period | No | K-line period (history) | daily |
| symbol | No | CB symbol e.g. sz128039 (history) | |
| keyword | No | Keyword filter (overview, optional) | |
| end_date | No | End date YYYY-MM-DD (history) | |
| bond_code | No | CB code (issuer_finance, mutually exclusive with stock_code) | |
| file_path | Yes | Output CSV file path | |
| start_date | No | Start date YYYY-MM-DD (history) | |
| stock_code | No | Underlying stock code (issuer_finance, mutually exclusive with bond_code) | |
| report_type | No | Financial report type (issuer_finance) | 资产负债表 |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries the behavioral burden. The description discloses a non-obvious side effect: output is written to file_path as CSV, and it also handles the special issuer_finance case with a guidance prompt for municipal and non-listed issuers. It does not mention overwrite behavior or error cases, but the core behavioral traits are covered well.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is compact and front-loaded with the main purpose and file output. Each kind clause earns its place. Some encoded Chinese text could be clearer for non-Chinese readers, but there is no redundance.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a 10-parameter, 4-mode tool with no output schema, the description covers what each mode returns, the CSV destination, and an edge-case behavior. It does not spell out all combinations, but it provides enough context for an agent to configure required and mode-specific parameters correctly.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100%, so parameters already have descriptions. The tool description still adds real value by mapping each kind to its expected content and data source, and by associating history mode with periods and symbols. This goes beyond the schema's terse field descriptions.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states 'Query China convertible bonds' and defines four distinct kinds (overview, terms, history, issuer_finance) with data sources and content. This is specific enough to distinguish it from siblings like query_bond and query_stock.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The four kind values give implicit usage guidance, but the description does not explicitly state when to prefer this tool over query_bond or query_stock, nor does it give exclusion conditions. It provides clear context for this tool itself but lacks explicit alternative routing.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
query_etfA
Query China onshore-listed ETF. Output is written to file_path as CSV. daily 自约2012年起(新浪,无复权返回原始价); min 腾讯源约8交易日. 分钟超覆盖时明确报错并给补数指引.
| Name | Required | Description | Default |
|---|---|---|---|
| freq | No | Minute granularity (period=min) | 1 |
| period | No | K-line period | daily |
| symbol | Yes | ETF code e.g. 510300 or sh510300 | |
| end_date | No | End date YYYY-MM-DD | |
| file_path | Yes | Output CSV file path | |
| start_date | No | Start date YYYY-MM-DD |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries the full burden of behavioral disclosure. It reveals data sources (Sina, Tencent), price adjustment (no adjustment, raw prices), date coverage (daily from ~2012, min ~8 trading days), and explicit error handling for minute over-coverage. This goes beyond basic operation and gives the agent clear expectations about output and limitations.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is compact and front-loaded with the core purpose and output format. It mixes English and Chinese but remains efficient, covering key behavioral details in two sentences. No wasted words, though the Chinese phrases could be seen as less accessible to non-Chinese readers.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a data-query tool with a complete schema and no output schema (since output goes to file), the description covers the essential operational details: output path, data sources, coverage, and error behavior. It does not explain return values (not needed as output is written to file) and the schema already documents parameter formats. The description is sufficient for correct invocation.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100%, so the baseline is 3. The description adds value by clarifying the data source and coverage behavior tied to period and freq (e.g., min uses Tencent source with ~8 days coverage), which enriches the schema's enum descriptions. This extra context helps the agent select appropriate parameter values.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool queries China onshore-listed ETFs and outputs CSV to a file path. It distinguishes itself from siblings like query_stock and query_index by explicitly targeting ETFs, though it does not name alternatives.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description implies usage when ETF data is needed but provides no explicit guidance on when to prefer this over sibling tools. It does mention data source differences (Sina for daily, Tencent for min) and coverage limitations, which helps decide when to use it, but no exclusions or alternative recommendations are given.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
query_futuresA
Query China futures. Output is written to file_path as CSV. kind=hist: 单合约/主连日线全历史(主连自品种上市日或2005-01-04起,IF0特例仅2017-01-17起; period=min 约4交易日需起止日期). kind=contracts: 品种挂牌合约清单(如 IM/RB). 分钟超覆盖时明确报错并给补数指引,不静默降级.
| Name | Required | Description | Default |
|---|---|---|---|
| freq | No | Minute granularity (period=min) | 1 |
| kind | No | Query type | hist |
| period | No | K-line period (hist) | daily |
| symbol | Yes | Contract e.g. IM2612, main IM0, or variety IM (contracts) | |
| end_date | No | End date YYYY-MM-DD | |
| file_path | Yes | Output CSV file path | |
| start_date | No | Start date YYYY-MM-DD | |
| trade_date | No | Trade date YYYY-MM-DD (contracts, default today; DCE/GFEX 品种忽略此参数,返回当前挂牌) |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations, the description must disclose behaviors itself. It clearly states the side effect of writing to file_path as CSV and the error policy for minute data coverage ('explicit error with guidance, no silent degradation'). It also mentions special start-date caveats for IF0, which helps agents reason about data availability.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is reasonably compact and front-loads the purpose, but the mixed-language style and dense run-on clauses reduce readability. It could be structured as bullets for kind=hist and kind=contracts, and several bounded parentheticals make it hard to scan.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For an 8-parameter tool with no output schema, the description covers the core behavior (query type, data coverage, file side effect, error disclosure). Remaining details of params like trade_date and freq live in the schema, which agents can consult directly, so the essential context for correct usage is mostly present.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100%, but the description adds substantial meaning beyond enum labels: it explains what kind=hist output is (continuous/variety daily history), what kind=contracts returns (variety contract lists like IM/RB), and adds date constraints (IF0 only 2017-01-17 onward, minute requires start/end with ~4 trading days). This is far beyond schema descriptions.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
Statement 'Query China futures' immediately identifies the verb and resource, and the description separates the two modes (kind=hist vs kind=contracts) and the CSV output, clearly distinguishing this from sibling query_stock/query_bond/query_index tools.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description gives concrete usage conditions: which kind to use, that minute-period data requires start/end dates, and that coverage errors are surfaced loudly rather than silently degraded. It doesn't explicitly compare to sibling tools, but the rules for choosing hist vs contracts and data coverage are sufficiently explicit.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
query_fxA
Query FX rates. Output is written to file_path as CSV. kind=mid: 央行人民币中间价(单位为 100 外币,自 1994 起;currency 过滤币种如 usd,eur). kind=bochina: 中行牌价(约 2012 起,symbol 用币种中文名如 美元;起止日期必填,长区间分页拉取较慢). kind=usdcnh: 离岸人民币 USDCNH 日线(Yahoo). kind=cross: 交叉盘日线,pair 如 EUR/USD(Yahoo,不可达时明确报错).
| Name | Required | Description | Default |
|---|---|---|---|
| kind | Yes | Query type | |
| pair | No | FX pair (cross only), e.g. EUR/USD or EURUSD | |
| symbol | No | Currency Chinese name (bochina only), e.g. 美元; note 港币 not 港元 | |
| currency | No | Comma-separated currency codes (mid only), e.g. usd,eur; default all 25 | |
| end_date | No | End date YYYY-MM-DD (required for bochina) | |
| file_path | Yes | Output CSV file path | |
| start_date | No | Start date YYYY-MM-DD (required for bochina) |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries full responsibility. It discloses the output method ('written to file_path as CSV'), mentions default behavior for currency, and notes error behavior for cross ('不可达时明确报错'). It does not mention potential side effects like overwriting files, but it is reasonably transparent for a query tool.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is long but well-structured, using a kind-by-kind breakdown that makes the information digestible. It avoids redundant phrasing and each sentence adds value (examples, notes, constraints). It could be slightly more compact, but the current length is justified by the complexity of the tool.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool's complexity (multiple kinds with distinct parameter requirements) and the absence of an output schema, the description covers all necessary operational details: parameter constraints, defaults, examples, and error behavior. It does not mention broader context like rate limits or authentication, but that is not essential for correct invocation.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100% for parameters, so the baseline is 3. The description adds significant extra value by explaining each kind in relation to parameters (e.g., 'currency 过滤币种', 'start_date/end_date required for bochina'), providing examples, and clarifying defaults. This exceeds the schema's basic descriptions.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description states a specific verb ('Query') and resource ('FX rates'), and clearly differentiates from sibling tools by explicitly enumerating the kinds of FX data (mid, bochina, usdcnh, cross). This leaves no ambiguity about the tool's purpose.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides detailed guidance on when to use each kind (e.g., 'kind=bochina' for Chinese bank rates, 'kind=cross' for cross pairs) and includes practical notes like '港币 not 港元' and '默认 all 25'. It does not explicitly contrast with sibling tools, but the purpose is clear enough that an agent can infer when to invoke this tool.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
query_global_ratesA
Query global rates for backtesting. Output is written to file_path as CSV. kind=us_treasury: 美债收益率(2/5/10/30Y 及 10Y-2Y 利差,1990 起;tenure 选期限,短端期限仅近 1000 交易日). kind=fed_rate: 美联储 EFFR 日频有效联邦基金利率(纽约联储 API,2000-07 起). kind=dxy: 美元指数(东财失败自动回退 Yahoo). kind=vix: VIX 波动率指数(CBOE 直连,1990 起).
| Name | Required | Description | Default |
|---|---|---|---|
| kind | Yes | Query type | |
| tenure | No | Treasury tenure (us_treasury only, default all) | |
| end_date | No | End date YYYY-MM-DD | |
| file_path | Yes | Output CSV file path | |
| start_date | No | Start date YYYY-MM-DD |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries the full burden. It discloses output to CSV, data sources (New York Fed, CBOE, etc.), fallback behavior (东财失败自动回退 Yahoo), and constraints (短端期限仅近 1000 交易日), providing rich behavioral transparency.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is compact but dense, with each kind explained in a structured manner. It is slightly verbose due to the level of detail, but every sentence carries useful information, so it remains efficient.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
The description covers all kinds, data sources, fallback logic, date ranges, and tenure constraints. It also mentions the output format (CSV). For a tool with this complexity, the description is complete and leaves no critical gaps for an agent to configure calls correctly.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The description adds significant meaning beyond the schema. It explains each kind's data content, start dates, tenure options, and specific constraints (e.g., short-end tenures limited to ~1000 trading days). This goes well beyond the schema's basic field descriptions.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool's purpose: 'Query global rates for backtesting.' It specifies the resource (global rates) and the action (query), and the breakdown by kind (us_treasury, fed_rate, dxy, vix) distinguishes it from sibling tools like query_bond or query_fx.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description implies usage for backtesting and details data sources and constraints, but it does not explicitly contrast with alternative tools or state when not to use this tool. The guidance is implied rather than explicit.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
query_indexA
Query China indices. Output is written to file_path as CSV. 000xxx/399xxx 走新浪(日线自2014起); 930xxx/950xxx 中证系列走官网(慢约10秒). period=min 仅沪深指数(腾讯源约8交易日). 分钟超覆盖时明确报错并给补数指引.
| Name | Required | Description | Default |
|---|---|---|---|
| freq | No | Minute granularity (period=min) | 1 |
| period | No | K-line period | daily |
| symbol | Yes | Index code e.g. 000852, sh000300, 930050 | |
| end_date | No | End date YYYY-MM-DD | |
| file_path | Yes | Output CSV file path | |
| start_date | No | Start date YYYY-MM-DD |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries the full disclosure burden — and it excels. It reveals output format/location (CSV to file_path), data source routing by symbol prefix, latency behavior (~10s for CSI), coverage limits (min only ~8 trading days for Shenzhen/Shanghai via Tencent), and error behavior (clear error + supplement guidance when minute coverage is exceeded). This is exemplary disclosure of behavioral traits.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Three dense sentences with the purpose and output format front-loaded before the data-source caveats. No wasted words — every clause (latency, coverage, error behavior) earns its place. It could arguably benefit from paragraph separation for scannability, but for a single-block description it is efficiently packed.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a 6-parameter tool with no output schema, the description is thorough: it covers purpose, output destination/format, data source selection rules, latency, coverage limits, and failure behavior. Since output is written to a CSV file at file_path, a return-value description is unnecessary. The main gap is the absence of explicit sibling differentiation, which is a usage-guidelines concern rather than a completeness one.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100%, so the baseline is 3. The description adds genuine value beyond the schema: it explains that symbol prefix determines the data source (000xxx/399xxx vs 930xxx/950xxx) and that period=min is restricted to Shanghai/Shenzhen indices — semantics not present in the parameter descriptions. This elevates it above the baseline.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
States a specific verb+resource ('Query China indices') that clearly identifies the tool's domain. The resource type (indices) distinguishes it from most siblings (bonds, stocks, futures, ETFs, options, FX), though it does not explicitly name the closest alternative (query_stock) which could also fetch index-like data.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description gives valuable usage context: data source routing by symbol prefix (000xxx/399xxx via Sina, 930xxx/950xxx via official site), the ~10s latency caveat for CSI series, and the period=min constraint (~8 trading days coverage, clear error + supplement guidance). However, it never explicitly names sibling alternatives or states when to prefer this tool over query_stock/query_yfinance — usage guidance is implied via data-source constraints rather than explicit tool selection rules.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
query_optionsA
Query China options (SSE ETF options + CFFEX index options IO/HO/MO). Output is written to file_path as CSV. kind=months: 标的到期月份. kind=contracts: 当月合约清单. kind=hist: 单合约日线. 本轮仅日线; 找合约代码先用 months/contracts.
| Name | Required | Description | Default |
|---|---|---|---|
| kind | Yes | Query type | |
| symbol | No | Option contract code e.g. 10003889 or IO2706-P-5600 (hist) | |
| end_date | No | End date YYYY-MM-DD (hist) | |
| file_path | Yes | Output CSV file path | |
| start_date | No | Start date YYYY-MM-DD (hist) | |
| trade_date | No | Trade date YYYY-MM-DD (contracts/CFFEX, default today) | |
| underlying | No | Underlying: 50ETF/300ETF/500ETF/科创50ETF/IO/HO/MO (months/contracts) |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries the full responsibility for revealing behavior. It clearly states that output is written to a file_path as CSV, and the use of 'Query' implies a read-only operation. However, it does not mention whether the file is overwritten, whether any network requests are made, or any potential side effects beyond file creation.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is compact and information-dense, with no fluff. It uses a structured format with bullet-like separations for the kind values, and the key operational note about finding contract codes is succinctly embedded. Every sentence contributes to understanding the tool, and the mixed Chinese/English is efficient for the intended domain.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
The description provides enough context for an agent to use the tool correctly: it covers the data scope, output format, the three query kinds, and a workflow tip. Since there is no output schema, it does not need to describe return values. However, it could be more complete by explicitly stating that the 'hist' kind requires start_date and end_date, or by noting default behaviors, but overall it is sufficient for basic usage.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The schema descriptions cover all parameters, and the tool description adds meaningful context: it explains that 'kind' controls the query mode, that 'underlying' applies to months/contracts, that 'trade_date' is for contracts/CFFEX, and that start_date/end_date are for hist. This goes beyond the schema by clarifying which parameters are relevant for each kind, making the semantics clearer.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool queries China options, specifically SSE ETF options and CFFEX index options (IO/HO/MO), which distinguishes it from sibling tools like query_etf, query_index, and query_futures. It also indicates the output is written to a CSV file, giving a complete picture of the tool's primary function.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description explains the three 'kind' values (months, contracts, hist) and provides a practical hint: '本轮仅日线' (only daily data for now) and '找合约代码先用 months/contracts' (find contract codes via months/contracts first). This guidance helps the agent choose the correct workflow, though it does not explicitly compare to alternative sibling tools.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
query_spotA
Query spot prices. Output is written to file_path as CSV. kind=sge: 上金所贵金属现货日线 date,open,high,low,close(2016-12 起约 10 年深度,symbol 必填如 Au99.99/Ag99.99/Au(T+D)). kind=sy: 生意社大宗现货含主力合约价与基差(symbols 如 ['CU','RB'];起止日期必填,逐日抓取较慢,单次区间最长 1 年).
| Name | Required | Description | Default |
|---|---|---|---|
| kind | Yes | Query type | |
| symbol | No | SGE variety, e.g. Au99.99, Ag99.99, Au(T+D) (sge only, required) | |
| symbols | No | 100ppi variety codes, e.g. ["CU", "RB"] (sy only, required) | |
| end_date | No | End date YYYY-MM-DD (required for sy; optional filter for sge) | |
| file_path | Yes | Output CSV file path | |
| start_date | No | Start date YYYY-MM-DD (required for sy; optional filter for sge) |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
The description discloses that output is written to a CSV file at file_path, and notes that sy daily fetching is slow. However, without annotations, it does not mention any other side effects or potential errors, leaving some behavioral transparency gap.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single run-on sentence mixing English and Chinese, making it less clear. It could be organized into separate points for each kind, but currently it is somewhat cluttered.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
The description provides enough context to use the tool: it explains the two kinds, required parameters, output format, and performance caveats. It even gives examples of valid symbols, which helps an agent construct correct queries.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The schema already has detailed descriptions for each parameter, including required conditions for each kind. The main description adds context about the two query modes and the 10-year depth for sge, but this information is mostly redundant with the schema.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states 'Query spot prices' and details two kinds (sge and sy) with specific examples. It distinguishes the tool as a spot-price query, which helps an agent identify its purpose among sibling tools, though it does not explicitly name alternatives.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides usage guidance by specifying which parameters are required for each kind: symbol for sge, symbols and dates for sy. It also notes that sy fetching is slow and limited to 1-year ranges, which informs decision-making.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
query_stockA
Query historical stock prices for A-share, Hong Kong, or US markets. Output is written to file_path as CSV.
| Name | Required | Description | Default |
|---|---|---|---|
| freq | No | Minute granularity (period=min) | 1 |
| adjust | No | Adjustment type | qfq |
| market | Yes | Market: a (A-share), hk (Hong Kong), us (US) | |
| period | No | K-line period (min: A-share only) | daily |
| ticker | Yes | Stock ticker, e.g. 600519, 00700, AAPL | |
| end_date | Yes | End date YYYY-MM-DD | |
| file_path | Yes | Output CSV file path | |
| start_date | Yes | Start date YYYY-MM-DD |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries the full burden. It explicitly mentions the side effect of writing output to a CSV file via file_path, which is a key behavioral trait. However, it does not disclose other behaviors like read-only nature, error handling, or rate limits, making the transparency partial but acceptable.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is extremely concise, consisting of only two sentences. It conveys the core purpose and output destination with no unnecessary words, perfectly matching the desired brevity and structure.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
The description, combined with the detailed parameter schema, gives the agent everything needed to call the tool correctly. It specifies the output format (CSV) and the target file path. It does not explain return codes or errors, but for a data query tool this is not critical. Overall, it is complete for the intended use.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The input schema already provides descriptions for all 8 parameters with 100% coverage. The description text adds no additional meaning beyond the schema, such as reasoning for the default adjustment type or the relationship between period and freq. This meets the baseline but does not exceed it.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the action (Query), the resource (historical stock prices), and the scope (A-share, Hong Kong, or US markets). This sufficiently distinguishes it from sibling tools like query_bond and query_index, which target different asset classes.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description does not explicitly state when to use this tool versus alternatives, but the tool name and description make it obvious for stock price queries. It would benefit from a note such as 'use for stocks only, not for bonds or indices' but the current wording is adequate for basic usage.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
query_trading_rulesA
查询当时生效的中国交易规则参数(印花税/过户费/涨跌幅/T+1/股指期货与国债期货保证金及平今费/融资保证金/期权与港股通费率),按 as_of 命中生效区间,缺省取今天;每行含生效区间/来源/置信度(official/media/to_verify/market_estimate);market=commodity_futures 返回查交易所当日结算参数的引导行。输出写入 file_path 为 CSV。
| Name | Required | Description | Default |
|---|---|---|---|
| as_of | No | 生效日判定日期 YYYY-MM-DD; default today | |
| market | Yes | Rule market: a (A股), etf, cffex (股指期货/期权品种), treasury_futures, margin (两融), option, hk_connect (港股通), commodity_futures (引导行) | |
| file_path | Yes | Output CSV file path | |
| parameter | No | Optional substring filter on parameter column (case-insensitive), e.g. 印花税/涨跌幅/融资保证金 |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries the burden. It discloses output format (each row contains effective range/source/confidence), confidence levels, and the special behavior for commodity_futures. It does not mention side effects like overwriting the output file, or potential error cases, but for a read-only query tool this is acceptable. It also does not explicitly state it is read-only, but the nature of querying rules implies it.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single dense paragraph but packs useful information: what is queried, the as_of semantics, output columns, confidence levels, special market behavior, and file output. It is slightly long but every sentence carries substantive info, and key points are front-loaded.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a tool with 4 params, full schema coverage, and no output schema, the description covers the core semantics well: what it returns, how as_of works, and the special commodity_futures case. It lacks explicit mention of error behavior or whether the output file is overwritten, but these are minor. The confidence levels and market-specific behaviors are sufficiently explained.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100%, so the baseline is 3. The description adds value by clarifying the meaning of 'as_of' (matching effective interval, default today) and elaborating on the 'market' enum values (e.g., cffex = 股指期货/期权品种). It also explains the 'parameter' filter is case-insensitive substring on parameter column. This goes beyond schema descriptions.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool queries Chinese trading rules parameters (stamp tax, transfer fees, price limits, T+1, margin rates, etc.) with an effective-date matching by 'as_of'. It distinguishes itself from the many query_* siblings by specifying the domain (trading rules) and the output (CSV file). However, it does not explicitly contrast with siblings, so it's clear but not maximally distinctive.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description explains the default behavior (default to today when as_of is not provided) and gives a specific note for market=commodity_futures (returns a guidance row for exchange settlement parameters). It does not mention when not to use this tool or alternatives, but the specialized domain and output make the usage context fairly clear.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
query_worldbankA
Query World Bank macroeconomic indicators. Output is written to file_path as CSV.
| Name | Required | Description | Default |
|---|---|---|---|
| country | Yes | Country code(s) comma-separated, e.g. CHN,USA or all | |
| end_year | Yes | End year | |
| file_path | Yes | Output CSV file path | |
| indicator | Yes | World Bank indicator code, e.g. NY.GDP.MKTP.CD | |
| start_year | Yes | Start year |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries the burden. It discloses the output behavior ('Output is written to file_path as CSV'), which is a side effect. However, it does not mention whether the tool is read-only in other aspects, any network usage, or potential errors. Partial transparency is present.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, concise sentence with no redundant words. It efficiently conveys the purpose and key output detail.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the simplicity of the tool (5 required parameters, no output schema), the description is fairly complete. It explains that output is written to a CSV file, which is essential. However, it does not clarify the return value (e.g., success indicator) or error handling, but these are minor gaps for such a tool.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The schema descriptions cover 100% of parameters with examples for country and indicator. The tool description itself does not add additional meaning beyond the schema, so it aligns with the baseline of 3.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states 'Query World Bank macroeconomic indicators', specifying both the verb (query) and the resource (World Bank). This distinguishes it from sibling tools that target other sources like arXiv, bonds, stocks, etc.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
No explicit guidance on when to use this tool over alternatives. The name and description imply use for World Bank data, but the description does not directly contrast with siblings or provide conditions for selection.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
query_yfinanceA
Query historical prices for US/global tickers. Defaults to akshare (free, no key); set use_yfinance=true to fall back to Yahoo Finance.
| Name | Required | Description | Default |
|---|---|---|---|
| period | No | 1y | |
| ticker | Yes | Ticker, e.g. AAPL, SPY, GLD | |
| end_date | No | Optional end date YYYY-MM-DD | |
| file_path | Yes | Output CSV file path | |
| start_date | No | Optional start date YYYY-MM-DD | |
| use_yfinance | No | Use yfinance instead of akshare |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
The description discloses the default data provider (akshare) and the fallback option (yfinance), which are behavioral choices. It also implies side effects via the required 'file_path' parameter (output CSV). No annotations are provided, so the description carries the transparency burden and handles it reasonably well.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is concise (two sentences) and front-loads the primary purpose. It avoids redundancy and directly addresses the key differentiator (data source selection). The structure is clean and easy to parse.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
The description covers the main purpose and data source behavior. It does not elaborate on output format or error handling, but given the absence of an output schema and the simplicity of the task, the provided information is largely sufficient. The description complements the schema without major gaps.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is high (83%), with descriptions for most parameters. The tool description adds valuable context by explaining the default behavior of 'use_yfinance' (even though the parameter description says 'Use yfinance instead of akshare', it does not state which is default). This extra detail enhances understanding beyond the schema.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool's function: 'Query historical prices for US/global tickers.' It specifies a verb ('Query') and a resource ('historical prices'), and the mention of akshare/yfinance distinguishes it from sibling query tools that target other asset classes or data sources.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description explains the data source selection: 'Defaults to akshare (free, no key); set use_yfinance=true to fall back to Yahoo Finance.' This provides guidance on when to use the tool and how to switch between providers. It does not explicitly compare to sibling tools, but the data source context is useful.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
resolve_stock_codeA
Resolve A-share stock code by company name (abbreviation or full name). Output is written to file_path as CSV with candidate rows (代码+名称). 简称精确命中;全称能命中简称子串则返回;城投/非上市发行人返回空候选。多候选时 Agent/用户从中选,再调 query_stock 查行情。
| Name | Required | Description | Default |
|---|---|---|---|
| keyword | Yes | Stock name or keyword, e.g. 茅台 / 贵州茅台酒股份有限公司 | |
| file_path | Yes | Output CSV file path |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
It transparently notes that output is written to a file (file_path) and describes the matching logic, including empty candidate cases. It does not mention any destructive side effects, but the file writing is a clear side effect.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is concise but mixes English and Chinese, which may reduce clarity for some readers. The structure is a bit disjointed with multiple clauses, but it remains brief and does not include unnecessary fluff.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
It covers the main aspects: input, output location and format, matching behavior, and a follow-up step. It does not specify error handling or edge cases beyond the non-listed issuer scenario, but for the tool's simplicity, it is fairly complete.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The description adds significant meaning beyond the schema: it explains that keyword can be an abbreviation or full name, details the exact matching rules (abbreviation exact, full name substring), and clarifies the output content. This goes well beyond the basic 'Stock name or keyword' and 'Output CSV file path' in the schema.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool's purpose: resolving an A-share stock code from a company name. It also mentions the output format (CSV) and distinguishes it from sibling tools like query_stock which fetch market data.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
It provides guidance on when to use it (for resolving codes by abbreviation or full name) and even suggests a follow-up action (calling query_stock when multiple candidates exist). However, it doesn't explicitly state when not to use it or alternatives.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections. Dates show when Glama detected each change.
16 tool updates
v0.1.0- First observed
align_series - First observed
query_arxiv - First observed
query_bond - First observed
query_convertible_bond - First observed
query_etf - First observed
query_futures - First observed
query_fx - First observed
query_global_rates - First observed
query_index - First observed
query_options - First observed
query_spot - First observed
query_stock - First observed
query_trading_rules - First observed
query_worldbank - First observed
query_yfinance - First observed
resolve_stock_code
TDQS
Scored across 16 tools
Each tool targets a distinct data domain (e.g., stocks, bonds, futures, FX, spot, rates), and descriptions clearly differentiate overlapping areas like bond vs. convertible_bond. Minor potential confusion exists between query_bond and query_convertible_bond or query_stock and query_yfinance, but the descriptions resolve these ambiguities.
The vast majority of tools follow the consistent query_<domain> pattern, making the API predictable. The single exception is align_series, which breaks the pattern but is still intuitive and clearly named.
With 16 tools, the server is slightly above the typical 3-15 range, but the count is justified by the breadth of financial and economic data sources covered. Each tool represents a meaningful asset class or data category, so the size feels deliberate rather than bloated.
The tool surface comprehensively covers the data-retrieval needs implied by a local financial datasource: equities, bonds, futures, FX, rates, spot commodities, options, ETFs, indices, and macroeconomic data. It also includes a utility tool for aligning series, avoiding a common workflow gap. No obvious dead ends or missing core operations are apparent for a read-only query server.
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Connectors
Free public MCP for AI agents — 193 tools, 44 workflows. No API key.
The financial MCP for AI agents - 90+ financial tables, SEC filings, signals, alt-data.
Package intelligence MCP for AI agents — 22 tools, 19 ecosystems, AGPL SDK, free.
Real SEC, 13F, insider, congress & macro data your AI agent can cite. Hosted MCP, 24 tools.
Related MCP Servers
- AlicenseCqualityDmaintenanceThe MCP provides comprehensive financial data and analytical tool support for AI large language models, specifically including the following five core data capabilities: Stock Analysis/ETF Analysis/Public Funds/News & Information/General Tools More Info: https://github.com/shenqingtech/deepq-finan44307ISC
- AlicenseNot gradedqualityDmaintenanceProvides 10 financial data tools (market data, economic indicators, news, insider trades, and calendars) via a single MCP layer, enabling any MCP-compatible LLM to access diverse financial data through a unified interface.MIT
- AlicenseBqualityCmaintenanceMCP server that wraps AKShare's 1000+ financial data functions, enabling LLMs to query Chinese stock, macro, futures, fund, bond, option, forex, and alternative data through standardized tools.143Apache 2.0

inferventisofficial
FlicenseNot gradedqualityDmaintenanceEnables AI agents to access real-time financial data, news, and web reading through a single MCP endpoint with zero installation.-
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/jarvislee90s-dot/local-datasource'
If you have feedback or need assistance with the MCP directory API, please join our Discord server