Globally distributed, multi-active graph database for the AI Agent era
AgentiX GraphVec is a next-generation graph database built from the ground up for AI Agent workloads. It combines Cypher-compatible graph querying, built-in graph algorithms (PageRank, Louvain, BFS/DFS, Shortest Path), GNN (Graph Neural Network) vector embeddings, Raft-based distributed consensus, and multi-leader active-active replication β all in a single, self-contained system.
With 5,000+ tests covering correctness, fault tolerance, and performance, GraphVec is engineered for production-grade reliability.
| Area | Capabilities |
|---|---|
| π Graph Model | Labeled Property Graph (LPG), typed nodes & edges, temporal validity, TTL, MVCC |
| π§ Graph Algorithms | PageRank, Louvain community detection, BFS/DFS, Shortest Path, Triangle Count, Clustering Coefficient, Betweenness Centrality |
| π Vector & GNN | Dense & sparse vector embeddings, inner-product/cosine search, GNN inference, node2vec-style embedding generation |
| ποΈ Cypher Compatibility | SQL-style graph queries via GraphEngine API β pattern matching, filtering, aggregation |
| π Distributed | Multi-leader active-active replication across datacenters, sharding with scatter-gather routing, edge-affinity optimization |
| βοΈ Raft Consensus | Production-grade Raft implementation with log replication, leader election, snapshot install, quorum-based writes |
| π Security | RBAC (Role-Based Access Control), TLS encryption, audit logging, query-level authentication |
| π Event Bus | High-throughput cross-node event streaming with worker pool parallelism and outbox pattern |
| π§ Operations | Built-in metrics, health checks, backup/restore, WAL-based durability, query slow-log |
| π¦ Materialized Views | Pre-computed graph projections for sub-millisecond query responses |
| π Resharding | Zero-downtime rebalancing with auto-splitter β no cluster restart required |
npm install agentix-graphvecPrerequisites: Node.js >= 16.0.0 (tested on 18.x, 20.x, 22.x)
import { GraphEngine } from 'agentix-graphvec'
async function main() {
// 1. Create engine and open
const engine = new GraphEngine({ path: '/tmp/my-graph' })
await engine.open()
// 2. Upsert nodes (returns nodeId)
const aliceId = await engine.upsertNode(1, 'alice', { props: { name: 'Alice', age: 30 } })
const bobId = await engine.upsertNode(1, 'bob', { props: { name: 'Bob', age: 25 } })
// 3. Create edge
await engine.upsertEdge(aliceId, bobId, 1, { props: { weight: 1.0 } })
// 4. Query neighbors
const neighborIds = engine.neighbors(aliceId)
for (const nid of neighborIds ?? []) {
const node = engine.getNode(nid)
console.log('Neighbor:', node)
}
// 5. Scan all nodes
const allNodes = engine.scanAllNodes()
console.log('Total nodes:', allNodes.length)
// 6. Clean up
engine.close()
}
main()# Start a 3-node cluster locally
npx agentix-graphvec dev --nodes=3
# In another terminal, query any node
curl http://localhost:4001/graph/neighbors?id=1| API | Description |
|---|---|
upsertNode(id, options) |
Insert or update a node with properties, vectors, TTL |
upsertEdge(from, to, options) |
Insert or update a typed, weighted edge |
getNeighbors(nodeId, depth) |
BFS/DFS traversal with depth control |
getNode(id) |
Retrieve node by ID with full metadata |
deleteNode(id) |
Remove node and all incident edges |
deleteEdge(from, to) |
Remove a specific edge |
query(customQuery) |
Run a CYPHER-like predicate query |
engine.pagerank(options) // PageRank centrality
engine.louvain(options) // Community detection
engine.bfs(startNode, callback) // Breadth-First Search
engine.dfs(startNode, callback) // Depth-First Search
engine.shortestPath(from, to) // Dijkstra / BFS shortest path
engine.triangleCount() // Triangle count per node
engine.clusteringCoefficient() // Local clustering coefficient
engine.betweennessCentrality() // Betweenness centrality| API | Description |
|---|---|
createConsensus(provider, config) |
Create Raft or standalone consensus |
StandaloneConsensus |
Single-node (no external deps) |
RaftLogicConsensus |
Multi-node Raft with leader election |
ShardManager |
Shard-aware graph operations |
HlcClock |
Hybrid Logical Clock for ordering |
import { Authenticator, RBAC, TLSConfig, AuditLogger } from 'agentix-graphvec'
const auth = new Authenticator({ provider: 'jwt' })
const rbac = new RBAC({ roles: ['admin', 'reader', 'writer'] })ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β Application / SDK β
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
β GraphEngine β
ββββββββββββ¬βββββββββββ¬βββββββββββ¬βββββββββββ¬ββββββββββββββ€
β Graph β Vector β Material β Event β Query β
β Store β Engine β View β Bus/WP β Engine β
ββββββββββββ΄βββββββββββ΄βββββββββββ΄βββββββββββ΄ββββββββββββββ€
β Shard Router β
ββββββββββββββββββββββββ¬βββββββββββββββββββββββββββββββββββ€
β Scatter-Gather β Edge Affinity Router β
ββββββββββββββββββββββββ΄βββββββββββββββββββββββββββββββββββ€
β Shard Manager β
ββββββββββββββββββββββββ¬βββββββββββββββββββββββββββββββββββ€
β Range Instance 0 β Range Instance 1 β ... β N β
ββββββββββββββββββββββββΌβββββββββββββββββββββββββββββββββββ€
β Raft β Raft β Standalone β
β Node0β Node1β(single-node fallback) β
ββββββββββββββββββββββββ΄βββββββββββββββββββββββββββββββββββ€
β Multi-Leader Replication (DC Sync) β
ββββββββββββββββββββββββ¬βββββββββββββββββββββββββββββββββββ€
β WAL/Segment β Outbox / PeerDB β
ββββββββββββββββββββββββ΄βββββββββββββββββββββββββββββββββββ€
β Security (Auth, RBAC, TLS, Audit Log) β
ββββββββββββββββββββββββ¬βββββββββββββββββββββββββββββββββββ€
β Ops (Metrics, Health, Backup, SlowLog) β
ββββββββββββββββββββββββ΄βββββββββββββββββββββββββββββββββββ
| Layer | Technology |
|---|---|
| Language | TypeScript (ES2022), Node.js 18+/20+/22+ |
| Testing | Vitest 4.1.7, 5,000+ tests, coverage via @vitest/coverage-v8 |
| Consensus | Custom Raft (log replication, leader election, snapshot install) |
| Serialization | Protocol Buffers-style binary encoding |
| WAL | Segment-based write-ahead log with streaming |
| Container | Docker (multi-stage build, see Dockerfile) |
| Dimension | AgentiX GraphVec | Neo4j |
|---|---|---|
| Deployment Model | Multi-leader active-active (all nodes write) | Single-leader (one writer, replicas read-only) |
| Multi-DC Replication | Native, conflict-free CRDT-based | Requires additional tooling (Neo4j Fabric) |
| Raft Consensus | Built-in, no external coordinator | Built-in (since 4.0), but single-leader |
| GNN / Vector | Dense + sparse vectors, GNN inference, node2vec | Requires GDS plugin + external vector DB |
| Graph Algorithms | Built-in: PageRank, Louvain, Shortest Path, etc. | Via GDS plugin (separate install) |
| Cypher Support | Compatible via GraphEngine query API |
Native Cypher |
| License | Apache 2.0 (open source, free) | Community Edition (GPL) / Enterprise (commercial) |
| Footprint | Lightweight, single npm package | JVM-based, memory-intensive |
| Embedding | Import as library β embed in Node.js apps | Runs as standalone server |
| Tests | 5,000+ unit/integration/fault/benchmark tests | Proprietary test suite |
Positioning: GraphVec is designed for AI Agent ecosystems where graph topology, vector embeddings, and distributed consensus must coexist in a lightweight embeddable library. If you need a standalone graph server with full Cypher coverage and an ecosystem of plugins, Neo4j is the right choice. If you need an embeddable, multi-active, vector-aware graph engine for Agent-native architectures, GraphVec is purpose-built for that.
We welcome contributions! Please see CONTRIBUTING.md for:
- Development environment setup
- How to run tests
- Coding standards
- PR workflow
Key points:
- Write tests for any new feature or bug fix
- Run
npm run lintbefore committing - All tests must pass:
npm run test:unit(fast) ornpm run test:all(full)
AgentiX GraphVec is licensed under the Apache License, Version 2.0. See LICENSE for details.
Copyright 2025 AgentiX
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.