Comment on page

LangStream CLI

Use the CLI to test, verify and deploy applications.
For LangStream CLI commands, see CLI commands. To configure the LangStream CLI, see CLI configuration.



Install the latest version
brew install LangStream/langstream/langstream
Install a specific version
brew install LangStream/langstream/[email protected]
To upgrade
brew upgrade LangStream/langstream/langstream
To upgrade to a specific version
brew upgrade LangStream/langstream/[email protected]


Install the latest version
curl -Ls "" | bash
Install a specific version
export LANGSTREAM_CLI_URL="$version/langstream-cli-$"
curl -Ls "" | bash
To upgrade the CLI version, you can run the installer again.


Use WSL.
Alternatively, you can run the .bat file present inside the CLI tarball. You can download the tarball from Github Releases
Want to get started a little quicker? Check out the LangStream VSCode Extension for pre-made applications and agent code snippets.

Confirm the installation

Once installed you can test the CLI with the following command.
langstream -h

Enable auto-completion

Installing the binary directly will enable auto-completion for the CLI.
If you installed the CLI with Homebrew, you can enable auto-completion with the following command:


[[ $(grep 'langstream generate-completion' "$HOME/.zshrc") ]] || echo -e "source <(langstream generate-completion)" >> "$HOME/.zshrc"
source $HOME/.zshrc # or open another terminal


[[ $(grep 'langstream generate-completion' "$HOME/.bashrc") ]] || echo -e "source <(langstream generate-completion)" >> "$HOME/.bashrc"
source $HOME/.bashrc # or open another terminal

Step by step guide on Amazon Linux VM

If for some reasons you prefer to install the CLI and test the applications on a remote machine, this is setup you need to go through.
After creating the VM on EC2, you can run the following commands:
sudo yum update
# jq, unzip are for the installer
sudo yum install -y docker jq unzip java-11-amazon-corretto-headless
# setup docker
sudo usermod -a -G docker ec2-user
id ec2-user
newgrp docker
sudo systemctl enable docker.service
sudo systemctl start docker.service
# download the CLI
curl -Ls "" | bash
source ~/.bashrc
# run the sample application
export OPEN_AI_ACCESS_KEY=your-key-here
langstream docker run test -app -s