GianJSX commited on
Commit
d6579b5
1 Parent(s): 490445b

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +6 -0
app.py CHANGED
@@ -2,12 +2,18 @@ from AssistantService import GPTAssistant
2
  from openai.error import AuthenticationError
3
  import streamlit as st
4
  import configparser
 
5
 
6
  config = configparser.ConfigParser()
7
  config.read('config.ini')
8
  if 'DEFAULT' in config:
9
  assistant_api_key = config['DEFAULT'].get('API-KEY', '')
10
 
 
 
 
 
 
11
  st.title("Web Scraping Assistant")
12
  st.write("This app helps you to extract data from HTML code using web scraping. It uses GPT-3.5-turbo to generate the code for you.")
13
  st.write("Contribute to this project on [GitHub](https://github.com/CognitiveLabs/GPT-auto-webscraping)")
 
2
  from openai.error import AuthenticationError
3
  import streamlit as st
4
  import configparser
5
+ import os
6
 
7
  config = configparser.ConfigParser()
8
  config.read('config.ini')
9
  if 'DEFAULT' in config:
10
  assistant_api_key = config['DEFAULT'].get('API-KEY', '')
11
 
12
+ os.environ["LANGCHAIN_TRACING_V2"]="true"
13
+ os.environ["LANGCHAIN_ENDPOINT"]="https://api.smith.langchain.com"
14
+ os.environ["LANGCHAIN_API_KEY"]=st.secrets["LANGCHAIN_API_KEY"]
15
+ os.environ["LANGCHAIN_PROJECT"]=st.secrets["LANGCHAIN_PROJECT"]
16
+
17
  st.title("Web Scraping Assistant")
18
  st.write("This app helps you to extract data from HTML code using web scraping. It uses GPT-3.5-turbo to generate the code for you.")
19
  st.write("Contribute to this project on [GitHub](https://github.com/CognitiveLabs/GPT-auto-webscraping)")