gnosys 5.2.19 → 5.2.21

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.
Files changed (2) hide show
  1. package/README.md +47 -27
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -5,7 +5,7 @@
5
5
  <p align="center">
6
6
  <a href="https://www.npmjs.com/package/gnosys"><img src="https://img.shields.io/npm/v/gnosys.svg" alt="npm version"></a>
7
7
  <a href="https://github.com/proticom/gnosys/actions"><img src="https://github.com/proticom/gnosys/actions/workflows/ci.yml/badge.svg" alt="CI"></a>
8
- <img src="https://img.shields.io/badge/tests-558%20passing-brightgreen" alt="tests">
8
+ <img src="https://img.shields.io/badge/tests-718%20passing-brightgreen" alt="tests">
9
9
  <img src="https://img.shields.io/badge/coverage-lib%2040%25%20|%20sandbox%2045%25-yellow" alt="coverage">
10
10
  <a href="https://gnosys.ai"><img src="https://img.shields.io/badge/docs-gnosys.ai-C04C4C" alt="docs"></a>
11
11
  <a href="https://gnosys.ai/guide.html"><img src="https://img.shields.io/badge/user%20guide-gnosys.ai%2Fguide-555560" alt="user guide"></a>
@@ -18,11 +18,11 @@
18
18
 
19
19
  **Gnosys** gives AI agents persistent memory that survives across sessions, projects, and machines.
20
20
 
21
- Gnosys is **sandbox-first**: a persistent background process holds the database connection while agents import a tiny helper library and call memory operations like normal code — no MCP schemas, no round-trips, near-zero context cost. The central brain at `~/.gnosys/gnosys.db` unifies all projects, user preferences, and global knowledge. Federated search ranks results across scopes with tier boosting and recency awareness. In v4.0, the **Web Knowledge Base** turns any website into a searchable knowledge base for serverless chatbots — pre-computed JSON index, zero runtime dependencies. Process tracing builds call chains from source code. Dream Mode consolidates knowledge during idle time. One-command export regenerates a full Obsidian vault.
21
+ Gnosys is **sandbox-first**: a persistent background process holds the database connection while agents import a tiny helper library and call memory operations like normal code — no MCP schemas, no round-trips, near-zero context cost. The central brain at `~/.gnosys/gnosys.db` unifies all projects, user preferences, and global knowledge. Federated search ranks results across scopes with tier boosting and recency awareness. The **Web Knowledge Base** turns any website into a searchable knowledge base for serverless chatbots — pre-computed JSON index, zero runtime dependencies. **Multimodal ingestion** handles PDFs, images, audio, and video. **Portfolio Dashboard** gives a bird's-eye view of all projects. Process tracing builds call chains from source code. Dream Mode consolidates knowledge during idle time. One-command export regenerates a full Obsidian vault.
22
22
 
23
23
  It also runs as a CLI and a complete MCP server that drops straight into Cursor, Claude Desktop, Claude Code, Cowork, Codex, or any MCP client.
24
24
 
25
- No vector DBs. No black boxes. No external services. Just SQLite, Markdown, and Obsidian — the way knowledge should be.
25
+ No vector DBs. No black boxes. No external services. Just SQLite and optional Obsidian export — the way knowledge should be.
26
26
 
27
27
  ---
28
28
 
@@ -30,7 +30,7 @@ No vector DBs. No black boxes. No external services. Just SQLite, Markdown, and
30
30
 
31
31
  Most "memory for LLMs" solutions use vector databases, embeddings, or proprietary services. They're opaque — you can't see what the model remembers, can't edit it, can't version it, can't share it.
32
32
 
33
- Gnosys takes a different approach: the central brain is a single SQLite database (`~/.gnosys/gnosys.db`) with sub-10ms reads, while every memory is also dual-written as a plain Markdown file with YAML frontmatter. The Markdown layer is a human-readable safety net and Obsidian export path you can read it, edit it, grep it, and back it up with the tools you already use.
33
+ Gnosys takes a different approach: the central brain is a single SQLite database (`~/.gnosys/gnosys.db`) with sub-10ms reads. SQLite is the sole source of truth no dual-write, no scattered files. When you want a human-readable view, `gnosys export` generates a full Obsidian vault on demand. History lives in the audit_log table, not Git.
34
34
 
35
35
  **What makes it different:**
36
36
 
@@ -39,7 +39,9 @@ Gnosys takes a different approach: the central brain is a single SQLite database
39
39
  - **Federated search** — tier-boosted search across project (1.5x) > user (1.0x) > global (0.7x) scopes with recency and reinforcement boosts.
40
40
  - **Web Knowledge Base** — `gnosys web build` turns any website into a searchable knowledge base for serverless chatbots. Powers [Sir Chats-A-Lot](https://sir-chats-a-lot.com).
41
41
  - **Dream Mode** — idle-time consolidation: confidence decay, self-critique, summary generation, relationship discovery. Never deletes — only suggests reviews.
42
- - **Transparent** — every memory has a human-readable `.md` file alongside the database. Export to Obsidian vault with one command.
42
+ - **Transparent** — DB-only with on-demand Obsidian export. `gnosys export` generates a full vault of human-readable `.md` files whenever you need them.
43
+ - **Portfolio Dashboard** — `gnosys status` for one project, `gnosys status --global` for all projects, `gnosys status --web` for an HTML dashboard. `gnosys update-status` runs a guided 8-section checklist for AI agents.
44
+ - **Multimodal ingestion** — ingest PDFs, images, audio, and video. Extraction pipelines for each media type feed structured memories into the central DB.
43
45
  - **Hybrid Search** — FTS5 keyword + semantic embeddings via Reciprocal Rank Fusion (RRF).
44
46
  - **Multi-project** — MCP roots + per-tool `projectRoot` routing + central project registry. Multiple Cursor windows, zero conflicts.
45
47
  - **Process tracing** — `gnosys trace <dir>` builds call chains from source code with `leads_to`, `follows_from`, and `requires` relationships.
@@ -300,8 +302,8 @@ command = ["gnosys", "serve"]
300
302
  | `gnosys_import` | Bulk import from CSV, JSON, or JSONL |
301
303
  | `gnosys_init` | Initialize a new store |
302
304
  | `gnosys_stale` | Find memories not modified within N days |
303
- | `gnosys_history` | Git-backed version history for a memory |
304
- | `gnosys_rollback` | Rollback a memory to a previous commit |
305
+ | `gnosys_history` | Version history for a memory (audit log) |
306
+ | `gnosys_rollback` | Rollback a memory to a previous version |
305
307
  | `gnosys_timeline` | Show when memories were created/modified over time |
306
308
  | `gnosys_stats` | Summary statistics for the memory store |
307
309
  | `gnosys_links` | Show wikilinks and backlinks for a memory |
@@ -317,8 +319,10 @@ command = ["gnosys", "serve"]
317
319
  | `gnosys_stores` | Show active stores, MCP roots, and detected project stores |
318
320
  | `gnosys_tags` | List tag registry |
319
321
  | `gnosys_tags_add` | Add a new tag to the registry |
322
+ | `gnosys_ingest_file` | Ingest a file (PDF, image, audio, video, DOCX) into memory |
323
+ | `gnosys_portfolio` | Portfolio dashboard — project status across all registered projects |
324
+ | `gnosys_update_status` | Guided 8-section status update checklist for AI agents |
320
325
  | **Centralized Brain** | |
321
- | `gnosys_projects` | List all registered projects in the central DB |
322
326
  | `gnosys_backup` | Create a point-in-time backup of the central DB |
323
327
  | `gnosys_restore` | Restore the central DB from a backup |
324
328
  | `gnosys_migrate_to_central` | Migrate project data into the central DB |
@@ -337,7 +341,7 @@ command = ["gnosys", "serve"]
337
341
 
338
342
  ### Central Brain
339
343
 
340
- All memories live in a single `~/.gnosys/gnosys.db` with `project_id` and `scope` columns. Every write is dual-written to both SQLite and a human-readable `.md` file. Sub-10ms reads, WAL mode for concurrent access. See the [User Guide](https://gnosys.ai/guide.html) for the full schema and memory format.
344
+ All memories live in a single `~/.gnosys/gnosys.db` with `project_id` and `scope` columns. SQLite is the sole source of truth no dual-write, no markdown files on disk. Sub-10ms reads, WAL mode for concurrent access. Use `gnosys export` to generate an Obsidian vault on demand. See the [User Guide](https://gnosys.ai/guide.html) for the full schema and memory format.
341
345
 
342
346
  ### LLM Providers
343
347
 
@@ -348,10 +352,10 @@ Eight providers behind a single interface — switch between cloud and local wit
348
352
  | **Anthropic** | Cloud | claude-sonnet-4-6 | `GNOSYS_ANTHROPIC_KEY` |
349
353
  | **Ollama** | Local | llama3.2 | — (runs locally) |
350
354
  | **Groq** | Cloud | llama-3.3-70b-versatile | `GNOSYS_GROQ_KEY` |
351
- | **OpenAI** | Cloud | gpt-5.4-mini | `GNOSYS_OPENAI_KEY` |
355
+ | **OpenAI** | Cloud | gpt-4o-mini | `GNOSYS_OPENAI_KEY` |
352
356
  | **LM Studio** | Local | default | — (runs locally) |
353
- | **xAI** | Cloud | grok-4.20 | `GNOSYS_XAI_KEY` |
354
- | **Mistral** | Cloud | mistral-small-4 | `GNOSYS_MISTRAL_KEY` |
357
+ | **xAI** | Cloud | grok-3 | `GNOSYS_XAI_KEY` |
358
+ | **Mistral** | Cloud | mistral-small-latest | `GNOSYS_MISTRAL_KEY` |
355
359
  | **Custom** | Any | (user-defined) | `GNOSYS_CUSTOM_KEY` |
356
360
 
357
361
  > Model lists and pricing are fetched dynamically from [OpenRouter](https://openrouter.ai) during `gnosys setup` and cached for 24 hours. Bundled defaults are used when offline.
@@ -422,9 +426,9 @@ gnosys import events.jsonl --format jsonl \
422
426
  | Aspect | Plain Markdown | RAG (Vector DB) | Knowledge Graph | **Gnosys** |
423
427
  |--------|---------------|-----------------|-----------------|-----------|
424
428
  | **Examples** | CLAUDE.md, .cursorrules | Mem0, LangChain Memory | Graphiti/Zep, Mem0 Graph | — |
425
- | **Storage** | `.md` files | Embeddings in vector DB | Nodes/edges in graph DB | Unified SQLite DB + `.md` dual-write |
426
- | **Transparency** | Perfect | Lossy (embeddings) | High (query nodes) | High (SQLite + dual-write `.md` + Obsidian export) |
427
- | **Version history** | Git native | None built-in | None built-in | Dual-write `.md` files (optional Git) |
429
+ | **Storage** | `.md` files | Embeddings in vector DB | Nodes/edges in graph DB | Central SQLite DB (on-demand Obsidian export) |
430
+ | **Transparency** | Perfect | Lossy (embeddings) | High (query nodes) | High (SQLite + audit log + Obsidian export) |
431
+ | **Version history** | Git native | None built-in | None built-in | Audit log table in SQLite |
428
432
  | **Keyword search** | Manual / grep | BM25 layer (some) | BM25 layer (some) | FTS5 (built-in) |
429
433
  | **Semantic search** | None | Vector similarity | Graph + vectors | Vector + FTS5 hybrid (RRF) |
430
434
  | **Relationship traversal** | None | None | Multi-hop graph queries | Wikilinks (manual encoding) |
@@ -457,7 +461,11 @@ All commands support `--json` for programmatic output. See the [User Guide](http
457
461
 
458
462
  **Export & config:** `export`, `setup`, `config show`, `config set`, `dashboard`, `doctor`, `stores`
459
463
 
460
- **Centralized brain:** `projects`, `backup`, `restore`, `migrate`, `pref set/get/delete`, `sync`, `ambiguity`, `briefing`, `working-set`
464
+ **Portfolio & status:** `status`, `status --global`, `status --web`, `portfolio`, `update-status`
465
+
466
+ **Centralized brain:** `backup`, `restore`, `migrate`, `pref set/get/delete`, `sync`, `ambiguity`, `briefing`, `working-set`
467
+
468
+ **Multimodal ingestion:** `ingest-file` (PDF, image, audio, video, DOCX)
461
469
 
462
470
  **Sandbox:** `sandbox start/stop/status`, `helper generate`
463
471
 
@@ -472,13 +480,13 @@ All commands support `--json` for programmatic output. See the [User Guide](http
472
480
  ```bash
473
481
  npm install # Install dependencies
474
482
  npm run build # Compile TypeScript
475
- npm test # Run test suite (558 tests)
483
+ npm test # Run test suite (718 tests)
476
484
  npm run test:watch # Run tests in watch mode
477
- npm run test:coverage # Run tests with v8 coverage report
485
+ npm run test:coverage # Run tests with v8 coverage report (HTML in coverage/)
478
486
  npm run dev # Run MCP server in dev mode (tsx)
479
487
  ```
480
488
 
481
- 558 tests across 35+ files. CI runs on Node 20 + 22 with multi-project scenario testing, network-share simulation, and TypeScript strict checking.
489
+ 718 tests across 35+ files. CI runs on Node 20 + 22 with multi-project scenario testing, network-share simulation, and TypeScript strict checking. Publishing uses OIDC trusted publishing via GitHub Actions — no npm tokens needed.
482
490
 
483
491
  ---
484
492
 
@@ -491,14 +499,14 @@ src/
491
499
  lib/
492
500
  db.ts # Central SQLite (6-table schema, project_id + scope)
493
501
  dbSearch.ts # Adapter bridging GnosysDB to search interfaces
494
- dbWrite.ts # Dual-write helpers (sync .md <-> gnosys.db)
502
+ dbWrite.ts # DB write helpers (SQLite sole source of truth)
495
503
  migrate.ts # Migration: v1.x -> v2.0 -> central DB
496
504
  dream.ts # Dream Mode engine + idle scheduler
497
505
  export.ts # Obsidian Export Bridge (gnosys.db -> vault)
498
506
  federated.ts # Federated search, ambiguity detection, briefings
499
507
  preferences.ts # User preferences as scoped memories
500
508
  rulesGen.ts # Agent rules generation (GNOSYS:START/END blocks)
501
- store.ts # Core: read/write/update memory files (.md)
509
+ store.ts # Bootstrap/import of external markdown files
502
510
  search.ts # FTS5 search and discovery
503
511
  embeddings.ts # Lazy semantic embeddings (all-MiniLM-L6-v2)
504
512
  hybridSearch.ts # Hybrid search with RRF fusion
@@ -513,9 +521,20 @@ src/
513
521
  config.ts # gnosys.json loader with Zod validation
514
522
  resolver.ts # Layered multi-store resolution + MCP roots
515
523
  import.ts # Bulk import engine (CSV, JSON, JSONL)
516
- staticSearch.ts # Zero-dep web search runtime (gnosys/web)
517
- webIndex.ts # Build-time inverted index generator
518
- webIngest.ts # Site crawler (sitemap -> markdown)
524
+ portfolio.ts # Portfolio dashboard (single/global project status)
525
+ portfolioHtml.ts # HTML dashboard renderer for gnosys status --web
526
+ # Multimodal ingestion
527
+ multimodalIngest.ts # Orchestrator for multi-format file ingestion
528
+ attachments.ts # Attachment storage and linking
529
+ pdfExtract.ts # PDF text/structure extraction
530
+ imageExtract.ts # Image description via vision models
531
+ audioExtract.ts # Audio transcription
532
+ videoExtract.ts # Video transcription and frame extraction
533
+ # Web Knowledge Base
534
+ staticSearch.ts # Zero-dep web search runtime (gnosys/web)
535
+ structuredIngest.ts # No-LLM fallback with TF-IDF keyword extraction
536
+ webIndex.ts # Build-time inverted index generator
537
+ webIngest.ts # Site crawler (sitemap -> markdown)
519
538
  sandbox/
520
539
  server.ts # Unix socket server + Dream Mode scheduler
521
540
  client.ts # Client for agent connections
@@ -537,9 +556,9 @@ Real numbers from a 120-memory test vault:
537
556
  | Reindex 120 embeddings | ~8s (first run downloads ~80 MB model) |
538
557
  | Maintenance dry-run (120 memories) | ~2s |
539
558
  | Graph reindex (120 memories) | <1s |
540
- | Storage per memory | ~1 KB `.md` file |
559
+ | Storage per memory | ~1 KB (SQLite row) |
541
560
  | Embedding storage (120 memories) | ~0.3 MB |
542
- | Test suite | 558 tests, 0 errors |
561
+ | Test suite | 718 tests, 0 errors |
543
562
 
544
563
  All benchmarks on Apple M-series hardware, Node.js 20+. Structured imports bypass LLM entirely.
545
564
 
@@ -565,7 +584,8 @@ Gnosys is open source (MIT) and actively developed. Here's how to get involved:
565
584
  - Graph visualization in the dashboard
566
585
  - Obsidian community plugin for native vault integration
567
586
  - Docker Hub published image for one-line deployment
568
- - Multimodal memory ingestion (PDFs, images, audio/video transcription)
587
+ - Improved test coverage targets
588
+ - Automated CHANGELOG generation
569
589
 
570
590
  ---
571
591
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "gnosys",
3
- "version": "5.2.19",
3
+ "version": "5.2.21",
4
4
  "description": "Gnosys — Persistent Memory for AI Agents. Sandbox-first runtime, central SQLite brain, federated search, Dream Mode, Web Knowledge Base, Obsidian export.",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",