llama-dev/README.md
The official CLI for development, testing, and automation in the LlamaIndex monorepo.
llama-dev is a command-line tool designed to simplify development and testing workflows in the LlamaIndex monorepo. It provides commands for managing packages, running tests, and automating common development tasks.
First step, create a virtual environment for the project:
uv venv
source .venv/bin/activate
Then install llama_dev in the virtual environment:
uv pip install -e .
You should now have the llama-dev CLI available in your path.
[!TIP] It's easier to run
llama-devfrom the root of thellama_indexrepo, otherwise you have to pass the--repo-rootoption at every command.
llama-dev --help
Get information about packages in the monorepo:
# Get info for a specific package
llama-dev pkg info llama-index-core
# Get info for all packages
llama-dev pkg info --all
Execute commands in package directories:
# Run a command in a specific package
llama-dev pkg exec --cmd "uv sync" llama-index-core
# Run a command in all packages
llama-dev pkg exec --cmd "uv sync" --all
# Same but exit at the first error
llama-dev pkg exec --cmd "uv" --all --fail-fast
Run tests across the monorepo:
# Run tests for packages changed compared to main
llama-dev test --base-ref main
# Run tests with coverage
llama-dev test --base-ref main --cov
# Run tests with coverage threshold
llama-dev test --base-ref main --cov --cov-fail-under 80
# Adjust the number of parallel workers
llama-dev test --base-ref main --workers 4
# Run tests with fail-fast option
llama-dev test --base-ref main --fail-fast
uv)This project is part of the LlamaIndex monorepo and follows its licensing.