langchain.document_loaders.ifixit.IFixitLoader

class langchain.document_loaders.ifixit.IFixitLoader(web_path: str)[source]

Load iFixit repair guides, device wikis and answers.

iFixit is the largest, open repair community on the web. The site contains nearly 100k repair manuals, 200k Questions & Answers on 42k devices, and all the data is licensed under CC-BY.

This loader will allow you to download the text of a repair guide, text of Q&A’s and wikis from devices on iFixit using their open APIs and web scraping.

Initialize with a web path.

Methods

__init__(web_path)

Initialize with a web path.

lazy_load()

A lazy loader for Documents.

load()

Load data into Document objects.

load_and_split([text_splitter])

Load Documents and split into chunks.

load_device([url_override, include_guides])

Loads a device

load_guide([url_override])

Load a guide

load_questions_and_answers([url_override])

Load a list of questions and answers.

load_suggestions([query, doc_type])

Load suggestions.

__init__(web_path: str)[source]

Initialize with a web path.

lazy_load() Iterator[Document]

A lazy loader for Documents.

load() List[Document][source]

Load data into Document objects.

load_and_split(text_splitter: Optional[TextSplitter] = None) List[Document]

Load Documents and split into chunks. Chunks are returned as Documents.

Parameters

text_splitter – TextSplitter instance to use for splitting documents. Defaults to RecursiveCharacterTextSplitter.

Returns

List of Documents.

load_device(url_override: Optional[str] = None, include_guides: bool = True) List[Document][source]

Loads a device

Parameters
  • url_override – A URL to override the default URL.

  • include_guides – Whether to include guides linked to from the device. Defaults to True.

Returns:

load_guide(url_override: Optional[str] = None) List[Document][source]

Load a guide

Parameters

url_override – A URL to override the default URL.

Returns: List[Document]

load_questions_and_answers(url_override: Optional[str] = None) List[Document][source]

Load a list of questions and answers.

Parameters

url_override – A URL to override the default URL.

Returns: List[Document]

static load_suggestions(query: str = '', doc_type: str = 'all') List[Document][source]

Load suggestions.

Parameters
  • query – A query string

  • doc_type – The type of document to search for. Can be one of “all”, “device”, “guide”, “teardown”, “answer”, “wiki”.

Returns:

Examples using IFixitLoader