feat(quant): M7.3 研究行情口径显式化(默认不复权 none,可切 qfq)

- DailyBarRepository.get_range_many / stream_range_many_columns 增加 adjust 参数
  (默认 'none')→ SQL 层过滤口径,消除 stock_daily 混 source/adjust 污染因子的风险
- ResearchSpec / SelectionQuery 增加 price_adjustment(none|qfq),随 config_snapshot
  落库可溯源;ResearchService._load_daily 与 SelectionService 装配按口径取数
- tests/test_price_adjustment.py:repo 读取按 adjust 过滤(none/qfq 各自命中)、
  spec 默认与字段记录;全量 pytest 通过
This commit is contained in:
Simon
2026-09-09 00:32:55 +08:00
parent 4fa2bb748e
commit ef09d5b419
12 changed files with 153 additions and 13 deletions
+1 -1
View File
@@ -48,7 +48,7 @@ def client(tmp_path) -> TestClient:
bars = bars_dataframe_to_daily_bars(daily_df)
class _MemDailyRepo:
def get_range_many(self, symbols, start, end):
def get_range_many(self, symbols, start, end, adjust="none"):
out = []
for b in bars:
if b.symbol in symbols and start <= b.trade_date <= end: