nikunjcepatel commited on
Commit
a0dcbc6
·
verified ·
1 Parent(s): f2d06de

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -23,9 +23,9 @@ def generate_text(input_text):
23
  inputs["input_ids"],
24
  max_length=256, # Set max length for output
25
  num_return_sequences=1,
26
- temperature=0.8, # Control randomness (higher is more random)
27
  top_k=50, # Top-k sampling to limit vocabulary to top 50 choices
28
- top_p=0.95, # Nucleus sampling to choose tokens with 95% cumulative probability
29
  repetition_penalty=1.2, # Penalize repetition; increase if repetitions persist
30
  do_sample=True # Enable sampling for non-deterministic output
31
  )
 
23
  inputs["input_ids"],
24
  max_length=256, # Set max length for output
25
  num_return_sequences=1,
26
+ temperature=0.2, # Control randomness (higher is more random)
27
  top_k=50, # Top-k sampling to limit vocabulary to top 50 choices
28
+ top_p=0.8, # Nucleus sampling to choose tokens with 95% cumulative probability
29
  repetition_penalty=1.2, # Penalize repetition; increase if repetitions persist
30
  do_sample=True # Enable sampling for non-deterministic output
31
  )