mrkeyoor.com_
Wed 05 Aug 23:09 UTC
PyPIAI / MLupdated 05 Aug 2026

langchain-community

langchain-community is the grab-bag package of third-party LangChain integrations: hundreds of document loaders, vector stores, retrievers, tools, and older chat model wrappers contributed by the community. It exists because the LangChain monorepo split in 2024 moved everything not core into this one package. As of mid-2026 it is officially sunset: the GitHub repo is archived with a 'no longer maintained' banner pointing to issue #674, while the package still pulls about 10 million downloads a week from existing codebases.

Verdict

Treat it as a legacy compatibility layer, not a dependency you choose in 2026: the repo is archived and the ecosystem moved to per-provider langchain-* packages. Keep it only for long-tail integrations that never got their own package, and migrate everything else.

API stability3/5Import paths have been stable since the 2024 monorepo split, but individual wrappers deprecate constantly, and the sunset freezes the package rather than stabilizing it.
Docs3/5reference.langchain.com has API docs for every class, but many community integrations have one-line docstrings and no usage guide, so you end up reading source.
Maintenance1/5The GitHub repo was archived in June 2026 with an explicit sunset notice (issue #674); no further fixes or releases beyond stragglers on PyPI.
Ecosystem4/5Hundreds of integrations and about 10M weekly downloads mean answers and examples are everywhere, but that surface is now frozen and slowly rotting against live provider APIs.

Use it if

  • You maintain an existing LangChain app that already imports from langchain_community and migrating every loader and vector store is not worth it yet
  • You need a long-tail integration (an obscure document loader or vector store) that never got its own langchain-* partner package
  • You are on the 0.4.x line with langchain-core 1.x and just need imports to keep resolving while you migrate piece by piece
  • You want BM25Retriever or a niche utility like SQLDatabase that has no direct partner-package equivalent
Skip it if

Setup reality

pip install langchain-community works, but that is where the honesty starts. The package is integration shells: almost every class needs its own extra dependency (faiss-cpu for FAISS, pypdf for PyPDFLoader, rank_bm25 for BM25Retriever, beautifulsoup4 for WebBaseLoader) and you find out at runtime via ImportError, not at install time. The 0.4.x line requires langchain-core>=1.4 and pulls langchain-classic, so pinning an older stack gets messy. And because the repo is archived, any bug you hit is yours to patch or work around.

Patterns

Install with a pin, given the sunsetinstall-pinned

pip install "langchain-community>=0.4,<0.5" langchain-core
# each integration needs its own extra package, e.g.:
pip install faiss-cpu pypdf rank_bm25

The package is sunset, so pin the minor version. Integration classes import their backing library lazily; missing extras surface as ImportError at first use, not at install.

Load web pages and PDFs into Documentsload-documents

from langchain_community.document_loaders import WebBaseLoader, PyPDFLoader

web_docs = WebBaseLoader("https://example.com/post").load()
pdf_docs = PyPDFLoader("report.pdf").load()  # one Document per page
print(pdf_docs[0].metadata)  # {'source': 'report.pdf', 'page': 0, ...}

WebBaseLoader needs beautifulsoup4, PyPDFLoader needs pypdf. Loaders return langchain_core Document objects, so they still plug into current 1.x chains.

Build an in-memory FAISS vector storevector-store-faiss

from langchain_community.vectorstores import FAISS
from langchain_openai import OpenAIEmbeddings

vs = FAISS.from_texts(["cats purr", "dogs bark"], OpenAIEmbeddings())
retriever = vs.as_retriever(search_kwargs={"k": 2})
print(retriever.invoke("what do cats do?"))

Requires faiss-cpu. FAISS here is local and in-process; for a served vector DB the maintained partner packages (langchain-chroma, langchain-qdrant) are the better path.

Persist and reload a FAISS indexsave-load-faiss

vs.save_local("faiss_index")

from langchain_community.vectorstores import FAISS
vs2 = FAISS.load_local(
    "faiss_index", OpenAIEmbeddings(),
    allow_dangerous_deserialization=True,
)

load_local refuses to run without allow_dangerous_deserialization=True because the index metadata is pickle; only load indexes you created yourself.

Keyword retrieval with BM25Retrieverbm25-retriever

from langchain_community.retrievers import BM25Retriever

retriever = BM25Retriever.from_texts(
    ["error handling in python", "async io patterns", "bm25 ranking"]
)
retriever.k = 2
print(retriever.invoke("python errors"))

Needs rank_bm25. This is one of the classes with no partner-package home, which is exactly the kind of thing that keeps langchain-community in dependency trees.

Inspect a SQL database for LLM chainssql-database-utility

from langchain_community.utilities import SQLDatabase

db = SQLDatabase.from_uri("sqlite:///app.db")
print(db.get_usable_table_names())
print(db.run("SELECT count(*) FROM users"))

Backed by sqlalchemy (already a hard dependency). db.run executes raw SQL, so never feed it model output without your own allowlisting.

Community chat model wrappers (deprecated path)chat-model-deprecated

# still works, but emits a deprecation warning:
from langchain_community.chat_models import ChatOllama
llm = ChatOllama(model="llama3")

# maintained replacement:
# pip install langchain-ollama
from langchain_ollama import ChatOllama as ChatOllamaNew
llm = ChatOllamaNew(model="llama3")

Most chat model classes here were deprecated in favor of partner packages long before the sunset; the community versions miss newer provider features like current tool-calling formats.

Migrate HuggingFaceEmbeddings off communityembeddings-migration

# old (deprecated, warns):
from langchain_community.embeddings import HuggingFaceEmbeddings

# new (maintained):
# pip install langchain-huggingface
from langchain_huggingface import HuggingFaceEmbeddings

emb = HuggingFaceEmbeddings(model_name="all-MiniLM-L6-v2")

The import path is usually the only change; constructor arguments carried over. This one-line swap pattern is how most of the migration off langchain-community goes.

DuckDuckGo search as an agent toolsearch-tool

from langchain_community.tools import DuckDuckGoSearchRun

search = DuckDuckGoSearchRun()
print(search.invoke("starlette 1.0 release date"))

Requires the ddgs package (the renamed duckduckgo-search). Scraper-based tools like this break whenever the upstream site changes, and with the repo archived nobody ships the fix.

Cache LLM calls with SQLiteCachellm-cache

from langchain_core.globals import set_llm_cache
from langchain_community.cache import SQLiteCache

set_llm_cache(SQLiteCache(database_path=".langchain.db"))
# identical prompts now return the cached response

Caches key on the exact prompt and model parameters, so any change in the prompt template busts the cache. Works with current langchain-core chat models.

Find what you still import from the sunset packageaudit-imports

grep -rn "from langchain_community" --include="*.py" . | sort | uniq -c
# migrate anything with a partner package equivalent;
# keep only the long-tail classes with no new home

A worthwhile audit now that the repo is archived: most teams find only two or three classes actually need to stay on langchain-community.

Alternatives

PackageRegistryPick it when
langchain-openaiPyPIYou need OpenAI chat models or embeddings: the partner package tracks the provider API and is actively maintained.
langchain-huggingfacePyPIYou use HuggingFaceEmbeddings or HF pipelines: the community versions were deprecated in favor of this package.
llama-indexPyPIYour app is mostly RAG over documents and you want maintained loaders and indexes without the LangChain stack.
haystack-aiPyPIYou want a pipeline-oriented RAG framework with maintained integrations and less churn history.