Local knowledge base CLI — hybrid search over markdown files with AI embeddings
Project description
kbx
Local knowledge base CLI with hybrid search over markdown files. Indexes meeting transcripts, notes, and entity records into SQLite (FTS5) and LanceDB (vector) for fast retrieval by humans and AI agents.
Install
pip install kbx # core CLI + FTS5 search
pip install "kbx[search]" # + vector search (Qwen3 embeddings)
pip install "kbx[search,mlx]" # + Apple Silicon acceleration
Requires Python 3.10+.
Quick Start
kbx init # create kbx.toml in the current directory
kbx index run # index markdown files
kbx search "quarterly planning" # hybrid search (FTS5 + vector)
kbx search "quarterly planning" --fast # keyword-only (no model needed)
Features
- Full-text search -- SQLite FTS5 with BM25 ranking and natural date filters
- Vector search -- Qwen3-Embedding-0.6B via sentence-transformers, fused with FTS5 using reciprocal rank fusion (RRF)
- Entity linking -- auto-links people, projects, and glossary terms to documents via regex matching
- Entity CRUD -- manage people, projects, and glossary terms from the CLI with markdown file sync
- MCP server -- stdio transport for integration with Claude, Cursor, and other AI tools
- Granola sync -- pull meeting transcripts from the Granola API or ingest local exports
- Configurable --
kbx.tomlcontrols source directories, search behaviour, and extras - Incremental indexing -- content-hash based; only re-indexes changed files
Configuration
kbx looks for configuration in this order:
$KBX_CONFIGenvironment variable./kbx.tomlin the current directory~/.config/kbx/config.toml
Run kbx init to generate a starter config file.
Optional Extras
| Extra | What it adds |
|---|---|
search |
LanceDB + sentence-transformers + NumPy for vector search |
mlx |
MLX backend for faster embeddings on Apple Silicon |
mcp |
MCP server for AI tool integration |
all |
Everything above plus test and dev dependencies |
Install with: pip install "kbx[search,mlx,mcp]"
Development
git clone https://github.com/tenfourty/kbx.git
cd kbx
uv sync --all-extras
uv run pre-commit install
uv run pytest -x -q --cov
See CONTRIBUTING.md for guidelines.
License
Apache-2.0
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file kbx-0.1.9.tar.gz.
File metadata
- Download URL: kbx-0.1.9.tar.gz
- Upload date:
- Size: 490.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ee3e148c6234050f1dd503e283d0a773489db04a31bf8011de4f2a4a0d49e1e2
|
|
| MD5 |
c49056e9b6edef6ad676fa5f37339b72
|
|
| BLAKE2b-256 |
21f9d143bcc0a488133b5545524ad47920d9bd43969e3f868689ba664abc564b
|
Provenance
The following attestation bundles were made for kbx-0.1.9.tar.gz:
Publisher:
release.yml on tenfourty/kbx
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
kbx-0.1.9.tar.gz -
Subject digest:
ee3e148c6234050f1dd503e283d0a773489db04a31bf8011de4f2a4a0d49e1e2 - Sigstore transparency entry: 1006378506
- Sigstore integration time:
-
Permalink:
tenfourty/kbx@0ed42c27744248f9e3f688ed9fa140d403d4c680 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/tenfourty
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@0ed42c27744248f9e3f688ed9fa140d403d4c680 -
Trigger Event:
push
-
Statement type:
File details
Details for the file kbx-0.1.9-py3-none-any.whl.
File metadata
- Download URL: kbx-0.1.9-py3-none-any.whl
- Upload date:
- Size: 121.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a90d33f5f5689c5bd6184042e8f24a7e24ef826fc875c538a3b6b9158978608f
|
|
| MD5 |
71f9811627a015b88f4c3311c13d6564
|
|
| BLAKE2b-256 |
107fade0363e03dce25ef433071e057d77433f15b1ebeff84d2358b962a83f24
|
Provenance
The following attestation bundles were made for kbx-0.1.9-py3-none-any.whl:
Publisher:
release.yml on tenfourty/kbx
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
kbx-0.1.9-py3-none-any.whl -
Subject digest:
a90d33f5f5689c5bd6184042e8f24a7e24ef826fc875c538a3b6b9158978608f - Sigstore transparency entry: 1006378507
- Sigstore integration time:
-
Permalink:
tenfourty/kbx@0ed42c27744248f9e3f688ed9fa140d403d4c680 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/tenfourty
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@0ed42c27744248f9e3f688ed9fa140d403d4c680 -
Trigger Event:
push
-
Statement type: