Skip to content

Commit f3688a8

Browse files
authored
Pick a slot from 0 to batch_size-1 during run_interactive.py (#67)
* Pick a slot from 0 to batch_size-1 * Fix pyink
1 parent 637c59f commit f3688a8

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

run_interactive.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,7 @@ def main(argv):
120120
"<s>[INST] <<SYS>>\nYou are an AI assistant. You will be given a task. You must generate a detailed and long answer.\n<</SYS>>\n\nContinue the following story.\n\nKay didn't have shoes that fit her feet properly. She only wore sneakers, because the \nChoose from: [I] shoes fitted badly. [II] sneakers fitted badly. [/INST]",
121121
]
122122
for prompt in prompts:
123-
slot = random.randint(0, _BATCH_SIZE.value)
123+
slot = random.randint(0, _BATCH_SIZE.value - 1)
124124
tokens, true_length = token_utils.tokenize_and_pad(
125125
prompt, vocab, is_bos=True
126126
)

0 commit comments

Comments
 (0)