textmachine/backend/internal/lang/data/refusal.txt

25 lines
1.4 KiB
Text
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# Universal refusal blacklist (pair-14 §3, ported 1:1 from eval/refusal_bench.py). Engine safety data:
# a model can refuse in ANY language regardless of the book's pair, so EVERY pattern here fires for EVERY
# book (the ja→ru golden flags a Russian refusal with NO langpack). ONE regex per non-comment line, joined
# with "|" under (?im); order is immaterial to the boolean match but preserved.
# NOTE: the `# --- xx ---` markers are ORGANIZATIONAL comments, NOT functional scoping — RefusalPatterns()
# reads every line flat into the one universal set. Deleting a language's lines TRIMS that universal set
# (drops those phrases for ALL books); it does NOT "turn off" detection for one pair. Add a language's phrases
# = add lines under (or beside) its marker.
# --- en ---
I (?:can(?:'|no)t|cannot|won'?t|am (?:not able|unable)) (?:to )?(?:assist|help|translate|continue|provide|fulfill)
I'?m sorry,? but
against (?:my|our) (?:content )?polic
content polic(?:y|ies)
# --- ru ---
не могу (?:помочь|перевести|продолжить|выполнить)
я не буду переводить
противоречит (?:политике|правилам)
# --- ja ---
としてお答えできません
申し訳ありませんが
# --- zh ---
我(?:不能|无法)(?:协助|翻译|继续)
抱歉[,]
# --- universal explicit marker ---
^\s*\[?(?:REFUSED|ОТКАЗ)\]?\s*$