Requirements

  1. Clickhouse DB self hosted or managed service
  2. Postgres self hosted or managed service

Step 1: Clone the repository

Clone the repository using the following command

git clone https://github.com/Scale3-Labs/langtrace
cd langtrace

Step 2: Configure environment variables

Langtrace needs postgres and clickhouse to run. Update the Postgres and Clickhouse connection details in the .env file to point to your database.

Make sure the Postgres and Clickhouse databases are running and accessible from the Langtrace app. If you wish to run them using Docker, checkout the docker compose guide here.

Authentication Configuration

Langtrace supports multiple authentication methods. Configure the necessary environment variables for your chosen authentication method(s) in the .env file. For detailed instructions, refer to our Authentication guide.

Step 3: Build the Docker image

This is an optional step, skip this step if you want to use the pre-built Docker image.

Run the following command to build the Docker image:

docker build -t scale3labs/langtrace-client .

Step 4: Run the Docker container

Run the following command to start the Langtrace app

docker run -d -p 3000:3000 --env-file .env --name langtrace scale3labs/langtrace-client:latest /bin/sh -c "npm run create-tables && npm run dev"

The Langtrace app will be available at http://localhost:3000

If you wish to manually pull the specific release version of the Docker image from docker hub, you can use the following command

docker pull scale3labs/langtrace-client:<Release Version>

Next Steps

After setting up Langtrace, make sure to configure your chosen authentication method(s) and create the necessary user accounts. Refer to the Authentication guide for detailed instructions.