Update app.py
Browse files
app.py
CHANGED
|
@@ -143,7 +143,7 @@ def quad(query,file):
|
|
| 143 |
#stext = resp[0]['summary_text']
|
| 144 |
|
| 145 |
# highlight,dff=score_fincat(answer)
|
| 146 |
-
return answer,summarize_text(answer),
|
| 147 |
|
| 148 |
|
| 149 |
# b6 = gr.Button("Get Sustainability")
|
|
@@ -153,7 +153,7 @@ def quad(query,file):
|
|
| 153 |
#iface = gr.Interface(fn=get_sustainability, inputs="textbox", title="CONBERT",description="SUSTAINABILITY TOOL", outputs=gr.HighlightedText(), allow_flagging="never")
|
| 154 |
#iface.launch()
|
| 155 |
|
| 156 |
-
iface = gr.Interface(fn=quad, inputs=[gr.inputs.Textbox(label='SEARCH QUERY'),gr.inputs.File(label='TXT FILE')], title="CONBERT",description="SUSTAINABILITY TOOL",article='Article', outputs=[gr.outputs.Textbox(label='Answer'),gr.outputs.Textbox(label='Summary'),gr.HighlightedText(label='
|
| 157 |
|
| 158 |
|
| 159 |
iface.launch()
|
|
|
|
| 143 |
#stext = resp[0]['summary_text']
|
| 144 |
|
| 145 |
# highlight,dff=score_fincat(answer)
|
| 146 |
+
return answer,summarize_text(answer),get_sustainability(answer),fls(answer)
|
| 147 |
|
| 148 |
|
| 149 |
# b6 = gr.Button("Get Sustainability")
|
|
|
|
| 153 |
#iface = gr.Interface(fn=get_sustainability, inputs="textbox", title="CONBERT",description="SUSTAINABILITY TOOL", outputs=gr.HighlightedText(), allow_flagging="never")
|
| 154 |
#iface.launch()
|
| 155 |
|
| 156 |
+
iface = gr.Interface(fn=quad, inputs=[gr.inputs.Textbox(label='SEARCH QUERY'),gr.inputs.File(label='TXT FILE')], title="CONBERT",description="SUSTAINABILITY TOOL",article='Article', outputs=[gr.outputs.Textbox(label='Answer'),gr.outputs.Textbox(label='Summary'),gr.HighlightedText(label='SUSTAINABILITY'),gr.HighlightedText(label='FLS')], allow_flagging="never")
|
| 157 |
|
| 158 |
|
| 159 |
iface.launch()
|