ashutoshzade commited on
Commit
8cf57d7
·
1 Parent(s): f623801

Update app.py

Browse files

Initial version

Files changed (1) hide show
  1. app.py +2 -1
app.py CHANGED
@@ -1,13 +1,14 @@
1
  import streamlit as st
2
  from transformers import pipeline
3
  from langchain.llms import GooglePalm
 
4
 
5
  #x = st.slider('Select a value')
6
  #st.write(x, 'squared is', x * x)
7
 
8
  #pipe = pipeline('sentiment-analysis')
9
 
10
- api_key = $GOOGLE_PALM_API_KEY
11
  llm = GooglePalm(google_api_key=api_key, temperature=0.1)
12
 
13
  text = st.text_area('enter text to get assistance!')
 
1
  import streamlit as st
2
  from transformers import pipeline
3
  from langchain.llms import GooglePalm
4
+ import os
5
 
6
  #x = st.slider('Select a value')
7
  #st.write(x, 'squared is', x * x)
8
 
9
  #pipe = pipeline('sentiment-analysis')
10
 
11
+ api_key = os.environ.getattribute("GOOGLE_PALM_API_KEY")
12
  llm = GooglePalm(google_api_key=api_key, temperature=0.1)
13
 
14
  text = st.text_area('enter text to get assistance!')