Spaces:
Running
Running
File size: 861 Bytes
363fa3b 69db7ab 363fa3b |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 |
import gradio as gr
import pandas as pd
df = pd.read_csv("https://huggingface.co/datasets/stevhliu/supported-peft-models-methods/raw/main/pefty.csv")
def get_model_and_peft_method(task):
"""
Returns the model and PEFT methods that match a given task.
"""
return df[df['task'] == task].drop('task', axis=1)
demo = gr.Interface(
get_model_and_peft_method,
inputs=gr.Dropdown(["causal language modeling", "conditional generation", "sequence classification", "token classification", "text-to-image", "image classification", "image-to-text", "semantic segmentation"], label="task"),
outputs=gr.Dataframe(headers=["model", "peft method"], label="supported models and PEFT methods"),
title="PEFT methods",
description="Discover compatible PEFT methods for officially supported models for a given task."
)
demo.launch(debug=True) |