vai logo
vai
Use CasesShared SpaceDocs
Get Started
Demo Library

Watch, copy, and reproducereal vai demos

A curated gallery of CLI demos sourced from `voyageai-cli`, with exact commands, prerequisites, and direct links to the original tape files.

13 published demos

22 learning paths

Source of truth: `voyageai-cli/docs/demos` and `docs/demos/tapes`

All
Benchmarks
Chat
Chunking
Cost Optimization
Docker
Embeddings
Getting Started
Hybrid Search
Input Types
Local Embeddings
Local Inference
Matryoshka
Model Discovery
Model Selection
MongoDB Atlas
Pipeline
Preprocessing
RAG
Reranking
Retrieval
Similarity
Vector Search

Featured demos

A lightweight starting set focused on developer education and reproducibility.

Getting Started
Embeddings
Featured
CLI Quickstart For Embeddings

Walk through the core vai embedding commands: model discovery, embedding generation, explainers, and similarity.

API key

VAI command

vai embed "What is MongoDB Atlas?"

Show Under the Hood

Prerequisites

A valid VOYAGE_API_KEY is set in the environment.

View DemoSource
Getting Started
Local Inference
Featured
Local Inference With Ollama

Run a local CLI workflow with Ollama generation and local embeddings, without a Voyage API key.

Offline-capable
Requires Ollama

VAI command

vai embed "Local inference keeps retrieval private, fast, and API-key free." --local --dimensions 256

Show Under the Hood

Prerequisites

Ollama is installed and running locally.

RAG
Local Inference
Featured
Local RAG Chat With Ollama And Nano

Build a tiny Atlas-backed RAG chat flow using local nano embeddings and Ollama for generation.

Requires Ollama
Atlas

VAI command

vai chat --db "$DEMO_DB" --collection "$DEMO_COLLECTION" --local --llm-provider ollama --llm-model "$OLLAMA_MODEL" --llm-base-url http://localhost:11434 --no-history --no-stream

Show Under the Hood

Prerequisites

Ollama is installed and running locally.

Getting Started
Embeddings
Featured
What Is an Embedding?

Start from first principles: generate a Voyage embedding, inspect its shape, and compare full-size versus Matryoshka-reduced vectors.

API key

VAI command

vai embed 'MongoDB Atlas makes vector search production-ready'

Show Under the Hood

Prerequisites

A valid VOYAGE_API_KEY is set in the environment.

Pipeline
MongoDB Atlas
Featured
End-to-End Atlas Pipeline

Run the full workflow in one command: create sample docs, chunk them, embed them, store them in Atlas, and auto-create the vector index.

Atlas
API key

VAI command

vai pipeline /tmp/vai-demo-docs/ --db vai_demo --collection knowledge --create-index

Show Under the Hood

Prerequisites

A valid VOYAGE_API_KEY is set in the environment.

Retrieval
Reranking
Featured
Two-Stage Retrieval With Reranking

Walk through the classic retrieval stack: embed the query, run Atlas vector search, rerank the candidates, then compare the result to a vector-only pass.

Atlas
API key

VAI command

vai query 'how does vector search work?' --db vai_demo --collection knowledge --model voyage-4-lite

Show Under the Hood

Prerequisites

A valid VOYAGE_API_KEY is set in the environment.

Pipeline
MongoDB Atlas
Featured
Vector Search Developer Day (VAI Edition)

The complete MongoDB Developer Day vector search workshop reimagined as a VAI CLI workflow. Use it as a backup during the Vector Search: Beginner to Pro lab or afterward to reinforce concepts: set up local MongoDB, install the CLI, generate embeddings with voyage-4-nano, create a vector index, and run semantic search — end to end from the command line.

Atlas

VAI command

vai query "A man wearing a golden crown" --db mongodb_genai_devday_vs --collection books --model voyage-4-lite

Show Under the Hood

Prerequisites

Docker installed (for local MongoDB Atlas) or access to a MongoDB Atlas cluster.

RAG
MongoDB Atlas
Featured
RAG Developer Day (VAI Edition)

The complete MongoDB Developer Day RAG lab reimagined as a VAI CLI workflow. Use it as a backup during the Build RAG Applications using MongoDB lab or afterward to reinforce concepts: ingest documentation chunks, create a vector index, and run RAG chat — end to end from the command line.

Atlas
API key

VAI command

vai chat --db mongodb_genai_devday_rag --collection knowledge_base

Show Under the Hood

Prerequisites

Docker installed (for local MongoDB Atlas) or access to a MongoDB Atlas cluster.


All demos

13 results matching the current filters.

Getting Started
Embeddings
Featured
CLI Quickstart For Embeddings

Walk through the core vai embedding commands: model discovery, embedding generation, explainers, and similarity.

API key

VAI command

vai embed "What is MongoDB Atlas?"

Show Under the Hood

Prerequisites

A valid VOYAGE_API_KEY is set in the environment.

Getting Started
Local Inference
Featured
Local Inference With Ollama

Run a local CLI workflow with Ollama generation and local embeddings, without a Voyage API key.

Offline-capable
Requires Ollama

VAI command

vai embed "Local inference keeps retrieval private, fast, and API-key free." --local --dimensions 256

Show Under the Hood

Prerequisites

Ollama is installed and running locally.

RAG
Local Inference
Featured
Local RAG Chat With Ollama And Nano

Build a tiny Atlas-backed RAG chat flow using local nano embeddings and Ollama for generation.

Requires Ollama
Atlas

VAI command

vai chat --db "$DEMO_DB" --collection "$DEMO_COLLECTION" --local --llm-provider ollama --llm-model "$OLLAMA_MODEL" --llm-base-url http://localhost:11434 --no-history --no-stream

Show Under the Hood

Prerequisites

Ollama is installed and running locally.

Getting Started
Embeddings
Featured
What Is an Embedding?

Start from first principles: generate a Voyage embedding, inspect its shape, and compare full-size versus Matryoshka-reduced vectors.

API key

VAI command

vai embed 'MongoDB Atlas makes vector search production-ready'

Show Under the Hood

Prerequisites

A valid VOYAGE_API_KEY is set in the environment.

Embeddings
Retrieval
Document vs Query Embeddings

Show why input type matters by embedding the same sentence as both a document and a query, then validating the semantic overlap with similarity.

API key

VAI command

vai embed 'Vector search finds semantically similar content' --input-type query

Show Under the Hood

Prerequisites

A valid VOYAGE_API_KEY is set in the environment.

Chunking
Preprocessing
Chunking Strategies Before Embedding

Compare fixed, sentence, and markdown chunking on the same sample document before any embedding or storage layer is introduced.

Offline-capable

VAI command

vai chunk /tmp/sample.md --strategy markdown

Show Under the Hood

Prerequisites

The `vai` CLI is installed locally. No API key is required for chunking-only workflows.

Pipeline
MongoDB Atlas
Featured
End-to-End Atlas Pipeline

Run the full workflow in one command: create sample docs, chunk them, embed them, store them in Atlas, and auto-create the vector index.

Atlas
API key

VAI command

vai pipeline /tmp/vai-demo-docs/ --db vai_demo --collection knowledge --create-index

Show Under the Hood

Prerequisites

A valid VOYAGE_API_KEY is set in the environment.

Retrieval
Reranking
Featured
Two-Stage Retrieval With Reranking

Walk through the classic retrieval stack: embed the query, run Atlas vector search, rerank the candidates, then compare the result to a vector-only pass.

Atlas
API key

VAI command

vai query 'how does vector search work?' --db vai_demo --collection knowledge --model voyage-4-lite

Show Under the Hood

Prerequisites

A valid VOYAGE_API_KEY is set in the environment.

Embeddings
Cost Optimization
Shared Embedding Space And Cost Savings

Validate that Voyage 4 models share an embedding space, then connect that result to asymmetric retrieval and concrete cost savings.

API key

VAI command

vai benchmark space

Show Under the Hood

Prerequisites

A valid VOYAGE_API_KEY is set in the environment.

Reranking
Retrieval
Standalone Reranking

Rerank intentionally messy candidate documents against a query, then compare the full reranker to the lite version to show the latency-precision tradeoff.

API key

VAI command

vai rerank 'how do I connect to MongoDB Atlas?' --documents 'Use the connection string from your Atlas dashboard' 'Python is a popular language' 'Atlas supports vectorSearch aggregation' 'Copy your URI and pass it to MongoClient' 'The weather in San Francisco is mild'

Show Under the Hood

Prerequisites

A valid VOYAGE_API_KEY is set in the environment.

Model Discovery
Benchmarks
Models And Benchmarks

Survey the Voyage model lineup, explain benchmark context, and then measure embedding latency on your own hardware before choosing a production model.

API key

VAI command

vai benchmark embed --input 'What is the best way to index a large document corpus?'

Show Under the Hood

Prerequisites

A valid VOYAGE_API_KEY is set in the environment.

Pipeline
MongoDB Atlas
Featured
Vector Search Developer Day (VAI Edition)

The complete MongoDB Developer Day vector search workshop reimagined as a VAI CLI workflow. Use it as a backup during the Vector Search: Beginner to Pro lab or afterward to reinforce concepts: set up local MongoDB, install the CLI, generate embeddings with voyage-4-nano, create a vector index, and run semantic search — end to end from the command line.

Atlas

VAI command

vai query "A man wearing a golden crown" --db mongodb_genai_devday_vs --collection books --model voyage-4-lite

Show Under the Hood

Prerequisites

Docker installed (for local MongoDB Atlas) or access to a MongoDB Atlas cluster.

RAG
MongoDB Atlas
Featured
RAG Developer Day (VAI Edition)

The complete MongoDB Developer Day RAG lab reimagined as a VAI CLI workflow. Use it as a backup during the Build RAG Applications using MongoDB lab or afterward to reinforce concepts: ingest documentation chunks, create a vector index, and run RAG chat — end to end from the command line.

Atlas
API key

VAI command

vai chat --db mongodb_genai_devday_rag --collection knowledge_base

Show Under the Hood

Prerequisites

Docker installed (for local MongoDB Atlas) or access to a MongoDB Atlas cluster.