iseesaw commited on
Commit
a988b38
1 Parent(s): 224e409

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -1,9 +1,9 @@
1
-
2
  from openai import OpenAI
3
  import gradio as gr
4
 
5
- api_key = "token-abc123" # Replace with your key
6
- base_url = "http://localhost:8000/v1"
7
  client = OpenAI(api_key=api_key, base_url=base_url)
8
 
9
  def predict(message, history):
 
1
+ import os
2
  from openai import OpenAI
3
  import gradio as gr
4
 
5
+ api_key = os.environ.get("API_KEY") # Replace with your key
6
+ base_url = os.environ.get("BASE_URL")
7
  client = OpenAI(api_key=api_key, base_url=base_url)
8
 
9
  def predict(message, history):