Verify Everything (vet)
Verify Everything (vet) is an LLM-based code review command-line interface (CLI) tool that identifies issues tests and linters often miss. It leverages various LLMs to analyze code changes and provide feedback. The library is currently at version 0.2.10 and receives frequent updates, typically involving minor version bumps to add new features, support new models, and fix bugs.
Common errors
-
Command 'vet' not found
cause The `vet` executable is not in your system's PATH, or the `verify-everything` package is not installed in the active Python environment.fixEnsure `verify-everything` is installed (`pip install verify-everything`) and that your shell's PATH includes the directory where pip installs scripts (e.g., `~/.local/bin` or your virtual environment's `bin` directory). -
Error: API key not provided. Please provide an API key...
cause You are attempting to run a `vet` command without providing the necessary LLM API key. This key is required to authenticate with the LLM service.fixSet the API key as an environment variable (e.g., `export ANTHROPIC_API_KEY="sk-..."`) or pass it directly using the `--api-key` argument (e.g., `vet diff --api-key YOUR_KEY`). -
SyntaxError: 'annotations' is not defined (Python < 3.11)
cause You are running `vet` with a Python version older than 3.11. `vet` uses syntax features only available in Python 3.11 or newer.fixUpgrade your Python environment to version 3.11 or higher. We recommend creating a virtual environment with the correct Python version: `python3.11 -m venv .venv && source .venv/bin/activate && pip install verify-everything`.
Warnings
- gotcha The `vet` tool requires Python 3.11 or newer. Using older Python versions will lead to syntax errors or other compatibility issues.
- gotcha Verify Everything (vet) is primarily a command-line interface (CLI) tool. It does not expose a public programmatic Python API for direct import and use by users. Its functionality is accessed through shell commands.
- breaking The default LLM model used by `vet` has changed multiple times across versions. For example, v0.2.10 switched the default to Claude Opus 4.7. If you rely on a specific model, it's best to explicitly specify it.
- gotcha The `vet` tool requires an API key for the chosen LLM (e.g., Anthropic, OpenAI) to be available, either as an environment variable (e.g., `ANTHROPIC_API_KEY`, `OPENAI_API_KEY`) or passed directly via the `--api-key` argument. Without it, commands will fail.
Install
-
pip install verify-everything
Quickstart
# Ensure you have an Anthropic or OpenAI API key set as an environment variable
# e.g., export ANTHROPIC_API_KEY="sk-..."
# Or pass it directly: --api-key $ANTHROPIC_API_KEY
# Create a dummy file and make a change
!echo "print('Hello, world!')" > test_file.py
!git init --initial-branch=main
!git add test_file.py
!git commit -m "Initial commit"
!echo "print('Hello, updated world!')" >> test_file.py
# Run vet diff to get an LLM review of the unstaged changes
# The default model is Claude Opus 4.7 as of v0.2.10
import os
if os.environ.get('ANTHROPIC_API_KEY'):
print("Running vet diff (requires Anthropic API key)...")
os.system("vet diff")
else:
print("Skipping vet diff: ANTHROPIC_API_KEY not found. Please set it to run.")
# To review staged changes, use:
# os.system("git add test_file.py")
# os.system("vet review --staged")