langchain-ai/langchain
Packages
The langchain-ai/langchain monorepo holds 21 independently-versioned Python packages. They split along two axes: layer (core abstractions vs implementation vs integrations) and lifecycle (active vs maintenance).
| Package | Path | Role | Status |
|---|---|---|---|
langchain-core |
libs/core/ |
Base abstractions: Runnable, messages, language models, tools, prompts | active (details) |
langchain |
libs/langchain_v1/ |
The new langchain package: create_agent, middleware, init_chat_model |
active (details) |
langchain-classic |
libs/langchain/ |
Legacy chains, agents, retrievers, evaluation, indexing | maintenance (details) |
langchain-text-splitters |
libs/text-splitters/ |
Document chunkers (text, code, HTML, JSON, Markdown, …) | active (details) |
langchain-tests |
libs/standard-tests/ |
Shared test base classes for partners | active (details) |
langchain-model-profiles |
libs/model-profiles/ |
CLI + data for model capability profiles | active (details) |
| 15 partner packages | libs/partners/<provider>/ |
Provider integrations (OpenAI, Anthropic, …) | active (details) |
Layering
graph TD
USER[User application]
LV1["langchain (libs/langchain_v1/)"]
LCC["langchain-classic (libs/langchain/)"]
PARTNERS["partners/* (libs/partners/*)"]
CORE["langchain-core (libs/core/)"]
SPLIT["langchain-text-splitters"]
PROF["langchain-model-profiles"]
TESTS["langchain-tests"]
USER --> LV1
USER --> LCC
USER --> PARTNERS
USER --> SPLIT
LV1 --> CORE
LCC --> CORE
PARTNERS --> CORE
PARTNERS -.uses for capability data.-> PROF
PARTNERS -.test base classes.-> TESTS
SPLIT --> COREWhy so many packages?
Three forces drive the split:
Dependency hygiene.
langchain-corehas only a handful of runtime dependencies (pydantic,tenacity,langsmith,jsonpatch,PyYAML,typing-extensions,packaging,uuid-utils,langchain-protocol). A user who installs onlylangchain-openaiandlangchain-coredoesn't get the entire ecosystem's dependency tree.Independent release cadence. Each partner can ship as fast as the upstream provider releases features.
langchain-openaitypically ships within hours of OpenAI announcing new model support, without waiting for a fulllangchainrelease.Versioning isolation.
langchain-core==1.3.xis API-stable for downstream consumers. Breaking changes happen at major version boundaries with deprecation warnings shipped in advance. Partner packages can independently signal their compatibility ranges viapyproject.toml.
Workspace plumbing
Every package has:
- A
pyproject.tomldeclaringhatchlingas the build backend. - A
uv.lockfor reproducible local installs. - A
Makefilewithtest,lint,formattargets (and integration variants). - A
tests/directory split intounit_tests/andintegration_tests/. - A
[tool.uv.sources]section pointing to sibling packages witheditable = true.
Cross-package edits propagate immediately because of the editable installs — there's no need to reinstall after a code change.
See also
- Architecture — how the layers fit together
- Partners — the 15 provider integrations in this repo
- Primitives — the cross-cutting abstractions in
langchain-core - Features — agents, middleware, structured output
Built by Factory AutoWiki from public repository content. It is a generated preview for codebase exploration, not source-maintained documentation.