Spaces:
Runtime error
Runtime error
Update text_download.py
Browse files- text_download.py +3 -3
text_download.py
CHANGED
|
@@ -11,10 +11,10 @@ TEXT_DOWNLOAD_DESCRIPTION = (
|
|
| 11 |
|
| 12 |
class TextDownloadTool(Tool):
|
| 13 |
name = "text_downloader"
|
| 14 |
-
inputs= {"url": {"type":
|
| 15 |
-
output_type=
|
| 16 |
description = TEXT_DOWNLOAD_DESCRIPTION
|
| 17 |
|
| 18 |
-
def
|
| 19 |
return BeautifulSoup(requests.get(url).text, features="html.parser").get_text()
|
| 20 |
|
|
|
|
| 11 |
|
| 12 |
class TextDownloadTool(Tool):
|
| 13 |
name = "text_downloader"
|
| 14 |
+
inputs= {"url": {"type": "string", "description": "url to download file from"}}
|
| 15 |
+
output_type= "string"
|
| 16 |
description = TEXT_DOWNLOAD_DESCRIPTION
|
| 17 |
|
| 18 |
+
def forward(self, url):
|
| 19 |
return BeautifulSoup(requests.get(url).text, features="html.parser").get_text()
|
| 20 |
|