Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 5 additions & 8 deletions src/docs.json
Original file line number Diff line number Diff line change
Expand Up @@ -809,14 +809,7 @@
{
"group": "Setup guides",
"pages": [
{
"group": "LangSmith",
"icon": "server",
"pages": [
"langsmith/kubernetes",
"langsmith/docker"
]
},
"langsmith/kubernetes",
"langsmith/deploy-self-hosted-full-platform",
{
"group": "Manage an installation",
Expand Down Expand Up @@ -1941,6 +1934,10 @@
}
},
"redirects": [
{
"source": "/langsmith/docker",
"destination": "/langsmith/self-hosted"
},
{
"source": "/oss/python/langgraph/memory",
"destination": "/oss/python/concepts/memory"
Expand Down
1 change: 0 additions & 1 deletion src/langsmith/deploy-self-hosted-full-platform.mdx
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
---
title: Enable LangSmith Deployment, Fleet, Insights, and Polly
sidebarTitle: Enable additional features
icon: "server"
description: Enable LangSmith Deployment, Fleet, Insights, and Polly on a self-hosted LangSmith instance.
---

Expand Down
130 changes: 0 additions & 130 deletions src/langsmith/docker.mdx

This file was deleted.

2 changes: 1 addition & 1 deletion src/langsmith/langsmith-managed-clickhouse.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ The overall architecture looks like this:
- **You must use a supported blob storage option.** Read the [blob storage guide](/langsmith/self-host-blob-storage) for more information.
- To use private endpoints, ensure that your VPC is in a ClickHouse Cloud supported [region](https://clickhouse.com/docs/en/cloud/reference/supported-regions). Otherwise, you will need to use a public endpoint we will secure with firewall rules. Your VPC will need to have a NAT gateway to allow us to allowlist your traffic.
- You must have a VPC that can connect to the LangSmith-managed ClickHouse service. You will need to work with our team to set up the necessary networking.
- You must have a LangSmith self-hosted instance running. You can use our managed ClickHouse service with both [Kubernetes](/langsmith/kubernetes) and [Docker](/langsmith/docker) installations.
- You must have a LangSmith self-hosted instance running. You can use our managed ClickHouse service with [Kubernetes](/langsmith/kubernetes) installations.

## Data storage

Expand Down
15 changes: 3 additions & 12 deletions src/langsmith/self-host-mirroring-images.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ By default, LangSmith will pull images from our public Docker registry. However,

* Authenticated access to a Docker registry that your Kubernetes cluster/machine has access to.
* Docker installed on your local machine or a machine that has access to the Docker registry.
* A Kubernetes cluster or a machine where you can run LangSmith.
* A Kubernetes cluster where you can run LangSmith.

## Mirroring the images

Expand Down Expand Up @@ -46,11 +46,9 @@ You will need to repeat this for each image that you want to mirror.

## Configuration

Once the images are mirrored, you will need to configure your LangSmith installation to use the mirrored images. You can do this by modifying the `values.yaml` file for your LangSmith Helm Chart installation or the `.env` file for your Docker installation. Replace tag with the version you want to use, e.g. `0.10.66` for the latest version at the time of writing.
Once the images are mirrored, you will need to configure your LangSmith installation to use the mirrored images. You can do this by modifying the `values.yaml` file for your LangSmith Helm Chart installation. Replace tag with the version you want to use, e.g. `0.10.66` for the latest version at the time of writing.

<CodeGroup>

```yaml Helm
```yaml
images:
imagePullSecrets: [] # Add your image pull secrets here if needed
registry: "" # Set this to your registry URL if you mirrored all images to the same registry using our script. Then you can remove the repository prefix from the images below.
Expand Down Expand Up @@ -96,13 +94,6 @@ images:
tag: "24.8"
```

```bash Docker
# In your .env file
_REGISTRY=your-registry # Set this to your registry URL if you mirrored all images to the same registry using our script. Otherwise you will need to manually set the repository for each image in the compose file.
```

</CodeGroup>

## Additional images for Fleet and Insights

If you are using Fleet or Insights, the LangGraph operator dynamically creates Redis and PostgreSQL (pgvector) pods for each deployment. These pods use images defined in operator templates that require separate configuration.
Expand Down
93 changes: 20 additions & 73 deletions src/langsmith/self-host-upgrades.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,10 @@ title: Upgrade an installation
sidebarTitle: Upgrade an installation
---

For general upgrade instructions, please follow the instructions below. Certain versions may have specific upgrade instructions, which will be detailed in more specific upgrade guides.

<Warning>
Downgrades are not officially supported. LangSmith upgrades may include database migrations and other changes that are not backward-compatible. If you need to roll back to a previous version, contact [support](mailto:support@langchain.dev) for guidance.
</Warning>

## Kubernetes(Helm)

If you don't have the repo added, run the following command to add it:

```bash
Expand All @@ -25,7 +21,7 @@ helm repo update

Update your helm chart config file with any updates that are needed in the new version. These will be detailed in the release notes for the new version.

Run the following command to upgrade the chart(replace version with the version you want to upgrade to):
Run the following command to upgrade the chart (replace `version` with the version you want to upgrade to):

<Note>
If you are using a namespace other than the default namespace, you will need to specify the namespace in the `helm` and `kubectl` commands by using the `-n <namespace` flag.
Expand All @@ -37,7 +33,7 @@ Find the latest version of the chart. You can find this in the [LangSmith Helm C
helm search repo langchain/langsmith --versions
```

You should see an output similar to this:
You should see output similar to this:

```bash
langchain/langsmith 0.10.14 0.10.32 Helm chart to deploy the langsmith application ...
Expand All @@ -48,7 +44,7 @@ langchain/langsmith 0.10.10 0.10.29 Helm chart to deploy the
langchain/langsmith 0.10.9 0.10.29 Helm chart to deploy the langsmith application ...
```

Choose the version you want to upgrade to (generally the latest version is recommended) and note the version number.
Choose the version you want to upgrade to (generally the latest version is recommended) and note the version number:

```bash
helm upgrade <release-name> langchain/langsmith --version <version> --values <path-to-values-file> --wait --debug
Expand All @@ -60,7 +56,7 @@ Verify that the upgrade was successful:
helm status <release-name>
```

All pods should be in the `Running` state. Verify that clickhouse is running and that both `migrations` jobs have completed.
All pods should be in the `Running` state. Verify that ClickHouse is running and that both `migrations` jobs have completed.

```bash
kubectl get pods
Expand All @@ -75,82 +71,33 @@ langsmith-playground-85b444d8f7-pl589 1/1 Running 0 15h
langsmith-queue-d58cb64f7-87d68 1/1 Running 0 15h
```

### Validate your deployment:
## Validate your deployment

1. Run `kubectl get services`

Output should look something like:
Output will be similar to:

```bash
NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE
kubernetes ClusterIP 172.20.0.1 <none> 443/TCP 27d
langsmith-backend ClusterIP 172.20.22.34 <none> 1984/TCP 21d
langsmith-clickhouse ClusterIP 172.20.117.62 <none> 8123/TCP,9000/TCP 21d
langsmith-frontend LoadBalancer 172.20.218.30 <external ip> 80:30093/TCP,443:31130/TCP 21d
langsmith-platform-backend ClusterIP 172.20.232.183 <none> 1986/TCP 21d
langsmith-playground ClusterIP 172.20.167.132 <none> 3001/TCP 21d
langsmith-postgres ClusterIP 172.20.59.63 <none> 5432/TCP 21d
langsmith-redis ClusterIP 172.20.229.98 <none> 6379/TCP 20d
```
```bash
NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE
kubernetes ClusterIP 172.20.0.1 <none> 443/TCP 27d
langsmith-backend ClusterIP 172.20.22.34 <none> 1984/TCP 21d
langsmith-clickhouse ClusterIP 172.20.117.62 <none> 8123/TCP,9000/TCP 21d
langsmith-frontend LoadBalancer 172.20.218.30 <external ip> 80:30093/TCP,443:31130/TCP 21d
langsmith-platform-backend ClusterIP 172.20.232.183 <none> 1986/TCP 21d
langsmith-playground ClusterIP 172.20.167.132 <none> 3001/TCP 21d
langsmith-postgres ClusterIP 172.20.59.63 <none> 5432/TCP 21d
langsmith-redis ClusterIP 172.20.229.98 <none> 6379/TCP 20d
```

2. Curl the external ip of the `langsmith-frontend` service:
1. Curl the external ip of the `langsmith-frontend` service:

```bash
curl <external ip>/api/info
{"version":"0.5.7","license_expiration_time":"2033-05-20T20:08:06","batch_ingest_config":{"scale_up_qsize_trigger":1000,"scale_up_nthreads_limit":16,"scale_down_nempty_trigger":4,"size_limit":100,"size_limit_bytes":20971520}}
```

Check that the version matches the version you upgraded to.
Check that the version matches the version you upgraded to.

3. Visit the external ip for the `langsmith-frontend` service on your browser

The LangSmith UI should be visible/operational
1. Visit the external IP for the `langsmith-frontend` service on your browser. The LangSmith UI should be visible and operational.

![LangSmith UI](/langsmith/images/langsmith-ui.png)

## Docker

Upgrading the Docker version of LangSmith is a bit more involved than the Helm version and may require a small amount of downtime. Please follow the instructions below to upgrade your Docker version of LangSmith.

1. Update your `docker-compose.yml` file to the file used in the latest release. You can find this in the [LangSmith SDK GitHub repository](https://github.com/langchain-ai/langsmith-sdk/blob/main/python/langsmith/cli/docker-compose.yaml)
2. Update your `.env` file with any new environment variables that are required in the new version. These will be detailed in the release notes for the new version.
3. Run the following command to stop your current LangSmith instance:

```bash
docker-compose down
```

4. Run the following command to start your new LangSmith instance in the background:

```bash
docker-compose up -d
```

If everything ran successfully, you should see all the LangSmith containers running and healthy.

```bash
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
e1c8f01a4ffc langchain/langsmith-frontend:0.5.7 "/entrypoint.sh ngin…" 10 hours ago Up 40 seconds 0.0.0.0:80->80/tcp, 8080/tcp cli-langchain-frontend-1
39e1394846b9 langchain/langsmith-backend:0.5.7 "/bin/sh -c 'exec uv…" 10 hours ago Up 40 seconds 0.0.0.0:1984->1984/tcp cli-langchain-backend-1
f8688dd58f2f langchain/langsmith-go-backend:0.5.7 "./smith-go" 10 hours ago Up 40 seconds 0.0.0.0:1986->1986/tcp cli-langchain-platform-backend-1
006f1303b04d langchain/langsmith-backend:0.5.7 "saq app.workers.que…" 10 hours ago Up 40 seconds cli-langchain-queue-1
73a90242ed3a redis:7 "docker-entrypoint.s…" 10 hours ago Up About a minute (healthy) 0.0.0.0:63791->6379/tcp cli-langchain-redis-1
eecf75ca672b postgres:14.7 "docker-entrypoint.s…" 10 hours ago Up About a minute (healthy) 0.0.0.0:5433->5432/tcp cli-langchain-db-1
3aa5652a864d clickhouse/clickhouse-server:23.9 "/entrypoint.sh" 10 hours ago Up About a minute (healthy) 9009/tcp, 0.0.0.0:8124->8123/tcp, 0.0.0.0:9001->9000/tcp cli-langchain-clickhouse-1
84edc329a37f langchain/langsmith-playground:0.5.7 "docker-entrypoint.s…" 10 hours ago Up About a minute 0.0.0.0:3001->3001/tcp cli-langchain-playground-1
```

### Validate your deployment:

1. Curl the exposed port of the `cli-langchain-frontend-1` container:

```bash
curl localhost:80/info
{"version":"0.5.7","license_expiration_time":"2033-05-20T20:08:06","batch_ingest_config":{"scale_up_qsize_trigger":1000,"scale_up_nthreads_limit":16,"scale_down_nempty_trigger":4,"size_limit":100,"size_limit_bytes":20971520}}
```

2. Visit the exposed port of the `cli-langchain-frontend-1` container on your browser

The LangSmith UI should be visible/operational

![LangSmith UI](/langsmith/images/langsmith-ui.png)
Loading
Loading