Skip to content

Getting Started with Latent Agent

Windows users should use WSL

If you're running the Latent Agent on a Windows machine, install and use Windows Subsystem for Linux (WSL).

1. Retrieve LEIP license key

Navigate to https://accounts.latentai.io/sign-up to create a new account. After you verify your email address, we'll email you a one-year trial license key.

2. Set LEIP license key

Complete this step before launching Visual Studio Code

If VS Code is already running, you'll need to close it and relaunch after completing this step.

License keys on target devices

On your target machine (i.e., the machine that will run inference), assign your license key to the LEIP_LICENSE_KEY environment variable:

bash
export LEIP_LICENSE_KEY=<your-license-key>

The license key you receive via email should be placed in the following location on your development machine: ~/.leip/license.key. If you'd like, you can replace <your-license-key> and run the following command:

bash
mkdir -p ~/.leip && echo "<your-license-key>" > ~/.leip/license.key
Alternative License Key Configurations

The above instructions are the best way to ensure multiple processes have access to your license key. If you prefer, however, you can set the LEIP_LICENSE_KEY as an environment variable. You can also place the license key in your present working directory: $(pwd)/.leip/license.key.

3. Install the Roo Code extension in VS Code

If you haven't already, download and install Visual Studio Code. Then, open a new window, select the Extensions tab from the Activity Bar on the left side of the VS Code window, and search for Roo Code. Install the Roo Code extension.

4. Configure the Roo Code extension in VS Code

The Roo Code extension should now be visible on the Activity Bar. Click on the Roo Code icon and then the gear icon to open the configuration settings in the Primary Sidebar on the left side of your window. Enter the following settings:

  • API Provider: OpenAI Compatible
  • Base URL:
https://chat.latentai.io
  • API Key: Enter your LEIP License Key
  • Model:
Latent Agent 1A
  • Select "Enable Prompt Caching"

When completed, your Roo Code Settings should look like this:

Completed Roo Code Configuration

5. Install the Latent Agent Model Context Protocol (MCP)

Create and Activate a Python Virtual Environment

We recommend creating and activating a Python virtual environment with Python 3.10. For example:

bash
python3.10 -m venv agentenv && source agentenv/bin/activate

To install the Latent Agent MCP, run the following command:

bash
pip install latent-agent --extra-index-url https://packages.latentai.io/pypi/public/simple

To initialize Latent Agent, replace path/to/workspace with the absolute path to your VS Code workspace root and run the following command:

bash
 latent-agent init /path/to/workspace
VS Code workspace root

The VSCode workspace root is the top-level folder that VSCode uses as the starting point for your project. It's where:

  • Your project files live
  • VSCode looks for configuration files like .vscode/settings.json, package.json, etc.
  • Relative paths in the terminal and editor are resolved
  • Roo Code looks for its project-level modes and MCPs (.roo/ folder)

If you open a folder in VSCode, that folder becomes the workspace root.

Finally, either relaunch or reload VS Code and use the Command Palette to select your virtual environment as the Python interpreter.

6. Verify installation

Under the Roo Code Modes tab, you should see the following:

  • LatentAI Orchestrator
  • LatentAI Customer Success Specialist
  • LatentAI Application Engineer
  • LatentAI Tester and Debugger
  • LatentAI Concierge
  • LatentAI Recipe Explorer

And under the MCP Servers tab, you should see model-purveyor and grdb-suggester.

To get started, simply ask the LatentAI Concierge what to do.