fix github account login issue (#132)

This commit is contained in:
KevinHuSh
2024-03-19 15:31:47 +08:00
committed by GitHub
parent 9da671b951
commit 9a843667b3
6 changed files with 15 additions and 9 deletions

View File

@ -76,6 +76,7 @@ def is_english(texts):
def tokenize(d, t, eng):
d["content_with_weight"] = t
t = re.sub(r"</?(table|td|caption|tr|th)( [^<>]{0,12})?>", " ", t)
if eng:
t = re.sub(r"([a-z])-([a-z])", r"\1\2", t)
d["content_ltks"] = " ".join([stemmer.stem(w)

View File

@ -29,7 +29,7 @@ class EsQueryer:
for t in arr:
if not re.match(r"[a-zA-Z]+$", t):
e += 1
return e * 1. / len(arr) >= 0.8
return e * 1. / len(arr) >= 0.7
@staticmethod
def rmWWW(txt):