Skip to content

Commit ed6767f

Browse files
authored
Merge pull request #36 from MasanoriYamada/main
fix arg #35
2 parents 2b2e36e + a10adb7 commit ed6767f

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

trustllm_pkg/trustllm/generation/generation.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,10 @@ def _generation_hf(self, prompt, tokenizer, model, temperature):
5555
:return: The generated text as a string.
5656
"""
5757

58+
59+
5860
prompt = prompt2conversation(model_path=self.model_path,prompt=prompt,)
61+
5962
inputs = tokenizer([prompt])
6063
inputs = {k: torch.tensor(v).to(self.device) for k, v in inputs.items()}
6164
output_ids = model.generate(

0 commit comments

Comments
 (0)