Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -8,6 +8,13 @@ import logging
|
|
| 8 |
logging.basicConfig(level=logging.INFO)
|
| 9 |
logger = logging.getLogger(__name__)
|
| 10 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 11 |
# Define fact_check_statement function here...
|
| 12 |
def fact_check_statement(query, api_key):
|
| 13 |
url = "https://api.wordlift.io/fact-check/score"
|
|
@@ -77,6 +84,7 @@ if submit_button and text_input:
|
|
| 77 |
#st.write(f"Claim Reviewed: {claim_reviewed}")
|
| 78 |
# Display the rating
|
| 79 |
if rating_value.isdigit():
|
|
|
|
| 80 |
st.progress(int(rating_value) / 5)
|
| 81 |
else:
|
| 82 |
st.write("Rating Value: ", rating_value)
|
|
|
|
| 8 |
logging.basicConfig(level=logging.INFO)
|
| 9 |
logger = logging.getLogger(__name__)
|
| 10 |
|
| 11 |
+
# Custom CSS to make the progress bar larger
|
| 12 |
+
def local_css(file_name):
|
| 13 |
+
with open(file_name) as f:
|
| 14 |
+
st.markdown(f'<style>{f.read()}</style>', unsafe_allow_html=True)
|
| 15 |
+
|
| 16 |
+
local_css("style.css")
|
| 17 |
+
|
| 18 |
# Define fact_check_statement function here...
|
| 19 |
def fact_check_statement(query, api_key):
|
| 20 |
url = "https://api.wordlift.io/fact-check/score"
|
|
|
|
| 84 |
#st.write(f"Claim Reviewed: {claim_reviewed}")
|
| 85 |
# Display the rating
|
| 86 |
if rating_value.isdigit():
|
| 87 |
+
st.markdown('## Truth rating')
|
| 88 |
st.progress(int(rating_value) / 5)
|
| 89 |
else:
|
| 90 |
st.write("Rating Value: ", rating_value)
|