session5app / app.py
Isaras's picture
Create app.py
c3750ee verified
raw
history blame contribute delete
587 Bytes
# AI-Assisted Code — Academic Integrity Notice
# Generated with The App Builder. ESCP coursework.
# Student must be able to explain all code when asked.
import gradio as gr
def greet(name):
"""Return a greeting message."""
if not name.strip():
return "Please enter your name."
return f"Hello {name}, your HF app works!"
demo = gr.Interface(
fn=greet,
inputs=gr.Textbox(label="Your name"),
outputs=gr.Textbox(label="Output"),
title="My First Hugging Face App",
description="A basic Gradio app deployed on Hugging Face Spaces."
)
demo.launch()