Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -1,17 +1,5 @@
|
|
1 |
import openai
|
2 |
-
|
3 |
-
import streamlit as st
|
4 |
-
|
5 |
-
# Access repository secret
|
6 |
-
api_key = os.environ.get('OPENAI_API_KEY')
|
7 |
-
|
8 |
-
# Check if the secret is available
|
9 |
-
if api_key:
|
10 |
-
st.write("API Key:", api_key)
|
11 |
-
else:
|
12 |
-
st.write("API Key not found.")
|
13 |
-
|
14 |
-
|
15 |
import numpy as np
|
16 |
from PIL import Image
|
17 |
from transformers import AutoTokenizer, ViTFeatureExtractor, VisionEncoderDecoderModel, GPT2Tokenizer, GPT2LMHeadModel
|
|
|
1 |
import openai
|
2 |
+
openai.api_key = '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'
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
3 |
import numpy as np
|
4 |
from PIL import Image
|
5 |
from transformers import AutoTokenizer, ViTFeatureExtractor, VisionEncoderDecoderModel, GPT2Tokenizer, GPT2LMHeadModel
|