ValadisCERTH's picture
Update app.py
89d0aed
from transformers import pipeline
import gradio as gr
from helper import dates_binding
title = "Date Identification Demo"
description = "This is a simple demo just for demonstration purposes for the Serco team, to validate the first results of the Natural Language module concerning the identification of dates"
examples = [
["Earthquake located in Rome, Italy in 01/01/23 with magnitude greater than 6.2"],
["Earthquake located in Rome, Italy in 1-1-2023 with magnitude greater than 6.2"],
["Earthquake located in Rome, Italy in 1/1/23 with magnitude greater than 6.2"],
["Earthquake located in Rome, Italy in January 1, 2023 with magnitude greater than 6.2"],
["Earthquake located in Rome, Italy in Jan 1, 23 with magnitude greater than 6.2"],
["Earthquake located in Rome, Italy in 1 January 2023 with magnitude greater than 6.2"],
["Earthquake located in Rome, Italy in 1 Jan 23 with magnitude greater than 6.2"],
["Earthquake located in Rome, Italy in January 2023 with magnitude greater than 6.2"],
["Earthquake located in Rome, Italy in Jan 2023 with magnitude greater than 6.2"],
]
gr.Interface(
fn=dates_binding,
inputs="text",
outputs="text",
title=title,
description=description,
examples=examples,
enable_queue=True,
).launch()