Update app.py
Browse files
app.py
CHANGED
|
@@ -37,16 +37,14 @@ def respond(message, history, budget, have_items, allergies):
|
|
| 37 |
|
| 38 |
with gr.Blocks() as demo:
|
| 39 |
gr.Markdown("## RecipEASY")
|
| 40 |
-
|
| 41 |
-
|
| 42 |
-
|
| 43 |
-
|
| 44 |
-
|
| 45 |
-
|
| 46 |
-
|
| 47 |
-
|
| 48 |
-
|
| 49 |
-
with gr.Tab("Talk with recipEASY! "):
|
| 50 |
-
chatbot_ui = gr.ChatInterface(fn=lambda msg, hist, budget, have_items, allergies: respond(msg, hist, budget, have_items, allergies))
|
| 51 |
|
| 52 |
demo.launch()
|
|
|
|
| 37 |
|
| 38 |
with gr.Blocks() as demo:
|
| 39 |
gr.Markdown("## RecipEASY")
|
| 40 |
+
budget = gr.Slider(
|
| 41 |
+
minimum=0, # lowest value
|
| 42 |
+
maximum=100, # highest value
|
| 43 |
+
step=1, # increment step
|
| 44 |
+
label="Enter Budget:"
|
| 45 |
+
)
|
| 46 |
+
have_items = gr.Textbox(label="Ingredients you have (comma separated)", placeholder="pasta,tomato,garlic")
|
| 47 |
+
allergies = gr.Textbox(label="Allergies (comma separated)", placeholder="gluten,soy")
|
| 48 |
+
chatbot_ui = gr.ChatInterface(fn=lambda msg, hist, budget, have_items, allergies: respond(msg, hist, budget, have_items, allergies))
|
|
|
|
|
|
|
| 49 |
|
| 50 |
demo.launch()
|