瀏覽代碼

WikiProjectTagger: Fix auto-assess when no current assessments.

tags/v0.3
Ben Kurtovic 7 年之前
父節點
當前提交
cc574cec6d
共有 1 個文件被更改,包括 2 次插入2 次删除
  1. +2
    -2
      earwigbot/tasks/wikiproject_tagger.py

+ 2
- 2
earwigbot/tasks/wikiproject_tagger.py 查看文件

@@ -350,8 +350,8 @@ class WikiProjectTagger(Task):
classes[value] += 1

values = tuple(classes.values())
if values:
best = max(values)
best = max(values)
if best:
confidence = float(best) / sum(values)
if confidence > 0.75:
rank = tuple(classes.keys())[values.index(best)]


Loading…
取消
儲存