Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -10,6 +10,7 @@ from tenacity import retry, wait_random_exponential, stop_after_attempt
|
|
| 10 |
# from termcolor import colored # doesn't actually work in Colab ¯\_(ツ)_/¯
|
| 11 |
|
| 12 |
GPT_MODEL = "gpt-3.5-turbo-1106"
|
|
|
|
| 13 |
|
| 14 |
def openai_api_calculate_cost(usage,model=GPT_MODEL):
|
| 15 |
pricing = {
|
|
|
|
| 10 |
# from termcolor import colored # doesn't actually work in Colab ¯\_(ツ)_/¯
|
| 11 |
|
| 12 |
GPT_MODEL = "gpt-3.5-turbo-1106"
|
| 13 |
+
openai.api_key = os.environ['OPENAI_API_KEY']
|
| 14 |
|
| 15 |
def openai_api_calculate_cost(usage,model=GPT_MODEL):
|
| 16 |
pricing = {
|