fix(bot): 防递归重连 guard - 防止 on_disconnect → reconnect → disconnect 无限递归导致栈溢出
This commit is contained in:
@@ -0,0 +1,43 @@
|
||||
{
|
||||
"module": "reports",
|
||||
"version": "1.0",
|
||||
"purpose": "分析报告管理。存储和查询 MoFin 系统生成的各类分析报告(盘中/盘后/周报等)。",
|
||||
|
||||
"human_help": {
|
||||
"title": "报告管理",
|
||||
"description": [
|
||||
"MoFin 系统自动生成的分析报告存档。",
|
||||
"报告存储在 data/reports/ 目录下,每条报告为一个 JSON 文件。",
|
||||
"支持按类型筛选:盘中、盘后、周报等。"
|
||||
],
|
||||
"usage": [
|
||||
"GET /api/reports — 获取最近 100 条报告列表(含标题、类型、摘要)",
|
||||
"GET /api/report/<id> — 获取单条报告完整内容(支持前缀匹配)",
|
||||
"POST /api/update/report — 上传/更新报告"
|
||||
],
|
||||
"troubleshooting": [
|
||||
"报告列表为空 → 确认 cron 任务(开盘简报/收盘简报/策略评估)是否正常运行",
|
||||
"报告ID找不到 → 检查 reports/ 目录下的 JSON 文件名"
|
||||
]
|
||||
},
|
||||
|
||||
"ai_spec": {
|
||||
"apis": [
|
||||
{"method": "GET", "path": "/api/reports", "returns": "[{id, title, type, created_at, summary}] — 最近 100 条报告"},
|
||||
{"method": "GET", "path": "/api/report/<id>", "returns": "报告完整 JSON 内容(支持前缀匹配)"},
|
||||
{"method": "POST", "path": "/api/update/report", "returns": "{status:'ok', id}"}
|
||||
],
|
||||
"dependencies": [
|
||||
"data/reports/ — 报告 JSON 文件存储目录",
|
||||
"cron: 开盘简报 (9:35) / 收盘简报 (16:10) / 策略评估 (21:00) — LLM Cron"
|
||||
],
|
||||
"constraints": [
|
||||
"报告 ID 前缀匹配:先精确查找 {id}.json,再按前缀匹配",
|
||||
"报告类型:盘中/盘后/周报/其他"
|
||||
],
|
||||
"related_files": [
|
||||
"server.py — /api/reports, /api/report/<id>, /api/update/report",
|
||||
"docs/cron-catalog.md — LLM Cron 调度说明"
|
||||
]
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user