ruvector 0.1.2 → 0.1.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
|
-
"startTime":
|
|
3
|
-
"sessionId": "session-
|
|
4
|
-
"lastActivity":
|
|
2
|
+
"startTime": 1763752189752,
|
|
3
|
+
"sessionId": "session-1763752189752",
|
|
4
|
+
"lastActivity": 1763752189752,
|
|
5
5
|
"sessionDuration": 0,
|
|
6
6
|
"totalTasks": 1,
|
|
7
7
|
"successfulTasks": 1,
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
[
|
|
2
2
|
{
|
|
3
|
-
"id": "cmd-hooks-
|
|
3
|
+
"id": "cmd-hooks-1763752189958",
|
|
4
4
|
"type": "hooks",
|
|
5
5
|
"success": true,
|
|
6
|
-
"duration":
|
|
7
|
-
"timestamp":
|
|
6
|
+
"duration": 12.741968000000043,
|
|
7
|
+
"timestamp": 1763752189971,
|
|
8
8
|
"metadata": {}
|
|
9
9
|
}
|
|
10
10
|
]
|
package/README.md
CHANGED
|
@@ -8,15 +8,63 @@
|
|
|
8
8
|
[](https://github.com/ruvnet/ruvector)
|
|
9
9
|
[](https://github.com/ruvnet/ruvector)
|
|
10
10
|
|
|
11
|
-
**
|
|
11
|
+
**The fastest vector database for Node.js—built in Rust, runs everywhere**
|
|
12
12
|
|
|
13
|
-
|
|
13
|
+
Ruvector is a next-generation vector database that brings **enterprise-grade semantic search** to Node.js applications. Unlike cloud-only solutions or Python-first databases, Ruvector is designed specifically for JavaScript/TypeScript developers who need **blazing-fast vector similarity search** without the complexity of external services.
|
|
14
|
+
|
|
15
|
+
> 🚀 **Sub-millisecond queries** • 🎯 **52,000+ inserts/sec** • 💾 **~50 bytes per vector** • 🌍 **Runs anywhere**
|
|
16
|
+
|
|
17
|
+
Built by [rUv](https://ruv.io) with production-grade Rust performance and intelligent platform detection—**automatically uses native bindings when available, falls back to WebAssembly when needed**.
|
|
14
18
|
|
|
15
19
|
🌐 **[Visit ruv.io](https://ruv.io)** | 📦 **[GitHub](https://github.com/ruvnet/ruvector)** | 📚 **[Documentation](https://github.com/ruvnet/ruvector/tree/main/docs)**
|
|
16
20
|
|
|
21
|
+
---
|
|
22
|
+
|
|
17
23
|
## 🌟 Why Ruvector?
|
|
18
24
|
|
|
19
|
-
|
|
25
|
+
### The Problem with Existing Vector Databases
|
|
26
|
+
|
|
27
|
+
Most vector databases force you to choose between three painful trade-offs:
|
|
28
|
+
|
|
29
|
+
1. **Cloud-Only Services** (Pinecone, Weaviate Cloud) - Expensive, vendor lock-in, latency issues, API rate limits
|
|
30
|
+
2. **Python-First Solutions** (ChromaDB, Faiss) - Poor Node.js support, require separate Python processes
|
|
31
|
+
3. **Self-Hosted Complexity** (Milvus, Qdrant) - Heavy infrastructure, Docker orchestration, operational overhead
|
|
32
|
+
|
|
33
|
+
**Ruvector eliminates these trade-offs.**
|
|
34
|
+
|
|
35
|
+
### The Ruvector Advantage
|
|
36
|
+
|
|
37
|
+
Ruvector is purpose-built for **modern JavaScript/TypeScript applications** that need vector search:
|
|
38
|
+
|
|
39
|
+
🎯 **Native Node.js Integration**
|
|
40
|
+
- Drop-in npm package—no Docker, no Python, no external services
|
|
41
|
+
- Full TypeScript support with complete type definitions
|
|
42
|
+
- Automatic platform detection with native Rust bindings
|
|
43
|
+
- Seamless WebAssembly fallback for universal compatibility
|
|
44
|
+
|
|
45
|
+
⚡ **Production-Grade Performance**
|
|
46
|
+
- **52,000+ inserts/second** with native Rust (10x faster than Python alternatives)
|
|
47
|
+
- **<0.5ms query latency** with HNSW indexing and SIMD optimizations
|
|
48
|
+
- **~50 bytes per vector** with advanced memory optimization
|
|
49
|
+
- Scales from edge devices to millions of vectors
|
|
50
|
+
|
|
51
|
+
🧠 **Built for AI Applications**
|
|
52
|
+
- Optimized for LLM embeddings (OpenAI, Cohere, Hugging Face)
|
|
53
|
+
- Perfect for RAG (Retrieval-Augmented Generation) systems
|
|
54
|
+
- Agent memory and semantic caching
|
|
55
|
+
- Real-time recommendation engines
|
|
56
|
+
|
|
57
|
+
🌍 **Universal Deployment**
|
|
58
|
+
- **Linux, macOS, Windows** with native performance
|
|
59
|
+
- **Browser support** via WebAssembly (experimental)
|
|
60
|
+
- **Edge computing** and serverless environments
|
|
61
|
+
- **Alpine Linux** and non-glibc systems supported
|
|
62
|
+
|
|
63
|
+
💰 **Zero Operational Costs**
|
|
64
|
+
- No cloud API fees or usage limits
|
|
65
|
+
- No infrastructure to manage
|
|
66
|
+
- No separate database servers
|
|
67
|
+
- Open source MIT license
|
|
20
68
|
|
|
21
69
|
### Key Advantages
|
|
22
70
|
|
|
@@ -232,6 +280,105 @@ Tested on AMD Ryzen 9 5950X, 128-dimensional vectors:
|
|
|
232
280
|
|
|
233
281
|
*Benchmarks measured with 100K vectors, 128 dimensions, k=10*
|
|
234
282
|
|
|
283
|
+
## 🔍 Comparison with Other Vector Databases
|
|
284
|
+
|
|
285
|
+
Comprehensive comparison of Ruvector against popular vector database solutions:
|
|
286
|
+
|
|
287
|
+
| Feature | Ruvector | Pinecone | Qdrant | Weaviate | Milvus | ChromaDB | Faiss |
|
|
288
|
+
|---------|----------|----------|--------|----------|--------|----------|-------|
|
|
289
|
+
| **Deployment** |
|
|
290
|
+
| Installation | `npm install` ✅ | Cloud API ☁️ | Docker 🐳 | Docker 🐳 | Docker/K8s 🐳 | `pip install` 🐍 | `pip install` 🐍 |
|
|
291
|
+
| Node.js Native | ✅ First-class | ❌ API only | ⚠️ HTTP API | ⚠️ HTTP API | ⚠️ HTTP API | ❌ Python | ❌ Python |
|
|
292
|
+
| Setup Time | < 1 minute | 5-10 minutes | 10-30 minutes | 15-30 minutes | 30-60 minutes | 5 minutes | 5 minutes |
|
|
293
|
+
| Infrastructure | None required | Managed cloud | Self-hosted | Self-hosted | Self-hosted | Embedded | Embedded |
|
|
294
|
+
| **Performance** |
|
|
295
|
+
| Query Latency (p50) | **<0.5ms** | ~2-5ms | ~1-2ms | ~2-3ms | ~3-5ms | ~50ms | ~1ms |
|
|
296
|
+
| Insert Throughput | **52,341 ops/sec** | ~10,000 ops/sec | ~20,000 ops/sec | ~15,000 ops/sec | ~25,000 ops/sec | ~1,000 ops/sec | ~40,000 ops/sec |
|
|
297
|
+
| Memory per Vector (128d) | **50 bytes** | ~80 bytes | 62 bytes | ~100 bytes | ~70 bytes | 150 bytes | 68 bytes |
|
|
298
|
+
| Recall @ k=10 | 95%+ | 93% | 94% | 92% | 96% | 85% | 97% |
|
|
299
|
+
| **Platform Support** |
|
|
300
|
+
| Linux | ✅ Native | ☁️ API | ✅ Docker | ✅ Docker | ✅ Docker | ✅ Python | ✅ Python |
|
|
301
|
+
| macOS | ✅ Native | ☁️ API | ✅ Docker | ✅ Docker | ✅ Docker | ✅ Python | ✅ Python |
|
|
302
|
+
| Windows | ✅ Native | ☁️ API | ✅ Docker | ✅ Docker | ⚠️ WSL2 | ✅ Python | ✅ Python |
|
|
303
|
+
| Browser/WASM | ✅ Yes | ❌ No | ❌ No | ❌ No | ❌ No | ❌ No | ❌ No |
|
|
304
|
+
| ARM64 | ✅ Native | ☁️ API | ✅ Yes | ✅ Yes | ⚠️ Limited | ✅ Yes | ✅ Yes |
|
|
305
|
+
| Alpine Linux | ✅ WASM | ☁️ API | ⚠️ Build from source | ⚠️ Build from source | ❌ No | ✅ Yes | ✅ Yes |
|
|
306
|
+
| **Features** |
|
|
307
|
+
| Distance Metrics | Cosine, L2, Dot | Cosine, L2, Dot | 11 metrics | 10 metrics | 8 metrics | L2, Cosine, IP | L2, IP, Cosine |
|
|
308
|
+
| Filtering | ✅ Metadata | ✅ Advanced | ✅ Advanced | ✅ Advanced | ✅ Advanced | ✅ Basic | ❌ Limited |
|
|
309
|
+
| Persistence | ✅ File-based | ☁️ Managed | ✅ Disk | ✅ Disk | ✅ Disk | ✅ DuckDB | ❌ Memory |
|
|
310
|
+
| Indexing | HNSW | Proprietary | HNSW | HNSW | IVF/HNSW | HNSW | IVF/HNSW |
|
|
311
|
+
| Quantization | ✅ PQ | ✅ Yes | ✅ Scalar | ✅ PQ | ✅ PQ/SQ | ❌ No | ✅ PQ |
|
|
312
|
+
| Batch Operations | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes |
|
|
313
|
+
| **Developer Experience** |
|
|
314
|
+
| TypeScript Types | ✅ Full | ✅ Generated | ⚠️ Community | ⚠️ Community | ⚠️ Community | ⚠️ Partial | ❌ No |
|
|
315
|
+
| Documentation | ✅ Excellent | ✅ Excellent | ✅ Good | ✅ Good | ✅ Good | ✅ Good | ⚠️ Technical |
|
|
316
|
+
| Examples | ✅ Many | ✅ Many | ✅ Good | ✅ Good | ✅ Many | ✅ Good | ⚠️ Limited |
|
|
317
|
+
| CLI Tools | ✅ Included | ⚠️ Limited | ✅ Yes | ✅ Yes | ✅ Yes | ⚠️ Basic | ❌ No |
|
|
318
|
+
| **Operations** |
|
|
319
|
+
| Monitoring | ✅ Metrics | ✅ Dashboard | ✅ Prometheus | ✅ Prometheus | ✅ Prometheus | ⚠️ Basic | ❌ No |
|
|
320
|
+
| Backups | ✅ File copy | ☁️ Automatic | ✅ Snapshots | ✅ Snapshots | ✅ Snapshots | ✅ File copy | ❌ Manual |
|
|
321
|
+
| High Availability | ⚠️ App-level | ✅ Built-in | ✅ Clustering | ✅ Clustering | ✅ Clustering | ❌ No | ❌ No |
|
|
322
|
+
| Auto-Scaling | ⚠️ App-level | ✅ Automatic | ⚠️ Manual | ⚠️ Manual | ⚠️ K8s HPA | ❌ No | ❌ No |
|
|
323
|
+
| **Cost** |
|
|
324
|
+
| Pricing Model | Free (MIT) | Pay-per-use | Free (Apache) | Free (BSD) | Free (Apache) | Free (Apache) | Free (MIT) |
|
|
325
|
+
| Monthly Cost (1M vectors) | **$0** | ~$70-200 | ~$20-50 (infra) | ~$30-60 (infra) | ~$50-100 (infra) | $0 | $0 |
|
|
326
|
+
| Monthly Cost (10M vectors) | **$0** | ~$500-1000 | ~$100-200 (infra) | ~$150-300 (infra) | ~$200-400 (infra) | $0 | $0 |
|
|
327
|
+
| API Rate Limits | None | Yes | None | None | None | None | None |
|
|
328
|
+
| **Use Cases** |
|
|
329
|
+
| RAG Systems | ✅ Excellent | ✅ Excellent | ✅ Excellent | ✅ Excellent | ✅ Excellent | ✅ Good | ⚠️ Limited |
|
|
330
|
+
| Serverless | ✅ Perfect | ✅ Good | ❌ No | ❌ No | ❌ No | ⚠️ Possible | ⚠️ Possible |
|
|
331
|
+
| Edge Computing | ✅ Excellent | ❌ No | ❌ No | ❌ No | ❌ No | ❌ No | ⚠️ Possible |
|
|
332
|
+
| Production Scale (100M+) | ⚠️ Single node | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Excellent | ⚠️ Limited | ⚠️ Manual |
|
|
333
|
+
| Embedded Apps | ✅ Excellent | ❌ No | ❌ No | ❌ No | ❌ No | ⚠️ Possible | ✅ Good |
|
|
334
|
+
|
|
335
|
+
### When to Choose Ruvector
|
|
336
|
+
|
|
337
|
+
✅ **Perfect for:**
|
|
338
|
+
- **Node.js/TypeScript applications** needing embedded vector search
|
|
339
|
+
- **Serverless and edge computing** where external services aren't practical
|
|
340
|
+
- **Rapid prototyping and development** with minimal setup time
|
|
341
|
+
- **RAG systems** with LangChain, LlamaIndex, or custom implementations
|
|
342
|
+
- **Cost-sensitive projects** that can't afford cloud API pricing
|
|
343
|
+
- **Offline-first applications** requiring local vector search
|
|
344
|
+
- **Browser-based AI** with WebAssembly fallback
|
|
345
|
+
- **Small to medium scale** (up to 10M vectors per instance)
|
|
346
|
+
|
|
347
|
+
⚠️ **Consider alternatives for:**
|
|
348
|
+
- **Massive scale (100M+ vectors)** - Consider Pinecone, Milvus, or Qdrant clusters
|
|
349
|
+
- **Multi-tenancy requirements** - Weaviate or Qdrant offer better isolation
|
|
350
|
+
- **Distributed systems** - Milvus provides better horizontal scaling
|
|
351
|
+
- **Zero-ops cloud solution** - Pinecone handles all infrastructure
|
|
352
|
+
|
|
353
|
+
### Why Choose Ruvector Over...
|
|
354
|
+
|
|
355
|
+
**vs Pinecone:**
|
|
356
|
+
- ✅ No API costs (save $1000s/month)
|
|
357
|
+
- ✅ No network latency (10x faster queries)
|
|
358
|
+
- ✅ No vendor lock-in
|
|
359
|
+
- ✅ Works offline and in restricted environments
|
|
360
|
+
- ❌ No managed multi-region clusters
|
|
361
|
+
|
|
362
|
+
**vs ChromaDB:**
|
|
363
|
+
- ✅ 50x faster queries (native Rust vs Python)
|
|
364
|
+
- ✅ True Node.js support (not HTTP API)
|
|
365
|
+
- ✅ Better TypeScript integration
|
|
366
|
+
- ✅ Lower memory usage
|
|
367
|
+
- ❌ Smaller ecosystem and community
|
|
368
|
+
|
|
369
|
+
**vs Qdrant:**
|
|
370
|
+
- ✅ Zero infrastructure setup
|
|
371
|
+
- ✅ Embedded in your app (no Docker)
|
|
372
|
+
- ✅ Better for serverless environments
|
|
373
|
+
- ✅ Native Node.js bindings
|
|
374
|
+
- ❌ No built-in clustering or HA
|
|
375
|
+
|
|
376
|
+
**vs Faiss:**
|
|
377
|
+
- ✅ Full Node.js support (Faiss is Python-only)
|
|
378
|
+
- ✅ Easier API and better developer experience
|
|
379
|
+
- ✅ Built-in persistence and metadata
|
|
380
|
+
- ⚠️ Slightly lower recall at same performance
|
|
381
|
+
|
|
235
382
|
## 🎯 Use Cases
|
|
236
383
|
|
|
237
384
|
### RAG Systems (Retrieval-Augmented Generation)
|