update google drive file link in json
This commit is contained in:
@@ -98,13 +98,16 @@ def fuzzy_place_math(result_file_path, rules) -> float:
|
||||
for para in doc.paragraphs:
|
||||
words_list.extend(para.text.split())
|
||||
# Print out the list of extracted words
|
||||
print("Your Answers: ")
|
||||
print(words_list)
|
||||
fuzzy_score_list = []
|
||||
for word in words_list:
|
||||
if not any(ans in word for ans in expect):
|
||||
print("Wrong place:", word)
|
||||
return 0
|
||||
return 1
|
||||
|
||||
max_score = 0
|
||||
for ans in expect:
|
||||
score = fuzz.ratio(word, ans)
|
||||
max_score = max(max_score, score)
|
||||
fuzzy_score_list.append(max_score)
|
||||
return sum(fuzzy_score_list) / len(fuzzy_score_list)
|
||||
|
||||
def check_csv(result: str, rules: Dict[str, List[Dict[str, str]]]) -> float:
|
||||
"""
|
||||
|
||||
Reference in New Issue
Block a user