mirror of
https://github.com/tiennm99/DocsGPT.git
synced 2026-10-15 02:16:08 +00:00
Refactor loader classes to accept inputs directly
This commit is contained in:
1 parent
030c2a740f
commit
0cb3d12d94
4 files changed
+9
-11
No files matched your search
@@ -10,7 +10,7 @@ class CrawlerLoader(BaseRemote):
|
||||
self.limit = limit # Set the limit for the number of pages to scrape
|
||||
|
||||
def load_data(self, inputs):
|
||||
url = inputs['data']
|
||||
url = inputs
|
||||
# Check if the input is a list and if it is, use the first element
|
||||
if isinstance(url, list) and url:
|
||||
url = url[0]
|
||||
|
||||
Reference in new issue
Block a user