Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -10,7 +10,6 @@ import requests
|
|
10 |
from bs4 import BeautifulSoup
|
11 |
import time
|
12 |
|
13 |
-
st.query_params['q'] = ''
|
14 |
PATH_t = './checkpoint-7500/'
|
15 |
PATH = './checkpoint-18750/'
|
16 |
SEQ_LEN = 128
|
@@ -123,12 +122,13 @@ def main():
|
|
123 |
st.title("댓글 필터링 서비스")
|
124 |
|
125 |
# URL 입력 받기
|
126 |
-
|
127 |
-
|
128 |
-
|
|
|
|
|
129 |
if st.button("스크랩 시작"):
|
130 |
if url:
|
131 |
-
st.query_params['q'] = url
|
132 |
title, content, comments = get_comments(url)
|
133 |
|
134 |
# 결과 표시
|
|
|
10 |
from bs4 import BeautifulSoup
|
11 |
import time
|
12 |
|
|
|
13 |
PATH_t = './checkpoint-7500/'
|
14 |
PATH = './checkpoint-18750/'
|
15 |
SEQ_LEN = 128
|
|
|
122 |
st.title("댓글 필터링 서비스")
|
123 |
|
124 |
# URL 입력 받기
|
125 |
+
value = st.query_params['q']
|
126 |
+
if value:
|
127 |
+
url = st.text_input("url을 입력하세요",value=st.query_params['q'])
|
128 |
+
else:
|
129 |
+
url = st.text_input("url을 입력하세요")
|
130 |
if st.button("스크랩 시작"):
|
131 |
if url:
|
|
|
132 |
title, content, comments = get_comments(url)
|
133 |
|
134 |
# 결과 표시
|