kusumakar commited on
Commit
669b780
1 Parent(s): 1705b5c

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +10 -2
app.py CHANGED
@@ -1,7 +1,15 @@
1
- import os
2
  import openai
 
 
 
3
  api_key = os.environ.get('OPENAI_API_KEY')
4
- openai.api_key = api_key
 
 
 
 
 
 
5
 
6
  import numpy as np
7
  from PIL import Image
 
 
1
  import openai
2
+ import os
3
+
4
+ # Access repository secret
5
  api_key = os.environ.get('OPENAI_API_KEY')
6
+
7
+ # Check if the secret is available
8
+ if api_key:
9
+ st.write("API Key:", api_key)
10
+ else:
11
+ st.write("API Key not found.")
12
+
13
 
14
  import numpy as np
15
  from PIL import Image