Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -6,6 +6,7 @@ import os
|
|
6 |
|
7 |
model = AutoModelForSequenceClassification.from_pretrained("Reem333/Citaion-Classifier")
|
8 |
tokenizer = AutoTokenizer.from_pretrained("allenai/longformer-base-4096")
|
|
|
9 |
def extract_text_from_pdf(file_path):
|
10 |
text = ''
|
11 |
with fitz.open(file_path) as pdf_document:
|
@@ -50,7 +51,7 @@ with st.sidebar:
|
|
50 |
st.markdown("## About")
|
51 |
st.markdown('''
|
52 |
This is a tool to classify paper citations into different levels based on their number of citations.
|
53 |
-
Powered by Fine-Tuned [Longformer model](https://huggingface.co/Reem333/
|
54 |
''')
|
55 |
st.markdown("### Class Levels:")
|
56 |
st.markdown("- Level 1: Highly cited papers")
|
@@ -129,4 +130,4 @@ elif option == "PDF":
|
|
129 |
unsafe_allow_html=True
|
130 |
)
|
131 |
else:
|
132 |
-
st.text(label)
|
|
|
6 |
|
7 |
model = AutoModelForSequenceClassification.from_pretrained("Reem333/Citaion-Classifier")
|
8 |
tokenizer = AutoTokenizer.from_pretrained("allenai/longformer-base-4096")
|
9 |
+
|
10 |
def extract_text_from_pdf(file_path):
|
11 |
text = ''
|
12 |
with fitz.open(file_path) as pdf_document:
|
|
|
51 |
st.markdown("## About")
|
52 |
st.markdown('''
|
53 |
This is a tool to classify paper citations into different levels based on their number of citations.
|
54 |
+
Powered by Fine-Tuned [Longformer model](https://huggingface.co/Reem333/Citaion-Classifier) with custom data.
|
55 |
''')
|
56 |
st.markdown("### Class Levels:")
|
57 |
st.markdown("- Level 1: Highly cited papers")
|
|
|
130 |
unsafe_allow_html=True
|
131 |
)
|
132 |
else:
|
133 |
+
st.text(label)
|