bstraehle commited on
Commit
0ecf209
·
1 Parent(s): 859fa91

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -1
app.py CHANGED
@@ -147,8 +147,10 @@ def invoke(openai_api_key, rag_option, prompt):
147
  result = llm_chain(llm, prompt)
148
  completion = result
149
  except Exception as e:
 
150
  raise gr.Error(e)
151
- wandb_log(prompt, completion, rag_option)
 
152
  return result
153
 
154
  description = """<strong>Overview:</strong> Context-aware multimodal reasoning application that demonstrates a <strong>large language model (LLM)</strong> with
 
147
  result = llm_chain(llm, prompt)
148
  completion = result
149
  except Exception as e:
150
+ completion = e
151
  raise gr.Error(e)
152
+ finally:
153
+ wandb_log(prompt, completion, rag_option)
154
  return result
155
 
156
  description = """<strong>Overview:</strong> Context-aware multimodal reasoning application that demonstrates a <strong>large language model (LLM)</strong> with