NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

Vector Database Watermarking

zhiwen ren, Wei Fan, Qiyi Yao, Jing Qiu, Weiming Zhang, Nenghai YuNeurIPS 2025

Introduction

Vector databases are the backbone of modern AI applications, particularly in Retrieval-Augmented Generation (RAG) and semantic search. Because they support complex machine learning tasks using Approximate Nearest Neighbor (ANN) queries, these databases are highly valuable digital assets—and increasingly vulnerable to theft and unauthorized replication. This paper introduces the first watermarking scheme specifically designed for vector databases. By cleverly hiding ownership data inside "transparent" vectors—data points naturally ignored during searches—the proposed method protects copyright without degrading query accuracy.

The Problem: Legacy Watermarking Fails on Vectors

If you build a massive, highly optimized vector database, proving ownership after a theft is a significant challenge. Traditionally, digital assets are protected using watermarking, which embeds hidden cryptographic signals into the data.

However, existing database watermarking techniques were designed for relational databases (SQL tables) or geographic coordinates. Applying these legacy methods to a vector database requires randomly modifying high-dimensional vectors. Because vector databases rely on ANN search—calculating geometric distances to find similarities—randomly tweaking vectors shifts their positions. This causes "missed queries" (failing to return the true nearest neighbor) and "false queries" (returning the wrong neighbor), severely degrading the database's usability and search quality.

The Solution: Transparent Vector Priority (TVP)

To address the accuracy degradation caused by random modifications, the authors propose a novel framework tailored for vector databases, culminating in the Transparent Vector Priority (TVP) technique.

The researchers first established a baseline Random Selection (RS) method, which involves generating unique identifiers, grouping vectors via cryptographic hashing, mapping them to binary values, and slightly modifying random vectors to embed a secret watermark bit.

To improve upon the RS baseline, the authors analyzed the mechanics of HNSW (Hierarchical Navigable Small World), the most popular graph-based index for vector databases. Instead of modifying vectors randomly, TVP specifically targets "transparent vectors." Because HNSW uses aggressive heuristic pruning to maintain fast search speeds, some vectors end up with very few edges, or even no edges at all. TVP calculates a "transparency score" ($ts$) for each vector based on its average edge length and edge count. Vectors with high transparency scores are prioritized for modification because altering them has almost zero impact on the database's search results.

Key Insights and Ideas

  • The "Sparsity Curse" is a Feature, Not a Bug: The aggressive pruning strategy of the HNSW algorithm naturally strands certain vectors. The authors realized these "stealth vectors" are practically invisible to the greedy search algorithm.
  • Zero-Impact Carriers: Because stealth/transparent vectors are almost never returned as nearest neighbors in a real-world query, their values can be altered to store watermark bits without users noticing a drop in search quality.
  • Predicting Query Frequency Without Querying: You do not need to run millions of test queries to determine which vectors are safe to modify. The authors demonstrated that a vector's structural properties in the graph strongly correlate with how often it will be queried.
Correlation between transparency score parameters.

Key Results

The researchers evaluated their method using standard benchmarks for ANN search, including the ANN_SIFT1M dataset, Deep1b, and arxiv-nomic-768-normalized. The TVP scheme demonstrated exceptional performance across several metrics:

  • Massive Error Reduction: Compared to state-of-the-art relational and tabular watermarking schemes (SCPW and TabularMark) as well as the RS baseline, the TVP scheme reduces the Average Missed Queries (AMQ) and Average False Queries (AFQ) by approximately 75%.
Comparison of AMQ and AFQ across watermarking schemes.
  • Negligible Impact on Recall: Embedding the watermark using TVP barely touches the database's actual retrieval accuracy. For example, the Recall@1 metric dropped by less than 0.2% (from 0.9933 to 0.9914) after the watermark was embedded.
  • High Robustness: The watermark survives "adaptive attacks." Even if an adversary knows the watermarking algorithm and attempts to delete or modify the transparent vectors to scrub the watermark, the system maintains a low Bit Error Rate (BER) and successfully extracts the copyright information.

Limitations and Future Work

The primary limitation of this work is its tight coupling with the HNSW index structure. The mathematical formula used to calculate the transparency score ($ts$) relies specifically on HNSW's graph edges.

While the authors demonstrate that the concept of prioritizing low-frequency vectors works for other index types (like LSH, NSG, and IVF), they acknowledge that there is currently no fast, concrete formula to calculate transparency scores for these alternative architectures. Future work will focus on extending the transparent vector priority concept with specific scoring methods for a wider variety of vector index structures.

Summary updated

BibTeX
@inproceedings{ren2025vector,
  author = {zhiwen ren and Wei Fan and Qiyi Yao and Jing Qiu and Weiming Zhang and Nenghai Yu},
  title = {{Vector Database Watermarking}},
  booktitle = {Advances in Neural Information Processing Systems},
  year = {2025},
  url = {https://openreview.net/forum?id=Dbjzqvmd7t},
}
Figure