hyejoo commited on
Commit
840d1e4
1 Parent(s): f7d538b

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -13,8 +13,8 @@ def generate_answer(input_text):
13
  # input_ids = tokenizer(input_text, max_length=700, return_tensors="pt").input_ids
14
 
15
  # 모델 추론
16
- # output_ids = model.generate(input_ids, max_length=1024)
17
- output_ids = model.generate(input_ids, num_beams=10, top_k=10, max_length=1024)
18
 
19
  # 모델 출력을 텍스트로 디코딩
20
  output_text = tokenizer.decode(output_ids[0], skip_special_tokens=True)
 
13
  # input_ids = tokenizer(input_text, max_length=700, return_tensors="pt").input_ids
14
 
15
  # 모델 추론
16
+ output_ids = model.generate(input_ids, max_length=1024)
17
+ # output_ids = model.generate(input_ids, num_beams=10, top_k=10, max_length=1024)
18
 
19
  # 모델 출력을 텍스트로 디코딩
20
  output_text = tokenizer.decode(output_ids[0], skip_special_tokens=True)