facfox commited on
Commit
7320dec
·
1 Parent(s): 9040b05

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -2
app.py CHANGED
@@ -4,7 +4,8 @@ import openai
4
 
5
  def Question(Ask_Question):
6
  # pass the generated text to audio
7
- openai.api_key = "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"
 
8
 
9
  # Set up the model and prompt
10
  model_engine = "text-davinci-003"
@@ -12,7 +13,7 @@ def Question(Ask_Question):
12
  completion = openai.Completion.create(
13
  engine=model_engine,
14
  prompt=Ask_Question,
15
- max_tokens=2048,
16
  n=1,
17
  top_p=1,
18
  stop=None,
 
4
 
5
  def Question(Ask_Question):
6
  # pass the generated text to audio
7
+ #openai.api_key = "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"
8
+ openai.api_key = os.environ.get('ApiKey')
9
 
10
  # Set up the model and prompt
11
  model_engine = "text-davinci-003"
 
13
  completion = openai.Completion.create(
14
  engine=model_engine,
15
  prompt=Ask_Question,
16
+ # max_tokens=2048,
17
  n=1,
18
  top_p=1,
19
  stop=None,