@dikolab/kbdb 0.3.1 → 0.3.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +72 -84
- package/docs/details/cli.md +9 -0
- package/docs/details/mcp-server.md +1 -1
- package/docs/details/search-and-ranking.md +55 -0
- package/docs/overview.md +44 -22
- package/docs/release-notes/0.3.1.md +10 -0
- package/docs/release-notes/0.3.2.md +64 -0
- package/docs/release-notes/README.md +1 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -6,7 +6,7 @@ required.
|
|
|
6
6
|
[GitLab](https://gitlab.com/tech-slaves/knowledge-base-db)
|
|
7
7
|
| [NPM](https://www.npmjs.com/package/@dikolab/kbdb)
|
|
8
8
|
| [JSR](https://jsr.io/@dikolab/kbdb)
|
|
9
|
-
| [License: ISC](
|
|
9
|
+
| [License: ISC](LICENSE)
|
|
10
10
|
|
|
11
11
|
---
|
|
12
12
|
|
|
@@ -23,13 +23,23 @@ works as an [MCP](https://modelcontextprotocol.io/)
|
|
|
23
23
|
server -- giving AI agents like Claude a searchable
|
|
24
24
|
second brain that persists between sessions.
|
|
25
25
|
|
|
26
|
-
**How search works:** kbdb
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
26
|
+
**How search works:** kbdb searches by keywords --
|
|
27
|
+
it matches your query against indexed terms, expands
|
|
28
|
+
synonyms, and ranks results by relevance. This is
|
|
29
|
+
the default **lexical** mode: fast, works offline,
|
|
30
|
+
and gives consistent results every time.
|
|
31
|
+
|
|
32
|
+
When an exact query finds nothing, kbdb automatically
|
|
33
|
+
loosens the match so you still get the best available
|
|
34
|
+
results. Headings count for more in ranking, so
|
|
35
|
+
writing clear headings helps.
|
|
36
|
+
|
|
37
|
+
Want smarter matching? kbdb supports **hybrid search**
|
|
38
|
+
(`--algo hybrid`) that blends keyword matching with
|
|
39
|
+
AI-powered similarity. This catches results that use
|
|
40
|
+
different words for the same concept. Hybrid mode
|
|
41
|
+
needs an embedding provider -- without one, kbdb
|
|
42
|
+
sticks to keyword search.
|
|
33
43
|
|
|
34
44
|
**Knowledge stays fresh:** Re-learn a file and kbdb
|
|
35
45
|
replaces the old version automatically.
|
|
@@ -87,7 +97,7 @@ kbdb learn ./docs --db ./my-kb
|
|
|
87
97
|
Point it at a folder of Markdown files. kbdb reads
|
|
88
98
|
them, breaks them into sections, and builds a
|
|
89
99
|
search index. Add `--tags design,v2` to tag
|
|
90
|
-
sections for scoping, or `--replace` to
|
|
100
|
+
sections for scoping, or `--replace` to update
|
|
91
101
|
existing sections from the same source.
|
|
92
102
|
|
|
93
103
|
**3. Search**
|
|
@@ -96,11 +106,16 @@ existing sections from the same source.
|
|
|
96
106
|
kbdb search "how does auth work" --db ./my-kb
|
|
97
107
|
```
|
|
98
108
|
|
|
99
|
-
Results are ranked by relevance with
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
109
|
+
Results are ranked by relevance with snippets
|
|
110
|
+
showing where your terms matched. Use `--offset`
|
|
111
|
+
to page through large result sets.
|
|
112
|
+
|
|
113
|
+
To try hybrid search (keyword + AI similarity):
|
|
114
|
+
|
|
115
|
+
```sh
|
|
116
|
+
kbdb search "how does auth work" --algo hybrid \
|
|
117
|
+
--db ./my-kb
|
|
118
|
+
```
|
|
104
119
|
|
|
105
120
|
**4. Recall context**
|
|
106
121
|
|
|
@@ -121,25 +136,28 @@ referenced sections.
|
|
|
121
136
|
|
|
122
137
|
- **Import** Markdown files and other documents,
|
|
123
138
|
with tags and source tracking
|
|
124
|
-
- **
|
|
125
|
-
|
|
126
|
-
- **Search** with
|
|
127
|
-
|
|
128
|
-
- **
|
|
129
|
-
|
|
139
|
+
- **Smart updates** -- re-learning a file replaces
|
|
140
|
+
the old version instead of duplicating it
|
|
141
|
+
- **Search** with three modes: keyword (default),
|
|
142
|
+
AI similarity, or hybrid (both combined)
|
|
143
|
+
- **Auto-fallback** -- if your exact query finds
|
|
144
|
+
nothing, kbdb loosens the match automatically
|
|
130
145
|
- **Recall** sections with progressive context --
|
|
131
146
|
from a quick summary to full related content
|
|
132
|
-
- **Export
|
|
147
|
+
- **Export and sync** -- snapshot your knowledge
|
|
148
|
+
base for backup or sharing across machines
|
|
133
149
|
- **Skills** -- store reusable prompt templates
|
|
134
|
-
with
|
|
150
|
+
with fill-in-the-blank arguments
|
|
135
151
|
- **Agents** -- create AI agent profiles that
|
|
136
152
|
combine a persona with skills
|
|
137
|
-
- **
|
|
138
|
-
|
|
139
|
-
|
|
153
|
+
- **Auto-capture** -- the MCP server can
|
|
154
|
+
proactively suggest knowledge to store from
|
|
155
|
+
your conversations
|
|
156
|
+
- **Verify** database integrity and clean up
|
|
157
|
+
stale data
|
|
140
158
|
- **Rebuild** indexes if anything goes wrong
|
|
141
159
|
|
|
142
|
-
See the [CLI Reference](
|
|
160
|
+
See the [CLI Reference](docs/details/cli.md)
|
|
143
161
|
for the full command list and examples.
|
|
144
162
|
|
|
145
163
|
---
|
|
@@ -153,51 +171,17 @@ recall context progressively, export snapshots,
|
|
|
153
171
|
store reusable skills, and build agent profiles --
|
|
154
172
|
a second brain that persists between sessions.
|
|
155
173
|
|
|
156
|
-
###
|
|
174
|
+
### Setup
|
|
157
175
|
|
|
158
|
-
|
|
176
|
+
Add kbdb to your AI tool's MCP config. The setup
|
|
177
|
+
is the same for Claude Code, VS Code, Cursor, and
|
|
178
|
+
Claude Desktop -- just put the config in the right
|
|
179
|
+
file for your tool.
|
|
159
180
|
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
"command": "npx",
|
|
165
|
-
"args": [
|
|
166
|
-
"-y",
|
|
167
|
-
"@dikolab/kbdb",
|
|
168
|
-
"mcp",
|
|
169
|
-
"--db",
|
|
170
|
-
"/path/to/.kbdb"
|
|
171
|
-
]
|
|
172
|
-
}
|
|
173
|
-
}
|
|
174
|
-
}
|
|
175
|
-
```
|
|
176
|
-
|
|
177
|
-
### Claude for VS Code
|
|
178
|
-
|
|
179
|
-
Create `.vscode/mcp.json` in your project:
|
|
180
|
-
|
|
181
|
-
```json
|
|
182
|
-
{
|
|
183
|
-
"servers": {
|
|
184
|
-
"kbdb": {
|
|
185
|
-
"command": "npx",
|
|
186
|
-
"args": [
|
|
187
|
-
"-y",
|
|
188
|
-
"@dikolab/kbdb",
|
|
189
|
-
"mcp",
|
|
190
|
-
"--db",
|
|
191
|
-
"${workspaceFolder}/.kbdb"
|
|
192
|
-
]
|
|
193
|
-
}
|
|
194
|
-
}
|
|
195
|
-
}
|
|
196
|
-
```
|
|
197
|
-
|
|
198
|
-
### Claude Desktop
|
|
199
|
-
|
|
200
|
-
Add to your `claude_desktop_config.json`:
|
|
181
|
+
**Claude Code** -- `.mcp.json` in your project root.
|
|
182
|
+
**VS Code / Cursor** -- `.vscode/mcp.json` in your
|
|
183
|
+
project. **Claude Desktop** --
|
|
184
|
+
`claude_desktop_config.json`.
|
|
201
185
|
|
|
202
186
|
```json
|
|
203
187
|
{
|
|
@@ -216,13 +200,18 @@ Add to your `claude_desktop_config.json`:
|
|
|
216
200
|
}
|
|
217
201
|
```
|
|
218
202
|
|
|
219
|
-
|
|
203
|
+
For VS Code / Cursor, wrap in `{"servers": ...}`
|
|
204
|
+
instead of `{"mcpServers": ...}`. Use
|
|
205
|
+
`"${workspaceFolder}/.kbdb"` for the db path.
|
|
220
206
|
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
207
|
+
**Deno users:** replace `npx` / `-y` /
|
|
208
|
+
`@dikolab/kbdb` with `deno` / `run` / `-A` /
|
|
209
|
+
`jsr:@dikolab/kbdb/cli`.
|
|
210
|
+
|
|
211
|
+
See the
|
|
212
|
+
[MCP Server Guide](docs/details/mcp-server.md)
|
|
213
|
+
for Deno examples, environment variable config,
|
|
214
|
+
multiple knowledge bases, and the full tool list.
|
|
226
215
|
|
|
227
216
|
---
|
|
228
217
|
|
|
@@ -246,13 +235,12 @@ const results = await client.search({
|
|
|
246
235
|
offset: 0,
|
|
247
236
|
});
|
|
248
237
|
|
|
249
|
-
// results = { items, total, offset, limit, has_more, relaxed }
|
|
250
238
|
console.log(results.items);
|
|
251
239
|
client.disconnect();
|
|
252
240
|
```
|
|
253
241
|
|
|
254
242
|
See the
|
|
255
|
-
[Library API Reference](
|
|
243
|
+
[Library API Reference](docs/details/library-api.md)
|
|
256
244
|
for the full API.
|
|
257
245
|
|
|
258
246
|
### Development Setup
|
|
@@ -273,7 +261,7 @@ A Docker setup is included with all build tools
|
|
|
273
261
|
HOST_UMASK=$(umask) docker compose run --rm dev bash
|
|
274
262
|
```
|
|
275
263
|
|
|
276
|
-
See the [Makefile](
|
|
264
|
+
See the [Makefile](Makefile) for all available
|
|
277
265
|
build targets.
|
|
278
266
|
|
|
279
267
|
### Contributing
|
|
@@ -288,17 +276,17 @@ build targets.
|
|
|
288
276
|
|
|
289
277
|
## Documentation
|
|
290
278
|
|
|
291
|
-
- [Detailed Guides](
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
- [Release Notes](
|
|
295
|
-
- [Architecture Overview](
|
|
279
|
+
- [Detailed Guides](docs/details/) -- CLI reference,
|
|
280
|
+
MCP setup, search internals, storage format,
|
|
281
|
+
library API
|
|
282
|
+
- [Release Notes](docs/release-notes/)
|
|
283
|
+
- [Architecture Overview](docs/overview.md)
|
|
296
284
|
|
|
297
285
|
---
|
|
298
286
|
|
|
299
287
|
## License
|
|
300
288
|
|
|
301
|
-
ISC License -- see [LICENSE](
|
|
289
|
+
ISC License -- see [LICENSE](LICENSE) for details.
|
|
302
290
|
|
|
303
291
|
---
|
|
304
292
|
|
package/docs/details/cli.md
CHANGED
|
@@ -80,8 +80,17 @@ These options apply to the `search` command.
|
|
|
80
80
|
| `--limit <n>` | `-l` | `20` | positive integer | Maximum results returned |
|
|
81
81
|
| `--offset <n>` | | `0` | non-negative integer | Zero-based result offset for pagination |
|
|
82
82
|
| `--format <fmt>` | `-f` | `json` | `json`, `text`, `mcp` | Output format |
|
|
83
|
+
| `--algo <algo>` | | `lexical` | `lexical`, `vector`, `hybrid` | Search algorithm |
|
|
83
84
|
| `--content` | `-c` | off | boolean flag | Hydrate results with section content |
|
|
84
85
|
|
|
86
|
+
### Search Algorithms
|
|
87
|
+
|
|
88
|
+
| Algorithm | Description |
|
|
89
|
+
|-----------|-------------|
|
|
90
|
+
| `lexical` | Keyword matching with stemming and synonyms (default) |
|
|
91
|
+
| `vector` | AI-powered similarity search using embeddings (requires a configured embedding provider) |
|
|
92
|
+
| `hybrid` | Combines keyword and similarity results for best coverage |
|
|
93
|
+
|
|
85
94
|
### Search Modes
|
|
86
95
|
|
|
87
96
|
| Mode | Description |
|
|
@@ -196,7 +196,7 @@ daemon via JSON-RPC 2.0 over IPC.
|
|
|
196
196
|
|
|
197
197
|
| Tool | Parameters | Description | Read-only | Destructive |
|
|
198
198
|
|------|-----------|-------------|-----------|-------------|
|
|
199
|
-
| `search` | `query` (string, required), `mode` (string), `limit` (number), `offset` (number), `content` (boolean) | Query the knowledge base by keywords. Returns ranked results with heading, snippet, and matched terms. Use
|
|
199
|
+
| `search` | `query` (string, required), `mode` (string), `algo` (string: lexical, vector, hybrid), `limit` (number), `offset` (number), `content` (boolean) | Query the knowledge base by keywords. Returns ranked results with heading, snippet, and matched terms. Use `algo` to select search algorithm (default: lexical). | yes | no |
|
|
200
200
|
| `learn` | `content` (string, required), `type` (string), `title` (string), `description` (string), `docid` (string), `tags` (string[]), `replace` (boolean) | Import content into the knowledge base. Use for durable facts, decisions, and corrections. Use `replace` when updating existing knowledge. Attach `tags` for scoping. | no | no |
|
|
201
201
|
| `unlearn` | `kbid` (string, required) | Remove a section by kb-id. Cascades deletion to index entries and ranking data. | no | yes |
|
|
202
202
|
| `retrieve` | `kbid` (string), `docid` (string) | Fetch a specific section or document by identifier. At least one of `kbid` or `docid` required. | yes | no |
|
|
@@ -1,5 +1,15 @@
|
|
|
1
1
|
# How Search Works
|
|
2
2
|
|
|
3
|
+
When you search, kbdb finds the sections that best
|
|
4
|
+
match your query and ranks them by relevance. By
|
|
5
|
+
default it matches keywords (like a search engine).
|
|
6
|
+
You can also enable AI-powered similarity search
|
|
7
|
+
or combine both with `--algo hybrid`. The rest of
|
|
8
|
+
this page explains how ranking works under the hood
|
|
9
|
+
-- you don't need to read it to use kbdb.
|
|
10
|
+
|
|
11
|
+
---
|
|
12
|
+
|
|
3
13
|
kbdb uses field-weighted BM25F ranking to score search
|
|
4
14
|
results by relevance. Sections are indexed across
|
|
5
15
|
three fields -- heading, body, and code -- each with a
|
|
@@ -513,3 +523,48 @@ Neither standalone module calls the other directly.
|
|
|
513
523
|
| `sections` | Individual matching sections with scores, snippets, and matched terms |
|
|
514
524
|
| `documents` | Documents containing matches, with aggregated scores and per-section details |
|
|
515
525
|
| `stats` | Match counts and top terms without content bodies |
|
|
526
|
+
|
|
527
|
+
## Search Algorithms
|
|
528
|
+
|
|
529
|
+
kbdb supports three search algorithms, selected
|
|
530
|
+
with `--algo` (CLI) or the `algo` parameter (MCP).
|
|
531
|
+
|
|
532
|
+
### Lexical (default)
|
|
533
|
+
|
|
534
|
+
Keyword matching with stemming and synonym
|
|
535
|
+
expansion, scored by BM25F as described above.
|
|
536
|
+
Fast, works offline, and gives consistent results.
|
|
537
|
+
This is the default when no `--algo` flag is given.
|
|
538
|
+
|
|
539
|
+
### Vector
|
|
540
|
+
|
|
541
|
+
Embedding-based similarity search. Each section's
|
|
542
|
+
content is converted into a numeric vector (an
|
|
543
|
+
"embedding") by an AI model. Search finds sections
|
|
544
|
+
whose vectors are closest to the query's vector
|
|
545
|
+
using cosine similarity.
|
|
546
|
+
|
|
547
|
+
Vector search catches matches that keyword search
|
|
548
|
+
misses -- for example, searching "database
|
|
549
|
+
rationale" finds a section about "we chose Postgres
|
|
550
|
+
because of JSONB" even though none of the words
|
|
551
|
+
overlap.
|
|
552
|
+
|
|
553
|
+
Requires an embedding provider to be configured.
|
|
554
|
+
Without one, vector mode falls back to lexical.
|
|
555
|
+
|
|
556
|
+
### Hybrid
|
|
557
|
+
|
|
558
|
+
Runs both lexical and vector searches in parallel,
|
|
559
|
+
then merges the two ranked lists using Reciprocal
|
|
560
|
+
Rank Fusion (RRF). This combines the precision of
|
|
561
|
+
keyword matching with the associative recall of
|
|
562
|
+
embeddings.
|
|
563
|
+
|
|
564
|
+
RRF works by converting each result's rank position
|
|
565
|
+
into a score (`1 / (k + rank)` with k=60), then
|
|
566
|
+
summing scores across both lists. Results that rank
|
|
567
|
+
well in both lists get the highest combined scores.
|
|
568
|
+
|
|
569
|
+
Hybrid mode requires an embedding provider. Without
|
|
570
|
+
one, it falls back to lexical.
|
package/docs/overview.md
CHANGED
|
@@ -27,6 +27,8 @@ to it as a tool.
|
|
|
27
27
|
for Model Context Protocol servers
|
|
28
28
|
- **Knowledge workers** -- a second brain your AI
|
|
29
29
|
assistant can search across conversations
|
|
30
|
+
- **Vibe coders** -- a searchable doc store for
|
|
31
|
+
your AI-assisted projects
|
|
30
32
|
- **CLI-first developers** -- composable commands
|
|
31
33
|
for managing knowledge from the terminal
|
|
32
34
|
|
|
@@ -34,15 +36,25 @@ to it as a tool.
|
|
|
34
36
|
|
|
35
37
|
- **Import** Markdown files with automatic keyword
|
|
36
38
|
extraction and indexing
|
|
37
|
-
- **Search**
|
|
38
|
-
|
|
39
|
+
- **Search** three ways: keyword (default),
|
|
40
|
+
AI similarity, or hybrid (both combined) via
|
|
41
|
+
`--algo`
|
|
42
|
+
- **Auto-fallback** -- loosens your query when
|
|
43
|
+
exact matches return nothing
|
|
39
44
|
- **Recall** sections with progressive context
|
|
40
45
|
(depth 0--3)
|
|
46
|
+
- **Smart updates** -- re-learning a file replaces
|
|
47
|
+
the old version, not duplicates it
|
|
48
|
+
- **Near-duplicate detection** -- warns when
|
|
49
|
+
imported content closely matches existing data
|
|
41
50
|
- **Skills** -- reusable prompt templates with
|
|
42
|
-
|
|
51
|
+
fill-in-the-blank arguments
|
|
43
52
|
- **Agents** -- AI profiles combining a persona
|
|
44
53
|
with skills
|
|
45
|
-
- **
|
|
54
|
+
- **Auto-capture** -- MCP server proactively
|
|
55
|
+
suggests knowledge to store from conversations
|
|
56
|
+
- **Export and sync** -- snapshot your knowledge
|
|
57
|
+
base for backup or sharing across machines
|
|
46
58
|
- **Verify** database integrity and clean up stale
|
|
47
59
|
data
|
|
48
60
|
- **MCP server** with 20 tools, prompts, resources,
|
|
@@ -76,32 +88,31 @@ mode runs short-lived commands (`learn`, `search`,
|
|
|
76
88
|
`recall`). MCP mode starts a long-lived server for
|
|
77
89
|
AI agents over stdio.
|
|
78
90
|
|
|
79
|
-
**Worker Client** --
|
|
80
|
-
|
|
91
|
+
**Worker Client** -- Connects to the background
|
|
92
|
+
daemon and gives your code a typed API.
|
|
81
93
|
|
|
82
94
|
**Worker Daemon** -- Background process that loads
|
|
83
|
-
|
|
84
|
-
|
|
95
|
+
the search engine, caches data in memory, and
|
|
96
|
+
handles requests.
|
|
85
97
|
|
|
86
|
-
**
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
runtime.
|
|
98
|
+
**Search Engine** -- Compiled from Rust to
|
|
99
|
+
WebAssembly for speed. Three modules handle
|
|
100
|
+
tokenization, indexing, ranking, and file I/O.
|
|
90
101
|
|
|
91
|
-
**File Database** -- Structured
|
|
102
|
+
**File Database** -- Structured folder on disk.
|
|
92
103
|
No server process. Portable, version-controllable,
|
|
93
104
|
and human-readable.
|
|
94
105
|
|
|
95
106
|
### Technology Stack
|
|
96
107
|
|
|
97
|
-
| Layer | Technology |
|
|
98
|
-
|
|
99
|
-
| Runtime | Node.js, Deno | Runs
|
|
100
|
-
| Language | TypeScript | CLI, MCP
|
|
101
|
-
| Engine | Rust -> WebAssembly |
|
|
108
|
+
| Layer | Technology | What it does |
|
|
109
|
+
|-------|-----------|--------------|
|
|
110
|
+
| Runtime | Node.js, Deno | Runs the tools |
|
|
111
|
+
| Language | TypeScript | CLI, MCP server, I/O |
|
|
112
|
+
| Engine | Rust -> WebAssembly | Fast indexing and search |
|
|
102
113
|
| Protocol | MCP | AI agent integration |
|
|
103
|
-
| Distribution | NPM, JSR |
|
|
104
|
-
| Storage | File database |
|
|
114
|
+
| Distribution | NPM, JSR | Install from either |
|
|
115
|
+
| Storage | File database | Your data, in a folder |
|
|
105
116
|
|
|
106
117
|
## Design Principles
|
|
107
118
|
|
|
@@ -120,7 +131,9 @@ and human-readable.
|
|
|
120
131
|
|
|
121
132
|
## Design Documents
|
|
122
133
|
|
|
123
|
-
|
|
134
|
+
Deeper docs for each part of the system. You don't
|
|
135
|
+
need to read these to use kbdb -- they're here for
|
|
136
|
+
contributors and anyone curious about internals.
|
|
124
137
|
|
|
125
138
|
- **[Database](goals/database.md)** -- File storage
|
|
126
139
|
engine, directory structure, section and document
|
|
@@ -128,6 +141,8 @@ Detailed specifications for each subsystem:
|
|
|
128
141
|
- **[Query Parser](goals/query-parser.md)** --
|
|
129
142
|
Tokenization, query parsing, keyword extraction,
|
|
130
143
|
ranking
|
|
144
|
+
- **[Hybrid Search](goals/hybrid-search.md)** --
|
|
145
|
+
Lexical + vector retrieval with score fusion
|
|
131
146
|
- **[Document](goals/document.md)** -- Content format
|
|
132
147
|
with markers and cross-references
|
|
133
148
|
- **[Content Parser](goals/content-parser.md)** --
|
|
@@ -138,6 +153,10 @@ Detailed specifications for each subsystem:
|
|
|
138
153
|
output formats
|
|
139
154
|
- **[MCP](goals/mcp.md)** -- MCP server, tools,
|
|
140
155
|
resources, agent wiring
|
|
156
|
+
- **[Auto-Capture](goals/auto-capture.md)** --
|
|
157
|
+
Proactive knowledge capture via MCP sampling
|
|
158
|
+
- **[Sync](goals/sync.md)** -- Cross-machine export
|
|
159
|
+
and import
|
|
141
160
|
- **[Worker Daemon](goals/worker-daemon.md)** --
|
|
142
161
|
Background daemon, WASM loading, caching, IPC
|
|
143
162
|
- **[Worker Client](goals/worker-client.md)** --
|
|
@@ -155,16 +174,19 @@ with zero failures and zero skips.
|
|
|
155
174
|
|
|
156
175
|
- 18 CLI commands across 6 groups
|
|
157
176
|
- 20 MCP tools with prompts, resources, completions
|
|
177
|
+
- Three search algorithms: lexical, vector, hybrid
|
|
158
178
|
- Sequential MCP request processing
|
|
159
179
|
- Worker daemon with fully implemented WASM host I/O
|
|
160
180
|
- Paginated search with rich metadata
|
|
161
181
|
- Progressive recall at depths 0--3
|
|
162
182
|
- Bidirectional reference graph
|
|
163
183
|
- Skills and agent document management
|
|
184
|
+
- Auto-capture hooks via MCP sampling
|
|
185
|
+
- Export/import sync primitives
|
|
164
186
|
- esbuild bundling (ESM + CJS + .d.ts)
|
|
165
187
|
- Docker build containers
|
|
166
188
|
- npm and JSR packages with documentation
|
|
167
189
|
|
|
168
190
|
## Links
|
|
169
191
|
|
|
170
|
-
- **Repository**: https://gitlab.com/tech-slaves
|
|
192
|
+
- **Repository**: https://gitlab.com/tech-slaves/knowledge-base-db
|
|
@@ -55,6 +55,16 @@ tool (`auto-capture-review`).
|
|
|
55
55
|
`list`, `approve`, or `reject`. This brings the
|
|
56
56
|
MCP server to 20 tools.
|
|
57
57
|
|
|
58
|
+
- **Hybrid search infrastructure** -- New `--algo`
|
|
59
|
+
flag (CLI) and `algo` parameter (MCP/IPC) with
|
|
60
|
+
values `lexical`, `vector`, `hybrid`. Embedding
|
|
61
|
+
module with pluggable provider interface, vector
|
|
62
|
+
index binary format (KBVX), cosine similarity,
|
|
63
|
+
and RRF score fusion. Defaults to `lexical`.
|
|
64
|
+
Concrete embedding providers are deferred -- a
|
|
65
|
+
`NullEmbeddingProvider` is used until one is
|
|
66
|
+
configured.
|
|
67
|
+
|
|
58
68
|
---
|
|
59
69
|
|
|
60
70
|
## Testing
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
# 0.3.2
|
|
2
|
+
|
|
3
|
+
*Patch release -- 2026-06-23*
|
|
4
|
+
|
|
5
|
+
Documentation alignment, hybrid search highlight,
|
|
6
|
+
and readability improvements for non-technical users.
|
|
7
|
+
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
## Documentation
|
|
11
|
+
|
|
12
|
+
- **Internal doc links use relative paths** --
|
|
13
|
+
README.md links to CLI reference, MCP guide,
|
|
14
|
+
library API, Makefile, release notes, overview,
|
|
15
|
+
and LICENSE now use relative paths instead of
|
|
16
|
+
absolute GitLab URLs. External links (NPM, JSR,
|
|
17
|
+
GitLab homepage) remain absolute.
|
|
18
|
+
|
|
19
|
+
- **Fixed repository URL in overview.md** --
|
|
20
|
+
Corrected `tech-slaves-internal` to `tech-slaves`.
|
|
21
|
+
|
|
22
|
+
- **`--algo` added to CLI reference** -- Search
|
|
23
|
+
Options table now documents the `--algo` flag with
|
|
24
|
+
values `lexical`, `vector`, `hybrid` and a new
|
|
25
|
+
Search Algorithms subsection.
|
|
26
|
+
|
|
27
|
+
- **Hybrid search section in search-and-ranking.md**
|
|
28
|
+
-- New section explains lexical, vector, and hybrid
|
|
29
|
+
algorithms with plain-language descriptions of
|
|
30
|
+
how each works and when to use it.
|
|
31
|
+
|
|
32
|
+
- **Beginner summary in search-and-ranking.md** --
|
|
33
|
+
Three-sentence intro at the top so non-technical
|
|
34
|
+
readers know what the page covers without reading
|
|
35
|
+
the full technical deep-dive.
|
|
36
|
+
|
|
37
|
+
- **Feature lists updated** -- README and overview
|
|
38
|
+
now include auto-capture, sync/export, and
|
|
39
|
+
near-duplicate detection. Design Documents section
|
|
40
|
+
in overview now links to hybrid search,
|
|
41
|
+
auto-capture, and sync goal docs.
|
|
42
|
+
|
|
43
|
+
- **Readability pass** -- Simplified jargon across
|
|
44
|
+
README and overview. "RRF score fusion" becomes
|
|
45
|
+
"blends keyword matching with AI-powered
|
|
46
|
+
similarity". Technology stack table simplified.
|
|
47
|
+
MCP setup examples consolidated from three
|
|
48
|
+
nearly-identical blocks into one with platform
|
|
49
|
+
notes.
|
|
50
|
+
|
|
51
|
+
- **"Vibe coders" added to audience list** in
|
|
52
|
+
overview.md.
|
|
53
|
+
|
|
54
|
+
---
|
|
55
|
+
|
|
56
|
+
## Upgrade
|
|
57
|
+
|
|
58
|
+
```sh
|
|
59
|
+
# Node.js
|
|
60
|
+
npm install -g @dikolab/kbdb@0.3.2
|
|
61
|
+
|
|
62
|
+
# Deno
|
|
63
|
+
deno install -Agf jsr:@dikolab/kbdb/cli
|
|
64
|
+
```
|
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
## Releases
|
|
4
4
|
|
|
5
|
+
- [0.3.2](0.3.2.md) -- Docs alignment, hybrid search highlight, readability
|
|
5
6
|
- [0.3.1](0.3.1.md) -- MCP reliability fixes, 20 tools, zero test skips
|
|
6
7
|
- [0.3.0](0.3.0.md) -- Supersession, relaxed queries, export, tags, confidence
|
|
7
8
|
- [0.2.0](0.2.0.md) -- Recall, paginated search, reference graph
|