Spaces:
Sleeping
Sleeping
Nathan Chang commited on
Commit ·
3ffb3b7
1
Parent(s): fab65bd
update to use HF secret
Browse files
app.py
CHANGED
|
@@ -44,8 +44,7 @@ h1 {
|
|
| 44 |
def generate_prompt():
|
| 45 |
try:
|
| 46 |
# Read the system prompt from file
|
| 47 |
-
|
| 48 |
-
system_prompt = f.read()
|
| 49 |
|
| 50 |
# Initialize OpenAI client
|
| 51 |
client = OpenAI(api_key=os.environ.get("OPENAI_API_KEY"))
|
|
|
|
| 44 |
def generate_prompt():
|
| 45 |
try:
|
| 46 |
# Read the system prompt from file
|
| 47 |
+
system_prompt = os.environ.get("SYSTEM_PROMPT")
|
|
|
|
| 48 |
|
| 49 |
# Initialize OpenAI client
|
| 50 |
client = OpenAI(api_key=os.environ.get("OPENAI_API_KEY"))
|