whimsicality-db
OfficialClick on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@whimsicality-dbSearch my context index for the tag 'security' and summarize the relevant entries."
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
whimsicality-db
A SQLite-backed MCP server with FTS5 full-text search for truly infinite agent context. Session tracking, event logging, todo management, and tagged context index for long-horizon tasks and heavy workloads.
Quick start
Add to your MCP client config:
{
"mcpServers": {
"whimsicality-db": {
"command": "npx",
"args": ["whimsicality-db"]
}
}
}Data is stored at ~/.whimsicality/db-storage/whimsicality.db by default (SQLite with WAL mode). Set WHIMSICALITY_DB_DIR to override.
Why SQLite?
The companion server whimsicality-mcp uses a JSON file for memory and docs. It's simple and correct, but every write rewrites the whole file and every search re-tokenizes the whole corpus. Fine for hundreds of entries, unusable for tens of thousands.
This server uses SQLite with FTS5:
Problem | JSON file | SQLite + FTS5 |
Write cost | O(n) full rewrite | O(log n) B-tree insert |
Search cost | O(n) re-tokenize per query | O(log n) inverted index lookup |
BM25 | Hand-rolled, recomputed | Native FTS5 bm25() function |
Concurrency | Lockfile + atomic rename | WAL mode: concurrent readers + 1 writer |
Durability | fsync + rename | SQLite WAL + journal |
Scale wall | ~1,000 entries | ~1,000,000+ entries |
What's different from whimsicality-mcp
Three new collections that the JSON server doesn't have:
Todos
Task tracking with status (pending/in_progress/completed), priority, tags, and session linkage. The model can add tasks, update their status, search them, and filter by tag or session. Useful for long-horizon work where the model needs to track its own progress across context window boundaries.
Context index
Tagged content entries that the model pulls by tag when needed. Instead of loading everything into context, the model stores reference material, architecture decisions, and domain knowledge with tags, then retrieves only what's relevant via db_context_by_tags(["security", "auth"]). This is the "multiple files with tags" pattern — the model has a dense catalog of tagged knowledge and pulls only what it needs.
Sessions + Events
Session tracking for long-horizon tasks. Create a session, log events (decisions, milestones, errors, observations) as they happen, and search them later. When a task spans multiple context windows, the session log is the persistent memory that connects them — the model can search past decisions and events without re-deriving them.
Tools (32 total)
Memory — namespaced key-value store (5)
Tool | Description |
| Store persistent text. Namespaced key-value. |
| Retrieve by key and namespace. Error if not found. |
| List all keys in a namespace. |
| Delete an entry. Returns deleted:false if absent. |
| FTS5 search across all memory values with BM25 ranking. |
Documents — full-text searchable (5)
Tool | Description |
| Save a document for FTS5 search. |
| Retrieve a full document by ID. |
| FTS5 search. Returns match-centered excerpts. |
| List saved document IDs. |
| Delete a document. |
Cache — compressed paged content (7)
Tool | Description |
| Store content. Brotli-compressed. Returns compression stats. |
| Read by ID with paging (offset + length). Returns total_length + has_more. |
| Compact summary table with token estimate. |
| FTS5 search over cache metadata (topic, summary, tags). |
| List all cached chunk IDs. |
| Delete a cached chunk. |
| Entry count, total bytes, compression ratio. |
Todos — task tracking (5)
Tool | Description |
| Add a todo with priority, tags, and optional session linkage. |
| List todos, filter by status/tag/session. Ordered by priority desc. |
| Update status, title, description, or priority. |
| Delete a todo. |
| FTS5 search over todo titles and descriptions. |
Context index — tagged content retrieval (5)
Tool | Description |
| Add a tagged context entry (reference material, decisions, notes). |
| Retrieve a context entry by ID. |
| Retrieve entries matching ANY of the specified tags. |
| FTS5 search over context entries (title, content, tags). |
| Delete a context entry. |
Sessions — long-horizon task tracking (4)
Tool | Description |
| Create or update a session. |
| Get session details by ID. |
| List sessions, optionally filtered by status. |
| Update session status (active/paused/completed/abandoned). |
Events — session log (3)
Tool | Description |
| Log an event (decision, milestone, error, note, observation). |
| List events, filter by session and/or type. |
| FTS5 search over event content. |
Stats (1)
Tool | Description |
| Database statistics: counts per table + total DB size. |
Architecture
┌──────────────────────────────────────────────────────────┐
│ SQLite Database (WAL mode) │
│ │
│ memory ─── memory_fts (FTS5) │
│ docs ─── docs_fts (FTS5) │
│ cache ─── cache_fts (FTS5) │
│ todos ─── todos_fts (FTS5) │
│ context_entries ── context_fts (FTS5) │
│ sessions (no FTS — small, direct query) │
│ events ─── events_fts (FTS5) │
│ │
│ Triggers keep FTS5 indexes in sync automatically. │
│ WAL mode allows concurrent readers + 1 writer. │
└──────────────────────────────────────────────────────────┘Every table with text content has a corresponding FTS5 virtual table with triggers that keep the index in sync on insert/update/delete. Searches use SQLite's native bm25() function for ranking — no re-tokenization, no recomputation.
The cache table stores content as brotli-compressed BLOBs. db_cache_read decompresses on demand with offset+length paging.
When to use which collection
Memory: small key-value pairs you want to recall by exact key (facts, decisions, config)
Docs: documents you want to search by content (returns matching excerpts)
Cache: large content you want to page in on demand (compressed, paged reads)
Todos: tasks the model is tracking across context windows (status, priority, tags)
Context index: reference material the model pulls by tag when needed (architecture, domain knowledge, patterns)
Sessions: long-horizon task containers (group events and todos)
Events: chronological log within a session (decisions, milestones, errors)
Configuration
Variable | Default | Description |
|
| Database storage directory |
Development
git clone https://github.com/WhimsicalityLabs/Whimsicality-DB.git
cd Whimsicality-DB
npm install
npm test
npm run typecheckThe test suite covers all 32 tools: memory CRUD + search, docs CRUD + search, cache compression + paging + search, todos CRUD + filtering + search, context index add/get/by-tags/search, sessions + events, cross-process visibility, and input validation.
License
MIT
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Connectors
Persistent memory for AI agents. Search, store, and recall across sessions.
Universal memory for AI agents and tools. Save, organize and search context anywhere.
Persistent memory for AI agents — verbatim conversations, searchable by meaning.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/WhimsicalityLabs/Whimsicality-DB'
If you have feedback or need assistance with the MCP directory API, please join our Discord server