feat: 完善 QMT 交易模块文档和配置展示功能

- 优化前端仪表盘界面
- 添加配置文件可视化展示
- 编写 QMT 模块配置文档
- 完善项目规则体系(KiloCode)
This commit is contained in:
2026-01-27 00:52:35 +08:00
parent 50ee1a5a0a
commit 4607555eaf
31 changed files with 5248 additions and 8621 deletions

View File

@@ -34,17 +34,17 @@
"output_type": "stream",
"text": [
"<class 'pandas.core.frame.DataFrame'>\n",
"Index: 9134824 entries, 0 to 20632\n",
"Index: 9336127 entries, 0 to 25845\n",
"Data columns (total 2 columns):\n",
" # Column Dtype \n",
"--- ------ ----- \n",
" 0 ts_code object\n",
" 1 trade_date object\n",
"dtypes: object(2)\n",
"memory usage: 209.1+ MB\n",
"memory usage: 213.7+ MB\n",
"None\n",
"20251120\n",
"start_date: 20251121\n"
"20260116\n",
"start_date: 20260119\n"
]
}
],
@@ -61,7 +61,7 @@
" max_date = df['trade_date'].max()\n",
"\n",
"print(max_date)\n",
"trade_cal = pro.trade_cal(exchange='', start_date='20170101', end_date='20251220')\n",
"trade_cal = pro.trade_cal(exchange='', start_date='20170101', end_date='20260201')\n",
"trade_cal = trade_cal[trade_cal['is_open'] == 1] # 只保留交易日\n",
"trade_dates = trade_cal[trade_cal['cal_date'] > max_date]['cal_date'].tolist()\n",
"start_date = min(trade_dates)\n",
@@ -84,27 +84,16 @@
"name": "stdout",
"output_type": "stream",
"text": [
"任务 20251218 完成\n",
"任务 20251219 完成\n",
"任务 20251217 完成\n",
"任务 20251216 完成\n",
"任务 20251215 完成\n",
"任务 20251212 完成\n",
"任务 20251211 完成\n",
"任务 20251210 完成\n",
"任务 20251209 完成\n",
"任务 20251208 完成\n",
"任务 20251205 完成\n",
"任务 20251204 完成\n",
"任务 20251203 完成\n",
"任务 20251202 完成\n",
"任务 20251201 完成\n",
"任务 20251128 完成\n",
"任务 20251127 完成\n",
"任务 20251126 完成\n",
"任务 20251125 完成\n",
"任务 20251124 完成\n",
"任务 20251121 完成\n"
"任务 20260129 完成\n",
"任务 20260130 完成\n",
"任务 20260128 完成\n",
"任务 20260127 完成\n",
"任务 20260126 完成\n",
"任务 20260123 完成\n",
"任务 20260122 完成\n",
"任务 20260121 完成\n",
"任务 20260120 完成\n",
"任务 20260119 完成\n"
]
}
],
@@ -193,59 +182,72 @@
"name": "stdout",
"output_type": "stream",
"text": [
" ts_code trade_date buy_sm_vol buy_sm_amount sell_sm_vol \\\n",
"0 002593.SZ 20251121 369428 21109.32 239444 \n",
"1 300405.SZ 20251121 173424 11775.01 115988 \n",
"2 001336.SZ 20251121 11378 2729.92 10423 \n",
"3 002403.SZ 20251121 24219 3104.96 19841 \n",
"4 688268.SH 20251121 12369 7423.62 12330 \n",
"... ... ... ... ... ... \n",
"5156 000881.SZ 20251121 146959 11936.56 155068 \n",
"5157 300676.SZ 20251121 21428 9913.61 15092 \n",
"5158 603138.SH 20251121 31243 4558.85 30559 \n",
"5159 301526.SZ 20251121 172815 9552.38 105860 \n",
"5160 300903.SZ 20251121 124772 20586.88 96098 \n",
" ts_code trade_date buy_sm_vol buy_sm_amount sell_sm_vol \\\n",
"0 300284.SZ 20260123 57213 4682.01 45561 \n",
"1 002835.SZ 20260123 10930 1886.39 9809 \n",
"2 603175.SH 20260123 28945 21106.65 29993 \n",
"3 600284.SH 20260123 62561 5324.31 55101 \n",
"4 300855.SZ 20260123 41944 15903.55 33566 \n",
"... ... ... ... ... ... \n",
"25876 600211.SH 20260119 10915 4796.09 12174 \n",
"25877 601229.SH 20260119 225161 21704.91 267726 \n",
"25878 003042.SZ 20260119 17500 2893.60 11703 \n",
"25879 601155.SH 20260119 75731 11076.12 70817 \n",
"25880 600169.SH 20260119 81734 2005.16 84188 \n",
"\n",
" sell_sm_amount buy_md_vol buy_md_amount sell_md_vol sell_md_amount \\\n",
"0 13673.67 256325 14655.03 298786 17088.39 \n",
"1 7859.14 154296 10473.88 176589 11973.97 \n",
"2 2498.94 5274 1266.93 5893 1415.57 \n",
"3 2546.44 17292 2218.64 18180 2333.03 \n",
"4 7430.97 16104 9682.18 16670 10042.76 \n",
"... ... ... ... ... ... \n",
"5156 12623.78 107103 8717.66 97089 7896.18 \n",
"5157 6975.73 17857 8249.34 16607 7679.15 \n",
"5158 4458.47 15126 2208.57 11879 1733.73 \n",
"5159 5855.69 155749 8607.76 160962 8892.48 \n",
"5160 15867.99 92082 15223.39 105748 17449.56 \n",
" sell_sm_amount buy_md_vol buy_md_amount sell_md_vol sell_md_amount \\\n",
"0 3728.28 48486 3966.28 59366 4856.95 \n",
"1 1693.39 6499 1121.44 6017 1038.84 \n",
"2 21840.97 22701 16511.38 23142 16835.79 \n",
"3 4687.48 68181 5800.70 62114 5285.81 \n",
"4 12712.79 35383 13409.44 40111 15213.47 \n",
"... ... ... ... ... ... \n",
"25876 5348.74 9594 4215.26 8253 3626.54 \n",
"25877 25799.99 204041 19664.19 207361 19990.67 \n",
"25878 1933.74 11780 1946.25 14398 2379.72 \n",
"25879 10351.64 45622 6659.41 46251 6765.59 \n",
"25880 2063.68 129391 3172.21 137053 3360.95 \n",
"\n",
" buy_lg_vol buy_lg_amount sell_lg_vol sell_lg_amount buy_elg_vol \\\n",
"0 125303 7153.65 190306 10868.03 13733 \n",
"1 68396 4621.42 100633 6820.12 12166 \n",
"2 326 77.32 662 159.66 0 \n",
"3 7131 916.27 8891 1137.58 0 \n",
"4 9155 5523.81 9780 5877.77 2793 \n",
"... ... ... ... ... ... \n",
"5156 63727 5186.84 54928 4460.74 8415 \n",
"5157 12528 5781.44 16425 7596.83 3906 \n",
"5158 5884 857.88 8048 1175.32 0 \n",
"5159 63089 3481.66 115498 6376.52 13568 \n",
"5160 58186 9624.92 77536 12811.46 25445 \n",
" buy_lg_vol buy_lg_amount sell_lg_vol sell_lg_amount buy_elg_vol \\\n",
"0 39133 3201.55 32920 2693.69 6576 \n",
"1 4067 702.11 4633 799.04 241 \n",
"2 11291 8249.67 11377 8302.90 3400 \n",
"3 46517 3960.29 57644 4906.75 23366 \n",
"4 24315 9212.24 24640 9342.34 5111 \n",
"... ... ... ... ... ... \n",
"25876 5507 2419.57 5204 2286.10 2 \n",
"25877 134694 12983.30 86737 8363.03 24453 \n",
"25878 4038 668.49 7218 1194.87 0 \n",
"25879 23725 3458.86 23634 3453.46 21891 \n",
"25880 63062 1545.61 49278 1208.05 5904 \n",
"\n",
" buy_elg_amount sell_elg_vol sell_elg_amount net_mf_vol net_mf_amount \n",
"0 781.20 36253 2069.12 -103672 -5866.51 \n",
"1 813.01 15071 1030.08 -34131 -2297.62 \n",
"2 0.00 0 0.00 -1180 -271.00 \n",
"3 0.00 1730 222.81 194 30.22 \n",
"4 1708.30 1640 986.41 476 282.30 \n",
"... ... ... ... ... ... \n",
"5156 686.43 19119 1546.77 -50922 -4113.23 \n",
"5157 1805.21 7595 3497.90 -4085 -1873.36 \n",
"5158 0.00 1768 257.78 713 110.42 \n",
"5159 744.87 22900 1261.99 -64224 -3539.76 \n",
"5160 4179.40 21103 3485.60 -29335 -4855.38 \n",
" buy_elg_amount sell_elg_vol sell_elg_amount net_mf_vol \\\n",
"0 539.18 13561 1110.11 -4914 \n",
"1 41.60 1278 220.26 1923 \n",
"2 2437.55 1825 1325.59 1620 \n",
"3 1991.65 25767 2196.91 46602 \n",
"4 1934.73 8437 3191.36 -19491 \n",
"... ... ... ... ... \n",
"25876 0.88 388 170.41 -44 \n",
"25877 2359.23 26525 2557.95 -37774 \n",
"25878 0.00 0 0.00 6587 \n",
"25879 3125.39 26267 3749.10 28653 \n",
"25880 144.65 9571 234.95 -10865 \n",
"\n",
"[5161 rows x 20 columns]\n"
" net_mf_amount \n",
"0 -391.89 \n",
"1 333.04 \n",
"2 1372.40 \n",
"3 3982.07 \n",
"4 -7354.89 \n",
"... ... \n",
"25876 -16.04 \n",
"25877 -3603.98 \n",
"25878 1092.73 \n",
"25879 4152.29 \n",
"25880 -256.23 \n",
"\n",
"[25881 rows x 20 columns]\n"
]
}
],