id
stringlengths
14
15
text
stringlengths
35
2.51k
source
stringlengths
61
154
ddfe0d59a602-0
langchain.retrievers.chatgpt_plugin_retriever.ChatGPTPluginRetriever¶ class langchain.retrievers.chatgpt_plugin_retriever.ChatGPTPluginRetriever(*, url: str, bearer_token: str, top_k: int = 3, filter: Optional[dict] = None, aiosession: Optional[ClientSession] = None)[source]¶ Bases: BaseRetriever, BaseModel Create a ne...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.chatgpt_plugin_retriever.ChatGPTPluginRetriever.html
5012a61bd058-0
langchain.retrievers.document_compressors.chain_extract.LLMChainExtractor¶ class langchain.retrievers.document_compressors.chain_extract.LLMChainExtractor(*, llm_chain: ~langchain.chains.llm.LLMChain, get_input: ~typing.Callable[[str, ~langchain.schema.Document], dict] = <function default_get_input>)[source]¶ Bases: Ba...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.document_compressors.chain_extract.LLMChainExtractor.html
ea689f40f003-0
langchain.retrievers.self_query.weaviate.WeaviateTranslator¶ class langchain.retrievers.self_query.weaviate.WeaviateTranslator[source]¶ Bases: Visitor Logic for converting internal query language elements to valid filters. Methods __init__() visit_comparison(comparison) Translate a Comparison. visit_operation(operation...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.self_query.weaviate.WeaviateTranslator.html
bf013579237b-0
langchain.retrievers.svm.create_index¶ langchain.retrievers.svm.create_index(contexts: List[str], embeddings: Embeddings) → ndarray[source]¶ Create an index of embeddings for a list of contexts. :param contexts: List of contexts to embed. :param embeddings: Embeddings model to use. Returns Index of embeddings.
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.svm.create_index.html
18d4681ffc4c-0
langchain.retrievers.self_query.qdrant.QdrantTranslator¶ class langchain.retrievers.self_query.qdrant.QdrantTranslator(metadata_key: str)[source]¶ Bases: Visitor Logic for converting internal query language elements to valid filters. Methods __init__(metadata_key) visit_comparison(comparison) Translate a Comparison. vi...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.self_query.qdrant.QdrantTranslator.html
2ec254dda68a-0
langchain.retrievers.document_compressors.base.BaseDocumentCompressor¶ class langchain.retrievers.document_compressors.base.BaseDocumentCompressor[source]¶ Bases: BaseModel, ABC Base abstraction interface for document compression. Create a new model by parsing and validating input data from keyword arguments. Raises Va...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.document_compressors.base.BaseDocumentCompressor.html
ef4a092dea11-0
langchain.retrievers.document_compressors.chain_filter.LLMChainFilter¶ class langchain.retrievers.document_compressors.chain_filter.LLMChainFilter(*, llm_chain: ~langchain.chains.llm.LLMChain, get_input: ~typing.Callable[[str, ~langchain.schema.Document], dict] = <function default_get_input>)[source]¶ Bases: BaseDocume...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.document_compressors.chain_filter.LLMChainFilter.html
659a74547dbc-0
langchain.retrievers.document_compressors.base.DocumentCompressorPipeline¶ class langchain.retrievers.document_compressors.base.DocumentCompressorPipeline(*, transformers: List[Union[BaseDocumentTransformer, BaseDocumentCompressor]])[source]¶ Bases: BaseDocumentCompressor Document compressor that uses a pipeline of tra...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.document_compressors.base.DocumentCompressorPipeline.html
6fe640aaaee7-0
langchain.retrievers.multi_query.LineList¶ class langchain.retrievers.multi_query.LineList(*, lines: List[str])[source]¶ Bases: BaseModel Create a new model by parsing and validating input data from keyword arguments. Raises ValidationError if the input data cannot be parsed to form a valid model. param lines: List[str...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.multi_query.LineList.html
09f06c01c04b-0
langchain.retrievers.kendra.DocumentAttributeValue¶ class langchain.retrievers.kendra.DocumentAttributeValue(*, DateValue: Optional[str] = None, LongValue: Optional[int] = None, StringListValue: Optional[List[str]] = None, StringValue: Optional[str] = None, **extra_data: Any)[source]¶ Bases: BaseModel Create a new mode...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.kendra.DocumentAttributeValue.html
1793589aa7e0-0
langchain.retrievers.remote_retriever.RemoteLangChainRetriever¶ class langchain.retrievers.remote_retriever.RemoteLangChainRetriever(*, url: str, headers: Optional[dict] = None, input_key: str = 'message', response_key: str = 'response', page_content_key: str = 'page_content', metadata_key: str = 'metadata')[source]¶ B...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.remote_retriever.RemoteLangChainRetriever.html
f1f6f67a4c01-0
langchain.retrievers.databerry.DataberryRetriever¶ class langchain.retrievers.databerry.DataberryRetriever(datastore_url: str, top_k: Optional[int] = None, api_key: Optional[str] = None)[source]¶ Bases: BaseRetriever Retriever that uses the Databerry API. Methods __init__(datastore_url[, top_k, api_key]) aget_relevant_...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.databerry.DataberryRetriever.html
41eb1361f8ae-0
langchain.retrievers.docarray.SearchType¶ class langchain.retrievers.docarray.SearchType(value, names=None, *, module=None, qualname=None, type=None, start=1, boundary=None)[source]¶ Bases: str, Enum Enumerator of the types of search to perform. Methods __init__(*args, **kwds) capitalize() Return a capitalized version ...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.docarray.SearchType.html
41eb1361f8ae-1
isdecimal() Return True if the string is a decimal string, False otherwise. isdigit() Return True if the string is a digit string, False otherwise. isidentifier() Return True if the string is a valid Python identifier, False otherwise. islower() Return True if the string is a lowercase string, False otherwise. isnumeri...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.docarray.SearchType.html
41eb1361f8ae-2
rjust(width[, fillchar]) Return a right-justified string of length width. rpartition(sep, /) Partition the string into three parts using the given separator. rsplit([sep, maxsplit]) Return a list of the substrings in the string, using sep as the separator string. rstrip([chars]) Return a copy of the string with trailin...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.docarray.SearchType.html
41eb1361f8ae-3
Return the number of non-overlapping occurrences of substring sub in string S[start:end]. Optional arguments start and end are interpreted as in slice notation. encode(encoding='utf-8', errors='strict')¶ Encode the string using the codec registered for encoding. encodingThe encoding in which to encode the string. erro...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.docarray.SearchType.html
41eb1361f8ae-4
Return the lowest index in S where substring sub is found, such that sub is contained within S[start:end]. Optional arguments start and end are interpreted as in slice notation. Raises ValueError when the substring is not found. isalnum()¶ Return True if the string is an alpha-numeric string, False otherwise. A string...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.docarray.SearchType.html
41eb1361f8ae-5
isnumeric()¶ Return True if the string is a numeric string, False otherwise. A string is numeric if all characters in the string are numeric and there is at least one character in the string. isprintable()¶ Return True if the string is printable, False otherwise. A string is printable if all of its characters are consi...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.docarray.SearchType.html
41eb1361f8ae-6
static maketrans()¶ Return a translation table usable for str.translate(). If there is only one argument, it must be a dictionary mapping Unicode ordinals (integers) or characters to Unicode ordinals, strings or None. Character keys will be then converted to ordinals. If there are two arguments, they must be strings of...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.docarray.SearchType.html
41eb1361f8ae-7
replaced. rfind(sub[, start[, end]]) → int¶ Return the highest index in S where substring sub is found, such that sub is contained within S[start:end]. Optional arguments start and end are interpreted as in slice notation. Return -1 on failure. rindex(sub[, start[, end]]) → int¶ Return the highest index in S where sub...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.docarray.SearchType.html
41eb1361f8ae-8
rstrip(chars=None, /)¶ Return a copy of the string with trailing whitespace removed. If chars is given and not None, remove characters in chars instead. split(sep=None, maxsplit=- 1)¶ Return a list of the substrings in the string, using sep as the separator string. sepThe separator used to split the string. When set to...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.docarray.SearchType.html
41eb1361f8ae-9
translate(table, /)¶ Replace each character in the string using the given translation table. tableTranslation table, which must be a mapping of Unicode ordinals to Unicode ordinals, strings, or None. The table must implement lookup/indexing via __getitem__, for instance a dictionary or list. If this operation raises L...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.docarray.SearchType.html
9fade27cc85f-0
langchain.retrievers.kendra.AmazonKendraRetriever¶ class langchain.retrievers.kendra.AmazonKendraRetriever(index_id: str, region_name: Optional[str] = None, credentials_profile_name: Optional[str] = None, top_k: int = 3, attribute_filter: Optional[Dict] = None, client: Optional[Any] = None)[source]¶ Bases: BaseRetrieve...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.kendra.AmazonKendraRetriever.html
9fade27cc85f-1
Asynchronously get documents relevant to a query. :param query: string to find relevant documents for :param callbacks: Callback manager or list of callbacks Returns List of relevant documents get_relevant_documents(query: str, *, callbacks: Callbacks = None, **kwargs: Any) → List[Document]¶ Retrieve documents relevant...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.kendra.AmazonKendraRetriever.html
16c0c6a1ef1a-0
langchain.retrievers.azure_cognitive_search.AzureCognitiveSearchRetriever¶ class langchain.retrievers.azure_cognitive_search.AzureCognitiveSearchRetriever(*, service_name: str = '', index_name: str = '', api_key: str = '', api_version: str = '2020-06-30', aiosession: Optional[ClientSession] = None, content_key: str = '...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.azure_cognitive_search.AzureCognitiveSearchRetriever.html
16c0c6a1ef1a-1
Retrieve documents relevant to a query. :param query: string to find relevant documents for :param callbacks: Callback manager or list of callbacks Returns List of relevant documents validator validate_environment  »  all fields[source]¶ Validate that service name, index name and api key exists in environment. model Co...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.azure_cognitive_search.AzureCognitiveSearchRetriever.html
280a5115de07-0
langchain.retrievers.self_query.pinecone.PineconeTranslator¶ class langchain.retrievers.self_query.pinecone.PineconeTranslator[source]¶ Bases: Visitor Logic for converting internal query language elements to valid filters. Methods __init__() visit_comparison(comparison) Translate a Comparison. visit_operation(operation...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.self_query.pinecone.PineconeTranslator.html
1a2ac1b86f66-0
langchain.retrievers.kendra.QueryResultItem¶ class langchain.retrievers.kendra.QueryResultItem(*, DocumentId: str, DocumentTitle: TextWithHighLights, DocumentURI: Optional[str] = None, FeedbackToken: Optional[str] = None, Format: Optional[str] = None, Id: Optional[str] = None, Type: Optional[str] = None, AdditionalAttr...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.kendra.QueryResultItem.html
bcaa94aec8ab-0
langchain.retrievers.document_compressors.embeddings_filter.EmbeddingsFilter¶ class langchain.retrievers.document_compressors.embeddings_filter.EmbeddingsFilter(*, embeddings: ~langchain.embeddings.base.Embeddings, similarity_fn: ~typing.Callable = <function cosine_similarity>, k: ~typing.Optional[int] = 20, similarity...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.document_compressors.embeddings_filter.EmbeddingsFilter.html
bcaa94aec8ab-1
validator validate_params  »  all fields[source]¶ Validate similarity parameters. model Config[source]¶ Bases: object Configuration for this pydantic object. arbitrary_types_allowed = True¶
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.document_compressors.embeddings_filter.EmbeddingsFilter.html
0091834482e5-0
langchain.retrievers.knn.KNNRetriever¶ class langchain.retrievers.knn.KNNRetriever(*, embeddings: Embeddings, index: Any = None, texts: List[str], k: int = 4, relevancy_threshold: Optional[float] = None)[source]¶ Bases: BaseRetriever, BaseModel KNN Retriever. Create a new model by parsing and validating input data from...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.knn.KNNRetriever.html
6a8c0d0537b0-0
langchain.retrievers.kendra.RetrieveResult¶ class langchain.retrievers.kendra.RetrieveResult(*, QueryId: str, ResultItems: List[RetrieveResultItem], **extra_data: Any)[source]¶ Bases: BaseModel Create a new model by parsing and validating input data from keyword arguments. Raises ValidationError if the input data canno...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.kendra.RetrieveResult.html
0b9caa862395-0
langchain.retrievers.knn.create_index¶ langchain.retrievers.knn.create_index(contexts: List[str], embeddings: Embeddings) → ndarray[source]¶ Create an index of embeddings for a list of contexts. Parameters contexts – List of contexts to embed. embeddings – Embeddings model to use. Returns Index of embeddings.
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.knn.create_index.html
44aafcd44051-0
langchain.retrievers.zilliz.ZillizRetreiver¶ langchain.retrievers.zilliz.ZillizRetreiver(*args: Any, **kwargs: Any) → ZillizRetriever[source]¶ Deprecated ZillizRetreiver. Please use ZillizRetriever (‘i’ before ‘e’) instead. :param *args: :param **kwargs: Returns ZillizRetriever
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.zilliz.ZillizRetreiver.html
306241925e12-0
langchain.retrievers.multi_query.MultiQueryRetriever¶ class langchain.retrievers.multi_query.MultiQueryRetriever(retriever: BaseRetriever, llm_chain: LLMChain, verbose: bool = True, parser_key: str = 'lines')[source]¶ Bases: BaseRetriever Given a user query, use an LLM to write a set of queries. Retrieve docs for each ...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.multi_query.MultiQueryRetriever.html
306241925e12-1
:param callbacks: Callback manager or list of callbacks Returns List of relevant documents classmethod from_llm(retriever: BaseRetriever, llm: BaseLLM, prompt: PromptTemplate = PromptTemplate(input_variables=['question'], output_parser=None, partial_variables={}, template='You are an AI language model assistant. Your t...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.multi_query.MultiQueryRetriever.html
306241925e12-2
Parameters queries – query list Returns List of retrived Documents unique_union(documents: List[Document]) → List[Document][source]¶ Get uniqe Documents. Parameters documents – List of retrived Documents Returns List of unique retrived Documents
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.multi_query.MultiQueryRetriever.html
fe0a21a63622-0
langchain.retrievers.elastic_search_bm25.ElasticSearchBM25Retriever¶ class langchain.retrievers.elastic_search_bm25.ElasticSearchBM25Retriever(client: Any, index_name: str)[source]¶ Bases: BaseRetriever Wrapper around Elasticsearch using BM25 as a retrieval method. To connect to an Elasticsearch instance that requires ...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.elastic_search_bm25.ElasticSearchBM25Retriever.html
fe0a21a63622-1
Retrieve documents relevant to a query. add_texts(texts: Iterable[str], refresh_indices: bool = True) → List[str][source]¶ Run more texts through the embeddings and add to the retriever. Parameters texts – Iterable of strings to add to the retriever. refresh_indices – bool to refresh ElasticSearch indices Returns List ...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.elastic_search_bm25.ElasticSearchBM25Retriever.html
58c826148f9a-0
langchain.retrievers.tfidf.TFIDFRetriever¶ class langchain.retrievers.tfidf.TFIDFRetriever(*, vectorizer: Any = None, docs: List[Document], tfidf_array: Any = None, k: int = 4)[source]¶ Bases: BaseRetriever, BaseModel Create a new model by parsing and validating input data from keyword arguments. Raises ValidationError...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.tfidf.TFIDFRetriever.html
87801ad0e1da-0
langchain.retrievers.vespa_retriever.VespaRetriever¶ class langchain.retrievers.vespa_retriever.VespaRetriever(app: Vespa, body: Dict, content_field: str, metadata_fields: Optional[Sequence[str]] = None)[source]¶ Bases: BaseRetriever Retriever that uses the Vespa. Parameters app – Vespa client. body – query body. conte...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.vespa_retriever.VespaRetriever.html
87801ad0e1da-1
Instantiate retriever from params. Parameters url (str) – Vespa app URL. content_field (str) – Field in results to return as Document page_content. k (Optional[int]) – Number of Documents to return. Defaults to None. metadata_fields (Sequence[str] or "*") – Fields in results to include in document metadata. Defaults to...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.vespa_retriever.VespaRetriever.html
6c90478b41fb-0
langchain.retrievers.self_query.myscale.FUNCTION_COMPOSER¶ langchain.retrievers.self_query.myscale.FUNCTION_COMPOSER(op_name: str) → Callable[source]¶ Composer for functions. :param op_name: Name of the function. Returns Callable that takes a list of arguments and returns a string.
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.self_query.myscale.FUNCTION_COMPOSER.html
6fe6b6e24b4c-0
langchain.retrievers.svm.SVMRetriever¶ class langchain.retrievers.svm.SVMRetriever(*, embeddings: Embeddings, index: Any = None, texts: List[str], k: int = 4, relevancy_threshold: Optional[float] = None)[source]¶ Bases: BaseRetriever, BaseModel SVM Retriever. Create a new model by parsing and validating input data from...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.svm.SVMRetriever.html
c7bd6eca85a9-0
langchain.retrievers.pubmed.PubMedRetriever¶ class langchain.retrievers.pubmed.PubMedRetriever(*, top_k_results: int = 3, load_max_docs: int = 25, doc_content_chars_max: int = 2000, load_all_available_meta: bool = False, email: str = 'your_email@example.com', base_url_esearch: str = 'https://eutils.ncbi.nlm.nih.gov/ent...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.pubmed.PubMedRetriever.html
c7bd6eca85a9-1
Retrieve documents relevant to a query. :param query: string to find relevant documents for :param callbacks: Callback manager or list of callbacks Returns List of relevant documents load(query: str) → List[dict]¶ Search PubMed for documents matching the query. Return a list of dictionaries containing the document meta...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.pubmed.PubMedRetriever.html
2945d926514b-0
langchain.retrievers.pinecone_hybrid_search.PineconeHybridSearchRetriever¶ class langchain.retrievers.pinecone_hybrid_search.PineconeHybridSearchRetriever(*, embeddings: Embeddings, sparse_encoder: Any = None, index: Any = None, top_k: int = 4, alpha: float = 0.5)[source]¶ Bases: BaseRetriever, BaseModel Create a new m...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.pinecone_hybrid_search.PineconeHybridSearchRetriever.html
2945d926514b-1
Configuration for this pydantic object. arbitrary_types_allowed = True¶ extra = 'forbid'¶
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.pinecone_hybrid_search.PineconeHybridSearchRetriever.html
16431bd6d91c-0
langchain.retrievers.kendra.QueryResult¶ class langchain.retrievers.kendra.QueryResult(*, ResultItems: List[QueryResultItem], **extra_data: Any)[source]¶ Bases: BaseModel Create a new model by parsing and validating input data from keyword arguments. Raises ValidationError if the input data cannot be parsed to form a v...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.kendra.QueryResult.html
c08b4e4d896f-0
langchain.retrievers.milvus.MilvusRetriever¶ class langchain.retrievers.milvus.MilvusRetriever(embedding_function: Embeddings, collection_name: str = 'LangChainCollection', connection_args: Optional[Dict[str, Any]] = None, consistency_level: str = 'Session', search_params: Optional[dict] = None)[source]¶ Bases: BaseRet...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.milvus.MilvusRetriever.html
2cc2eb274e77-0
langchain.retrievers.merger_retriever.MergerRetriever¶ class langchain.retrievers.merger_retriever.MergerRetriever(retrievers: List[BaseRetriever])[source]¶ Bases: BaseRetriever This class merges the results of multiple retrievers. Parameters retrievers – A list of retrievers to merge. Initialize the MergerRetriever cl...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.merger_retriever.MergerRetriever.html
2cc2eb274e77-1
:param callbacks: Callback manager or list of callbacks Returns List of relevant documents merge_documents(query: str, run_manager: CallbackManagerForRetrieverRun) → List[Document][source]¶ Merge the results of the retrievers. Parameters query – The query to search for. Returns A list of merged documents.
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.merger_retriever.MergerRetriever.html
e11d6d2566f8-0
langchain.retrievers.kendra.Highlight¶ class langchain.retrievers.kendra.Highlight(*, BeginOffset: int, EndOffset: int, TopAnswer: Optional[bool] = None, Type: Optional[str] = None, **extra_data: Any)[source]¶ Bases: BaseModel Create a new model by parsing and validating input data from keyword arguments. Raises Valida...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.kendra.Highlight.html
cb99d670ae01-0
langchain.retrievers.self_query.chroma.ChromaTranslator¶ class langchain.retrievers.self_query.chroma.ChromaTranslator[source]¶ Bases: Visitor Logic for converting internal query language elements to valid filters. Methods __init__() visit_comparison(comparison) Translate a Comparison. visit_operation(operation) Transl...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.self_query.chroma.ChromaTranslator.html
65629d8b12f1-0
langchain.retrievers.self_query.myscale.DEFAULT_COMPOSER¶ langchain.retrievers.self_query.myscale.DEFAULT_COMPOSER(op_name: str) → Callable[source]¶ Default composer for logical operators. Parameters op_name – Name of the operator. Returns Callable that takes a list of arguments and returns a string.
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.self_query.myscale.DEFAULT_COMPOSER.html
92fee0220f57-0
langchain.retrievers.weaviate_hybrid_search.WeaviateHybridSearchRetriever¶ class langchain.retrievers.weaviate_hybrid_search.WeaviateHybridSearchRetriever(client: Any, index_name: str, text_key: str, alpha: float = 0.5, k: int = 4, attributes: Optional[List[str]] = None, create_schema_if_missing: bool = True)[source]¶ ...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.weaviate_hybrid_search.WeaviateHybridSearchRetriever.html
d5a41a243a66-0
langchain.retrievers.arxiv.ArxivRetriever¶ class langchain.retrievers.arxiv.ArxivRetriever(*, arxiv_search: Any = None, arxiv_exceptions: Any = None, top_k_results: int = 3, load_max_docs: int = 100, load_all_available_meta: bool = False, doc_content_chars_max: Optional[int] = 4000, ARXIV_MAX_QUERY_LENGTH: int = 300)[s...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.arxiv.ArxivRetriever.html
d5a41a243a66-1
Run Arxiv search and get the article texts plus the article meta information. See https://lukasschwab.me/arxiv.py/index.html#Search Returns: a list of documents with the document.page_content in text format run(query: str) → str¶ Run Arxiv search and get the article meta information. See https://lukasschwab.me/arxiv.py...
https://api.python.langchain.com/en/latest/retrievers/langchain.retrievers.arxiv.ArxivRetriever.html
20ab63a5bbcf-0
langchain.utilities.openapi.HTTPVerb¶ class langchain.utilities.openapi.HTTPVerb(value, names=None, *, module=None, qualname=None, type=None, start=1, boundary=None)[source]¶ Bases: str, Enum HTTP verbs. Methods from_str(verb) Parse an HTTP verb. __init__(*args, **kwds) capitalize() Return a capitalized version of the ...
https://api.python.langchain.com/en/latest/utilities/langchain.utilities.openapi.HTTPVerb.html
20ab63a5bbcf-1
isdecimal() Return True if the string is a decimal string, False otherwise. isdigit() Return True if the string is a digit string, False otherwise. isidentifier() Return True if the string is a valid Python identifier, False otherwise. islower() Return True if the string is a lowercase string, False otherwise. isnumeri...
https://api.python.langchain.com/en/latest/utilities/langchain.utilities.openapi.HTTPVerb.html
20ab63a5bbcf-2
rjust(width[, fillchar]) Return a right-justified string of length width. rpartition(sep, /) Partition the string into three parts using the given separator. rsplit([sep, maxsplit]) Return a list of the substrings in the string, using sep as the separator string. rstrip([chars]) Return a copy of the string with trailin...
https://api.python.langchain.com/en/latest/utilities/langchain.utilities.openapi.HTTPVerb.html
20ab63a5bbcf-3
Return the number of non-overlapping occurrences of substring sub in string S[start:end]. Optional arguments start and end are interpreted as in slice notation. encode(encoding='utf-8', errors='strict')¶ Encode the string using the codec registered for encoding. encodingThe encoding in which to encode the string. erro...
https://api.python.langchain.com/en/latest/utilities/langchain.utilities.openapi.HTTPVerb.html
20ab63a5bbcf-4
Parse an HTTP verb. index(sub[, start[, end]]) → int¶ Return the lowest index in S where substring sub is found, such that sub is contained within S[start:end]. Optional arguments start and end are interpreted as in slice notation. Raises ValueError when the substring is not found. isalnum()¶ Return True if the string...
https://api.python.langchain.com/en/latest/utilities/langchain.utilities.openapi.HTTPVerb.html
20ab63a5bbcf-5
there is at least one cased character in the string. isnumeric()¶ Return True if the string is a numeric string, False otherwise. A string is numeric if all characters in the string are numeric and there is at least one character in the string. isprintable()¶ Return True if the string is printable, False otherwise. A s...
https://api.python.langchain.com/en/latest/utilities/langchain.utilities.openapi.HTTPVerb.html
20ab63a5bbcf-6
If chars is given and not None, remove characters in chars instead. static maketrans()¶ Return a translation table usable for str.translate(). If there is only one argument, it must be a dictionary mapping Unicode ordinals (integers) or characters to Unicode ordinals, strings or None. Character keys will be then conver...
https://api.python.langchain.com/en/latest/utilities/langchain.utilities.openapi.HTTPVerb.html
20ab63a5bbcf-7
If the optional argument count is given, only the first count occurrences are replaced. rfind(sub[, start[, end]]) → int¶ Return the highest index in S where substring sub is found, such that sub is contained within S[start:end]. Optional arguments start and end are interpreted as in slice notation. Return -1 on failu...
https://api.python.langchain.com/en/latest/utilities/langchain.utilities.openapi.HTTPVerb.html
20ab63a5bbcf-8
rstrip(chars=None, /)¶ Return a copy of the string with trailing whitespace removed. If chars is given and not None, remove characters in chars instead. split(sep=None, maxsplit=- 1)¶ Return a list of the substrings in the string, using sep as the separator string. sepThe separator used to split the string. When set to...
https://api.python.langchain.com/en/latest/utilities/langchain.utilities.openapi.HTTPVerb.html
20ab63a5bbcf-9
translate(table, /)¶ Replace each character in the string using the given translation table. tableTranslation table, which must be a mapping of Unicode ordinals to Unicode ordinals, strings, or None. The table must implement lookup/indexing via __getitem__, for instance a dictionary or list. If this operation raises L...
https://api.python.langchain.com/en/latest/utilities/langchain.utilities.openapi.HTTPVerb.html
b63c2e034c0e-0
langchain.utilities.searx_search.SearxResults¶ class langchain.utilities.searx_search.SearxResults(data: str)[source]¶ Bases: dict Dict like wrapper around search api results. Take a raw result from Searx and make it into a dict like object. Methods __init__(data) Take a raw result from Searx and make it into a dict li...
https://api.python.langchain.com/en/latest/utilities/langchain.utilities.searx_search.SearxResults.html
b63c2e034c0e-1
get(key, default=None, /)¶ Return the value for key if key is in the dictionary, else default. items() → a set-like object providing a view on D's items¶ keys() → a set-like object providing a view on D's keys¶ pop(k[, d]) → v, remove specified key and return the corresponding value.¶ If the key is not found, return th...
https://api.python.langchain.com/en/latest/utilities/langchain.utilities.searx_search.SearxResults.html
605f295c4b4e-0
langchain.utilities.openweathermap.OpenWeatherMapAPIWrapper¶ class langchain.utilities.openweathermap.OpenWeatherMapAPIWrapper(*, owm: Any = None, openweathermap_api_key: Optional[str] = None)[source]¶ Bases: BaseModel Wrapper for OpenWeatherMap API using PyOWM. Docs for using: Go to OpenWeatherMap and sign up for an A...
https://api.python.langchain.com/en/latest/utilities/langchain.utilities.openweathermap.OpenWeatherMapAPIWrapper.html
9c6cb59062bb-0
langchain.utilities.google_places_api.GooglePlacesAPIWrapper¶ class langchain.utilities.google_places_api.GooglePlacesAPIWrapper(*, gplaces_api_key: Optional[str] = None, google_map_client: Any = None, top_k_results: Optional[int] = None)[source]¶ Bases: BaseModel Wrapper around Google Places API. To use, you should ha...
https://api.python.langchain.com/en/latest/utilities/langchain.utilities.google_places_api.GooglePlacesAPIWrapper.html
7c5cce7f543a-0
langchain.utilities.loading.try_load_from_hub¶ langchain.utilities.loading.try_load_from_hub(path: Union[str, Path], loader: Callable[[str], T], valid_prefix: str, valid_suffixes: Set[str], **kwargs: Any) → Optional[T][source]¶ Load configuration from hub. Returns None if path is not a hub path.
https://api.python.langchain.com/en/latest/utilities/langchain.utilities.loading.try_load_from_hub.html
6afbb7bd1e81-0
langchain.utilities.graphql.GraphQLAPIWrapper¶ class langchain.utilities.graphql.GraphQLAPIWrapper(*, custom_headers: Optional[Dict[str, str]] = None, graphql_endpoint: str, gql_client: Any = None, gql_function: Callable[[str], Any])[source]¶ Bases: BaseModel Wrapper around GraphQL API. To use, you should have the gql ...
https://api.python.langchain.com/en/latest/utilities/langchain.utilities.graphql.GraphQLAPIWrapper.html
2972b5168057-0
langchain.utilities.serpapi.SerpAPIWrapper¶ class langchain.utilities.serpapi.SerpAPIWrapper(*, search_engine: Any = None, params: dict = {'engine': 'google', 'gl': 'us', 'google_domain': 'google.com', 'hl': 'en'}, serpapi_api_key: Optional[str] = None, aiosession: Optional[ClientSession] = None)[source]¶ Bases: BaseMo...
https://api.python.langchain.com/en/latest/utilities/langchain.utilities.serpapi.SerpAPIWrapper.html
2972b5168057-1
Run query through SerpAPI and parse result. validator validate_environment  »  all fields[source]¶ Validate that api key and python package exists in environment. model Config[source]¶ Bases: object Configuration for this pydantic object. arbitrary_types_allowed = True¶ extra = 'forbid'¶
https://api.python.langchain.com/en/latest/utilities/langchain.utilities.serpapi.SerpAPIWrapper.html
c3ebef9ef669-0
langchain.utilities.powerbi.PowerBIDataset¶ class langchain.utilities.powerbi.PowerBIDataset(*, dataset_id: str, table_names: List[str], group_id: Optional[str] = None, credential: Optional[TokenCredential] = None, token: Optional[str] = None, impersonated_user_name: Optional[str] = None, sample_rows_in_table_info: Con...
https://api.python.langchain.com/en/latest/utilities/langchain.utilities.powerbi.PowerBIDataset.html
c3ebef9ef669-1
Execute a DAX command and return the result asynchronously. validator fix_table_names  »  table_names[source]¶ Fix the table names. get_schemas() → str[source]¶ Get the available schema’s. get_table_info(table_names: Optional[Union[List[str], str]] = None) → str[source]¶ Get information about specified tables. get_tabl...
https://api.python.langchain.com/en/latest/utilities/langchain.utilities.powerbi.PowerBIDataset.html
4253bdd7d701-0
langchain.utilities.google_search.GoogleSearchAPIWrapper¶ class langchain.utilities.google_search.GoogleSearchAPIWrapper(*, search_engine: Any = None, google_api_key: Optional[str] = None, google_cse_id: Optional[str] = None, k: int = 10, siterestrict: bool = False)[source]¶ Bases: BaseModel Wrapper for Google Search A...
https://api.python.langchain.com/en/latest/utilities/langchain.utilities.google_search.GoogleSearchAPIWrapper.html
4253bdd7d701-1
4. Enable the Custom Search API - Navigate to the APIs & Services→Dashboard panel in Cloud Console. - Click Enable APIs and Services. - Search for Custom Search API and click on it. - Click Enable. URL for it: https://console.cloud.google.com/apis/library/customsearch.googleapis .com Create a new model by parsing and v...
https://api.python.langchain.com/en/latest/utilities/langchain.utilities.google_search.GoogleSearchAPIWrapper.html
51b93b5aadfa-0
langchain.utilities.pupmed.PubMedAPIWrapper¶ class langchain.utilities.pupmed.PubMedAPIWrapper(*, top_k_results: int = 3, load_max_docs: int = 25, doc_content_chars_max: int = 2000, load_all_available_meta: bool = False, email: str = 'your_email@example.com', base_url_esearch: str = 'https://eutils.ncbi.nlm.nih.gov/ent...
https://api.python.langchain.com/en/latest/utilities/langchain.utilities.pupmed.PubMedAPIWrapper.html
51b93b5aadfa-1
param top_k_results: int = 3¶ load(query: str) → List[dict][source]¶ Search PubMed for documents matching the query. Return a list of dictionaries containing the document metadata. load_docs(query: str) → List[Document][source]¶ retrieve_article(uid: str, webenv: str) → dict[source]¶ run(query: str) → str[source]¶ Run ...
https://api.python.langchain.com/en/latest/utilities/langchain.utilities.pupmed.PubMedAPIWrapper.html
8b3192af9020-0
langchain.utilities.metaphor_search.MetaphorSearchAPIWrapper¶ class langchain.utilities.metaphor_search.MetaphorSearchAPIWrapper(*, metaphor_api_key: str, k: int = 10)[source]¶ Bases: BaseModel Wrapper for Metaphor Search API. Create a new model by parsing and validating input data from keyword arguments. Raises Valida...
https://api.python.langchain.com/en/latest/utilities/langchain.utilities.metaphor_search.MetaphorSearchAPIWrapper.html
8b3192af9020-1
validator validate_environment  »  all fields[source]¶ Validate that api key and endpoint exists in environment. model Config[source]¶ Bases: object Configuration for this pydantic object. extra = 'forbid'¶
https://api.python.langchain.com/en/latest/utilities/langchain.utilities.metaphor_search.MetaphorSearchAPIWrapper.html
ab577c2a79a5-0
langchain.utilities.duckduckgo_search.DuckDuckGoSearchAPIWrapper¶ class langchain.utilities.duckduckgo_search.DuckDuckGoSearchAPIWrapper(*, k: int = 10, region: Optional[str] = 'wt-wt', safesearch: str = 'moderate', time: Optional[str] = 'y', max_results: int = 5)[source]¶ Bases: BaseModel Wrapper for DuckDuckGo Search...
https://api.python.langchain.com/en/latest/utilities/langchain.utilities.duckduckgo_search.DuckDuckGoSearchAPIWrapper.html
48d8dddea466-0
langchain.utilities.vertexai.raise_vertex_import_error¶ langchain.utilities.vertexai.raise_vertex_import_error() → None[source]¶ Raise ImportError related to Vertex SDK being not available. Raises ImportError – an ImportError that mentions a required version of the SDK.
https://api.python.langchain.com/en/latest/utilities/langchain.utilities.vertexai.raise_vertex_import_error.html
2e3bc92065b3-0
langchain.utilities.apify.ApifyWrapper¶ class langchain.utilities.apify.ApifyWrapper(*, apify_client: Any = None, apify_client_async: Any = None)[source]¶ Bases: BaseModel Wrapper around Apify. To use, you should have the apify-client python package installed, and the environment variable APIFY_API_TOKEN set with your ...
https://api.python.langchain.com/en/latest/utilities/langchain.utilities.apify.ApifyWrapper.html
2e3bc92065b3-1
Return type ApifyDatasetLoader async acall_actor_task(task_id: str, task_input: Dict, dataset_mapping_function: Callable[[Dict], Document], *, build: Optional[str] = None, memory_mbytes: Optional[int] = None, timeout_secs: Optional[int] = None) → ApifyDatasetLoader[source]¶ Run a saved Actor task on Apify and wait for ...
https://api.python.langchain.com/en/latest/utilities/langchain.utilities.apify.ApifyWrapper.html
2e3bc92065b3-2
dataset_mapping_function (Callable) – A function that takes a single dictionary (an Apify dataset item) and converts it to an instance of the Document class. build (str, optional) – Optionally specifies the actor build to run. It can be either a build tag or build number. memory_mbytes (int, optional) – Optional memory...
https://api.python.langchain.com/en/latest/utilities/langchain.utilities.apify.ApifyWrapper.html
2e3bc92065b3-3
Return type ApifyDatasetLoader validator validate_environment  »  all fields[source]¶ Validate environment. Validate that an Apify API token is set and the apify-client Python package exists in the current environment.
https://api.python.langchain.com/en/latest/utilities/langchain.utilities.apify.ApifyWrapper.html
55aa4897a5a5-0
langchain.utilities.brave_search.BraveSearchWrapper¶ class langchain.utilities.brave_search.BraveSearchWrapper(*, api_key: str, search_kwargs: dict = None)[source]¶ Bases: BaseModel Create a new model by parsing and validating input data from keyword arguments. Raises ValidationError if the input data cannot be parsed ...
https://api.python.langchain.com/en/latest/utilities/langchain.utilities.brave_search.BraveSearchWrapper.html
aa2602adb9b0-0
langchain.utilities.jira.JiraAPIWrapper¶
https://api.python.langchain.com/en/latest/utilities/langchain.utilities.jira.JiraAPIWrapper.html
aa2602adb9b0-1
class langchain.utilities.jira.JiraAPIWrapper(*, jira: Any = None, confluence: Any = None, jira_username: Optional[str] = None, jira_api_token: Optional[str] = None, jira_instance_url: Optional[str] = None, operations: List[Dict] = [{'mode': 'jql', 'name': 'JQL Query', 'description': '\n    This tool is a wrapper aroun...
https://api.python.langchain.com/en/latest/utilities/langchain.utilities.jira.JiraAPIWrapper.html
aa2602adb9b0-2
issue, and will be passed into atlassian-python-api\'s Jira `issue_create` function.\n    For example, to create a low priority task called "test issue" with description "test description", you would pass in the following dictionary: \n    {{"summary": "test issue", "description": "test description", "issuetype": {{"na...
https://api.python.langchain.com/en/latest/utilities/langchain.utilities.jira.JiraAPIWrapper.html
aa2602adb9b0-3
page, and will be passed into atlassian-python-api\'s Confluence `create_page` \nfunction. For example, to create a page in the DEMO space titled "This is the title" with body "This is the body. You can use \n<strong>HTML tags</strong>!", you would pass in the following dictionary: {{"space": "DEMO", "title":"This is t...
https://api.python.langchain.com/en/latest/utilities/langchain.utilities.jira.JiraAPIWrapper.html
aa2602adb9b0-4
Bases: BaseModel Wrapper for Jira API. Create a new model by parsing and validating input data from keyword arguments. Raises ValidationError if the input data cannot be parsed to form a valid model. param confluence: Any = None¶ param jira_api_token: Optional[str] = None¶ param jira_instance_url: Optional[str] = None¶...
https://api.python.langchain.com/en/latest/utilities/langchain.utilities.jira.JiraAPIWrapper.html
aa2602adb9b0-5
param operations: List[Dict] = [{'mode': 'jql', 'name': 'JQL Query', 'description': '\n    This tool is a wrapper around atlassian-python-api\'s Jira jql API, useful when you need to search for Jira issues.\n    The input to this tool is a JQL query string, and will be passed into atlassian-python-api\'s Jira `jql` fun...
https://api.python.langchain.com/en/latest/utilities/langchain.utilities.jira.JiraAPIWrapper.html
aa2602adb9b0-6
"test issue", "description": "test description", "issuetype": {{"name": "Task"}}, "priority": {{"name": "Low"}}}}\n    '}, {'mode': 'other', 'name': 'Catch all Jira API call', 'description': '\n    This tool is a wrapper around atlassian-python-api\'s Jira API.\n    There are other dedicated tools for fetching all proj...
https://api.python.langchain.com/en/latest/utilities/langchain.utilities.jira.JiraAPIWrapper.html
aa2602adb9b0-7
you would pass in the following dictionary: {{"space": "DEMO", "title":"This is the \ntitle","body":"This is the body. You can use <strong>HTML tags</strong>!"}} '}]¶
https://api.python.langchain.com/en/latest/utilities/langchain.utilities.jira.JiraAPIWrapper.html
aa2602adb9b0-8
issue_create(query: str) → str[source]¶ list() → List[Dict][source]¶ other(query: str) → str[source]¶ page_create(query: str) → str[source]¶ parse_issues(issues: Dict) → List[dict][source]¶ parse_projects(projects: List[dict]) → List[dict][source]¶ project() → str[source]¶ run(mode: str, query: str) → str[source]¶ sear...
https://api.python.langchain.com/en/latest/utilities/langchain.utilities.jira.JiraAPIWrapper.html