A股期现套利/基差交易策略。当用户说"期现套利"、"基差交易"、"index arb"、"期货基差"、"正向套利"、"反向套利"、"基差收敛"时触发。基于 cn-stock-data 获取数据,分析股指期货基差与套利机会。支持 formal/brief 两种输出风格。
Scanned 9/7/2026
Install to Claude Code
npx -y skills add aifinlab/FinClaw --skill a-share-index-arb --agent claude-codeInstalls into .claude/skills of the current project.
Are you the author of A Share Index Arb?
Add the live security badge to your README — it updates automatically with every re-scan.
[](https://www.skillsdirectory.com/skills/aifinlab-a-share-index-arb)More formats (shields.io, HTML) on the badges page.
---
name: a-share-index-arb
description: A股期现套利/基差交易策略。当用户说"期现套利"、"基差交易"、"index arb"、"期货基差"、"正向套利"、"反向套利"、"基差收敛"时触发。基于 cn-stock-data 获取数据,分析股指期货基差与套利机会。支持 formal/brief 两种输出风格。
---
# 期现套利/基差交易助手
## 数据获取
通过 cn-stock-data skill 获取数据:
- **期货数据**: 股指期货价格(IF/IC/IM/IH)
- **指数数据**: 对应现货指数
- **利率数据**: 无风险利率/融资成本
## 分析工作流
### Step 1: 基差分析
- 基差 = 期货价格 - 现货指数
- 年化基差率 = 基差/现货 × 365/剩余天数
- 理论基差 = 现货 × (r-d) × T (持有成本模型)
- 基差偏离 = 实际基差 - 理论基差
### Step 2: 套利策略
- 正向套利:期货溢价→买现货+卖期货
- 反向套利:期货贴水→卖现货(融券)+买期货
- 跨期套利:买近月+卖远月(或反向)
- 基差收敛交易:到期日基差必然收敛至零
### Step 3: 现货组合构建
- 完全复制:买入全部成分股(成本高)
- 抽样复制:选取代表性成分股(跟踪误差)
- ETF替代:用ETF替代现货组合(最简单)
- 跟踪误差控制:<0.5%为优秀
### Step 4: 风险与成本
- 保证金风险:期货追加保证金
- 跟踪误差风险:现货组合偏离指数
- 交易成本:期货手续费+现货冲击成本
- A股特征:IC/IM长期贴水,反向套利受融券限制
### Step 5: 输出报告
## 输出格式
### formal 风格(研报级)
```
# 期现套利分析报告
## 一、基差状态
| 合约 | 期货 | 现货 | 基差 | 年化 |
|------|------|------|------|------|
## 二、套利机会
[策略类型、预期收益]
## 三、执行方案
[现货组合、对冲比例]
## 四、风险控制
```
### brief 风格(快速分析)
```
## 期现套利速览
- IF当月基差 -15点,年化贴水 -3.2%
- IC当月基差 -45点,年化贴水 -8.5%
- IC贴水较深,正向套利空间有限
- 建议:关注IC跨期价差收敛机会
```
参考 `references/index-arb-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".