vektor-slipstream 1.4.2 → 1.4.4

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 (4) hide show
  1. package/README.md +179 -114
  2. package/package.json +2 -2
  3. package/vektor-cli.js +221 -444
  4. package/vektor-setup.js +270 -266
package/README.md CHANGED
@@ -3,6 +3,7 @@
3
3
  Hardware-accelerated persistent memory for AI agents. Local-first. No cloud. One-time payment.
4
4
 
5
5
  [![npm](https://img.shields.io/npm/v/vektor-slipstream)](https://www.npmjs.com/package/vektor-slipstream)
6
+ [![downloads](https://img.shields.io/npm/dw/vektor-slipstream)](https://www.npmjs.com/package/vektor-slipstream)
6
7
  [![license](https://img.shields.io/badge/license-Commercial-blue)](https://vektormemory.com/product#pricing)
7
8
 
8
9
  ## Install
@@ -39,7 +40,83 @@ const delta = await memory.delta('project decisions', 7);
39
40
  const brief = await memory.briefing();
40
41
  ```
41
42
 
42
- ## CLI
43
+ ---
44
+
45
+ ## CLI Chat — Persistent Memory Terminal
46
+
47
+ Chat with any LLM with full memory across every session. Zero configuration.
48
+
49
+ ```bash
50
+ npx vektor chat # start chat (auto-detects Ollama)
51
+ npx vektor chat --provider claude # use Anthropic Claude
52
+ npx vektor chat --provider groq --model llama-3.3-70b-versatile
53
+ npx vektor chat --provider gemini
54
+ npx vektor chat --provider openai
55
+ ```
56
+
57
+ ### Providers
58
+
59
+ | Provider | Details |
60
+ |---|---|
61
+ | `ollama` | Default — free, local, no API key. Auto-detects best installed model. |
62
+ | `claude` | Anthropic Claude — set `ANTHROPIC_API_KEY` |
63
+ | `openai` | OpenAI GPT — set `OPENAI_API_KEY` |
64
+ | `groq` | Groq LLaMA — set `GROQ_API_KEY` (free tier available) |
65
+ | `gemini` | Google Gemini — set `GEMINI_API_KEY` |
66
+
67
+ Set a permanent default:
68
+ ```bash
69
+ # Windows
70
+ $env:VEKTOR_PROVIDER = "claude"
71
+
72
+ # macOS/Linux
73
+ export VEKTOR_PROVIDER=claude
74
+ ```
75
+
76
+ ### In-chat commands
77
+
78
+ Type `/` to see available commands with autocomplete. Tab to select, arrow keys to navigate.
79
+
80
+ | Command | Action |
81
+ |---|---|
82
+ | `/recall <query>` | Search MAGMA memory mid-conversation |
83
+ | `/stats` | Show memory node count, edges, pinned |
84
+ | `/briefing` | Generate memory briefing inline |
85
+ | `/exit` | Exit chat (Ctrl+C also works) |
86
+
87
+ ### One-liner commands
88
+
89
+ ```bash
90
+ # Store a fact
91
+ npx vektor remember "I prefer TypeScript over JavaScript"
92
+ npx vektor remember "deadline is Friday" --importance 5
93
+
94
+ # Pipe support
95
+ cat meeting-notes.txt | npx vektor remember
96
+
97
+ # One-shot recall + LLM answer
98
+ npx vektor ask "what stack am I using?"
99
+ npx vektor ask "what did we decide about the database?"
100
+
101
+ # Autonomous goal executor
102
+ npx vektor agent "summarise everything I know about project Alpha"
103
+ npx vektor agent "research AI memory tools" --steps 15 --provider groq
104
+ ```
105
+
106
+ ### Ollama auto-detection
107
+
108
+ VEKTOR queries `http://localhost:11434/api/tags` and picks the best available model:
109
+ `qwen3` → `qwen2` → `llama` → `mistral` → first available.
110
+
111
+ Override:
112
+ ```bash
113
+ $env:OLLAMA_MODEL = "qwen3.5:4b"
114
+ export OLLAMA_MODEL=qwen3.5:4b
115
+ ```
116
+
117
+ ---
118
+
119
+ ## All CLI Commands
43
120
 
44
121
  ```bash
45
122
  npx vektor setup # First-run wizard — licence, hardware, integrations
@@ -48,49 +125,110 @@ npx vektor test # Test memory engine with progress bar
48
125
  npx vektor status # System health check
49
126
  npx vektor mcp # Start Claude Desktop MCP server
50
127
  npx vektor rem # Run REM dream cycle
51
- npx vektor chat # Persistent memory chat (all LLMs)
52
- npx vektor remember # Store a fact: npx vektor remember "I prefer TypeScript"
53
- npx vektor ask # Query memory: npx vektor ask "what stack am I using?"
54
- npx vektor agent # Autonomous goal executor
128
+ npx vektor chat # Persistent memory chat (all LLMs)
129
+ npx vektor remember # Store a fact
130
+ npx vektor ask # Query memory + LLM answer
131
+ npx vektor agent # Autonomous goal executor
55
132
  npx vektor help # All commands
56
133
  ```
57
134
 
58
- ## CLOAK — Developer Context Layer for Claude Code
135
+ ---
136
+
137
+ ## Claude Desktop Extension (DXT)
138
+
139
+ Install the `.dxt` extension for zero-config memory in every Claude Desktop session.
140
+
141
+ **Install:** drag `vektor-slipstream.dxt` onto the Claude Desktop Extensions page.
142
+
143
+ Once installed, Claude automatically:
144
+ - Recalls relevant context at session start
145
+ - Stores facts and decisions during conversation
146
+ - Summarises at session end
59
147
 
60
- CLOAK is a 4-tool MCP layer that gives Claude Code persistent memory of your project.
61
- Every session starts with full context. Every error is remembered. Every wasted token is tracked.
148
+ All 28 tools are available in Claude Desktop no configuration needed beyond your licence key.
62
149
 
63
- ### What it does
150
+ **User config fields:**
64
151
 
65
- | Tool | Does exactly one thing |
152
+ | Field | Purpose |
66
153
  |---|---|
67
- | `cloak_cortex` | Scans project files, builds a token-aware anatomy index in Vektor's entity graph |
68
- | `cloak_axon` | Session boundary handler loads last context on start, saves MemCell on stop |
69
- | `cloak_cerebellum` | Pre-write enforcer checks writes against known error patterns, auto-resolves fixes |
70
- | `cloak_token` | Token ledger — detects repeated reads and waste, one summary write per session |
154
+ | `licence_key` | Your Polar licence key (required) |
155
+ | `db_path` | Memory DB path (defaults to `~/vektor-slipstream-memory.db`) |
156
+ | `project_path` | Default path for `cloak_cortex` project scanning (optional) |
71
157
 
72
- ### Import
158
+ Download the latest `.dxt` from [vektormemory.com/docs/dxt](https://vektormemory.com/docs/dxt).
73
159
 
74
- ```js
75
- const { runCortex } = require('vektor-slipstream/cloak/cortex');
76
- const { onSessionStart,
77
- onSessionStop } = require('vektor-slipstream/cloak/axon');
78
- const { checkWrite,
79
- recordError } = require('vektor-slipstream/cloak/cerebellum');
80
- const { getSessionSummary} = require('vektor-slipstream/cloak/token');
81
-
82
- // Clean terminal output (replaces emoji with box-drawing chars)
83
- const { createMemory } = require('vektor-slipstream/boot');
84
- ```
160
+ ---
161
+
162
+ ## MCP Tools — All 28
163
+
164
+ ### Memory Tools
85
165
 
86
- ### Claude Code setup
166
+ | Tool | Function |
167
+ |---|---|
168
+ | `vektor_recall` | Semantic search across MAGMA graph |
169
+ | `vektor_store` | Store memory with importance score |
170
+ | `vektor_graph` | Traverse associative memory graph |
171
+ | `vektor_delta` | See what changed on a topic over time |
172
+ | `vektor_briefing` | Generate morning briefing from recent memories |
173
+
174
+ ### CLOAK Core
175
+
176
+ | Tool | Function |
177
+ |---|---|
178
+ | `cloak_fetch` | Stealth headless browser fetch via Playwright |
179
+ | `cloak_fetch_smart` | Checks `llms.txt` first, falls back to stealth browser |
180
+ | `cloak_render` | Full CSS/DOM layout sensor |
181
+ | `cloak_diff` | Semantic diff of URL since last fetch |
182
+ | `cloak_diff_text` | Structural diff between two text blobs |
183
+ | `cloak_passport` | AES-256-GCM credential vault (get/set/delete/list) |
184
+ | `tokens_saved` | Token efficiency ROI calculator |
185
+
186
+ ### Identity Tools
187
+
188
+ | Tool | Function |
189
+ |---|---|
190
+ | `cloak_identity_create` | Create persistent browser fingerprint identity |
191
+ | `cloak_identity_use` | Apply saved identity to a fetch call |
192
+ | `cloak_identity_list` | List all saved identities with trust summary |
193
+
194
+ ### Behaviour Tools
195
+
196
+ | Tool | Function |
197
+ |---|---|
198
+ | `cloak_inject_behaviour` | Human mouse/scroll injection for reCAPTCHA/Cloudflare bypass |
199
+ | `cloak_behaviour_stats` | List available patterns and categories |
200
+ | `cloak_load_pattern` | Load custom recorded behaviour pattern |
201
+ | `cloak_pattern_stats` | Self-improving pattern store tier breakdown |
202
+ | `cloak_pattern_list` | List patterns with scores and tier |
203
+ | `cloak_pattern_prune` | Remove stale/low-scoring patterns |
204
+ | `cloak_pattern_seed` | Seed store with built-in patterns |
205
+
206
+ ### CAPTCHA Tools
207
+
208
+ | Tool | Function |
209
+ |---|---|
210
+ | `cloak_detect_captcha` | Detect CAPTCHA type and sitekey |
211
+ | `cloak_solve_captcha` | Solve via vision AI (Claude/GPT-4o/2captcha) |
212
+
213
+ ### Compression & Cortex Tools
214
+
215
+ | Tool | Function |
216
+ |---|---|
217
+ | `turbo_quant_compress` | PolarQuant vector compression (~75% smaller) |
218
+ | `turbo_quant_stats` | Compression ratio and savings stats |
219
+ | `cloak_cortex` | Scan project directory into MAGMA entity graph |
220
+ | `cloak_cortex_anatomy` | Get cached file anatomy without rescanning |
221
+
222
+ ---
223
+
224
+ ## Claude Code Setup
87
225
 
88
226
  Add to `.claude/settings.json` in your project:
89
227
 
90
228
  ```json
91
229
  {
92
230
  "mcpServers": {
93
- "cloak": {
231
+ "vektor": {
94
232
  "command": "node",
95
233
  "args": ["/path/to/node_modules/vektor-slipstream/index.js"],
96
234
  "env": {
@@ -98,70 +236,11 @@ Add to `.claude/settings.json` in your project:
98
236
  "CLOAK_PROJECT_PATH": "/path/to/your/project"
99
237
  }
100
238
  }
101
- },
102
- "hooks": {
103
- "SessionStart": [{ "type": "command", "command": "node /path/to/node_modules/vektor-slipstream/index.js --hook SessionStart" }],
104
- "Stop": [{ "type": "command", "command": "node /path/to/node_modules/vektor-slipstream/index.js --hook Stop" }],
105
- "PreToolUse": [{ "type": "command", "command": "node /path/to/node_modules/vektor-slipstream/index.js --hook PreToolUse" }],
106
- "PostToolUse": [{ "type": "command", "command": "node /path/to/node_modules/vektor-slipstream/index.js --hook PostToolUse" }]
107
239
  }
108
240
  }
109
241
  ```
110
242
 
111
- ### Usage
112
-
113
- ```js
114
- // Scan project files into Vektor entity graph (call once on init)
115
- await cloak_cortex({})
116
-
117
- // Start session — loads last context automatically
118
- await cloak_axon({ action: 'start' })
119
-
120
- // Check before a risky write
121
- await cloak_cerebellum({
122
- action: 'check',
123
- content: '...code...',
124
- filePath: 'src/auth.ts'
125
- })
126
-
127
- // Record a bug you just hit
128
- await cloak_cerebellum({
129
- action: 'record_error',
130
- description: 'Null ref on user.id when DB returns empty',
131
- filePath: 'src/auth.ts',
132
- errorType: 'null_reference',
133
- fix: 'Add guard: if (user && user.id)'
134
- })
135
-
136
- // Save session with intent — the "why" not just the "what"
137
- await cloak_axon({
138
- action: 'stop',
139
- narrative: 'Fixed null reference in auth module'
140
- })
141
-
142
- // Check token waste
143
- await cloak_token({ action: 'summary' })
144
- ```
145
-
146
- ### Architecture
147
-
148
- ```
149
- Claude Code
150
- ↓ hooks + MCP tool calls
151
- CLOAK (4 tools, ~800 lines Node.js)
152
- ↓ memory.remember() / memory.recall()
153
- Vektor / MAGMA
154
- ↓ 4-layer graph (semantic, temporal, causal, entity)
155
- SQLite-vec (local, no cloud)
156
- ```
157
-
158
- ### DB growth
159
-
160
- CLOAK writes 3-5 nodes per session — not per operation.
161
- At 1 year of daily use: ~1,000 nodes. Sub-millisecond recall throughout.
162
-
163
- > ⚠️ **Concurrency warning**: Use stdio MCP (default). The HTTP mode
164
- > (`CLOAK_HTTP=1`) does not support concurrent multi-agent sessions.
243
+ All 28 tools are available in Claude Code via this config.
165
244
 
166
245
  ---
167
246
 
@@ -177,37 +256,19 @@ At 1 year of daily use: ~1,000 nodes. Sub-millisecond recall throughout.
177
256
 
178
257
  ### Integrations
179
258
 
180
- - **Claude MCP** — `vektor_recall`, `vektor_store`, `vektor_graph`, `vektor_delta`
181
- - **Claude Code** — CLOAK 4-tool developer context layer (see above)
259
+ - **Claude Desktop** — DXT extension, 28 tools, auto-memory system prompt
260
+ - **Claude Code** — MCP server, all 28 tools
261
+ - **CLI** — `chat`, `remember`, `ask`, `agent` commands
182
262
  - **LangChain** — v1 + v2 adapter included
183
263
  - **OpenAI Agents SDK** — drop-in integration
184
- - **Mistral** — `vektor_memoire` HTTP tool, localhost bridge
185
264
  - **Gemini · Groq · Ollama** — provider agnostic
186
265
 
187
- ### Cloak (Sovereign Identity)
188
-
189
- - `cloak_fetch` — stealth headless browser fetch
190
- - `cloak_render` — computed CSS · post-JS DOM sensor
191
- - `cloak_passport` — AES-256-GCM credential vault, machine-bound
192
- - `cloak_diff` — semantic diff since last fetch
193
- - `tokens_saved` — ROI audit per session
194
-
195
- ```js
196
- const { cloak_passport, cloak_fetch, tokens_saved } = require('vektor-slipstream/cloak');
197
-
198
- cloak_passport('GITHUB_TOKEN', 'ghp_xxxx');
199
- const token = cloak_passport('GITHUB_TOKEN');
200
-
201
- const { text, tokensSaved } = await cloak_fetch('https://example.com');
202
-
203
- const roi = tokens_saved({ raw_tokens: 10000, actual_tokens: 3000 });
204
- // → { reduction_pct: 70, cost_saved_usd: 0.0175, roi_multiple: 2.3 }
205
- ```
266
+ ---
206
267
 
207
268
  ## Performance
208
269
 
209
270
  | Metric | Value |
210
- |--------|-------|
271
+ |---|---|
211
272
  | Recall latency | ~8ms avg (local SQLite) |
212
273
  | Embedding cost | $0 — fully local ONNX |
213
274
  | Embedding latency | ~10ms GPU / ~25ms CPU |
@@ -222,15 +283,19 @@ Zero config. VEKTOR detects and uses the best available accelerator:
222
283
  - **Apple Silicon** — CoreML
223
284
  - **CPU** — optimised fallback, works everywhere
224
285
 
286
+ ---
287
+
225
288
  ## Licence
226
289
 
227
290
  Commercial licence. One-time payment of $159. Activates on up to 3 machines.
228
291
  Manage at [polar.sh](https://polar.sh).
229
292
 
230
- Purchase: [vektormemory.com/product#pricing](https://vektormemory.com/product#pricing)
231
- Docs: [vektormemory.com/docs](https://vektormemory.com/docs)
293
+ Purchase: [vektormemory.com/product#pricing](https://vektormemory.com/product#pricing)
294
+ Docs: [vektormemory.com/docs](https://vektormemory.com/docs)
232
295
  Support: hello@vektormemory.com
233
296
 
297
+ ---
298
+
234
299
  ## Research
235
300
 
236
301
  Built on peer-reviewed research:
@@ -238,4 +303,4 @@ Built on peer-reviewed research:
238
303
  - [MAGMA (arxiv:2601.03236)](https://arxiv.org/abs/2601.03236) — Multi-Graph Agentic Memory Architecture
239
304
  - [EverMemOS (arxiv:2601.02163)](https://arxiv.org/abs/2601.02163) — Self-Organizing Memory OS
240
305
  - [HippoRAG (arxiv:2405.14831)](https://arxiv.org/abs/2405.14831) — Neurobiologically Inspired Long-Term Memory (NeurIPS 2024)
241
- - [Mem0 (arxiv:2504.19413)](https://arxiv.org/abs/2504.19413) — Production-Ready Agent Memory
306
+ - [Mem0 (arxiv:2504.19413)](https://arxiv.org/abs/2504.19413) — Production-Ready Agent Memory
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "vektor-slipstream",
3
- "version": "1.4.2",
3
+ "version": "1.4.4",
4
4
  "description": "Hardware-accelerated persistent memory for AI agents. Local-first, zero cloud dependency, $0 embedding cost.",
5
5
  "main": "slipstream-core-extended.js",
6
6
  "types": "./types/index.d.ts",
@@ -72,7 +72,7 @@
72
72
  "dependencies": {
73
73
  "better-sqlite3": "^12.8.0",
74
74
  "onnxruntime-node": "^1.17.3",
75
- "vektor-slipstream": "^1.4.1"
75
+ "vektor-slipstream": "^1.4.4"
76
76
  },
77
77
  "optionalDependencies": {
78
78
  "@anthropic-ai/sdk": "^0.82.0",