bstraehle commited on
Commit
a5f2386
·
verified ·
1 Parent(s): 12fba10

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -30,7 +30,7 @@ from assistants import (
30
 
31
  def chat(message, history, openai_api_key):
32
  if not openai_api_key:
33
- raise gr.Error("OpenAI API Key is required.")
34
  if not message:
35
  raise gr.Error("Message is required.")
36
 
@@ -93,5 +93,5 @@ gr.ChatInterface(
93
  cache_examples=False,
94
  additional_inputs=[
95
  gr.Textbox("", label="OpenAI API Key")
96
- ],
97
  ).launch()
 
30
 
31
  def chat(message, history, openai_api_key):
32
  if not openai_api_key:
33
+ raise gr.Error("OpenAI API Key is required (see additional inputs below).")
34
  if not message:
35
  raise gr.Error("Message is required.")
36
 
 
93
  cache_examples=False,
94
  additional_inputs=[
95
  gr.Textbox("", label="OpenAI API Key")
96
+ ],
97
  ).launch()