Registry / database / vecdb-table

vecdb-table

JSON →
library0.4.9jsnpmunverified

vecdb-table is a lightweight vector database that stores embeddings and metadata directly in an HTML table structure, enabling in-browser similarity search without external services. Version 0.4.9 is the latest stable release, updated infrequently. It differentiates from other vector DBs by its zero-dependency, browser-first design using IndexedDB and HTML table representation for transparency and simplicity. Suitable for small-scale vector search in web apps, with support for cosine similarity and metadata filtering.

npm install vecdb-table
INSTALL
IMPORT
SIG · VECDB-TABLE
V
vecdb-table
databasejavascriptv0.4.9
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

VectorTable
import { VectorTable } from 'vecdb-table'
const VectorTable = require('vecdb-table')
Package is ESM-only; no CommonJS support.
createVectorTable
import { createVectorTable } from 'vecdb-table'
import { createTable } from 'vecdb-table'
Function name is createVectorTable, not createTable.

Creates a VectorTable, opens database, inserts a vector with metadata, and performs a similarity search.

import { VectorTable } from 'vecdb-table'; async function main() { const table = new VectorTable('my-vectors'); await table.open(); const id = await table.insert({ vector: [0.1, 0.2, 0.3], metadata: { label: 'test' } }); const results = await table.search({ vector: [0.1, 0.2, 0.3], k: 10 }); console.log(results); } main().catch(console.error);
Debug
Known issues
breakingIn version 0.4.0, the API changed from callback-based to async/await. Old code using callbacks will break.
fix
Wrap calls in async functions and use await.
affects: <0.4.0
deprecatedThe method `addVector` has been deprecated in favor of `insert` since v0.3.0.
fix
Replace `addVector(vector, metadata)` with `insert({ vector, metadata })`.
affects: >=0.3.0
gotchaWhen using in Node.js, the library falls back to an in-memory store because IndexedDB is not available. This may cause unexpected data loss on restart.
fix
Use in browser environments, or implement custom persistence in Node.js.
affects: >=0.0.1
Errors
Common errors & fixes
ReferenceError: VectorTable is not defined
Incorrect import or script type not set to module.
fix
Use ES module imports: <script type="module"> or import { VectorTable } from 'vecdb-table'.
TypeError: table.open is not a function
Older version of the library where open was synchronous or not yet added.
fix
Update to version >=0.4.0 and use await table.open().
Upgrade
Version history
0.4.9latest on npm
Audit
Dependencies

No dependency data recorded yet.

Agent activity
39 hits · last 30 days
node
34
Meta
2
OpenAI (training)
1
Resources
vecdb-table — npm install vecdb-table · libregistry