{"id":48355094,"url":"https://github.com/thinkgrid-labs/taladb","last_synced_at":"2026-04-19T15:10:33.745Z","repository":{"id":346705618,"uuid":"1191218955","full_name":"thinkgrid-labs/taladb","owner":"thinkgrid-labs","description":"The embedded database for local-first JavaScript apps.","archived":false,"fork":false,"pushed_at":"2026-04-19T09:56:40.000Z","size":18194,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-04-19T11:31:50.444Z","etag":null,"topics":["ai","database","local-first","mobile","offline","rag","react","react-native","sematic-search","vector-database","wasm","web"],"latest_commit_sha":null,"homepage":"https://taladb.dev","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/thinkgrid-labs.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":"docs/roadmap.md","authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null},"funding":{"github":["thinkgrid-labs"]}},"created_at":"2026-03-25T03:03:48.000Z","updated_at":"2026-04-19T09:53:29.000Z","dependencies_parsed_at":null,"dependency_job_id":"3bea2ce2-3cdc-4e1e-8e7a-1dcb3e99bce7","html_url":"https://github.com/thinkgrid-labs/taladb","commit_stats":null,"previous_names":["thinkgrid-labs/taladb"],"tags_count":27,"template":false,"template_full_name":null,"purl":"pkg:github/thinkgrid-labs/taladb","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thinkgrid-labs%2Ftaladb","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thinkgrid-labs%2Ftaladb/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thinkgrid-labs%2Ftaladb/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thinkgrid-labs%2Ftaladb/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/thinkgrid-labs","download_url":"https://codeload.github.com/thinkgrid-labs/taladb/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thinkgrid-labs%2Ftaladb/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32011050,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-18T20:23:30.271Z","status":"online","status_checked_at":"2026-04-19T02:00:07.110Z","response_time":55,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["ai","database","local-first","mobile","offline","rag","react","react-native","sematic-search","vector-database","wasm","web"],"created_at":"2026-04-05T11:00:46.564Z","updated_at":"2026-04-19T15:10:33.736Z","avatar_url":"https://github.com/thinkgrid-labs.png","language":"Rust","funding_links":["https://github.com/sponsors/thinkgrid-labs"],"categories":[],"sub_categories":[],"readme":"\u003cdiv align=\"center\"\u003e\n\n\u003cimg src=\".github/assets/tala-db-banner.png\" alt=\"TalaDB\" width=\"800\" /\u003e\n\n**The embedded database for local-first JavaScript apps.**\u003cbr/\u003e\nDocuments + vector search built in Rust — browser, Node.js, and React Native. No cloud. No compromise.\n\n[![Status: Stable](https://img.shields.io/badge/Status-Stable-green)](https://github.com/thinkgrid-labs/taladb)\n[![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](LICENSE)\n[![Rust](https://img.shields.io/badge/Rust-2021_Edition-orange?logo=rust)](https://www.rust-lang.org)\n[![WASM](https://img.shields.io/badge/WASM-wasm--bindgen-purple?logo=webassembly)](https://rustwasm.github.io/wasm-bindgen/)\n[![Platform](https://img.shields.io/badge/Platform-Browser%20%7C%20React%20Native%20%7C%20Node.js-green)](https://github.com/thinkgrid-labs/taladb)\n[![Sponsor](https://img.shields.io/badge/Sponsor-thinkgrid--labs-red?logo=github-sponsors)](https://github.com/sponsors/thinkgrid-labs)\n\n**[Documentation](https://taladb.dev) · [Live Demo](https://taladb-playground.vercel.app/) · [Web Guide](https://taladb.dev/guide/web) · [Node.js Guide](https://taladb.dev/guide/node) · [React Native Guide](https://taladb.dev/guide/react-native)**\n\n\u003c/div\u003e\n\n\n---\n\nTalaDB is an open-source, **embedded database for local-first JavaScript apps** built in Rust. It gives web and React Native developers a MongoDB-like query API alongside on-device vector similarity search — store documents, search embeddings, and combine both in a single query, all running entirely on the user's device with no server, no network, and no cloud subscription.\n\nThe same Rust core powers all three runtimes:\n\n| Runtime | Package | Mechanism |\n|---|---|---|\n| Browser | `@taladb/web` | `wasm-bindgen` + OPFS via SharedWorker |\n| Node.js | `@taladb/node` | `napi-rs` native module |\n| React Native | `@taladb/react-native` | JSI HostObject (C FFI via `cbindgen`) |\n\nApplication code uses the unified `taladb` package with a single TypeScript API on every platform.\n\n## Highlights\n\n- **Vector search** — on-device similarity search (cosine, dot, euclidean) with optional metadata pre-filter; pairs naturally with on-device AI models (transformers.js, ONNX Web)\n- **Hybrid queries** — combine a regular document filter with vector ranking in one call: find the 5 most semantically similar *english-language support articles* without two round-trips\n- **MongoDB-like API** — familiar filter and update DSL, fully typed with TypeScript generics\n- **Secondary indexes** — type-safe B-tree indexes with automatic index selection and O(log n) range scans\n- **ACID transactions** — powered by [redb](https://github.com/cberner/redb), a pure-Rust B-tree storage engine\n- **Full-text search** — inverted token index with `$contains` filter\n- **Live queries** — subscribe to a filter and receive snapshots after every write, no polling\n- **Encryption at rest** — transparent AES-GCM-256 via `EncryptedBackend`, keys derived with PBKDF2-HMAC-SHA256\n- **Schema migrations** — versioned, atomic, run at open time\n- **Snapshot export / import** — portable binary format for backup and cross-device sync\n- **CLI dev tools** — `taladb inspect`, `export`, `import`, `count`, `drop`\n\n## Usage\n\n### Install\n\n```bash\n# Browser\npnpm add taladb @taladb/web\n\n# Node.js\npnpm add taladb @taladb/node\n\n# React Native\npnpm add taladb @taladb/react-native\n```\n\n### Open a database\n\n```ts\nimport { openDB } from 'taladb'\n\nconst db = await openDB('myapp.db')  // OPFS in browser, file on Node.js / React Native\n```\n\n---\n\n### As a document database\n\n```ts\ninterface Article {\n  _id?: string\n  title: string\n  category: string\n  locale: string\n  publishedAt: number\n}\n\nconst articles = db.collection\u003cArticle\u003e('articles')\n\n// Insert\nconst id = await articles.insert({\n  title: 'How to reset your password',\n  category: 'support',\n  locale: 'en',\n  publishedAt: Date.now(),\n})\n\n// Query with filters\nconst results = await articles.find({\n  category: 'support',\n  locale: 'en',\n  publishedAt: { $gte: Date.now() - 86_400_000 },\n})\n\n// Update\nawait articles.updateOne({ _id: id }, { $set: { title: 'Reset your password' } })\n\n// Delete\nawait articles.deleteOne({ _id: id })\n\n// Secondary index for fast lookups\nawait articles.createIndex('category')\nawait articles.createIndex('publishedAt')\n```\n\n---\n\n### As a vector database\n\n```ts\nimport { pipeline } from '@xenova/transformers'\n\n// Any on-device embedding model works\nconst embedder = await pipeline('feature-extraction', 'Xenova/all-MiniLM-L6-v2')\nconst embed = async (text: string) =\u003e {\n  const out = await embedder(text, { pooling: 'mean', normalize: true })\n  return Array.from(out.data) as number[]\n}\n\n// 1. Create the vector index once (backfills existing documents automatically)\nawait articles.createVectorIndex('embedding', { dimensions: 384 })\n\n// 2. Insert documents with their embeddings\nawait articles.insert({\n  title: 'How to reset your password',\n  category: 'support',\n  locale: 'en',\n  publishedAt: Date.now(),\n  embedding: await embed('How to reset your password'),\n})\n\n// 3. Semantic search — find the 5 most similar articles\nconst query = await embed('forgot my login credentials')\nconst results = await articles.findNearest('embedding', query, 5)\n\nresults.forEach(({ document, score }) =\u003e {\n  console.log(score.toFixed(3), document.title)\n})\n// 0.941  How to reset your password\n// 0.887  Account recovery options\n// 0.823  Two-factor authentication setup\n```\n\n---\n\n### Hybrid search — the killer feature\n\nFilter by metadata first, then rank by vector similarity. One call, no extra round-trips.\n\n```ts\n// \"Find the 5 most relevant english support articles for this query\"\nconst results = await articles.findNearest('embedding', query, 5, {\n  category: 'support',\n  locale: 'en',\n})\n\n// Works across all runtimes — browser, React Native, Node.js\n// Data never leaves the device\n```\n\n---\n\n### Live queries\n\n```ts\n// Subscribe to changes — callback fires after every matching write\nconst unsub = articles.subscribe({ category: 'support' }, (docs) =\u003e {\n  console.log('support articles updated:', docs.length)\n})\n\n// Stop listening\nunsub()\n```\n\n## Documentation\n\nFull documentation is at **[taladb.dev](https://taladb.dev)**.\n\n| Section | Link |\n|---|---|\n| Introduction \u0026 architecture | [/introduction](https://taladb.dev/introduction) |\n| Core concepts | [/concepts](https://taladb.dev/concepts) |\n| Feature overview | [/features](https://taladb.dev/features) |\n| Web (Browser / WASM) guide | [/guide/web](https://taladb.dev/guide/web) |\n| Node.js guide | [/guide/node](https://taladb.dev/guide/node) |\n| React Native guide | [/guide/react-native](https://taladb.dev/guide/react-native) |\n| Collection API | [/api/collection](https://taladb.dev/api/collection) |\n| Filters | [/api/filters](https://taladb.dev/api/filters) |\n| Updates | [/api/updates](https://taladb.dev/api/updates) |\n| Migrations | [/api/migrations](https://taladb.dev/api/migrations) |\n| Encryption | [/api/encryption](https://taladb.dev/api/encryption) |\n| Live queries | [/api/live-queries](https://taladb.dev/api/live-queries) |\n\n## Development\n\n### Prerequisites\n\n- [Rust](https://rustup.rs/) stable 1.75+\n- [wasm-pack](https://rustwasm.github.io/wasm-pack/) — for browser builds\n- [Node.js](https://nodejs.org/) 18+ and [pnpm](https://pnpm.io/) 9+\n- `@napi-rs/cli` — for Node.js native module builds\n\n### Running tests\n\n```bash\n# Rust unit + integration tests\ncargo test --workspace\n\n# TypeScript tests\npnpm --filter taladb test\n\n# Browser WASM tests (requires Chrome)\nwasm-pack test packages/@taladb/web --headless --chrome\n```\n\n### Building\n\n```bash\n# Browser WASM\npnpm --filter @taladb/web build\n\n# Node.js native module\npnpm --filter @taladb/node build\n\n# TypeScript package\npnpm --filter taladb build\n\n# All packages\npnpm build\n```\n\n### Local docs\n\n```bash\npnpm docs:dev     # dev server at http://localhost:5173\npnpm docs:build   # production build\npnpm docs:preview # preview production build\n```\n\n## Contributing\n\nTalaDB is built by and for the community. Whether you're fixing a bug, adding a new query operator, or improving documentation, your help is welcome!\n\n1. Fork the repo and create a branch: `git checkout -b feat/my-feature`\n2. Make your changes and add tests\n3. Run `cargo test --workspace` and `pnpm --filter taladb test`\n4. Open a pull request with a clear description\n\nPlease open an issue first for large features or architectural changes. See [CONTRIBUTING.md](CONTRIBUTING.md) for the full development workflow.\n\n\n| Name | Contact |\n|---|---|\n| Dennis P | [dennis@thinkgrid.dev](mailto:dennis@thinkgrid.dev) |\n\n## License\n\nMIT © [thinkgrid-labs](https://github.com/thinkgrid-labs)\n\n## Sponsors\n\nIf you find TalaDB useful, please consider [sponsoring the project](https://github.com/sponsors/thinkgrid-labs). Your support helps me maintain the project and develop new features.\n\n\n---\n\n\u003cdiv align=\"center\"\u003e\n\nBuilt with Rust · Documents and vectors, on device · [taladb.dev](https://taladb.dev)\n\n\u003c/div\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthinkgrid-labs%2Ftaladb","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fthinkgrid-labs%2Ftaladb","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthinkgrid-labs%2Ftaladb/lists"}