diff --git a/server.py b/server.py index 07e24df7..0fe022ad 100644 --- a/server.py +++ b/server.py @@ -1587,37 +1587,8 @@ def confirm_advice(): # ── 准确率统计API ── -@app.route("/api/stats/accuracy") -def get_accuracy_stats(): - data = _load_json(DATA_DIR / "accuracy_stats.json", {}) - return jsonify(data) - # ── 策略评估API ── -@app.route("/api/evaluation") -def get_evaluation(): - """返回所有策略的双维度评估结果""" - # 主数据源:evaluation.json - eval_data = _load_json(DATA_DIR / "evaluation.json", {}) - strategies = eval_data.get("strategies", []) - if strategies: - return jsonify(strategies) - - # 备选:从 decisions.json 的 evaluation 字段读取(尚未反写时的兼容) - decisions = read_decisions() - evals = [] - for d in decisions.get("decisions", []): - e = d.get("evaluation", []) - if e: - evals.append({ - "code": d["code"], - "name": d["name"], - "type": d.get("type", ""), - "current": d.get("current", ""), - "evaluations": e, - }) - return jsonify(evals) - @app.route("/api/evaluation/trigger", methods=["POST"]) def trigger_evaluation(): @@ -2280,16 +2251,6 @@ def api_research_log(): return jsonify({"log": [], "error": str(e)}) -@app.route("/api/evolution/dashboard") -def api_evolution_dashboard(): - """进化模块 Dashboard""" - try: - sys.path.insert(0, '/home/hmo/MoFin/evolution') - from evolution_api import get_evolution_dashboard - return jsonify(get_evolution_dashboard()) - except Exception as e: - return jsonify({'error': str(e)}), 500 - @app.route("/api/evolution/merge_b_group", methods=["POST"]) def api_evolution_merge_b_group(): @@ -2306,28 +2267,6 @@ def api_evolution_merge_b_group(): return jsonify({"error": str(e)}), 500 -@app.route("/api/evolution/health_trend") -def api_evolution_health_trend(): - """健康度趋势""" - try: - version = request.args.get('version', 'v_next4') - days = int(request.args.get('days', 30)) - sys.path.insert(0, '/home/hmo/MoFin/evolution') - from evolution_api import get_health_trend - return jsonify({'trend': get_health_trend(version, days)}) - except Exception as e: - return jsonify({'error': str(e)}), 500 - - -@app.route("/api/evolution/combo") -def api_evolution_combo(): - """组合方案 Dashboard (v_next4+v_mr regime分工 + v_combo回测)""" - try: - sys.path.insert(0, '/home/hmo/MoFin/evolution') - from evolution_api import get_combo_dashboard - return jsonify(get_combo_dashboard()) - except Exception as e: - return jsonify({'error': str(e)}), 500 # ── 📚 文档 Tab 端点(2026-08-11 新增,开源项目式文档体系)── diff --git a/static/index.html b/static/index.html index bd30f83c..88db2cbe 100644 --- a/static/index.html +++ b/static/index.html @@ -109,7 +109,7 @@ body { background: #0f0f13; color: #e2e8f0; } - + @@ -123,7 +123,6 @@ body { background: #0f0f13; color: #e2e8f0; }
-