Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -258,7 +258,7 @@ def get_links_from_page(url, visited_urls, domain_links):
|
|
258 |
if url in visited_urls:
|
259 |
return
|
260 |
|
261 |
-
if len(visited_urls) >
|
262 |
return
|
263 |
|
264 |
visited_urls.add(url)
|
@@ -289,14 +289,14 @@ def get_all_links_from_domain(domain_url):
|
|
289 |
return domain_links
|
290 |
|
291 |
# Example usage:
|
292 |
-
|
293 |
-
|
294 |
-
|
295 |
|
296 |
#########
|
297 |
-
|
298 |
-
|
299 |
-
|
300 |
|
301 |
|
302 |
|
|
|
258 |
if url in visited_urls:
|
259 |
return
|
260 |
|
261 |
+
if len(visited_urls) > 12:
|
262 |
return
|
263 |
|
264 |
visited_urls.add(url)
|
|
|
289 |
return domain_links
|
290 |
|
291 |
# Example usage:
|
292 |
+
domain_url = 'https://www.bofrost.de/'
|
293 |
+
links = get_all_links_from_domain(domain_url)
|
294 |
+
print("Links from the domain:", links)
|
295 |
|
296 |
#########
|
297 |
+
Assuming visited_urls is a list of URLs
|
298 |
+
for url in links:
|
299 |
+
vs = get_vectorstore_from_url(url)
|
300 |
|
301 |
|
302 |
|