Skip to content

Releases: matte1782/edgevec

v0.9.0 — Sparse Vectors, Hybrid Search, FlatIndex, BinaryFlatIndex

27 Feb 01:20

Choose a tag to compare

What's New in v0.9.0

Sparse Vectors (RFC-007)

  • SparseVector — CSR format sparse vector storage with 6 enforced invariants
  • SparseStorage — Inverted index with insert, search, delete, batch operations
  • SparseSearcher — Dot product similarity search
  • WASM bindings: initSparseStorage(), insertSparse(), searchSparse()
  • Persistence format v2 with CRC32 checksum and backward compatibility

RRF Hybrid Search (RFC-007)

  • HybridSearcher — Combines dense (HNSW) + sparse retrieval
  • Reciprocal Rank Fusion (RRF) with configurable k parameter (default k=60)
  • Linear fusion with alpha weight parameter
  • Per-source rank/score tracking in HybridSearchResult
  • WASM binding: hybridSearch()

FlatIndex

  • FlatIndex — Brute-force exact nearest neighbor search (100% recall)
  • O(1) insert, O(n·d) search with 4 distance metrics (Cosine, DotProduct, L2, Hamming)
  • Soft delete with bitmap tracking + auto-compaction
  • Binary quantization (32x memory reduction)
  • Snapshot persistence with CRC32 checksum

BinaryFlatIndex (PR #7 by @marlon-costa-dc)

  • BinaryFlatIndex — Native binary vector storage with SIMD-accelerated Hamming distance
  • O(1) insert (~1μs), O(n) search with 32x memory reduction
  • HNSW binary methods: insert_binary(), search_binary(), search_binary_with_ef()
  • WASM integration with JsIndexType runtime selection

Safety & Quality (Hostile Reviewer Remediation)

All 30 findings from the hostile reviewer audit have been addressed:

Critical fixes:

  • Custom Deserialize for SparseVector enforcing all 6 invariants
  • FusionMethod::linear() returns Result instead of panicking (prevents WASM trap)
  • NaN/Infinity validation unconditional in ALL 4 WASM insert functions
  • get_binary_vector() returns Result instead of panicking

Test coverage:

  • 1018 library unit tests + 36 integration tests
  • 3 new fuzz targets (sparse_vector, sparse_storage, flat_index)
  • New integration test suites for FlatIndex and BinaryFlatIndex

Install

Rust:

[dependencies]
edgevec = "0.9.0"

npm:

npm install edgevec@0.9.0

Contributors

Full Changelog: v0.8.0...v0.9.0

v0.8.0: Consolidation + Developer Experience

08 Jan 12:18

Choose a tag to compare

v0.8.0: Consolidation + Developer Experience

This release focuses on developer experience improvements and technical debt reduction.

Highlights

Vue 3 Support

import { useEdgeVec, useSearch } from 'edgevec/vue';

const { db, isLoading } = useEdgeVec({ dimensions: 384 });
const { results, search } = useSearch(db);

Standalone Filter Functions

import { eq, gt, and, contains } from 'edgevec';

const filter = and(
  eq('category', 'electronics'),
  gt('price', 100)
);

Comprehensive Documentation

  • 25 filter examples with real-world use cases
  • Embedding integration guide (Ollama, Transformers.js, OpenAI, Cohere, HuggingFace)
  • EdgeVec vs pgvector comparison guide

What's Changed

Added

  • Vue 3 composables (useEdgeVec, useSearch)
  • Standalone filter function exports
  • Filter examples guide (25 examples)
  • Embedding integration guide (5 providers)
  • EdgeVec vs pgvector comparison
  • SIMD Euclidean distance consolidation

Fixed

  • WAL chunk_size edge case handling
  • Safety documentation placement
  • 65+ cast_possible_truncation warnings
  • Test/bench clippy warnings

Installation

Rust:

cargo add edgevec@0.8.0

npm:

npm install edgevec@0.8.0

Quality

  • 700 tests pass
  • Clippy clean
  • WASM builds verified
  • TypeScript compiles

HOSTILE_REVIEWER: APPROVED

v0.7.0: SIMD Acceleration + First Community Contribution

30 Dec 18:58

Choose a tag to compare

🚀 2x+ faster vector operations with WASM SIMD

🎉 First External Contribution!

This release includes our first community contribution from @jsonMartin:

  • WASM SIMD128 Hamming distance with 8.75x speedup
  • AVX2 native implementation
  • 10 comprehensive tests

Thank you for raising the bar! 🙌

Highlights

Performance Improvements

Metric v0.6.0 v0.7.0 Improvement
Dot Product (768D) ~500ns ~200ns 2.5x
L2 Distance (768D) ~600ns ~250ns 2.4x
Hamming Distance ~350ns ~40ns 8.75x
Search (10k, k=10) ~2ms ~1ms 2x

Bundle Size

Package Size Notes
WASM (gzip) 264 KB Optimized with wasm-opt -Oz
WASM (raw) 494 KB Under 500KB target

Browser Support

  • Chrome 91+ ✅
  • Firefox 89+ ✅
  • Safari 16.4+ (macOS) ✅
  • Edge 91+ ✅
  • iOS Safari (scalar fallback)

New Features

  • SIMD128 enabled by default for WASM
  • Interactive Filter Playground with live sandbox
  • Enhanced benchmark pages

Installation

```bash

Rust

cargo add edgevec

npm

npm install edgevec@0.7.0
```

Try It Live

Full Changelog

See CHANGELOG.md for complete details.


Contributors:

EdgeVec v0.6.0 — RFC-002 Complete

23 Dec 03:38

Choose a tag to compare

Pre-release

EdgeVec v0.6.0 - RFC-002 Complete

This release implements RFC-002: Metadata & Binary Quantization.

Highlights

  • 32x Memory Reduction - Binary Quantization compresses vectors from 3KB to 96 bytes
  • Metadata Filtering - Filter search by category, tags, and numeric ranges
  • Memory Monitoring - Track pressure levels and prevent OOM
  • Hybrid Search - Combine BQ speed with F32 accuracy via rescoring

New WASM Exports

Function Description
insertWithMetadata() Insert vectors with JSON metadata
searchFiltered() Search with filter expressions
searchBQ() Fast binary quantized search
searchBQRescored() BQ search with F32 rescoring
searchHybrid() Adaptive hybrid search
getMemoryPressure() Get current memory status

Performance

Metric v0.5.x v0.6.0 Improvement
Memory/vector (BQ) 3KB 96B 32x reduction
Search latency (BQ) - 2-5ms NEW
Recall@10 (BQ+rescore) - 0.936 NEW

Installation

# Rust
cargo add edgevec

# npm
npm install edgevec

Filter Syntax Examples

// Simple equality
searchFiltered(query, 10, { filter: "category = 'docs'" })

// Numeric comparison
searchFiltered(query, 10, { filter: "score > 0.8" })

// Compound expressions
searchFiltered(query, 10, { filter: "category = 'tech' AND year >= 2024" })

// Array membership
searchFiltered(query, 10, { filter: "tag IN ('rust', 'wasm')" })

Breaking Changes

None. v0.6.0 is backwards compatible with v0.5.x.

Links

v0.5.3 2025-12-19 crates.io Publishing

19 Dec 20:23

Choose a tag to compare

Pre-release

[0.5.3] - 2025-12-19 — crates.io Publishing Fix

Type: Release engineering fix

Fixed

  • crates.io 413 Payload Too Large — Package was 28.0 MiB (11.0 MiB compressed), exceeding crates.io's 10 MiB limit
    • Added exclude patterns to Cargo.toml to strip internal development files
    • Excluded: docs/, tests/, .claude/, .cursor/, .github/, benches/competitive/, scripts/
    • New size: 1.7 MiB (358 KiB compressed) — 96% reduction

Changed

  • Version sync: Cargo.toml and pkg/package.json both at 0.5.3
  • Previous versions: crates.io was stuck at v0.4.0, npm was at v0.5.2

Note

This release enables crates.io publishing that was blocked since v0.5.0.

v0.5.0 — Filter API Release

19 Dec 00:50

Choose a tag to compare

Pre-release

[0.5.1] - 2025-12-19 — README Update

Type: Documentation patch

Changed

  • Updated pkg/README.md with v0.5.0 Filter API content for npm display
  • Tagline: "The first WASM-native vector database"
  • Added Filter API Quick Start example with Filter.parse()
  • Updated version references from v0.4.0 to v0.5.0

Note

No code changes. This release ensures npm displays the correct v0.5.0 documentation.


[0.5.0] - 2025-12-19 — Filter API Release

Focus: Metadata filtering — The feature that transforms EdgeVec from a search library into a vector database.

Added

Filter API

  • SQL-like filter expressions — 15 operators for metadata filtering
    • Comparison: =, !=, >, <, >=, <=
    • Set: IN, NOT IN
    • String: CONTAINS, STARTS_WITH, ENDS_WITH
    • Null: IS NULL, IS NOT NULL
    • Boolean: AND, OR, NOT
  • Filter.parse() — Parse filter expressions with detailed error messages
  • Filter.evaluate() — Evaluate filters against metadata objects
  • FilterBuilder — TypeScript fluent API for type-safe filter construction
  • Strategy selection — Automatic prefilter/postfilter/hybrid selection

Interactive Demos

  • Filter Playground (wasm/examples/filter-playground.html)

    • Real-time filter parsing with syntax highlighting
    • AST visualization
    • Example expressions gallery
    • Dark/light theme toggle
    • Keyboard shortcuts (Ctrl+Enter, Ctrl+/)
  • Demo Catalog (wasm/examples/index.html)

    • Professional landing page with all demos
    • Mobile responsive design
    • Filter integration across all demos

Documentation

  • docs/api/FILTER_SYNTAX.md — Complete filter expression reference
  • docs/api/DATABASE_OPERATIONS.md — CRUD operations guide
  • docs/api/TYPESCRIPT_API.md — TypeScript API reference
  • docs/COMPARISON.md — EdgeVec vs alternatives guide
  • docs/design/ACCESSIBILITY_AUDIT.md — WCAG 2.1 AA compliance

Competitive Analysis

  • docs/benchmarks/competitive_analysis_v2.md — Full methodology
  • docs/benchmarks/w24_voy_comparison.md — EdgeVec vs voy (24x faster)
  • docs/benchmarks/w24_hnswlib_comparison.md — EdgeVec vs hnswlib-node
  • docs/benchmarks/w24_tier2_feature_matrix.md — Feature comparison

Changed

  • README.md — Repositioned as "vector database" with feature matrix
  • pkg/package.json — 16 keywords for npm discoverability
  • All demos — Added filter capabilities and mobile responsiveness

Fixed

  • UTF-8 panic — Filter parser now handles multi-byte UTF-8 correctly (f75a4c0)
  • XSS vulnerabilities — Added escapeHtml() to all demos (359cd7d, d60770c)

Security

  • All user input in demos escaped via escapeHtml()
  • Filter parser fuzz tested for 24+ hours (14.4B executions, 0 crashes)

Performance

Metric Result Target
Search P50 (10k) 0.20 ms <1 ms
Bundle (gzip) 262 KB <500 KB
Fuzz testing 24h+ 0 crashes

v0.4.0 - Documentation & Quality Sprint

16 Dec 03:02

Choose a tag to compare

Pre-release

[0.4.0] - 2025-12-20 — Documentation & Quality Sprint

Focus: Production readiness — comprehensive documentation, P99 tracking, and quality hardening.

Added

User Documentation

  • docs/TUTORIAL.md — Complete getting started guide

    • Step-by-step installation instructions
    • First index creation walkthrough
    • Browser and Node.js examples
    • Persistence tutorial
  • docs/PERFORMANCE_TUNING.md — HNSW parameter optimization guide

    • M, efConstruction, ef parameter explanations
    • Tuning recommendations for different use cases
    • Memory vs. recall tradeoff guidance
    • Quantization configuration
  • docs/TROUBLESHOOTING.md — Debugging guide

    • Top 10 common errors and solutions
    • WASM initialization issues
    • Dimension mismatch debugging
    • Search returning empty results
  • docs/INTEGRATION_GUIDE.md — Third-party integration guide

    • transformers.js integration
    • TensorFlow.js Universal Sentence Encoder
    • OpenAI embeddings API
    • Cohere embeddings

Benchmark Dashboard

  • wasm/examples/benchmark-dashboard.html — Interactive visualization

    • Real-time performance charts (Chart.js)
    • EdgeVec vs hnswlib-node vs voy comparison
    • Search latency, insert latency, memory charts
    • Dark/light theme toggle
  • docs/benchmarks/PERFORMANCE_BASELINES.md — Baseline documentation

    • Official baseline values for regression detection
    • Target metrics for different scales
    • CI threshold configuration

Quality Infrastructure

  • Chaos Testing (tests/chaos_hnsw.rs)

    • 15 edge case tests (11 required + 4 bonus)
    • Empty index, single vector, all deleted
    • Zero vector, max dimensions (4096)
    • Duplicate vectors, delete/reinsert
    • Extreme values, rapid cycles
    • Compaction stress, recall accuracy
  • Load Testing (tests/load_test.rs)

    • 100k vector insertion stress test
    • Sustained search load (60 seconds)
    • Mixed workload (insert + search + delete)
    • High tombstone ratio validation
    • Memory stability testing
    • Batch insert performance
  • P99 Latency Tracking (benches/p99_bench.rs)

    • P50/P99/P999 percentile reporting
    • 10k index latency benchmark
    • Tombstone impact benchmark
    • Scaling benchmark (1k to 25k)
  • CI Regression Detection (.github/workflows/regression.yml)

    • Automatic P99 benchmark on PRs
    • 10% regression threshold enforcement
    • Performance summary in PR comments
    • Artifact upload for historical tracking

Release Documentation

  • CONTRIBUTING.md — Contribution guidelines

    • Code of Conduct reference
    • PR process and requirements
    • Development setup instructions
    • Commit message conventions
  • docs/RELEASE_CHECKLIST_v0.4.md — Release verification

    • 25+ verification items
    • Pre-release, release, post-release steps
    • Rollback procedures
  • docs/MIGRATION.md — Migration from competitors

    • hnswlib migration guide
    • FAISS migration guide
    • Pinecone migration guide
    • General migration tips

Changed

  • Version bumped from 0.3.0 to 0.4.0
  • Updated README.md with v0.4.0 features
  • CI pipeline enhanced with P99 tracking

Documentation

  • Week 16-18 work reconciled with gate files
  • ROADMAP.md updated to reflect v0.4.0 completion
  • All pending gates (16, 17, 18) documented

v0.3.0: Soft Delete API (RFC-001)

15 Dec 15:00

Choose a tag to compare

Pre-release

[0.3.0] - 2025-12-15 — Soft Delete Release

Focus: RFC-001 Soft Delete implementation — non-destructive vector deletion with compaction.

Added

Soft Delete API (RFC-001)

  • soft_delete(VectorId) — Mark vector as deleted in O(1) time

    • Tombstone-based deletion (vector remains in index but excluded from search)
    • Idempotent: returns false if already deleted
    • Error on invalid vector ID
  • is_deleted(VectorId) — Check if vector is deleted

    • Returns true for tombstoned vectors
    • Error on invalid vector ID
  • deleted_count() — Count of tombstoned vectors

  • live_count() — Count of active (non-deleted) vectors

  • tombstone_ratio() — Ratio of deleted to total vectors (0.0 to 1.0)

Compaction API

  • compact() — Rebuild index removing all tombstones

    • Returns CompactionResult with statistics
    • Creates new index with only live vectors
    • Preserves vector IDs during rebuild
    • Warning: blocking operation for large indices
  • needs_compaction() — Check if tombstone ratio exceeds threshold

  • compaction_warning() — Get warning message if compaction recommended

  • compaction_threshold() — Get current threshold (default: 0.3 / 30%)

  • set_compaction_threshold(ratio) — Configure threshold (0.01 to 0.99)

  • CompactionResult struct:

    • tombstones_removed: u32 — Number of deleted vectors removed
    • new_size: u32 — Index size after compaction
    • duration_ms: f64 — Time taken in milliseconds

WASM Bindings (v0.3.0)

  • softDelete(vectorId) — JavaScript soft delete
  • isDeleted(vectorId) — Check deletion status
  • deletedCount() / liveCount() — Statistics methods
  • tombstoneRatio() — Get tombstone ratio
  • needsCompaction() — Check compaction recommendation
  • compactionWarning() — Get warning string or null
  • compact() — Execute compaction, returns WasmCompactionResult
  • compactionThreshold() / setCompactionThreshold() — Threshold management

Persistence Format v0.3

  • deleted_count field in snapshot header (offset 60-63)
  • deleted field per HnswNode (1 byte, was padding — zero memory overhead)
  • Automatic migration from v0.2 snapshots on load
  • VERSION_MINOR bumped from 2 to 3

Browser Examples

  • wasm/examples/soft_delete.html — Interactive cyberpunk-themed demo

    • Particle effects for visual feedback
    • Real-time statistics dashboard
    • Vector grid visualization (live vs deleted)
    • Warning banner for compaction recommendation
    • Activity log with color-coded entries
  • wasm/examples/soft_delete.js — Reusable JavaScript module

    • SoftDeleteDemo class with full API
    • Event system for insert/delete/compact/search
    • Benchmark functionality
    • Accessibility: focus indicators, ARIA labels, keyboard navigation

TypeScript Support

  • Updated pkg/edgevec.d.ts with soft delete types
  • WasmCompactionResult interface
  • Full JSDoc documentation

Changed

  • Search now automatically excludes tombstoned vectors
  • HnswNode.pad renamed to HnswNode.deleted (repurposed padding byte)
  • Internal adjusted_k() calculation compensates for tombstones during search
  • Snapshot version bumped to v0.3 (reads v0.2, writes v0.3)

Fixed

  • Memory leak prevention in browser demo particle system (MAX_PARTICLES cap)
  • Silent error swallowing replaced with proper logging

Migration Notes

From v0.2.x to v0.3.0:

  1. v0.2 snapshots are automatically migrated to v0.3 on load
  2. v0.3 snapshots cannot be read by v0.2.x (forward-incompatible)
  3. Always backup your index files before upgrading
  4. New soft delete methods are additive — existing code continues to work

Breaking Changes: None for existing API users.

v0.2.0-alpha.2

12 Dec 21:52

Choose a tag to compare

v0.2.0-alpha.2 Pre-release
Pre-release
Hotfix v0.2.0-alpha.2 - Include missing snippets directory

Fixed npm package that was missing the snippets/ directory containing
IndexedDB storage JS code. v0.2.0-alpha.1 is now deprecated.

Changes:
- Added snippets directory to package.json files array
- Package now imports correctly in Node.js

Install: npm install edgevec@0.2.0-alpha.2

v0.2.0-alpha.1 — Initial Alpha Release

12 Dec 21:31

Choose a tag to compare

EdgeVec v0.2.0-alpha.1

High-performance vector search for Browser, Node, and Edge.

Highlights

  • Sub-millisecond search at 100k vectors (329µs quantized, 572µs float32)
  • 3.6x memory reduction with Scalar Quantization (SQ8)
  • 148 KB bundle (70% under 500KB target)
  • WASM-native with IndexedDB persistence
  • Zero network latency — runs 100% locally

Performance (768d vectors, k=10)

Scale Float32 Quantized (SQ8)
10k 203 µs 88 µs
50k 480 µs 167 µs
100k 572 µs 329 µs

Quick Start

import init, { EdgeVec } from 'edgevec';

await init();
const index = new EdgeVec({ dimensions: 768 });
index.insert(new Float32Array(768).fill(0.1));
const results = index.search(new Float32Array(768).fill(0.1), 10);

Install

npm install edgevec

Known Limitations

This is an alpha release. See docs/KNOWN_LIMITATIONS.md for details.

Key limitations:
- Build time not optimized (batch insert API planned for v0.3.0)
- No delete/update operations (planned for v0.3.0)
- Single-threaded WASM execution

Links

- README.md
- CHANGELOG.md
- docs/KNOWN_LIMITATIONS.md

---
Full Changelog: See CHANGELOG.md

5. **Pre-release checkbox:**  Check **"Set as a pre-release"**

6. Click **"Publish release"**