Spaces:
Sleeping
Sleeping
mattoofahad
commited on
Commit
·
42bef68
1
Parent(s):
17c52e7
removed cost calculator
Browse files- src/app.py +0 -11
src/app.py
CHANGED
@@ -59,17 +59,6 @@ def check_openai_api_key():
|
|
59 |
return False
|
60 |
|
61 |
|
62 |
-
def openai_request_cost(prompt_token, completion_token, model_name):
|
63 |
-
"""_summary_"""
|
64 |
-
if model_name == "gpt-3.5-turbo":
|
65 |
-
input_cost = 0.5 / 1e6
|
66 |
-
output_cost = 1.5 / 1e6
|
67 |
-
elif model_name == "gpt-4-turbo-preview":
|
68 |
-
input_cost = 1.5 / 1e6
|
69 |
-
output_cost = 2 / 1e6
|
70 |
-
return prompt_token * input_cost + completion_token * output_cost
|
71 |
-
|
72 |
-
|
73 |
def main():
|
74 |
"""_summary_"""
|
75 |
st.set_page_config(
|
|
|
59 |
return False
|
60 |
|
61 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
62 |
def main():
|
63 |
"""_summary_"""
|
64 |
st.set_page_config(
|