smjain commited on
Commit
ab564bf
1 Parent(s): 8006e20

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -7,7 +7,7 @@ mdl = T5ForConditionalGeneration.from_pretrained("t5-small")
7
 
8
 
9
  def text2text_paraphrase(sentence1,sentence2):
10
- inp1 = "mrpc sentence1: "+sentence1
11
  inp2 = "sentence2: "+sentence2
12
  combined_inp=inp1+" "+inp2
13
  enc = text2text_tkn(combined_inp, return_tensors="pt")
@@ -17,5 +17,5 @@ def text2text_paraphrase(sentence1,sentence2):
17
 
18
  sent1=grad.Textbox(lines=1, label="Sentence1", placeholder="Text in English")
19
  sent2=grad.Textbox(lines=1, label="Sentence2", placeholder="Text in English")
20
- out=grad.Textbox(lines=1, label="Whether the sentence is acceptable or not")
21
  grad.Interface(text2text_paraphrase, inputs=[sent1,sent2], outputs=out).launch()
 
7
 
8
 
9
  def text2text_paraphrase(sentence1,sentence2):
10
+ inp1 = "rte sentence1: "+sentence1
11
  inp2 = "sentence2: "+sentence2
12
  combined_inp=inp1+" "+inp2
13
  enc = text2text_tkn(combined_inp, return_tensors="pt")
 
17
 
18
  sent1=grad.Textbox(lines=1, label="Sentence1", placeholder="Text in English")
19
  sent2=grad.Textbox(lines=1, label="Sentence2", placeholder="Text in English")
20
+ out=grad.Textbox(lines=1, label="Whether sentence2 is deductible from sentence1")
21
  grad.Interface(text2text_paraphrase, inputs=[sent1,sent2], outputs=out).launch()