TI

titusai-io/kimmydb

开发工具

本页由 AI 翻译,技术细节请以原文为准。 查看原文

0 stars 0 forks 质量 67 趋势 20AGPL-3.0

一个无领导的JSON文档数据库,支持变更流、矢量搜索和内置MCP服务器

概览

一个用Rust构建的JSON文档数据库,围绕三个通常难以整合的东西构建: - 无副本集,无集群,无仪式。启动一个容器并订阅变更。- 无主容器,无选举,无法定人数。节点通过SWIM和反熵进行八卦状态——每轮联系少数节点,拉取缺失的oplog条目,数据传递至整个集群。发现方式为DNS或Kubernetes无头服务。- 嵌入按集合自动生成和维护,数据库内运行MCP服务器,方便代理直接查询。 📚 ——架构、内部结构、API引用、操作和决策记录。 多用户文档 CRUD、Mongo 风格查询与聚合、二级索引、WebSocket 上的实时变更流、签名的 webhook、带向量和混合搜索的自动嵌入、/mcp 的进程中 MCP 服务器、OIDC 联合以及版本化的 /v1 合同,这些都可正常工作。

概述(AI 翻译)

一个用Rust构建的JSON文档数据库,围绕三个通常的要素构建 尴尬的聚会:

  • 在单一实例上更改流。 没有副本集,没有集群,没有 仪式。启动一个容器并订阅变更。
  • 无领导集群。 没有初选,没有选举,没有法定人数。节点八卦 SWIM和gossip通过反熵定性——各自接触了几个人 每轮对等节点,拉取缺失的oplog条目,数据到达 整个集群的传递性。发现是DNS或Kubernetes无头服务。
  • AI原生存储。 嵌入自动生成和维护 每个集合,并且MCP服务器运行在数据库内部,以便代理能够 直接查询。

📚 完整文档见docs/ — 架构、内部结构, API 引用、操作和决策记录。

状态:早期开发,已发布。 多用户文档 CRUD,Mongo 风格 查询和聚合、二级索引、实时变更流 WebSocket、签名的 webhook、自动嵌入向量和混合 搜索、在/mcp的进程中MCP服务器、OIDC联合,以及 版本化的/v1合同所有工作。

本页由 AI 翻译,技术细节请以原文为准。

README

以下为原文 README 节选,完整内容请查看原文。

KimmyDB

A JSON document database in Rust, built around three things that are usually awkward to get together:

  • Change streams on a single instance. No replica set, no cluster, no ceremony. Start one container and subscribe to changes.
  • Leaderless clustering. No primary, no elections, no quorum. Nodes gossip membership over SWIM and gossip state by anti-entropy — each contacts a few peers per round, pulls the oplog entries it is missing, and data reaches the whole cluster transitively. Discovery is DNS or a Kubernetes headless Service.
  • AI-native storage. Embeddings are generated and maintained automatically per collection, and an MCP server runs inside the database so agents can query it directly.

📚 Full documentation is in docs/ — architecture, internals, API reference, operations, and the decision record.

Status: early development, released. Multi-user document CRUD, Mongo-style queries and aggregation, secondary indexes, live change streams over WebSocket, signed webhooks, automatic embeddings with vector and hybrid search, an in-process MCP server at /mcp, OIDC federation, and a versioned /v1 contract all work. Clustering works too — every node accepts writes, membership is SWIM and convergence is anti-entropy over the oplog; docker-compose.yml brings up three nodes. Pre-1.0: a minor release may break things and the changelog says so. See Roadmap.

Why it is built this way

The oplog is the spine. Every mutation appends one durable, HLC-ordered entry, and three subsystems consume that same log:

  1. Change streams — WebSocket subscribers, resumable by token.
  2. The embedding pipeline — an internal subscriber, which is why auto-embeddings need no separate scheduler.
  3. Cluster anti-entropy — peers pull ranges they are missing.

Building the log once and reusing it three times is exactly why single-instance change streams work here. In MongoDB they are a byproduct of replication, so they require a replica set. Here the log exists whether or not the node has ever seen a peer.

Install

Releases are cut by tag. The server ships as a container image, and as a prebuilt Linux tarball.

# The server — multi-arch (amd64 + arm64) image on GHCR. Pick a root password
# and generate the signing key (32 bytes minimum): a container listens on
# every interface, and off loopback the node refuses an example's value for
# either secret rather than start with one everybody knows.
export KIMMY_ROOT_PASSWORD=$(openssl rand -base64 18)
docker run --rm -p 7878:7878 \
  -e KIMMY_ROOT_PASSWORD \
  -e KIMMY_JWT_SECRET="$(openssl rand -base64 32)" \
  -v kimmy-data:/var/lib/kimmy \
  ghcr.io/titusai-io/kimmydb:latest

Prebuilt kimmyd tarballs with SHA256 checksums — Linux arm64 and x86_64, statically linked against musl, so they run on any distribution — are on the

在 GitHub 查看完整 README

安装

docker run --rm -p 7878:7878 \
新手?先看 mcpskill.org 教程 →