import gradio as gr import pandas as pd def load_csv(file): df = pd.read_csv(file) return df iface = gr.Interface( fn=load_csv, inputs="file", outputs="dataframe", title="CSV Loader", description="Load a CSV file and display its contents.", ) iface.launch()