You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
AlphaFutures/# AI 期货分析系统运行指南.ini

89 lines
2.5 KiB

This file contains invisible Unicode characters!

This file contains invisible Unicode characters that may be processed differently from what appears below. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to reveal hidden characters.

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

# AI 期货分析系统运行指南
## 1. 环境准备
### 1.1 系统要求
- 操作系统 : Windows 10/11 或 Linux/macOS
- Python 版本 : Python 3.8 及以上
- 内存 : 至少 4GB
- 存储空间 : 至少 500MB
### 1.2 检查 Python 环境
```
# 检查 Python 版本
python --version
# 检查 pip 版本
pip --version
```
## 2. 安装依赖
### 2.1 安装核心依赖
在项目根目录执行:
```
pip install -r requirements.txt
```
### 2.2 解决可能的依赖问题
- tqsdk 导入失败 : 系统会自动使用模拟数据,不影响基本功能
- TA-Lib 安装失败 : 可以注释掉该依赖,系统会使用内置的技术分析函数
## 3. 配置设置
### 3.1 创建环境配置文件
复制 .env.example 文件并重命名为 .env
```
# Windows
copy .env.example .env
# Linux/macOS
cp .env.example .env
```
### 3.2 配置关键参数
编辑 .env 文件,设置以下参数:
- DEEPSEEK_API_KEY : DeepSeek API 密钥(可选,不设置会使用模拟响应)
- DB_PATH : 数据库存储路径(默认即可)
- REVIEW_TIMES : 自动复盘时间默认09:00,12:30,15:30
## 4. 运行系统
### 4.1 运行系统测试
验证所有组件是否正常工作:
```
python test_system.py
```
### 4.2 运行功能演示
体验完整的系统功能:
```
python demo.py
```
### 4.3 预期输出
运行 demo.py 后,您将看到:
- 系统初始化信息
- 数据获取和分析过程
- 多维度分析结果
- AI 智能研判
- 交易建议生成
- 综合分析报告
## 5. 系统使用说明
### 5.1 核心功能
- 数据获取 : 支持实时数据和模拟数据
- 趋势分析 : 基于 ADX 和多周期分析
- 风险控制 : ATR 动态止损和仓位管理
- 资金监控 : 持仓量和资金流向分析
- AI 研判 : DeepSeek 大模型智能分析
- 换月预警 : 交割日风险提示
### 5.2 扩展功能
- 定时任务 : 可配置的自动复盘
- 数据存储 : 历史分析结果持久化
- API 接口 : 可扩展为 Web 服务
## 6. 故障排除
### 6.1 常见问题
- 模块导入失败 : 检查依赖安装是否完整
- API 调用失败 : 检查网络连接和 API 密钥
- 数据为空 : 系统会自动使用模拟数据,确保数据获取模块正常
### 6.2 日志查看
系统运行过程中会输出详细日志,可根据日志信息定位问题。
## 7. 后续开发建议
- Web 前端 : 开发可视化界面
- 实时行情 : 接入更多数据源
- 策略回测 : 增加历史数据回测功能
- 多模型融合 : 集成多个 AI 模型