micrem73 commited on
Commit
4a9f337
1 Parent(s): 22dcb77

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -2
app.py CHANGED
@@ -11,14 +11,13 @@ tokenizer = GPT2Tokenizer.from_pretrained(
11
  shroom_generator = pipeline("text-generation", model=AutoModelWithLMHead.from_pretrained('micrem73/GePpeTto-finetuned-bolo2.0'),
12
  tokenizer='LorenzoDeMattei/GePpeTto',
13
  do_sample=True,
14
- max_length=100,
15
  top_k=50,
16
  top_p=0.95,
17
  repetition_penalty=9.5,
18
  temperature = 1.2 )
19
 
20
  def generator(inizia_la_storia = ''):
21
- shroom_result = shroom_generator(inizia_la_storia, max_length=120)
22
  return shroom_result[0]["generated_text"]
23
 
24
 
 
11
  shroom_generator = pipeline("text-generation", model=AutoModelWithLMHead.from_pretrained('micrem73/GePpeTto-finetuned-bolo2.0'),
12
  tokenizer='LorenzoDeMattei/GePpeTto',
13
  do_sample=True,
 
14
  top_k=50,
15
  top_p=0.95,
16
  repetition_penalty=9.5,
17
  temperature = 1.2 )
18
 
19
  def generator(inizia_la_storia = ''):
20
+ shroom_result = shroom_generator(inizia_la_storia, max_length=80)
21
  return shroom_result[0]["generated_text"]
22
 
23