Agent skill

A Share Comps

by aifinlab in aifinlab/FinClaw

A股可比公司分析/行业估值对标。当用户说"可比公司"、"估值对标"、"行业估值"、"comps"、"comparable company"、"同行对比"、"XX跟同行比怎么样"、"XX板块估值"、"可比公司分析"、"comps analysis"时触发。MUST USE when user asks about comparable company analysis, peer…

Apache-2.0Auto-check passedDocuments & Office

Install A Share Comps

skills CLI
$ npx skills add aifinlab/FinClaw --skill a-share-comps -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install aifinlab/FinClaw a-share-comps --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/aifinlab/FinClaw.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/a-share-comps .claude/skills/a-share-comps && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
a-share-comps
GitHub stars
254
Token cost
~592 tokens
SKILL.md length
166 words
Files
2 (incl. references)
Skills in repo
74
Repo updated
First seen
Licence
Apache-2.0

At a glance

A股可比公司分析/行业估值对标。当用户说"可比公司"、"估值对标"、"行业估值"、"comps"、"comparable company"、"同行对比"、"XX跟同行比怎么样"、"XX板块估值"、"可比公司分析"、"comps analysis"时触发。MUST USE when user asks about comparable company analysis, peer…

  • Works in 5 steps: 确定标的与可比公司池 → 数据获取 → 构建估值表 → …
  • User asks about comparable company analysis
  • SKILL.md covers 数据源, Workflow, 风格说明 and 关键规则
  • Calls python

What it does

A Share Comps is an agent skill from aifinlab/FinClaw. A股可比公司分析/行业估值对标。当用户说"可比公司"、"估值对标"、"行业估值"、"comps"、"comparable company"、"同行对比"、"XX跟同行比怎么样"、"XX板块估值"、"可比公司分析"、"comps analysis"时触发。MUST USE when user asks about comparable company analysis, peer valuation comparison, or industry valuation benchmarking (comps). 通过 cn-stock-data 获取标的及可比公司的财务指标和实时行情,构建多维度估值对标表。输出 Excel(公式驱动)或 Markdown 对比表。支持投行估值表风格(formal)和快速对标表风格(brief)。

Its SKILL.md is about 590 tokens, which your agent loads only when the skill is triggered. The skill folder holds 2 other files, including reference files (for example `references/valuation-metrics.md`).

It sits in Documents & Office, covering Excel spreadsheets. It works with Microsoft Excel. The licence is Apache-2.0.

When your agent uses it

  • User asks about comparable company analysis
  • Peer valuation comparison
  • Industry valuation benchmarking (comps)

Example prompts

  • “comparable company”
  • “XX跟同行比怎么样”
  • “XX板块估值”
  • “/a-share-comps”

Requirements

  • Python 3

Workflow steps

5 steps, taken from the step headings in SKILL.md.

  1. 确定标的与可比公司池
  2. 数据获取
  3. 构建估值表
  4. 统计分析
  5. 输出

What it can do on your machine

Read from SKILL.md and the folder at commit 9e62862. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • python

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

A Share Comps loads about 592 tokens when it runs, and up to ~1.6k if it reads all its reference files. Until then it costs about 95 tokens; SKILL.md has 166 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~95
When it runs · the whole SKILL.md, loaded when a task matches
~592
With references · SKILL.md plus every file in references/, read only if the agent opens them
~1.6k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from aifinlab/FinClaw at commit 9e62862, republished under its Apache-2.0 licence (© aifinlab). 166 words, ~592 tokens.

Download SKILL.mdSave it as .claude/skills/a-share-comps/SKILL.md (or your agent's skills folder). This skill also uses 1 other file; get the full folder from GitHub.
name
a-share-comps
description
A股可比公司分析/行业估值对标。当用户说"可比公司"、"估值对标"、"行业估值"、"comps"、"comparable company"、"同行对比"、"XX跟同行比怎么样"、"XX板块估值"、"可比公司分析"、"comps analysis"时触发。MUST USE when user asks about comparable company analysis, peer valuation comparison, or industry valuation benchmarking (comps). 通过 cn-stock-data 获取标的及可比公司的财务指标和实时行情,构建多维度估值对标表。输出 Excel(公式驱动)或 Markdown 对比表。支持投行估值表风格(formal)和快速对标表风格(brief)。

A 股可比公司分析

数据源

bash
SCRIPTS="$SKILLS_ROOT/cn-stock-data/scripts"

# 各公司财务指标
python "$SCRIPTS/cn_stock_data.py" finance --code [CODE]

# 各公司实时行情(市值、PE、PB 等)
python "$SCRIPTS/cn_stock_data.py" quote --code [CODE1],[CODE2],[CODE3]

# 各公司近 1 年日线(用于股价走势对比)
python "$SCRIPTS/cn_stock_data.py" kline --code [CODE] --freq daily --start [1年前日期]

补充:通过 web 搜索确认行业分类、可比公司池选择的合理性。

Workflow

Step 1: 确定标的与可比公司池
  1. 明确标的公司(用户指定的代码/名称)
  2. 确定可比公司池:
    • 用户直接给出 → 使用
    • 用户说"同行"/"行业对比" → 通过 web 搜索确认行业分类,选 5-10 家同行业上市公司
    • 选择标准:同行业、相似业务模式、相近市值规模

可比公司选择注意事项:

  • A 股同行为主,港股/美股同行可用 cn-stock-data 跨市场获取
  • 避免选择ST/*ST公司
  • 标注哪些是直接可比(业务高度相似)vs 间接可比(同行业但模式不同)
Step 2: 数据获取

对标的和每家可比公司获取:

  1. finance — 最新财务指标(ROE、毛利率、净利率、增速等)
  2. quote — 实时行情(市值、PE、PB)
  3. 如需更多估值数据(EV/EBITDA、PS 等),需要计算:
    • EV = 市值 + 有息负债 - 现金(从财务数据估算)
    • PS = 市值 / 收入
Step 3: 构建估值表

参见 references/valuation-metrics.md 的指标定义和行业处理规则。

核心估值列(必含): | 代码 | 名称 | 市值(亿) | PE(TTM) | PB | ROE(%) | 营收增速(%) | 净利润增速(%) | 毛利率(%) | 净利率(%) |

进阶列(formal 模式): | EV/EBITDA | PS | PEG | 资产负债率(%) | 经营现金流/利润 | 股息率(%) |

Step 4: 统计分析

计算可比公司组的:

  • 均值 / 中位数 / 最大值 / 最小值
  • 标的公司所处的百分位排名
  • 标注标的哪些指标优于/低于中位数
Step 5: 输出

Excel 输出规则(formal 模式):

  • 所有派生值必须是 Excel 公式,不是硬编码数字
  • 输入数据(从 cn-stock-data 获取的原始值)用蓝色字体
  • 公式计算结果用黑色字体
  • 统计行(均值/中位数)用粗体
  • 标的公司行用黄色底色高亮
  • 包含条件格式:PE 低于中位数=绿色,高于=红色

Markdown 输出(brief 模式):

  • 直接输出 Markdown 表格
  • 在表格下方用 1-2 句话总结标的的估值位置

风格说明

维度formal(投行估值表)brief(快速对标表)
输出格式Excel (.xlsx)Markdown 表格
指标列数12-15 列6-8 列
统计行均值+中位数+最大+最小仅中位数
图表PE/PB 散点图数据无
结论客观描述估值位置可加个人判断
免责声明需要不需要

关键规则

  1. 公式优先于硬编码:在 Excel 中,PE 不应直接写入数字,而应该是 =市值单元格/净利润单元格
  2. 数据来源标注:每个数字都应能追溯到 cn-stock-data 的哪个字段
  3. 行业调整:银行/保险用 PB 而非 PE;科技用 PS 或 EV/Revenue;地产看 NAV
  4. 不给买卖建议:formal 模式只陈述事实("标的 PE 处于可比组 25 百分位"),不说"建议买入"

© aifinlab, Apache-2.0. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 1 other file (references) in skills/a-share-comps of aifinlab/FinClaw.

  • SKILL.md
  • references/valuation-metrics.md

Open the folder on GitHubat commit 9e62862

Compare with similar skills

A Share Comps next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

A Share Comps compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
A Share Comps this skillaifinlab/FinClaw254—~592Automated safety check: PassApache-2.0
Anti Gambling Tradermars-tw/anti-gambling-trader-tw904—~1.9kAutomated safety check: PassMIT
Data UpdateSixian-Li/plain-backtest190—~1.6kAutomated safety check: PassMIT
Cn Ib Diligence WorkpaperQiushenZou/cn-investment-banking-skills102—~1.4kAutomated safety check: PassApache-2.0
Officecli Commonly TemplatesTeam-Commonly/commonly1.4k—~1.7kAutomated safety check: PassApache-2.0
Brigade Spreadsheet Builderspinabot/brigade11k—~1.4kAutomated safety check: PassMIT

Similar skills

  • Anti Gambling Trader

    mars-tw/anti-gambling-trader-tw

    分析台股 / 台股ETF / 台指期選擇權 / 美股 / 加密貨幣 / 外匯的交易紀錄 (CSV / JSON / Excel),用統計學判斷使用者的獲利是「可重複的優勢」還是 「運氣 + 倖存者偏差(賭博)」,不適合長期投資會明確勸退。內建反詐工具: 掃描群組對話的詐騙話術(scan-text)、檢驗老師宣稱的績效(guru-check)、…

    904 GitHub stars~1.9k tokensUpdated today
    Documents & OfficeAuto-check passed
  • Data Update

    Sixian-Li/plain-backtest

    Operate and assess the Quant workspace market-data layer through the tested data-update CLI.

    190 GitHub stars~1.6k tokensUpdated 11 days ago
    Documents & OfficeAuto-check passed
  • Cn Ib Diligence Workpaper

    QiushenZou/cn-investment-banking-skills

    Structure Chinese investment-banking due-diligence materials into traceable schedules, testing workpapers, exception logs, and closure records.

    102 GitHub stars~1.4k tokensUpdated 1 mo ago
    Documents & OfficeAuto-check passed
  • Officecli Commonly Templates

    Team-Commonly/commonly

    A skill your agent uses when producing a polished, Commonly-branded deliverable (.docx brief / memo, .xlsx data matrix, .pptx deck) and you do not have specific brand guidance from the user.

    1.4k GitHub stars~1.7k tokensUpdated today
    Documents & OfficeAuto-check passed
  • Builds and edits Excel workbooks for the Brigade agent, with live formulas, formatting, dropdowns and multiple sheets, plus an optional recalculation check.

    11k GitHub stars~1.4k tokensUpdated today
    Documents & OfficeAuto-check passed
  • Open-Sheet Workbook Creator

    lianghsun/open-sheet

    Walks an agent through building a new spreadsheet workbook in an open-sheet project, from choosing a theme to settling the real numbers and workbook type.

    127 GitHub stars~1.4k tokensUpdated 1 mo ago
    Documents & OfficeAuto-check passed

More from aifinlab/FinClaw

All 74 skills in this repo
  • Bank Corporate Credit Dd

    aifinlab/FinClaw

    A skill your agent uses when the user asks for help with corporate credit due diligence, enterprise credit investigation, pre-loan review, borrower analysis, document collection, management…

    254 GitHub stars~952 tokensUpdated 4 mo ago
    Auto-check passed
  • A skill your agent uses when you need a bank corporate-risk monitoring assistant for enterprise litigation/penalty/enforcement scanning (处罚/诉讼/被执行/失信等).

    254 GitHub stars~751 tokensUpdated 4 mo ago
    Auto-check passed
  • A skill your agent uses when you need a bank corporate client operating-volatility monitoring assistant (经营监测/指标波动/预警解释).

    254 GitHub stars~605 tokensUpdated 4 mo ago
    Auto-check passed
  • A skill your agent uses when you need a bank post-loan visit follow-up assistant to turn visit notes/materials into a structured memo (摘要/关键更新/风险观察/用途核验/行动项).

    254 GitHub stars~544 tokensUpdated 4 mo ago
    Auto-check passed
  • A skill your agent uses when you need a bank corporate credit issue-list assistant (问题清单/补件清单/催办台账).

    254 GitHub stars~487 tokensUpdated 4 mo ago
    Auto-check passed
  • A skill your agent uses when you need a bank corporate credit approval-opinion drafting assistant (审批意见/条款建议/有条件同意).

    254 GitHub stars~549 tokensUpdated 4 mo ago
    Auto-check passed

Works with

Questions about A Share Comps

What does A Share Comps do?

A股可比公司分析/行业估值对标。当用户说"可比公司"、"估值对标"、"行业估值"、"comps"、"comparable company"、"同行对比"、"XX跟同行比怎么样"、"XX板块估值"、"可比公司分析"、"comps analysis"时触发。MUST USE when user asks about comparable company analysis, peer…. A Share Comps is an agent skill from aifinlab/FinClaw. A股可比公司分析/行业估值对标。当用户说"可比公司"、"估值对标"、"行业估值"、"comps"、"comparable company"、"同行对比"、"XX跟同行比怎么样"、"XX板块估值"、"可比公司分析"、"comps analysis"时触发。MUST USE when user asks about comparable company analysis, peer valuation comparison, or industry valuation benchmarking (comps).

When should I use A Share Comps?

A Share Comps fits situations like: user asks about comparable company analysis; peer valuation comparison; industry valuation benchmarking (comps).

How do I install A Share Comps in Claude Code?

Run `npx skills add aifinlab/FinClaw --skill a-share-comps -a claude-code`. Or copy the skill folder (skills/a-share-comps in aifinlab/FinClaw) into .claude/skills/a-share-comps in your project. Claude Code loads it when a task matches its description.

How do I install A Share Comps in Codex?

Run `npx skills add aifinlab/FinClaw --skill a-share-comps -a codex`. Or copy the skill folder (skills/a-share-comps in aifinlab/FinClaw) into .agents/skills/a-share-comps in your project. Codex loads it when a task matches its description.

Can I use A Share Comps in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add aifinlab/FinClaw --skill a-share-comps -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/a-share-comps, .gemini/skills/a-share-comps, .github/skills/a-share-comps and .opencode/skills/a-share-comps in your project.

What does A Share Comps need to run?

Going by SKILL.md and its folder, A Share Comps needs the command-line tools its instructions call (python). Our summary lists: Python 3.

Does A Share Comps access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is A Share Comps safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does A Share Comps use?

A Share Comps is published under the Apache-2.0 licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does A Share Comps use?

About 592 tokens (SKILL.md is roughly 2.4k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full. Its references folder adds about 964 tokens, read only when the agent opens those files.

What are the alternatives to A Share Comps?

Skills that share tags, products or a category with A Share Comps: Anti Gambling Trader (mars-tw/anti-gambling-trader-tw, 904 stars), Data Update (Sixian-Li/plain-backtest, 190 stars), Cn Ib Diligence Workpaper (QiushenZou/cn-investment-banking-skills, 102 stars) and Officecli Commonly Templates (Team-Commonly/commonly, 1.4k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains A Share Comps?

aifinlab (a GitHub user) maintains it in aifinlab/FinClaw, which has 254 GitHub stars. The repository holds 74 skills in this directory. The repository was last updated on May 13, 2026.

Source: aifinlab/FinClaw on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.