Open Source • MIT License

VectorCode

Semantic code search MCP server using embeddings.
Find code by meaning, not just by name.

curl -fsSL https://raw.githubusercontent.com/alejandro-technology/vectorcode/main/install.sh | bash

Requires Rust 1.75+ for manual build

Search Beyond Keywords

Fills the gap between exact string matching (grep) and structural analysis.

"code that handles payment retries"

"where do we validate user permissions"

"functions similar to createUser"

"error recovery logic"

How It Works

1. Chunk

Source files are parsed with tree-sitter into semantically meaningful chunks.

2. Embed

Chunks are converted to vector embeddings using ONNX, Gemini, Ollama, or OpenAI.

3. Store

Vectors are stored in SQLite with sqlite-vec for fast similarity search.

4. Search

Natural language queries are embedded and compared via cosine similarity.

5. Watch

A file watcher auto-syncs the index when files change (debounced, gitignore-aware).

Powerful Features

4 Search Modes

Dense, Sparse (BM25), Hybrid (RRF fusion), and Hybrid+Rerank with ONNX cross-encoder for 116% better MRR.

6+ MCP Tools

vec_search, vec_outline, vec_find_callers, vec_find_dependents, vec_trace_imports, vec_read_lines, and more.

Path-Boundary Security

Enforces path-boundary checks across MCP handlers, CLI commands, and the indexer to prevent file access outside workspace.

14 Languages Supported

All 14 languages are chunked via tree-sitter. Rust, TypeScript/JavaScript, and Python also emit graph edges for structural analysis.

TypeScript

.ts

Graph

TSX

.tsx

Graph

JavaScript

.js

Graph

JSX

.jsx

Graph

Python

.py

Graph

Rust

.rs

Graph

Go

.go

Java

.java

C#

.cs

C

.c

C++

.cpp

Ruby

.rb

Swift

.swift

Kotlin

.kt

Proven Performance

1.80x

Step Efficiency Ratio

Traditional tools required 80% more steps to solve the same tasks

1.29x

Token Efficiency Ratio

Saves 29% in context token consumption vs full file reads

116%

MRR Improvement

Hybrid+Rerank mode boosts ranking quality over standard hybrid

Based on formal evaluation across 3 phases: Retrieval, End-to-End Agent, and Context Efficiency

Seamless AI Agent Integration

Auto-detects your AI coding agents and adds VectorCode to their MCP configuration with a single command.

vectorcode install
OpenCode Claude Code Cursor Gemini CLI Antigravity