eliujl commited on
Commit
7f1bb55
1 Parent(s): cbfda56

Correct a condition

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -197,7 +197,7 @@ def setup_prompt():
197
  return prompt
198
 
199
  def setup_em_llm(OPENAI_API_KEY, temperature, r_llm):
200
- if r_llm == gpt3p5 or r_llm == gpt4 and not OPENAI_API_KEY:
201
  # Set up OpenAI embeddings
202
  embeddings = OpenAIEmbeddings(openai_api_key=OPENAI_API_KEY)
203
  # Use Open AI LLM with gpt-3.5-turbo or gpt-4.
 
197
  return prompt
198
 
199
  def setup_em_llm(OPENAI_API_KEY, temperature, r_llm):
200
+ if r_llm == gpt3p5 or r_llm == gpt4 and OPENAI_API_KEY:
201
  # Set up OpenAI embeddings
202
  embeddings = OpenAIEmbeddings(openai_api_key=OPENAI_API_KEY)
203
  # Use Open AI LLM with gpt-3.5-turbo or gpt-4.