Spaces:
Runtime error
Runtime error
samarthagarwal23
commited on
Commit
•
31f12cb
1
Parent(s):
c20cdc3
Update app.py
Browse files
app.py
CHANGED
@@ -6,7 +6,7 @@ os.system("pip install pdfminer.six rank_bm25 torch transformers")
|
|
6 |
from gradio.mix import Series
|
7 |
#import re
|
8 |
from rank_bm25 import BM25Okapi
|
9 |
-
|
10 |
import torch
|
11 |
from transformers import pipeline
|
12 |
import pdfminer
|
@@ -120,7 +120,7 @@ iface = gr.Interface(
|
|
120 |
inputs = [gr.inputs.File(label="input pdf file"), gr.inputs.Textbox(label="Question:")],
|
121 |
outputs = [gr.outputs.HTML(label="Top 1 answer"), gr.outputs.HTML(label="Top 2 answer")],
|
122 |
examples=examples,
|
123 |
-
theme = "
|
124 |
title = "Question Answering on annual reports",
|
125 |
description = "Navigate long annual reports by using Machine learning to answer your questions. \nSimply upload any annual report pdf you are interested in and ask model a question OR load an example from below."
|
126 |
)
|
|
|
6 |
from gradio.mix import Series
|
7 |
#import re
|
8 |
from rank_bm25 import BM25Okapi
|
9 |
+
import string
|
10 |
import torch
|
11 |
from transformers import pipeline
|
12 |
import pdfminer
|
|
|
120 |
inputs = [gr.inputs.File(label="input pdf file"), gr.inputs.Textbox(label="Question:")],
|
121 |
outputs = [gr.outputs.HTML(label="Top 1 answer"), gr.outputs.HTML(label="Top 2 answer")],
|
122 |
examples=examples,
|
123 |
+
theme = "grass",
|
124 |
title = "Question Answering on annual reports",
|
125 |
description = "Navigate long annual reports by using Machine learning to answer your questions. \nSimply upload any annual report pdf you are interested in and ask model a question OR load an example from below."
|
126 |
)
|