arpm01 commited on
Commit
fafb7d8
·
1 Parent(s): 0c6a00e

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -1,13 +1,13 @@
1
  import gradio as gr
2
  from transformers import AutoTokenizer, AutoModelForSeq2SeqLM, pipeline
3
 
4
- tokenizer = AutoTokenizer.from_pretrained("human-centered-summarization/financial-summarization-pegasus")
5
 
6
  model = AutoModelForSeq2SeqLM.from_pretrained("human-centered-summarization/financial-summarization-pegasus")
7
 
8
  pipe = pipeline(task="summarization",
9
- model=model,
10
- tokenizer=tokenizer,)
11
 
12
  with open('text1.txt') as f:
13
  text1 = f.read()
 
1
  import gradio as gr
2
  from transformers import AutoTokenizer, AutoModelForSeq2SeqLM, pipeline
3
 
4
+ #tokenizer = AutoTokenizer.from_pretrained("human-centered-summarization/financial-summarization-pegasus")
5
 
6
  model = AutoModelForSeq2SeqLM.from_pretrained("human-centered-summarization/financial-summarization-pegasus")
7
 
8
  pipe = pipeline(task="summarization",
9
+ model=model,)
10
+ #tokenizer=tokenizer,)
11
 
12
  with open('text1.txt') as f:
13
  text1 = f.read()