cryogenic22 commited on
Commit
2d6015c
·
verified ·
1 Parent(s): b0e5312

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -2
app.py CHANGED
@@ -374,8 +374,11 @@ def main():
374
  st.warning("Please enter your Anthropic API Key in the sidebar to continue.")
375
  return
376
 
377
- # Initialize Anthropic client
378
- anthropic_client = Anthropic(api_key=api_key)
 
 
 
379
 
380
  # Initialize database with synthetic data
381
  if "db" not in st.session_state:
 
374
  st.warning("Please enter your Anthropic API Key in the sidebar to continue.")
375
  return
376
 
377
+ # Set the API key as an environment variable
378
+ os.environ["ANTHROPIC_API_KEY"] = api_key
379
+
380
+ # Initialize Anthropic client using default settings
381
+ anthropic_client = Anthropic() # Uses API key from environment variable
382
 
383
  # Initialize database with synthetic data
384
  if "db" not in st.session_state: