aaronmat1905 commited on
Commit
74019c1
1 Parent(s): e838b4f
Files changed (1) hide show
  1. app.py +2 -1
app.py CHANGED
@@ -26,7 +26,7 @@ model_path = "gemini-1.5-flash"
26
  FoodSafetyAssistant = genai.GenerativeModel(model_path, system_instruction=system_instruction)
27
 
28
  def respond(usertxt):
29
- response = FoodSafetyAssistant.send_message(usertxt)
30
  return response.text
31
 
32
  html_content = """
@@ -65,5 +65,6 @@ with gr.Blocks() as demo:
65
  output_text = gr.Textbox(label="Assistant Output", interactive=False, lines=5)
66
  submit_btn = gr.Button("Submit")
67
  submit_btn.click(respond, inputs=user_input, outputs=output_text)
 
68
 
69
  demo.launch()
 
26
  FoodSafetyAssistant = genai.GenerativeModel(model_path, system_instruction=system_instruction)
27
 
28
  def respond(usertxt):
29
+ response = FoodSafetyAssistant.generate_content(contents=[prompt]
30
  return response.text
31
 
32
  html_content = """
 
65
  output_text = gr.Textbox(label="Assistant Output", interactive=False, lines=5)
66
  submit_btn = gr.Button("Submit")
67
  submit_btn.click(respond, inputs=user_input, outputs=output_text)
68
+ gr.Dataframe(value = data)
69
 
70
  demo.launch()