import gradio as gr from transformers import pipeline pipe = pipeline("text-generation", model="mistralai/Mistral-7B-v0.1") #generates an AI description of your character def describe(names): return "Hello " + pipe(names) + "!!" iface = gr.Interface(fn=describe, inputs=gr.Textbox(label="Your DND character",show_label=True), outputs=gr.Textbox(label="The character",show_label=True)) iface.launch()