Manjushri commited on
Commit
75df636
1 Parent(s): 8859aa1

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -8,8 +8,8 @@ model = AutoModelForCausalLM.from_pretrained("KoboldAI/OPT-2.7B-Nerybus-Mix")
8
 
9
  def chat(Prompt):
10
 
11
- input_ids = tokenizer(Prompt, repetition_penalty = 2.5, top_k = 75, return_tensors="pt").input_ids
12
- generated_ids = model.generate(input_ids, max_length=128)
13
  bot = tokenizer.decode(generated_ids[0], skip_special_tokens=True)
14
  return bot
15
 
 
8
 
9
  def chat(Prompt):
10
 
11
+ input_ids = tokenizer(Prompt, return_tensors="pt").input_ids
12
+ generated_ids = model.generate(input_ids, max_length=512, repetition_penalty = 2.5, top_k = 75)
13
  bot = tokenizer.decode(generated_ids[0], skip_special_tokens=True)
14
  return bot
15