From 3553345f5008d593bfd985ce2142a49aa2299548 Mon Sep 17 00:00:00 2001 From: QCQCQC <1220204124@zust.edu.cn> Date: Fri, 25 Apr 2025 18:55:55 +0800 Subject: [PATCH] =?UTF-8?q?search=E7=BB=93=E6=9E=9C=E6=A0=B9=E6=8D=AE?= =?UTF-8?q?=E7=9B=B8=E4=BC=BC=E5=BA=A6=E6=8E=92=E5=BA=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/router.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/app/router.py b/app/router.py index 740abd2..cda01a3 100644 --- a/app/router.py +++ b/app/router.py @@ -102,4 +102,6 @@ def search_error(query: ErrorQuery): "matched_layers": db_entry["layers"] }) + # 还需要根据相似度排序 + results.sort(key=lambda x: x["similarity"], reverse=True) return results