Arhashmi's picture
Update app.py
0c954ca
raw
history blame
No virus
647 Bytes
import streamlit as st
from scrape import scrape_data_from_url
import response
data = "No data"
url = ""
def main():
global data
global url
st.title("Scraping App")
url = st.text_input("Enter URL:")
if st.button("Scrape Data"):
data = scrape_data_from_url(url)
st.success("Data scraped successfully!")
st.subheader("Scraped Data:")
st.write(data)
user_input = st.text_input("Enter your message:")
if st.button("Send"):
bot_response = response.get_response(user_input, data)
st.success("Bot Response:")
st.write(bot_response)
if __name__ == '__main__':
main()