fix chat engines

do not use pop(key, default) since api assigns None to dict values


Former-commit-id: d52fae2fa8
This commit is contained in:
hiyouga
2024-05-20 00:36:43 +08:00
parent 6955042c10
commit 864da49139
3 changed files with 50 additions and 37 deletions

View File

@@ -68,8 +68,8 @@ class Template:
self,
tokenizer: "PreTrainedTokenizer",
messages: List[Dict[str, str]],
system: str,
tools: str,
system: Optional[str],
tools: Optional[str],
cutoff_len: int,
reserved_label_len: int,
) -> Sequence[Tuple[List[int], List[int]]]: