Spaces:
Sleeping
Sleeping
| import gradio as gr | |
| from question_extractor import hf_predict # from your file | |
| def predict(file): | |
| return hf_predict(file) | |
| iface = gr.Interface( | |
| fn=predict, | |
| inputs=gr.File(type="filepath", label="file"), # label must be "file" | |
| outputs="text", | |
| title="Question Paper Extractor", | |
| ) | |
| if __name__ == "__main__": | |
| iface.launch() |