Spaces:
Runtime error
Runtime error
import gradio as gr | |
import tensorflow as tf | |
# Load your model | |
model = tf.keras.models.load_model("https://huggingface.co/GiladtheFixer/Text-Classifiy/resolve/main/my_model.h5") | |
# Define your input and output components | |
input_component = gr.Textbox() | |
output_component = gr.Textbox() | |
# Define your Gradio interface | |
interface = gr.Interface( | |
fn=model, | |
inputs=input_component, | |
outputs=output_component, | |
live=True, | |
) | |
# Launch the interface | |
interface.launch() |