Americo commited on
Commit
63c4e77
·
verified ·
1 Parent(s): 00011b4

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -2
app.py CHANGED
@@ -5,7 +5,9 @@ from langchain.prompts import ChatPromptTemplate
5
  from langchain.chat_models import ChatOpenAI
6
  import gradio as gr
7
 
8
- OPENAI_API_KEY = os.getenv("OPENAI_API_KEY") # add your OpenAI API Key
 
 
9
  # for this example I used Alphabet Inc 10-K Report 2022
10
  # https://www.sec.gov/Archives/edgar/data/1652044/000165204423000016/goog-20221231.htm
11
 
@@ -45,4 +47,4 @@ def get_response(query,history):
45
  return response_text
46
 
47
 
48
- gr.ChatInterface(fn=get_response,examples=['CI/CD', 'Kuberflow Pipeline', 'Cloud Build Service', 'TensorFlow Extended (TFX)'],title='Machine Learning Certification Chatbot').launch(auth=("username", "password"), debug=True)
 
5
  from langchain.chat_models import ChatOpenAI
6
  import gradio as gr
7
 
8
+ OPENAI_API_KEY = os.getenv("OPENAI_API_KEY")
9
+ username = os.getenv("username")
10
+ passw = os.getenv("pass")# add your OpenAI API Key
11
  # for this example I used Alphabet Inc 10-K Report 2022
12
  # https://www.sec.gov/Archives/edgar/data/1652044/000165204423000016/goog-20221231.htm
13
 
 
47
  return response_text
48
 
49
 
50
+ gr.ChatInterface(fn=get_response,examples=['CI/CD', 'Kuberflow Pipeline', 'Cloud Build Service', 'TensorFlow Extended (TFX)'],title='Machine Learning Chatbot').launch(auth=(username, passw), debug=True)