Install
openclaw skills install @soul-code/financial-report-analyzerAnalyze financial reports and research notes (PDF, Word, images) to extract key financial metrics, profitability trends, risk signals, and management commentary. Uses SoMark to accurately parse complex financial tables, multi-column layouts, and charts before AI analysis. Ideal for earnings analysis, equity research, and investment due diligence. Requires SoMark API Key (SOMARK_API_KEY).
openclaw skills install @soul-code/financial-report-analyzerExtract key financial metrics, risks, and insights from any financial report. SoMark first parses the report into high-fidelity Markdown — correctly handling nested financial tables, multi-column layouts, footnotes, and embedded charts. The AI then performs structured analysis covering profitability, liquidity, growth trends, and risk signals.
Annual reports and research notes are notoriously difficult to parse: financial tables span multiple pages with merged cells, footnotes contain material disclosures, and multi-column layouts get scrambled by standard PDF readers. SoMark recovers the true table structure so no figure is misread or missed.
In short: parse with SoMark first, then analyze the structured output.
Example requests:
Important — API quota notice: Each parse consumes one API call from the user's SoMark quota.
Before running the parser, ask the user:
Wait for the user to confirm before proceeding. Do not run the parser without explicit user confirmation.
Important: Before starting, tell the user that SoMark will parse the document to preserve the full table structure and footnotes — ensuring financial figures are extracted accurately from even complex multi-page financial statements. The parser can also be configured to control output formats, element rendering behavior, and document parsing features, which is useful for complex financial tables and image-heavy reports.
API concurrency limit: For the same SOMARK_API_KEY, do not run multiple parsing script invocations concurrently. Wait until the current invocation finishes and the parsed outputs are available before starting another invocation that uses the same API key.
python financial_report_analyzer.py \
-f <report_file> \
-o <output_dir> \
--output-formats '["markdown", "json"]' \
--element-formats '{"image": "url", "formula": "latex", "table": "html", "cs": "image"}' \
--feature-config '{"enable_text_cross_page": false, "enable_table_cross_page": false, "enable_title_level_recognition": false, "enable_inline_image": true, "enable_table_image": true, "enable_image_understanding": true, "keep_header_footer": false}'
Script location: financial_report_analyzer.py in the same directory as this SKILL.md
Supported formats: .pdf .png .jpg .jpeg .bmp .tiff .webp .heic .heif .gif .doc .docx
--output-formats (Optional)This argument controls which parser outputs should be requested and saved.
If omitted, the default value is:
["markdown", "json"]
Supported values:
| Value | Description |
|---|---|
markdown | Save the parsed report as a Markdown file |
json | Save the parsed report as a JSON output |
Example:
--output-formats '["markdown", "json"]'
--element-formats (Optional)This argument controls how specific element types are rendered in the parser output.
If omitted, the default value is:
{
"image": "url",
"formula": "latex",
"table": "html",
"cs": "image"
}
If you provide this argument, you may pass a partial JSON object. Any omitted keys will continue using the default values.
Supported keys, allowed values, and defaults:
| Key | Allowed values | Default |
|---|---|---|
| image | url, base64, none | url |
| formula | latex, mathml, ascii | latex |
| table | html, image, markdown | html |
| cs | image | image |
Example:
--element-formats '{"image": "base64", "table": "html"}'
--feature-config (Optional)This argument controls parser feature switches.
If omitted, the default value is:
{
"enable_text_cross_page": false,
"enable_table_cross_page": false,
"enable_title_level_recognition": false,
"enable_inline_image": true,
"enable_table_image": true,
"enable_image_understanding": true,
"keep_header_footer": false
}
If you provide this argument, you may pass a partial JSON object. Any omitted keys will continue using the default values. All values must be boolean (true or false).
Supported keys and defaults:
| Key | Default | Description |
|---|---|---|
enable_text_cross_page | false | Merge text content across page boundaries |
enable_table_cross_page | false | Merge tables across page boundaries |
enable_title_level_recognition | false | Recognize heading and title levels |
enable_inline_image | true | Include inline image output |
enable_table_image | true | Include table image output |
enable_image_understanding | true | Enable image understanding features |
keep_header_footer | false | Preserve header and footer content |
Example:
--feature-config '{"enable_text_cross_page": false, "enable_table_cross_page": false, "enable_title_level_recognition": false, "enable_inline_image": true, "enable_table_image": true, "enable_image_understanding": true, "keep_header_footer": false}'
--base-url (Optional)This argument overrides the SoMark API base URL. Use it to switch between regional endpoints.
If omitted, the SOMARK_BASE_URL environment variable is used. If that is also unset, the default is https://somark.cn/api/v1 (mainland China).
| Region | URL |
|---|---|
| Mainland China (中国大陆) | https://somark.cn/api/v1 |
| Outside mainland China | https://somark.ai/api/v1 |
Example:
# Mainland China (default)
--base-url "https://somark.cn/api/v1"
# Outside mainland China
--base-url "https://somark.ai/api/v1"
<filename>.md — full report in Markdown (preserves table structure)<filename>.json — JSON output (blocks with positions)parse_summary.json — metadata (file path, elapsed time)After the script finishes, read the generated Markdown and perform structured analysis across these dimensions:
| 字段 | 内容 |
|---|---|
| 公司名称 | |
| 报告类型 | (年报/季报/半年报/研报/招股说明书) |
| 报告期间 | |
| 货币单位 | |
| 会计准则 | (GAAP / IFRS / 中国会计准则) |
| 审计机构 | (如适用) |
| 审计意见 | (标准无保留/保留/否定/无法表示) |
Extract and present in a table. Use N/A if not available. Include YoY change where prior period data is present.
损益表关键指标
| 指标 | 本期 | 上期 | 同比变化 |
|---|---|---|---|
| 营业收入 | |||
| 毛利润 | |||
| 毛利率 | |||
| 营业利润 | |||
| 净利润 | |||
| 净利率 | |||
| EBITDA | |||
| 每股收益 (EPS) |
资产负债表关键指标
| 指标 | 本期 | 上期 |
|---|---|---|
| 总资产 | ||
| 总负债 | ||
| 股东权益 | ||
| 资产负债率 | ||
| 现金及等价物 | ||
| 应收账款 | ||
| 存货 |
现金流量表关键指标
| 指标 | 本期 | 上期 |
|---|---|---|
| 经营活动现金流 | ||
| 投资活动现金流 | ||
| 融资活动现金流 | ||
| 自由现金流 |
If the report includes segment data, extract revenue and profit contribution by business line or geography.
Systematically scan for the following risk indicators and rate each as 存在 / 不存在 / 需关注:
| 风险类型 | 状态 | 具体说明 |
|---|---|---|
| 审计意见异常 | ||
| 持续经营疑虑 | ||
| 大额商誉减值 | ||
| 应收账款异常增长 | ||
| 经营现金流为负而净利润为正 | ||
| 存货大幅积压 | ||
| 关联交易占比过高 | ||
| 债务集中到期 | ||
| 管理层重大变动 | ||
| 诉讼或监管调查 | ||
| 业绩预警或修正 |
Extract key statements from MD&A (管理层讨论与分析) or chairman's letter:
Calculate or extract where available:
| 比率 | 数值 | 行业参考(如知晓) |
|---|---|---|
| 市盈率 (P/E) | ||
| 市净率 (P/B) | ||
| ROE | ||
| ROA | ||
| 流动比率 | ||
| 速动比率 | ||
| 利息保障倍数 |
Structure the output as:
## 财务报告分析
### 报告概览
[overview table]
### 核心财务指标
[three financial statement tables]
### 分业务分析
[segment breakdown if available]
### 风险信号扫描
[risk signal table]
### 管理层重要表述
[key quotes and paraphrases with context]
### 关键财务比率
[ratios table]
### 综合评估
[3-5 sentence assessment: financial health, trend direction, key concerns, and overall signal — bullish/neutral/bearish with reasoning]
If the user has not configured an API key:
Step 1: Ask whether SOMARK_API_KEY is already set — do not ask for the key in chat.
Step 2: Direct them to:
Open "API Workbench" → "APIKey", and create a key in the format sk-******.
Step 3: Ask them to run:
export SOMARK_API_KEY=your_key_here
Step 4: Mention free quota is available:
--output-formats, --element-formats, or --feature-config: ask the user to provide valid JSON syntax.markdown, json.image, formula, table, and cs.feature-config values must be booleans.1107 / Invalid API Key: ask the user to verify SOMARK_API_KEY.2000 / Invalid parameters: check file path and format.N/A.