import gradio as gr from gradio_pdf import PDF with gr.Blocks() as demo: pdf = PDF(label="Upload a PDF", interactive=True, height=800) name = gr.Textbox() pdf.upload(lambda f: f, pdf, name) demo.launch()