mirror of
https://github.com/hwchase17/langchain.git
synced 2025-08-22 19:08:40 +00:00
## **Description:** When using the Tavily retriever with include_raw_content=True, the retriever occasionally fails with a Pydantic ValidationError because raw_content can be None. The Document model in langchain_core/documents/base.py requires page_content to be a non-None value, but the Tavily API sometimes returns None for raw_content. This PR fixes the issue by ensuring that even when raw_content is None, an empty string is used instead: ```python page_content=result.get("content", "") if not self.include_raw_content else (result.get("raw_content") or ""), |
||
---|---|---|
.. | ||
__init__.py | ||
arcee.py | ||
arxiv.py | ||
asknews.py | ||
azure_ai_search.py | ||
bedrock.py | ||
bm25.py | ||
breebs.py | ||
chaindesk.py | ||
chatgpt_plugin_retriever.py | ||
cohere_rag_retriever.py | ||
databerry.py | ||
docarray.py | ||
dria_index.py | ||
elastic_search_bm25.py | ||
embedchain.py | ||
google_cloud_documentai_warehouse.py | ||
google_vertex_ai_search.py | ||
kay.py | ||
kendra.py | ||
knn.py | ||
llama_index.py | ||
metal.py | ||
milvus.py | ||
nanopq.py | ||
needle.py | ||
outline.py | ||
pinecone_hybrid_search.py | ||
pubmed.py | ||
pupmed.py | ||
qdrant_sparse_vector_retriever.py | ||
rememberizer.py | ||
remote_retriever.py | ||
svm.py | ||
tavily_search_api.py | ||
tfidf.py | ||
thirdai_neuraldb.py | ||
vespa_retriever.py | ||
weaviate_hybrid_search.py | ||
web_research.py | ||
wikipedia.py | ||
you.py | ||
zep_cloud.py | ||
zep.py | ||
zilliz.py |