Spaces:
Runtime error
Runtime error
import gradio as gr | |
from helpers import majority_vote_dicts | |
from model import process_document, process_pdf | |
input_interface = gr.inputs.File(label="Upload a PDF file") | |
description = "Gradio Demo for Donut trained on Quandri internal dataset." | |
gradio_interface = gr.Interface(fn=process_pdf, | |
inputs=input_interface, | |
outputs= 'json', | |
title="Demo: Donut π© for Document Parsing on Quandri Dataset", | |
description=description, | |
examples=[["data/aviva.pdf"], ["data/wawanesa.pdf"], ["data/sgi.pdf"]], | |
) | |
gradio_interface.launch(auth=("quandri", "Quandri@1234")) |