Compare commits

...

3 Commits

Author SHA1 Message Date
Bagatur
304a2e6ece fmt 2024-07-08 19:44:20 -07:00
Bagatur
bb749f49b8 fmt 2024-07-08 19:43:30 -07:00
Bagatur
6ffcdc1c13 docs: intro nit 2024-07-08 19:40:32 -07:00
2 changed files with 36 additions and 26 deletions

View File

@@ -7,18 +7,18 @@ This section contains introductions to key parts of LangChain.
## Architecture
LangChain as a framework consists of a number of packages.
LangChain as a framework consists of a number of packages and platforms.
### `langchain-core`
This package contains base abstractions of different components and ways to compose them together.
The interfaces for core components like LLMs, vector stores, retrievers and more are defined here.
No third party integrations are defined here.
The dependencies are kept purposefully very lightweight.
The dependencies are intentionally kept very lightweight.
### Partner packages
### Integration packages
While the long tail of integrations are in `langchain-community`, we split popular integrations into their own packages (e.g. `langchain-openai`, `langchain-anthropic`, etc).
This was done in order to improve support for these important integrations.
The most commonly-used integrations are split into their own packages (e.g. `langchain-openai`, `langchain-anthropic`, etc.) so that they can be properly versioned and tested, and their dependencies fully specified.
Integrations that are not yet maintained in their own package live in the `langchain-community` package (see below).
### `langchain`
@@ -29,7 +29,7 @@ All chains, agents, and retrieval strategies here are NOT specific to any one in
### `langchain-community`
This package contains third party integrations that are maintained by the LangChain community.
Key partner packages are separated out (see below).
Key integration are separated out into their own packages (see **Integration packages** above).
This contains all integrations for various components (LLMs, vector stores, retrievers).
All dependencies in this package are optional to keep the package as lightweight as possible.
@@ -37,8 +37,9 @@ All dependencies in this package are optional to keep the package as lightweight
`langgraph` is an extension of `langchain` aimed at
building robust and stateful multi-actor applications with LLMs by modeling steps as edges and nodes in a graph.
`langgraph` exposes high level interfaces for creating common types of agents, as well as a low-level API for composing custom flows.
LangGraph exposes high level interfaces for creating common types of agents, as well as a low-level API for composing custom flows.
Head to the [`langgraph` docs here](https://langchain-ai.github.io/langgraph).
### [`langserve`](/docs/langserve)
@@ -46,7 +47,9 @@ A package to deploy LangChain chains as REST APIs. Makes it easy to get a produc
### [LangSmith](https://docs.smith.langchain.com)
A developer platform that lets you debug, test, evaluate, and monitor LLM applications.
A developer platform that lets you debug, evaluate, monitor, and optimize LLM applications, whether they're built with LangChain libraries or not.
Head to the [LangSmith docs here](https://docs.smith.langchain.com/).
<ThemedImage
alt="Diagram outlining the hierarchical organization of the LangChain framework, displaying the interconnected parts across multiple layers."
@@ -57,6 +60,12 @@ A developer platform that lets you debug, test, evaluate, and monitor LLM applic
title="LangChain Framework Overview"
/>
- **[LangGraph Cloud](https://langchain-ai.github.io/langgraph/cloud/)**:
Turn your LangGraph applications into production-ready Assistant APIs.
Head to the [LangGraph Cloud docs here](https://langchain-ai.github.io/langgraph/cloud/).
## LangChain Expression Language (LCEL)
<span data-heading-keywords="lcel"></span>

View File

@@ -5,19 +5,20 @@ sidebar_class_name: hidden
# Introduction
**LangChain** is a framework for developing applications powered by large language models (LLMs).
**LangChain** is a software framework that helps you build more reliable large language model (LLM) applications, faster.
LangChain simplifies every stage of the LLM application lifecycle:
- **Development**: Build your applications using LangChain's open-source [building blocks](/docs/concepts#langchain-expression-language-lcel), [components](/docs/concepts), and [third-party integrations](/docs/integrations/platforms/).
Use [LangGraph](/docs/concepts/#langgraph) to build stateful agents with first-class streaming and human-in-the-loop support.
- **Productionization**: Use [LangSmith](https://docs.smith.langchain.com/) to inspect, monitor and evaluate your chains, so that you can continuously optimize and deploy with confidence.
- **Deployment**: Turn your LangGraph applications into production-ready APIs and Assistants with [LangGraph Cloud](https://langchain-ai.github.io/langgraph/cloud/).
LangChain open-source libraries and commercial products simplify every stage of the LLM application lifecycle:
- **Develop**: Quickly build applications that are highly modular and easy to iterate on with `langchain`'s
[standard interfaces](/docs/concepts/#langchain-expression-language-lcel) for the most popular [models](/docs/concepts/#chat-models), [vector stores](/docs/concepts/#vector-stores), and [much more](/docs/concepts/#components).
Create stateful, agentic workflows with first-class support for event streaming and human-in-the-loop architectures using [`langgraph`](/docs/concepts/#langgraph).
- **Productionize**: Continuously deploy with confidence using [LangSmith](https://docs.smith.langchain.com/), a developer platform for inspecting, monitoring, evaluating, and optimizing LLM applications.
- **Deploy**: Turn your LangGraph applications into production-ready Assistant APIs with [LangGraph Cloud](https://langchain-ai.github.io/langgraph/cloud/).
import ThemedImage from '@theme/ThemedImage';
import useBaseUrl from '@docusaurus/useBaseUrl';
<ThemedImage
alt="Diagram outlining the hierarchical organization of the LangChain framework, displaying the interconnected parts across multiple layers."
alt="Outline of the LangChain framework."
sources={{
light: useBaseUrl('/svg/langchain_stack_062024.svg'),
dark: useBaseUrl('/svg/langchain_stack_062024_dark.svg'),
@@ -27,18 +28,19 @@ import useBaseUrl from '@docusaurus/useBaseUrl';
Concretely, the framework consists of the following open-source libraries:
- **`langchain-core`**: Base abstractions and LangChain Expression Language.
- **`langchain-community`**: Third party integrations.
- Partner packages (e.g. **`langchain-openai`**, **`langchain-anthropic`**, etc.): Some integrations have been further split into their own lightweight packages that only depend on **`langchain-core`**.
- **`langchain`**: Chains, agents, and retrieval strategies that make up an application's cognitive architecture.
- **[LangGraph](https://langchain-ai.github.io/langgraph)**: Build robust and stateful multi-actor applications with LLMs by modeling steps as edges and nodes in a graph. Integrates smoothly with LangChain, but can be used without it.
- **[LangServe](/docs/langserve)**: Deploy LangChain chains as REST APIs.
- **[LangSmith](https://docs.smith.langchain.com)**: A developer platform that lets you debug, test, evaluate, and monitor LLM applications.
- **`langchain-core`**: [Component abstractions](/docs/concepts/#components) and [LangChain Expression Language](/docs/concepts/#langchain-expression-language-lcel).
- Integration packages (`langchain-openai`, `langchain-anthropic`, `langchain-community`, etc.): Standard interfaces for all the most popular third-party integrations.
- **`langchain`**: Prebuilt chains, agents, and retrieval strategies for common cognitive architectures.
- **[`langgraph`](https://langchain-ai.github.io/langgraph)**: Protocol for building robust and stateful multi-actor applications with LLMs by modeling steps as edges and nodes in a graph. Integrates seamlessly with `langchain` and LangSmith, but can be used without them as well.
- **[`langserve`](/docs/langserve)**: Library for serving `langchain` chains as REST APIs.
And the following commercial products:
- **[LangSmith](https://docs.smith.langchain.com)**: A developer platform that lets you debug, evaluate, monitor, and optimize LLM applications, whether or not they're built with LangChain libraries.
- **[LangGraph Cloud](https://langchain-ai.github.io/langgraph/cloud/)**: Turn your LangGraph applications into production-ready Assistant APIs.
:::note
These docs focus on the Python LangChain library. [Head here](https://js.langchain.com) for docs on the JavaScript LangChain library.
These docs focus on the Python LangChain libraries (`langchain-core`, `langchain`, `langchain-community`, etc.). [Head here](https://js.langchain.com) for docs on the JavaScript LangChain libraries and [here](https://langchain-ai.github.io/langgraph) for docs on LangGraph.
:::
@@ -54,12 +56,11 @@ These are the best ones to get started with:
- [Build an Agent](/docs/tutorials/agents)
- [Introduction to LangGraph](https://langchain-ai.github.io/langgraph/tutorials/introduction/)
Explore the full list of LangChain tutorials [here](/docs/tutorials), and check out other [LangGraph tutorials here](https://langchain-ai.github.io/langgraph/tutorials/).
Explore the full list of [LangChain tutorials here](/docs/tutorials), and check out [LangGraph tutorials here](https://langchain-ai.github.io/langgraph/tutorials/).
## [How-to guides](/docs/how_to)
[Here](/docs/how_to) youll find short answers to “How do I….?” types of questions.
[Here](/docs/how_to) youll find short answers to “How do I…?” types of questions.
These how-to guides dont cover topics in depth youll find that material in the [Tutorials](/docs/tutorials) and the [API Reference](https://api.python.langchain.com/en/latest/).
However, these guides will help you quickly accomplish common tasks.