import gradio as gr import pandas as pd def filter_records(records, part): return records[records["part"] == part] data = pd.read_csv('leaderboard.csv') demo = gr.Interface( filter_records, [ gr.Dataframe(data, headers=data.columns, datatype=data.dtypes), gr.Dropdown(["Toxicity", "Bias", "Value-alignment"]), ], "dataframe", description="Enter the part.", ) demo.launch()