LangChain: the open source framework for LLM applications

LangChain formalises chains, agents, tools, memory and retrievers in a Python and JavaScript framework. Version 0.1.0 from January 2024 separates langchain-core, langchain-community and langchain.

Open SourceAI Open SourceLangChainAgenticLLMAIFramework

Origin and positioning

LangChain was born in October 2022 as an open source project by Harrison Chase, at the moment large language models started to become accessible through commercial APIs. The goal is to provide a common abstraction layer above models — OpenAI, Anthropic, Hugging Face, Cohere and others — and to formalise recurring patterns in LLM application development.

The framework is available in two languages, Python and JavaScript/TypeScript, under the MIT licence. Around the project LangChain Inc. was founded, which also develops complementary commercial components such as LangSmith, an observability and evaluation platform.

Core concepts

LangChain organises LLM application development around a set of primitives. Chains are ordered sequences of processing steps: a typical chain combines a prompt template, a model call and an output parser. Agents introduce the ability to dynamically decide which operations to execute, selecting the available tools based on conversation context.

Memory manages state across successive calls, providing different strategies — window buffer, summaries, vector memories — to keep context within model limits. Retrievers abstract access to external knowledge sources, typically vector stores, to implement retrieval-augmented generation patterns.

The 0.1.0 release and package separation

On 8 January 2024 LangChain 0.1.0 was released, the first declared stable release after more than a year of intense development. The most relevant change is structural: the codebase is split into three distinct packages. langchain-core contains fundamental abstractions and the LCEL (LangChain Expression Language) composition language. langchain-community collects integrations with third-party providers and services. langchain holds higher-level chains and agents.

The separation addresses a recurring criticism of previous releases: an API surface that was too broad and subject to frequent changes. With the split, integrations with individual providers can be versioned independently without impacting the framework core.

Ecosystem and adoption

LangChain has become one of the reference points for building RAG pipelines and conversational agents, with an integration ecosystem covering most vector databases, LLM providers and cloud services. Adoption is accompanied by a recurring debate on the appropriate abstraction level: the availability of high-level components accelerates prototyping but requires care in choosing the primitives most suitable to the use case.

Link: langchain.com

Need support? Under attack? Service Status
Need support? Under attack? Service Status