feat(engine): 新增 Python 策略引擎模块

- config/settings.py:Pydantic 解析 env.yaml
- data/db.py:asyncpg 连接池管理
- data/reader.py:KlineReader 只读查询 TimescaleDB
- data/models.py:KlineRecord 等 Pydantic 模型,镜像 TypeORM 实体
- example/test_db.py:数据库查询验证示例
- README.md:引擎架构文档
This commit is contained in:
Rekey
2026-06-08 18:19:50 +08:00
parent 5e385547c7
commit 1c9339a4db
18 changed files with 1711 additions and 0 deletions
+14
View File
@@ -0,0 +1,14 @@
[project]
name = "trade-engine"
version = "0.1.0"
description = "量化交易策略引擎"
requires-python = ">=3.10"
dependencies = [
"asyncpg>=0.29",
"pydantic>=2.5",
"pyyaml>=6.0",
]
[tool.pyright]
venvPath = "."
venv = ".venv"