# langchain-ai/langchain

> LangChain is a framework for building agents and LLM-powered applications. It chains together interoperable components and third-party integrations to simplify AI application development. The core code is written in Python.

Source: https://github.com/langchain-ai/langchain
Indexed: commit 6bd561c on 2026-11-18 by Repowise. Facts come from the source and git history, not from the maintainer.

## Facts

- Language: Python
- Stars: 149,847 at index time
- License: MIT
- Code health: 7.3/10, Good
- Last commit: 2026-11-18
- Contributors: 3,721

## Install

From the README: https://github.com/langchain-ai/langchain#quickstart

Install LangChain with uv.
    uv add langchain

## How it works

The repository is organized as separate Python packages under libs, which holds most of its files. libs/core/langchain_core/__init__.py is the entry point of the langchain_core package, which provides the shared base layer for the other packages. libs/core/langchain_core/runnables/base.py is a hotspot file in that core package and defines the runnable base classes that components are built on. Provider integrations live under libs/partners, where libs/partners/openai/langchain_openai/chat_models/base.py holds the chat model code for OpenAI. libs/langchain_v1/langchain/__init__.py is the entry point of the langchain package that the quickstart imports from. A model object takes a prompt through invoke and returns the result.

- libs/core/langchain_core/__init__.py: entry point
- libs/langchain/langchain_classic/__init__.py: entry point
- libs/langchain/langchain_classic/tools/ainetwork/app.py: entry point
- libs/langchain_v1/langchain/__init__.py: entry point
- libs/model-profiles/langchain_model_profiles/__init__.py: entry point
Modules: libs, .github. 2,994 files, 334,205 lines, 21,089 symbols.

## Code health

- Score: 7.3/10 (Good)
- Trend: 6.8 on 2026-11-11, 7.3 on 2026-11-18
- Rank: #129 of 4,000+ indexed repos
- Hotspots: libs/partners/openrouter/langchain_openrouter/data/_profiles.py, libs/partners/anthropic/langchain_anthropic/chat_models.py, libs/partners/openai/langchain_openai/chat_models/base.py, libs/partners/fireworks/langchain_fireworks/data/_profiles.py, libs/core/langchain_core/runnables/base.py
- Lowest file: libs/partners/openai/langchain_openai/chat_models/base.py
- Dead code: 2 findings

## Maintenance

- Last commit 2026-11-18, first commit 2022-10-24, 17,117 commits
- 3,721 contributors, bus factor 3

## Security

- Security findings are shown to signed-in users at https://repowise.dev/repo/langchain-ai/langchain/security

## More

- Page: https://repowise.dev/repo/langchain-ai/langchain
- Ask this codebase: https://repowise.dev/repo/langchain-ai/langchain/chat
- Docs: https://repowise.dev/repo/langchain-ai/langchain/docs
- MCP (signs in with Repowise on first use):
    claude mcp add --transport http repowise https://api.repowise.dev/mcp/langchain-ai/langchain
