natasha1704 victoria-latynina commited on
Commit
d64fafd
·
verified ·
1 Parent(s): ea73772

Update wellbe_agent.py (#8)

Browse files

- Update wellbe_agent.py (91096adeb55a8841a8739165a5cef2f81c355d2b)


Co-authored-by: Victoria Latynina <victoria-latynina@users.noreply.huggingface.co>

Files changed (1) hide show
  1. wellbe_agent.py +1 -1
wellbe_agent.py CHANGED
@@ -77,7 +77,7 @@ def answer_sync(question: str, openai_key: str, email: str, password: str) -> st
77
  """Blocking wrapper around :func:`answer_question`."""
78
  api_key = openai_key or os.getenv("OPENAI_API_KEY")
79
  openai.api_key = api_key
80
-
81
  if not question.strip():
82
  return "Please enter a question."
83
  try:
 
77
  """Blocking wrapper around :func:`answer_question`."""
78
  api_key = openai_key or os.getenv("OPENAI_API_KEY")
79
  openai.api_key = api_key
80
+ os.environ["OPENAI_API_KEY"] = api_key
81
  if not question.strip():
82
  return "Please enter a question."
83
  try: