mirror of
https://github.com/hwchase17/langchain.git
synced 2025-08-11 05:45:01 +00:00
Wiki loader lint (#6670)
This commit is contained in:
parent
1c81883d42
commit
2da1aab50b
@ -25,10 +25,14 @@ class WikipediaLoader(BaseLoader):
|
|||||||
|
|
||||||
Args:
|
Args:
|
||||||
query (str): The query string to search on Wikipedia.
|
query (str): The query string to search on Wikipedia.
|
||||||
lang (str, optional): The language code for the Wikipedia language edition. Defaults to "en".
|
lang (str, optional): The language code for the Wikipedia language edition.
|
||||||
load_max_docs (int, optional): The maximum number of documents to load. Defaults to 100.
|
Defaults to "en".
|
||||||
load_all_available_meta (bool, optional): Indicates whether to load all available metadata for each document. Defaults to False.
|
load_max_docs (int, optional): The maximum number of documents to load.
|
||||||
doc_content_chars_max (int, optional): The maximum number of characters for the document content. Defaults to 4000.
|
Defaults to 100.
|
||||||
|
load_all_available_meta (bool, optional): Indicates whether to load all
|
||||||
|
available metadata for each document. Defaults to False.
|
||||||
|
doc_content_chars_max (int, optional): The maximum number of characters
|
||||||
|
for the document content. Defaults to 4000.
|
||||||
"""
|
"""
|
||||||
self.query = query
|
self.query = query
|
||||||
self.lang = lang
|
self.lang = lang
|
||||||
@ -41,7 +45,8 @@ class WikipediaLoader(BaseLoader):
|
|||||||
Loads the query result from Wikipedia into a list of Documents.
|
Loads the query result from Wikipedia into a list of Documents.
|
||||||
|
|
||||||
Returns:
|
Returns:
|
||||||
List[Document]: A list of Document objects representing the loaded Wikipedia pages.
|
List[Document]: A list of Document objects representing the loaded
|
||||||
|
Wikipedia pages.
|
||||||
"""
|
"""
|
||||||
client = WikipediaAPIWrapper(
|
client = WikipediaAPIWrapper(
|
||||||
lang=self.lang,
|
lang=self.lang,
|
||||||
|
Loading…
Reference in New Issue
Block a user