ALVHB95 commited on
Commit
33a475f
·
1 Parent(s): 57d1004
Files changed (1) hide show
  1. app.py +4 -7
app.py CHANGED
@@ -31,7 +31,7 @@ from pydantic import BaseModel
31
  import shutil
32
 
33
  # Cell 1: Image Classification Model
34
- image_pipeline = pipeline(task="image-classification", model="rocioadlc/TrashNet_ResNet152V2")
35
 
36
  def predict_image(input_img):
37
  predictions = image_pipeline(input_img)
@@ -121,12 +121,9 @@ def chat_interface(question):
121
  else:
122
  return "Unexpected answer format"
123
 
124
- chatbot_gradio_app = gr.Interface(
125
- fn=chat_interface,
126
- inputs=[
127
- gr.inputs.Textbox(lines=1, label="Question"),
128
- ],
129
- outputs="text"
130
  )
131
 
132
  # Combine both interfaces into a single app
 
31
  import shutil
32
 
33
  # Cell 1: Image Classification Model
34
+ image_pipeline = pipeline(task="image-classification", model="microsoft/resnet-50")
35
 
36
  def predict_image(input_img):
37
  predictions = image_pipeline(input_img)
 
121
  else:
122
  return "Unexpected answer format"
123
 
124
+ chatbot_gradio_app = gr.ChatInterface(
125
+ fn=chat_interface,
126
+ title='Our doubts are traitors, And make us lose the good we oft might win, By fearing to attempt.'
 
 
 
127
  )
128
 
129
  # Combine both interfaces into a single app