A股压力测试/情景分析。当用户说"压力测试"、"stress test"、"情景分析"、"scenario analysis"、"极端测试"、"如果暴跌"、"最坏情况"时触发。基于 cn-stock-data 获取数据,进行组合压力测试与情景分析。支持 formal/brief 两种输出风格。
Scanned 9/7/2026
Install to Claude Code
npx -y skills add aifinlab/FinClaw --skill a-share-stress-test --agent claude-codeInstalls into .claude/skills of the current project.
Are you the author of A Share Stress Test?
Add the live security badge to your README — it updates automatically with every re-scan.
[](https://www.skillsdirectory.com/skills/aifinlab-a-share-stress-test)More formats (shields.io, HTML) on the badges page.
---
name: a-share-stress-test
description: A股压力测试/情景分析。当用户说"压力测试"、"stress test"、"情景分析"、"scenario analysis"、"极端测试"、"如果暴跌"、"最坏情况"时触发。基于 cn-stock-data 获取数据,进行组合压力测试与情景分析。支持 formal/brief 两种输出风格。
---
# 压力测试/情景分析助手
## 数据获取
通过 cn-stock-data skill 获取数据:
- **组合数据**: 持仓明细与权重
- **历史数据**: 极端行情期间的价格序列
- **宏观数据**: 利率/汇率/商品价格
## 分析工作流
### Step 1: 历史情景测试
- 2015股灾:沪指-45%,小盘股跌幅更大
- 2016熔断:4个交易日-15%
- 2018贸易战:沪指全年-25%
- 2020疫情冲击:春节后首日-8%
- 组合在各历史情景下的模拟损失
### Step 2: 假设情景测试
- 市场暴跌:指数-10%/-20%/-30%
- 利率冲击:10Y国债收益率+50bp/+100bp
- 汇率冲击:人民币贬值5%/10%
- 流动性危机:成交量萎缩50%+价差扩大
### Step 3: 敏感性分析
- 单因子敏感性:逐一变动风险因子
- 多因子联合冲击:相关性在危机时趋向1
- 非线性效应:期权/可转债的凸性影响
- 二阶效应:波动率飙升+流动性枯竭
### Step 4: 压力测试报告
- 各情景下的组合损失金额与比例
- 最大损失情景识别
- 风险集中度:哪些持仓贡献最大损失
- 应对预案:触发止损/减仓/对冲的阈值
### Step 5: 输出报告
## 输出格式
### formal 风格(研报级)
```
# 组合压力测试报告
## 一、历史情景
| 情景 | 组合损失 | 最大回撤 |
|------|---------|----------|
## 二、假设情景
[各假设情景损失]
## 三、敏感性分析
[单因子/多因子敏感性]
## 四、应对预案
[止损阈值、对冲方案]
```
### brief 风格(快速分析)
```
## 压力测试速览
- 最大历史损失:2015股灾情景 -32%
- 假设暴跌20%:组合损失 -18%
- 风险集中:前3大持仓贡献65%损失
- 建议:增加对冲,降低集中度
```
参考 `references/stress-test-guide.md` 获取详细方法论与 A股实证研究。
## 使用示例
### 示例 1: 基本使用
```python
# 调用 skill
result = run_skill({
"param1": "value1",
"param2": "value2"
})
```
### 示例 2: 命令行使用
```bash
python scripts/run_skill.py --input data.json
```
Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.
No comments yet. Be the first to comment!
Create Mermaid diagrams for flowcharts, sequences, ERDs, and
Understand the components, mechanics, and constraints of context in agent systems. Use when designing agent architectures, debugging context-related failures, or optimizing context usage.
Draft release notes and changelog entries from git history or merged PRs between two refs (tags/SHAs/branches), including breaking changes, migrations, and upgrade steps. Use when the user asks for release notes, changelog updates, or a GitHub Release draft.
Documentation style guide enforcer by @planetabhi. Applies and reviews the writing style guide when authoring or editing product documentation and tutorials. Use to check prose for voice, tense, word choice, inclusive language, formatting, code block, UI, Markdown, and number/date conventions.
Quick-reference card for all caveman modes, skills, and commands. One-shot display, not a persistent mode. Trigger: /caveman-help, "caveman help", "what caveman commands", "how do I use caveman".