tests/final-tests 完成最终代码 #34

Merged
sangge merged 39 commits from tests/final-tests into main 2024-06-09 13:09:50 +08:00
Showing only changes of commit 72901463c6 - Show all commits

View File

@@ -60,7 +60,10 @@ def detectGPT(content: str):
classified_results = {"high": [], "medium": [], "low": [], "none": []}
for res in res_json:
try:
classified_results[res["Risk"]].append(
(res["Line"], text.split("\n")[res["Line"] - 1].strip())
)
except IndexError:
pass
return classified_results