• Import from "@langchain/community/document_loaders/web/couchbase" instead. This entrypoint will be removed in 0.3.0.

loader for couchbase document

Hierarchy (view full)

Implements

Constructors

  • construct Couchbase document loader with a requirement for couchbase cluster client

    Parameters

    • client: Cluster

      { Cluster } [ couchbase connected client to connect to database ]

    • query: string

      { string } [ query to get results from while loading the data ]

    • OptionalpageContentFields: string[]

      { Array } [ filters fields of the document and shows these only ]

    • OptionalmetadataFields: string[]

      { Array } [ metadata fields required ]

    Returns CouchbaseDocumentLoader

Methods

  • Function to load documents based on iterator rather than full load

    Returns AsyncIterable<Document<Record<string, any>>>

    [ Returns an iterator to fetch documents ]

  • Parameters

    • Optionalsplitter: BaseDocumentTransformer<DocumentInterface<Record<string, any>>[], DocumentInterface<Record<string, any>>[]>

    Returns Promise<Document<Record<string, any>>[]>

    A Promise that resolves with an array of Document instances, each split according to the provided TextSplitter.

    Use this.load() and splitter.splitDocuments() individually. Loads the documents and splits them using a specified text splitter.