@aeriondyseti/vector-memory-mcp 2.0.0 → 2.1.1-dev.0
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 +39 -8
- package/package.json +1 -1
- package/src/config/index.ts +11 -2
- package/src/services/conversation.service.ts +32 -12
- package/src/types/conversation.ts +13 -0
package/README.md
CHANGED
|
@@ -103,14 +103,45 @@ Assistant: [calls search_memories with history_only: true, history_before/after
|
|
|
103
103
|
|
|
104
104
|
CLI flags:
|
|
105
105
|
|
|
106
|
-
| Flag | Default | Description |
|
|
107
|
-
|
|
108
|
-
| `--db-file
|
|
109
|
-
| `--port
|
|
110
|
-
| `--no-http` | *(HTTP enabled)* | Disable HTTP/SSE transport |
|
|
111
|
-
| `--enable-history` | *(disabled)* | Enable conversation history indexing |
|
|
112
|
-
| `--history-path` | *(auto-detect)* | Path to session log directory |
|
|
113
|
-
| `--history-weight` | `0.75` | Weight for history results in unified search |
|
|
106
|
+
| Flag | Alias | Default | Description |
|
|
107
|
+
|------|-------|---------|-------------|
|
|
108
|
+
| `--db-file <path>` | `-d` | `.vector-memory/memories.db` | Database location (relative to cwd) |
|
|
109
|
+
| `--port <number>` | `-p` | `3271` | HTTP server port |
|
|
110
|
+
| `--no-http` | | *(HTTP enabled)* | Disable HTTP/SSE transport |
|
|
111
|
+
| `--enable-history` | | *(disabled)* | Enable conversation history indexing |
|
|
112
|
+
| `--history-path` | | *(auto-detect)* | Path to session log directory |
|
|
113
|
+
| `--history-weight` | | `0.75` | Weight for history results in unified search |
|
|
114
|
+
|
|
115
|
+
---
|
|
116
|
+
|
|
117
|
+
## Release Channels
|
|
118
|
+
|
|
119
|
+
The stable release is what you get by default:
|
|
120
|
+
|
|
121
|
+
```bash
|
|
122
|
+
bun install -g @aeriondyseti/vector-memory-mcp
|
|
123
|
+
```
|
|
124
|
+
|
|
125
|
+
Pre-release channels are available for testing upcoming changes. **These are unstable and may break without notice — use at your own risk.**
|
|
126
|
+
|
|
127
|
+
| Channel | Install | Description |
|
|
128
|
+
|---------|---------|-------------|
|
|
129
|
+
| `@latest` | *(default)* | Stable releases |
|
|
130
|
+
| `@rc` | `@aeriondyseti/vector-memory-mcp@rc` | Release candidates — final testing before stable |
|
|
131
|
+
| `@dev` | `@aeriondyseti/vector-memory-mcp@dev` | Development builds — latest features, least stable |
|
|
132
|
+
|
|
133
|
+
```bash
|
|
134
|
+
# Install the dev channel
|
|
135
|
+
bun install -g @aeriondyseti/vector-memory-mcp@dev
|
|
136
|
+
|
|
137
|
+
# Pin to a specific pre-release version
|
|
138
|
+
bun install -g @aeriondyseti/vector-memory-mcp@2.1.0-dev.1
|
|
139
|
+
|
|
140
|
+
# Go back to stable
|
|
141
|
+
bun install -g @aeriondyseti/vector-memory-mcp@latest
|
|
142
|
+
```
|
|
143
|
+
|
|
144
|
+
> **Warning:** Pre-release versions may include breaking changes, incomplete features, or data migration requirements that haven't been finalized. Do not use them in production workflows you depend on.
|
|
114
145
|
|
|
115
146
|
---
|
|
116
147
|
|
package/package.json
CHANGED
package/src/config/index.ts
CHANGED
|
@@ -59,10 +59,19 @@ export function loadConfig(overrides: ConfigOverrides = {}): Config {
|
|
|
59
59
|
const enableHttp = overrides.enableHttp ?? true;
|
|
60
60
|
|
|
61
61
|
return {
|
|
62
|
-
dbPath: resolvePath(
|
|
62
|
+
dbPath: resolvePath(
|
|
63
|
+
overrides.dbPath
|
|
64
|
+
?? process.env.VECTOR_MEMORY_DB_PATH
|
|
65
|
+
?? DEFAULT_DB_PATH
|
|
66
|
+
),
|
|
63
67
|
embeddingModel: DEFAULT_EMBEDDING_MODEL,
|
|
64
68
|
embeddingDimension: DEFAULT_EMBEDDING_DIMENSION,
|
|
65
|
-
httpPort:
|
|
69
|
+
httpPort:
|
|
70
|
+
overrides.httpPort
|
|
71
|
+
?? (process.env.VECTOR_MEMORY_HTTP_PORT
|
|
72
|
+
? parseInt(process.env.VECTOR_MEMORY_HTTP_PORT, 10)
|
|
73
|
+
: undefined)
|
|
74
|
+
?? DEFAULT_HTTP_PORT,
|
|
66
75
|
httpHost: DEFAULT_HTTP_HOST,
|
|
67
76
|
enableHttp,
|
|
68
77
|
transportMode,
|
|
@@ -9,6 +9,7 @@ import type {
|
|
|
9
9
|
IndexedSession,
|
|
10
10
|
ParsedMessage,
|
|
11
11
|
SessionFileInfo,
|
|
12
|
+
SessionIndexDetail,
|
|
12
13
|
} from "../types/conversation.js";
|
|
13
14
|
import type { ConversationHistoryConfig } from "../config/index.js";
|
|
14
15
|
import { resolveSessionLogPath } from "../config/index.js";
|
|
@@ -175,12 +176,18 @@ export class ConversationHistoryService {
|
|
|
175
176
|
async indexConversations(
|
|
176
177
|
path?: string,
|
|
177
178
|
since?: Date
|
|
178
|
-
): Promise<{
|
|
179
|
+
): Promise<{
|
|
180
|
+
indexed: number;
|
|
181
|
+
skipped: number;
|
|
182
|
+
errors: string[];
|
|
183
|
+
details: SessionIndexDetail[];
|
|
184
|
+
}> {
|
|
179
185
|
if (!this.config.enabled) {
|
|
180
186
|
return {
|
|
181
187
|
indexed: 0,
|
|
182
188
|
skipped: 0,
|
|
183
189
|
errors: ["Conversation history indexing is not enabled"],
|
|
190
|
+
details: [],
|
|
184
191
|
};
|
|
185
192
|
}
|
|
186
193
|
|
|
@@ -190,6 +197,7 @@ export class ConversationHistoryService {
|
|
|
190
197
|
indexed: 0,
|
|
191
198
|
skipped: 0,
|
|
192
199
|
errors: ["No session log path configured or detected"],
|
|
200
|
+
details: [],
|
|
193
201
|
};
|
|
194
202
|
}
|
|
195
203
|
|
|
@@ -203,39 +211,48 @@ export class ConversationHistoryService {
|
|
|
203
211
|
let indexed = 0;
|
|
204
212
|
let skipped = 0;
|
|
205
213
|
const errors: string[] = [];
|
|
214
|
+
const details: SessionIndexDetail[] = [];
|
|
206
215
|
|
|
207
216
|
for (const file of sessionFiles) {
|
|
208
217
|
const existing = indexState.get(file.sessionId);
|
|
209
218
|
if (existing && existing.lastModified >= file.lastModified.getTime()) {
|
|
210
219
|
skipped++;
|
|
220
|
+
details.push({ sessionId: file.sessionId, project: file.project, status: "skipped" });
|
|
211
221
|
continue;
|
|
212
222
|
}
|
|
213
223
|
|
|
214
224
|
try {
|
|
215
|
-
await this.indexSession(file, indexState);
|
|
225
|
+
const state = await this.indexSession(file, indexState);
|
|
216
226
|
indexed++;
|
|
227
|
+
details.push({
|
|
228
|
+
sessionId: file.sessionId,
|
|
229
|
+
project: file.project,
|
|
230
|
+
status: "indexed",
|
|
231
|
+
chunks: state.chunkCount,
|
|
232
|
+
messages: state.messageCount,
|
|
233
|
+
});
|
|
217
234
|
} catch (err) {
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
);
|
|
235
|
+
const message = err instanceof Error ? err.message : String(err);
|
|
236
|
+
errors.push(`${file.sessionId}: ${message}`);
|
|
237
|
+
details.push({ sessionId: file.sessionId, project: file.project, status: "error", error: message });
|
|
221
238
|
}
|
|
222
239
|
}
|
|
223
240
|
|
|
224
241
|
await this.saveIndexState(indexState);
|
|
225
|
-
return { indexed, skipped, errors };
|
|
242
|
+
return { indexed, skipped, errors, details };
|
|
226
243
|
}
|
|
227
244
|
|
|
228
245
|
private async indexSession(
|
|
229
246
|
file: SessionFileInfo,
|
|
230
247
|
indexState: Map<string, IndexedSession>
|
|
231
|
-
): Promise<
|
|
248
|
+
): Promise<IndexedSession> {
|
|
232
249
|
const messages = await this.parser.parse(
|
|
233
250
|
file.filePath,
|
|
234
251
|
this.config.indexSubagents
|
|
235
252
|
);
|
|
236
253
|
if (messages.length === 0) {
|
|
237
254
|
// Still track it so we don't re-attempt
|
|
238
|
-
|
|
255
|
+
const session: IndexedSession = {
|
|
239
256
|
sessionId: file.sessionId,
|
|
240
257
|
filePath: file.filePath,
|
|
241
258
|
project: file.project,
|
|
@@ -245,8 +262,9 @@ export class ConversationHistoryService {
|
|
|
245
262
|
indexedAt: new Date(),
|
|
246
263
|
firstMessageAt: file.lastModified,
|
|
247
264
|
lastMessageAt: file.lastModified,
|
|
248
|
-
}
|
|
249
|
-
|
|
265
|
+
};
|
|
266
|
+
indexState.set(file.sessionId, session);
|
|
267
|
+
return session;
|
|
250
268
|
}
|
|
251
269
|
|
|
252
270
|
const chunks = chunkMessages(
|
|
@@ -280,7 +298,7 @@ export class ConversationHistoryService {
|
|
|
280
298
|
await this.repository.insertBatch(rows);
|
|
281
299
|
|
|
282
300
|
// Update index state
|
|
283
|
-
|
|
301
|
+
const session: IndexedSession = {
|
|
284
302
|
sessionId: file.sessionId,
|
|
285
303
|
filePath: file.filePath,
|
|
286
304
|
project: file.project,
|
|
@@ -290,7 +308,9 @@ export class ConversationHistoryService {
|
|
|
290
308
|
indexedAt: new Date(),
|
|
291
309
|
firstMessageAt: messages[0].timestamp,
|
|
292
310
|
lastMessageAt: messages[messages.length - 1].timestamp,
|
|
293
|
-
}
|
|
311
|
+
};
|
|
312
|
+
indexState.set(file.sessionId, session);
|
|
313
|
+
return session;
|
|
294
314
|
}
|
|
295
315
|
|
|
296
316
|
async reindexSession(
|
|
@@ -90,6 +90,19 @@ export interface SessionFileInfo {
|
|
|
90
90
|
lastModified: Date;
|
|
91
91
|
}
|
|
92
92
|
|
|
93
|
+
/** Outcome status for a single session during indexing */
|
|
94
|
+
export type IndexStatus = "indexed" | "skipped" | "error";
|
|
95
|
+
|
|
96
|
+
/** Per-session detail returned from indexConversations */
|
|
97
|
+
export interface SessionIndexDetail {
|
|
98
|
+
sessionId: string;
|
|
99
|
+
project: string;
|
|
100
|
+
status: IndexStatus;
|
|
101
|
+
chunks?: number;
|
|
102
|
+
messages?: number;
|
|
103
|
+
error?: string;
|
|
104
|
+
}
|
|
105
|
+
|
|
93
106
|
/** Search filter options for conversation history */
|
|
94
107
|
export interface HistoryFilters {
|
|
95
108
|
sessionId?: string;
|