rashedalhuniti's picture
Update app.py
f042d67 verified
raw
history blame contribute delete
430 Bytes
import gradio as gr
from transformers import pipeline
# Create a pipeline using the model you want
pipe = pipeline("text-generation", model="inceptionai/jais-13b", trust_remote_code=True)
# Function to generate text
def generate_text(prompt):
return pipe(prompt)[0]['generated_text']
# Set up the Gradio interface
iface = gr.Interface(fn=generate_text, inputs="text", outputs="text")
# Launch the interface
iface.launch()