Skip to content

Commit 4fe34dc

Browse files
committed
add pad_token_id to generate string
1 parent 44e6db5 commit 4fe34dc

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

jsonformer/main.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -117,6 +117,7 @@ def generate_string(self) -> str:
117117
stopping_criteria=[
118118
StringStoppingCriteria(self.tokenizer, len(input_tokens[0]))
119119
],
120+
pad_token_id=self.tokenizer.eos_token_id,
120121
)
121122

122123
# Some models output the prompt as part of the response

0 commit comments

Comments
 (0)