Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -6,7 +6,7 @@ import openai
|
|
6 |
from flask import Flask
|
7 |
import os
|
8 |
|
9 |
-
print(os.getenv('OPEN_AI_KEY'))
|
10 |
|
11 |
open_ai_api_key = os.getenv('OPEN_AI_KEY')
|
12 |
|
@@ -209,7 +209,7 @@ def decide(issue_id):
|
|
209 |
st.write(f"- {solution.content}")
|
210 |
|
211 |
if st.button("Get AI Decision"):
|
212 |
-
openai.api_key =
|
213 |
prompt = f"Given the following solutions for the issue '{issue.title}', which one is the most socio-democratic decision?\n"
|
214 |
for solution in solutions:
|
215 |
prompt += f"- {solution.content}\n"
|
|
|
6 |
from flask import Flask
|
7 |
import os
|
8 |
|
9 |
+
#print(os.getenv('OPEN_AI_KEY'))
|
10 |
|
11 |
open_ai_api_key = os.getenv('OPEN_AI_KEY')
|
12 |
|
|
|
209 |
st.write(f"- {solution.content}")
|
210 |
|
211 |
if st.button("Get AI Decision"):
|
212 |
+
openai.api_key = open_ai_api_key
|
213 |
prompt = f"Given the following solutions for the issue '{issue.title}', which one is the most socio-democratic decision?\n"
|
214 |
for solution in solutions:
|
215 |
prompt += f"- {solution.content}\n"
|