financial-expert

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

前置依赖:阿里云百炼 CLI

Prerequisite: Alibaba Cloud Bailian CLI

本技能依赖阿里云百炼 CLI(
bl
)。在使用本技能前,请先检查
bl
是否已安装:
bash
bl --version
如果未安装或命令不存在,请阅读以下安装文档并按照说明为用户完成安装:

This skill depends on Alibaba Cloud Bailian CLI (
bl
). Before using this skill, please check if
bl
is installed:
bash
bl --version
If it is not installed or the command does not exist, please read the following installation document and complete the installation for the user as instructed:

金融数据分析 Skill

Financial Data Analysis Skill

基于
bl mcp
调用阿里云百炼 MCP 市场金融数据服务(
market-cmapi00073529
), 提供股票 / 基金 / 基金经理筛选、财务与宏观数据查询、研报与公告检索的端到端能力。
bl
内置 MCP 客户端,复用
DASHSCOPE_API_KEY
,无需额外注册服务。
Based on
bl mcp
to call the financial data service (
market-cmapi00073529
) from Alibaba Cloud Bailian MCP Market, providing end-to-end capabilities for stock/fund/fund manager screening, financial and macro data query, research report and announcement retrieval.
bl
has a built-in MCP client, which reuses
DASHSCOPE_API_KEY
, no additional service registration is required.

何时使用

When to Use

满足以下任一条件时激活:
  • 股票相关:选股、股票筛选、A 股财务指标筛选、行业 / 概念股查询
  • 基金相关:基金筛选、按业绩 / 风险 / 持仓 / 类型筛选基金
  • 基金经理相关:按管理规模 / 业绩 / 风格筛选基金经理
  • 结构化金融数据:净利润、营业收入、ROE、市盈率、行情快照、舆情、工商信息
  • 宏观 / 行业数据:GDP、CPI、PPI、行业产量 / 销量 / 价格时序
  • 券商研报:分析师观点、行业格局、公司发展、市场趋势叙述
  • 公司公告:A 股上市公司公告原文(财务、重大事项、权益分派、关联交易)
Activate when any of the following conditions are met:
  • Stock-related: stock selection, stock screening, A-share financial indicator screening, industry/concept stock query
  • Fund-related: fund screening, fund screening by performance/risk/holding/type
  • Fund manager-related: fund manager screening by management scale/performance/style
  • Structured financial data: net profit, operating revenue, ROE, P/E ratio, market snapshot, public opinion, industrial and commercial information
  • Macro/industry data: GDP, CPI, PPI, industry production/sales price time-series
  • Brokerage research reports: analyst opinions, industry structure, company development, market trend narration
  • Company announcements: original announcements of A-share listed companies (financial, major events, equity distribution, related transactions)

何时不要使用

When NOT to Use

  • 非中国市场标的(美股、港股、加密货币等)
  • 通用编程 / 框架问题
  • 实时行情下单 / 交易接口(本技能仅提供数据查询,不下单)
  • 投资建议或荐股 — 仅返回数据,由用户自行决策
  • Non-Chinese market instruments (US stocks, Hong Kong stocks, cryptocurrencies, etc.)
  • General programming/framework issues
  • Real-time market order/transaction interfaces (this skill only provides data query, no order placement)
  • Investment advice or stock recommendation — only return data, users make their own decisions

前置条件

Prerequisites

1. 安装
bailian-cli

1. Install
bailian-cli

bash
npm install -g bailian-cli
bl --version
如果用户尚未安装,引导其访问 https://bailian.aliyun.com/cli/install.md
bash
npm install -g bailian-cli
bl --version
If the user has not installed it yet, guide them to visit https://bailian.aliyun.com/cli/install.md

2. 配置百炼 API Key

2. Configure Bailian API Key

bash
undefined
bash
undefined

方式 A:环境变量(推荐)

Method A: Environment variable (recommended)

export DASHSCOPE_API_KEY=sk-你的APIKey
export DASHSCOPE_API_KEY=sk-yourAPIKey

方式 B:bl auth

Method B: bl auth

bl auth login --api-key sk-你的APIKey
bl auth login --api-key sk-yourAPIKey

验证

Verification

bl auth status

获取 API Key:https://bailian.console.aliyun.com/cli?source_channel=key_github&

**注意**:用户已有 `DASHSCOPE_API_KEY` 则跳过配置。仅当 `bl auth status` 显示未登录或调用失败时再询问 Key。
bl auth status

Get API Key: https://bailian.console.aliyun.com/cli?source_channel=key_github&

**Note**: Skip configuration if the user already has `DASHSCOPE_API_KEY`. Only ask for the Key when `bl auth status` shows not logged in or the call fails.

3. 确认 MCP 服务可用

3. Confirm MCP Service Availability

bash
undefined
bash
undefined

在用户百炼账号下查看已激活的 MCP 服务

View activated MCP services under the user's Bailian account

bl mcp list --name 金融
bl mcp list --name 金融

查看具体服务暴露的工具

View tools exposed by the specific service

bl mcp tools market-cmapi00073529

如 `bl mcp list` 中没有目标服务,引导用户去百炼控制台「MCP 市场」激活
`market-cmapi00073529`(金融数据分析)。
bl mcp tools market-cmapi00073529

If the target service is not found in `bl mcp list`, guide the user to activate `market-cmapi00073529` (Financial Data Analysis) in the Bailian Console "MCP Market".

工作流程

Workflow

第一步:解析用户

Step 1: Parse User Input

从用户输入中提取:
  • 目标标的 — 具体股票 / 基金名称或品类(如「贵州茅台」「消费板块」「股票型基金」)
  • 筛选条件 — 财务指标、业绩阈值、行业筛选、时间窗口等
  • 数据类型 — 结构化(财务 / 行情)、时序(宏观)、非结构化(研报 / 公告)
  • 时间范围 — 数据或研报的历史区间
Extract from user input:
  • Target instrument — specific stock/fund name or category (e.g., "Kweichow Moutai", "Consumer Sector", "Equity Fund")
  • Filter conditions — financial indicators, performance thresholds, industry screening, time window, etc.
  • Data type — structured (financial/market), time-series (macro), unstructured (research reports/announcements)
  • Time range — historical interval of data or research reports

第二步:选择工具

Step 2: Select Tool

用户意图工具类别
「筛选...股票」「选股」
SmartStockSelection
候选清单
「筛选...基金」
SmartFundSelection
候选清单
「筛选...基金经理」
SmartFundManagerSelection
候选清单
「查 X 公司 / 基金的财务 / 行情 / 估值」
FinQuery
结构化数据
「查 GDP / CPI / 行业产销 / 价格走势」
MacroIndustryData
时序数据
「找 X 行业 / 公司的券商研报」
FinancialResearchReport
非结构化研报
「查 X 公司公告」
AnnouncementData
非结构化公告
User IntentionToolCategory
"Screen...stocks" "Stock selection"
SmartStockSelection
Candidate list
"Screen...funds"
SmartFundSelection
Candidate list
"Screen...fund managers"
SmartFundManagerSelection
Candidate list
"Check financial/market/valuation of X company/fund"
FinQuery
Structured data
"Check GDP/CPI/industry production-sales/price trend"
MacroIndustryData
Time-series data
"Find brokerage research reports on X industry/company"
FinancialResearchReport
Unstructured research reports
"Check X company's announcements"
AnnouncementData
Unstructured announcements

第三步:调用
bl mcp call

Step 3: Call
bl mcp call

所有金融工具都挂在
market-cmapi00073529
这一个 MCP server 下, 调用格式统一为:
bash
bl mcp call market-cmapi00073529.<ToolName> --query "<自然语言查询>"
也支持结构化入参:
bash
undefined
All financial tools are hosted under the
market-cmapi00073529
MCP server, with a unified calling format:
bash
bl mcp call market-cmapi00073529.<ToolName> --query "<Natural language query>"
Structured parameters are also supported:
bash
undefined

完整 JSON 入参

Complete JSON input

bl mcp call market-cmapi00073529.SmartStockSelection
--json '{"query":"消费板块","filters":{"roe":">15"}}'
bl mcp call market-cmapi00073529.SmartStockSelection
--json '{"query":"Consumer Sector","filters":{"roe":">15"}}'

多个 K=V(值自动尝试解析为 JSON)

Multiple K=V (values are automatically parsed as JSON)

bl mcp call market-cmapi00073529.SmartFundSelection
--arg riskLevel=R3 --arg minScale=10

输出 JSON 用于 Agent 解析:

```bash
bl mcp call market-cmapi00073529.FinQuery --query "贵州茅台 2024 年净利润" --output json
bl mcp call market-cmapi00073529.SmartFundSelection
--arg riskLevel=R3 --arg minScale=10

Output JSON for Agent parsing:

```bash
bl mcp call market-cmapi00073529.FinQuery --query "Kweichow Moutai 2024 net profit" --output json

工具参考

Tool Reference

每个工具的入参 schema 可通过
bl mcp tools market-cmapi00073529 --output json
查询。 下面给出典型调用示例,所有工具默认接收自然语言
--query
The input schema of each tool can be queried via
bl mcp tools market-cmapi00073529 --output json
. The following are typical call examples, all tools accept natural language
--query
by default.

1. 股票筛选 —
SmartStockSelection

1. Stock Screening —
SmartStockSelection

按财务、行情、技术、行业 / 概念等多维条件筛选股票。仅返回候选名单,不返回详情。
bash
bl mcp call market-cmapi00073529.SmartStockSelection \
  --query "筛选净利润增速超过 30% 且 ROE 大于 15% 的消费股"
Screen stocks based on multi-dimensional conditions such as finance, market, technology, industry/concept. Only returns candidate lists, no details.
bash
bl mcp call market-cmapi00073529.SmartStockSelection \
  --query "Screen consumer stocks with net profit growth rate exceeding 30% and ROE greater than 15%"

2. 基金筛选 —
SmartFundSelection

2. Fund Screening —
SmartFundSelection

按业绩、风险、持仓、基金经理、类型等条件筛选基金。
bash
bl mcp call market-cmapi00073529.SmartFundSelection \
  --query "筛选近一年收益率排名前 10% 的股票型基金"
Screen funds based on conditions such as performance, risk, holdings, fund manager, type.
bash
bl mcp call market-cmapi00073529.SmartFundSelection \
  --query "Screen equity funds ranked top 10% in return over the past year"

3. 基金经理筛选 —
SmartFundManagerSelection

3. Fund Manager Screening —
SmartFundManagerSelection

按管理规模、业绩、风险控制、投资风格等条件筛选基金经理。
bash
bl mcp call market-cmapi00073529.SmartFundManagerSelection \
  --query "筛选管理规模超过 100 亿且年化收益超过 15% 的基金经理"
Screen fund managers based on conditions such as management scale, performance, risk control, investment style.
bash
bl mcp call market-cmapi00073529.SmartFundManagerSelection \
  --query "Screen fund managers with management scale exceeding 10 billion RMB and annualized return exceeding 15%"

4. 金融数据查询 —
FinQuery

4. Financial Data Query —
FinQuery

查询股票 / 基金 / 债券基本资料、财务数据、行情快照、估值指标等结构化数据。 也支持舆情、工商数据。返回表格或叙述文本。
bash
bl mcp call market-cmapi00073529.FinQuery \
  --query "查询贵州茅台 2020 年至今的净利润数据"
Query structured data such as basic information, financial data, market snapshots, valuation indicators of stocks/funds/bonds. It also supports public opinion and industrial and commercial data. Returns tables or narrative text.
bash
bl mcp call market-cmapi00073529.FinQuery \
  --query "Query Kweichow Moutai's net profit data from 2020 to present"

5. 宏观行业数据 —
MacroIndustryData

5. Macro Industry Data —
MacroIndustryData

查询宏观经济(GDP、CPI)或行业经济(产量、销量、价格)的时序数据
bash
bl mcp call market-cmapi00073529.MacroIndustryData \
  --query "查询近五年中国 GDP 同比增速数据"
Query time-series data of macro economy (GDP, CPI) or industry economy (production, sales, price).
bash
bl mcp call market-cmapi00073529.MacroIndustryData \
  --query "Query China's year-on-year GDP growth rate data over the past five years"

6. 研报查询 —
FinancialResearchReport

6. Research Report Query —
FinancialResearchReport

检索券商研报中的分析师观点、行业格局判断、公司发展历程、市场趋势叙述等非结构化内容
bash
bl mcp call market-cmapi00073529.FinancialResearchReport \
  --query "查找最近三个月关于新能源汽车行业的券商研报"
Retrieve unstructured content such as analyst opinions, industry structure judgments, company development history, market trend narration from brokerage research reports.
bash
bl mcp call market-cmapi00073529.FinancialResearchReport \
  --query "Find brokerage research reports on the new energy vehicle industry in the last three months"

7. 公告检索 —
AnnouncementData

7. Announcement Retrieval —
AnnouncementData

检索 A 股上市公司公告原文:财务公告、重大事项、权益分派、关联交易等。
bash
bl mcp call market-cmapi00073529.AnnouncementData \
  --query "查询贵州茅台 2024 年年度股东大会决议公告"
Retrieve original announcements of A-share listed companies: financial announcements, major events, equity distribution, related transactions, etc.
bash
bl mcp call market-cmapi00073529.AnnouncementData \
  --query "Query Kweichow Moutai's 2024 annual general meeting resolution announcement"

输出呈现规范

Output Presentation Specifications

向用户展示结果时遵循以下结构:
  • 筛选类(股票 / 基金 / 经理):表格展示,含名称、代码、关键指标值
  • FinQuery
    结构化数据
    :表格展示,列标题需含单位(万元 / % / 倍 / 元等)
  • MacroIndustryData
    时序
    :时序表格 + 一句话趋势摘要(同比 / 环比方向)
  • FinancialResearchReport
    研报
    :研报标题 + 发布日期 + 券商 + 核心观点摘要(不超过 3 条)
  • AnnouncementData
    公告
    :公告标题 + 发布日期 + 公司名称 + 相关原文片段
强约束:
  • 始终注明数据来源(百炼 MCP 市场 / market-cmapi00073529)和查询时间(
    date
    命令)。
  • 若工具返回为空,不要编造数据;建议用户放宽筛选条件或调整关键词后重试。
  • 涉及金额、比例时保留原始精度,不要四舍五入到无意义的位数。
  • 不要给出投资建议;可总结数据特征,但不得说「建议买入 / 卖出」。
Follow the following structure when presenting results to users:
  • Screening categories (stocks/funds/managers): display in tables, including name, code, key indicator values
  • FinQuery
    structured data
    : display in tables, column headers must include units (10,000 RMB / % / times / yuan, etc.)
  • MacroIndustryData
    time-series
    : time-series table + one-sentence trend summary (year-on-year/quarter-on-quarter direction)
  • FinancialResearchReport
    research reports
    : research report title + release date + brokerage + core opinion summary (no more than 3 points)
  • AnnouncementData
    announcements
    : announcement title + release date + company name + relevant original fragments
Strong Constraints:
  • Always indicate the data source (Bailian MCP Market / market-cmapi00073529) and query time (using the
    date
    command).
  • If the tool returns empty, do not fabricate data; suggest users relax screening conditions or adjust keywords and try again.
  • Retain original precision when involving amounts or ratios, do not round to meaningless digits.
  • Do not give investment advice; you can summarize data features, but must not say "suggest buying/selling".

错误处理

Error Handling

错误现象排查思路
BailianGateway.Login.NotLogined
/ 401
API Key 缺失或失效 →
bl auth login --api-key sk-...
bl mcp list
找不到
market-cmapi00073529
用户未在百炼控制台「MCP 市场」激活该服务,引导其激活
bl mcp tools
报 connection 错误
检查网络 / 区域(默认
cn-beijing
);可加
--region us
--base-url
覆盖
工具返回
isError: true
读取
result.content[].text
中的错误描述,常见原因:query 太宽 / 缺少必填实体名
无返回结果放宽筛选条件、确认实体名称(全称 / 简称 / 代码)是否准确
Error PhenomenonTroubleshooting Ideas
BailianGateway.Login.NotLogined
/ 401
Missing or invalid API Key →
bl auth login --api-key sk-...
market-cmapi00073529
not found in
bl mcp list
The user has not activated the service in the Bailian Console "MCP Market", guide them to activate it
bl mcp tools
reports connection error
Check network/region (default
cn-beijing
); can add
--region us
or
--base-url
to override
Tool returns
isError: true
Read the error description in
result.content[].text
, common reasons: query is too broad / missing required entity name
No results returnedRelax screening conditions, confirm whether the entity name (full name/abbreviation/code) is accurate

完整端到端示例

Complete End-to-End Example

用户问:「帮我筛选 ROE > 15% 且近三年净利润复合增速 > 20% 的消费股,再查一下排名前 3 的公司最近的研报观点。
bash
undefined
User asks: "Help me screen consumer stocks with ROE > 15% and compound net profit growth rate > 20% in the past three years, then check the latest research report opinions of the top 3 companies."
bash
undefined

Step 1: 候选筛选

Step 1: Candidate screening

bl mcp call market-cmapi00073529.SmartStockSelection
--query "ROE 大于 15%,近三年净利润复合增速大于 20% 的消费股"
--output json
bl mcp call market-cmapi00073529.SmartStockSelection
--query "Consumer stocks with ROE greater than 15% and compound net profit growth rate greater than 20% in the past three years"
--output json

假设返回 top 3:贵州茅台、五粮液、伊利股份

Assume top 3 returned: Kweichow Moutai, Wuliangye, Yili Group

Step 2: 分别拉取最新研报

Step 2: Pull latest research reports respectively

bl mcp call market-cmapi00073529.FinancialResearchReport
--query "贵州茅台近一个月券商研报核心观点"
bl mcp call market-cmapi00073529.FinancialResearchReport
--query "五粮液近一个月券商研报核心观点"
bl mcp call market-cmapi00073529.FinancialResearchReport
--query "伊利股份近一个月券商研报核心观点"

汇总为表格 + 每家 3 条要点 + 数据来源 + 查询时间。
bl mcp call market-cmapi00073529.FinancialResearchReport
--query "Core opinions of brokerage research reports on Kweichow Moutai in the past month"
bl mcp call market-cmapi00073529.FinancialResearchReport
--query "Core opinions of brokerage research reports on Wuliangye in the past month"
bl mcp call market-cmapi00073529.FinancialResearchReport
--query "Core opinions of brokerage research reports on Yili Group in the past month"

Summarize into a table + 3 key points for each company + data source + query time.

bailian-cli
skill 的协同

Collaboration with
bailian-cli
Skill

  • 本 skill 专注金融 MCP 工具调用;不要在这里调用
    bl text chat
    /
    bl image
    等。
  • 若用户拿到金融数据后想写研报 / 出图 / 出 PPT:
    • 文本撰写 → 转给
      bailian-cli
      bl text chat
    • 可视化图表生成 → 转给
      bailian-cli
      bl image generate
    • 配音播报 → 转给
      bailian-cli
      bl speech synthesize
  • This skill focuses on financial MCP tool calls; do not call
    bl text chat
    /
    bl image
    , etc. here.
  • If users want to write research reports/create charts/make PPTs after obtaining financial data:
    • Text writing → transfer to
      bailian-cli
      to use
      bl text chat
    • Visual chart generation → transfer to
      bailian-cli
      to use
      bl image generate
    • Dubbing broadcast → transfer to
      bailian-cli
      to use
      bl speech synthesize

备注

Notes

  • 本 skill 依赖的
    bl mcp
    子命令(
    list
    /
    tools
    /
    call
    )由
    bailian-cli
    提供; 详细参数见
    bailian-cli
    skill 的
    reference/
    目录或
    bl mcp <子命令> --help
  • 金融 MCP 服务可能按调用计费;首次大批量调用前建议先
    --dry-run
    预览请求。
  • 数据准确性以阿里云百炼 MCP 市场提供方为准,本 skill 不对数据准确性背书。
  • The
    bl mcp
    subcommands (
    list
    /
    tools
    /
    call
    ) relied on by this skill are provided by
    bailian-cli
    ; For detailed parameters, see the
    reference/
    directory of the
    bailian-cli
    skill or
    bl mcp <subcommand> --help
    .
  • Financial MCP services may charge by call; it is recommended to use
    --dry-run
    to preview the request before large-scale calls for the first time.
  • Data accuracy is subject to the provider of Alibaba Cloud Bailian MCP Market, this skill does not endorse data accuracy.