From 16965f95d682351ec975bb9ffa0fb8803470775b Mon Sep 17 00:00:00 2001 From: Joseph Cheung Date: Wed, 1 Mar 2023 20:10:09 +0800 Subject: [PATCH] c --- searx/webapp.py | 2 +- searx/webapp1.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/searx/webapp.py b/searx/webapp.py index 4b815cf54..70fecc161 100755 --- a/searx/webapp.py +++ b/searx/webapp.py @@ -1751,7 +1751,7 @@ function send_modalchat(elem) prompt = prompt +'网页内容:\n' fulltext.sort((a, b) => { - if (a.cosineSimilarity(word,a) < b.cosineSimilarity(word,b)) { + if (cosineSimilarity(word,a) < cosineSimilarity(word,b)) { return -1 } else { return 1 diff --git a/searx/webapp1.py b/searx/webapp1.py index 4b815cf54..70fecc161 100644 --- a/searx/webapp1.py +++ b/searx/webapp1.py @@ -1751,7 +1751,7 @@ function send_modalchat(elem) prompt = prompt +'网页内容:\n' fulltext.sort((a, b) => { - if (a.cosineSimilarity(word,a) < b.cosineSimilarity(word,b)) { + if (cosineSimilarity(word,a) < cosineSimilarity(word,b)) { return -1 } else { return 1