osl-ai's picture
Update app.py
34f61d3
import gradio as gr
# Assuming this is the correct path to your model and it returns a usable object.
model = gr.Interface.load("models/NousResearch/Yarn-Mistral-7b-64k")
# Define a function that uses your model for inference, ensuring that the 'model' can predict.
def predict(input):
# Example prediction code. Replace with actual prediction logic.
return model(input)
# Create a Gradio interface
interface = gr.Interface(fn=predict, inputs="text", outputs="text")
# Launch the interface with share=True to create a public link.
interface.launch(share=True)