From d53db732485df4112b0eb2eb126d3fc189c58154 Mon Sep 17 00:00:00 2001 From: H Lohaus Date: Fri, 15 Nov 2024 18:21:22 +0100 Subject: Update internet.py --- g4f/gui/server/internet.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'g4f') diff --git a/g4f/gui/server/internet.py b/g4f/gui/server/internet.py index a2d0165b..6426f608 100644 --- a/g4f/gui/server/internet.py +++ b/g4f/gui/server/internet.py @@ -67,7 +67,7 @@ def scrape_text(html: str, max_words: int = None) -> str: if select: select.extract() clean_text = "" - for paragraph in soup.select("p"): + for paragraph in soup.select("p, h1, h2, h3, h4, h5, h6"): text = paragraph.get_text() for line in text.splitlines(): words = [] -- cgit v1.2.3