@openparachute/vault 0.7.9-rc.2 → 0.7.9-rc.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 (38) hide show
  1. package/core/src/core.test.ts +546 -0
  2. package/core/src/cursor.ts +1 -0
  3. package/core/src/link-count.test.ts +29 -0
  4. package/core/src/links.ts +43 -0
  5. package/core/src/mcp-manifest.ts +10 -6
  6. package/core/src/mcp.ts +129 -44
  7. package/core/src/notes.ts +51 -2
  8. package/core/src/schema-v28-unresolved-wikilinks.test.ts +103 -0
  9. package/core/src/schema.ts +28 -1
  10. package/core/src/store.ts +180 -57
  11. package/core/src/txn.test.ts +33 -1
  12. package/core/src/txn.ts +80 -7
  13. package/core/src/types.ts +11 -0
  14. package/core/src/vault-projection.ts +8 -1
  15. package/core/src/wikilinks.ts +873 -44
  16. package/package.json +2 -2
  17. package/src/aggregate-routes.test.ts +76 -0
  18. package/src/config.ts +8 -2
  19. package/src/mcp-http.test.ts +51 -1
  20. package/src/mcp-tools.ts +106 -5
  21. package/src/mirror-routes.test.ts +47 -0
  22. package/src/release-plan.test.ts +90 -1
  23. package/src/routes.ts +280 -66
  24. package/src/routing.test.ts +67 -0
  25. package/src/tag-scope-query-tag.test.ts +374 -0
  26. package/src/tag-scope.ts +116 -0
  27. package/src/test-support/vault-714-find-path.json +58 -0
  28. package/src/test-support/vault-714-graph.json +27 -0
  29. package/src/test-support/vault-714-has_links.json +96 -0
  30. package/src/test-support/vault-714-include_broken_links.json +118 -0
  31. package/src/test-support/vault-714-include_link_count.json +348 -0
  32. package/src/test-support/vault-714-include_links.json +86 -0
  33. package/src/test-support/vault-714-near.json +78 -0
  34. package/src/test-support/vault-714-unresolved-wikilinks.json +6 -0
  35. package/src/vault.test.ts +928 -1
  36. package/src/write-warnings-scope.test.ts +344 -0
  37. package/src/ws-server.ts +16 -3
  38. package/src/ws-subscribe.test.ts +76 -2
@@ -0,0 +1,118 @@
1
+ {
2
+ "MCP": [
3
+ {
4
+ "id": "work-src",
5
+ "content": "src [[Dup]]",
6
+ "path": "work-src",
7
+ "extension": "md",
8
+ "metadata": {},
9
+ "createdAt": "2026-01-01T00:00:00.000Z",
10
+ "updatedAt": "2026-01-01T00:00:00.000Z",
11
+ "createdBy": null,
12
+ "createdVia": null,
13
+ "lastUpdatedBy": null,
14
+ "lastUpdatedVia": null,
15
+ "tags": [
16
+ "work"
17
+ ],
18
+ "broken_links": []
19
+ },
20
+ [],
21
+ [
22
+ {
23
+ "id": "hidden-dup",
24
+ "path": "p1/Dup",
25
+ "extension": "md",
26
+ "createdAt": "2026-01-01T00:00:00.000Z",
27
+ "updatedAt": "2026-01-01T00:00:00.000Z",
28
+ "createdBy": null,
29
+ "createdVia": null,
30
+ "lastUpdatedBy": null,
31
+ "lastUpdatedVia": null,
32
+ "tags": [
33
+ "personal"
34
+ ],
35
+ "metadata": {},
36
+ "byteSize": 12,
37
+ "preview": "personal dup",
38
+ "displayTitle": "personal dup"
39
+ },
40
+ {
41
+ "id": "work-src",
42
+ "path": "work-src",
43
+ "extension": "md",
44
+ "createdAt": "2026-01-01T00:00:00.000Z",
45
+ "updatedAt": "2026-01-01T00:00:00.000Z",
46
+ "createdBy": null,
47
+ "createdVia": null,
48
+ "lastUpdatedBy": null,
49
+ "lastUpdatedVia": null,
50
+ "tags": [
51
+ "work"
52
+ ],
53
+ "metadata": {},
54
+ "byteSize": 11,
55
+ "preview": "src [[Dup]]",
56
+ "displayTitle": "src [[Dup]]"
57
+ }
58
+ ]
59
+ ],
60
+ "REST": [
61
+ {
62
+ "id": "work-src",
63
+ "content": "src [[Dup]]",
64
+ "path": "work-src",
65
+ "extension": "md",
66
+ "metadata": {},
67
+ "createdAt": "2026-01-01T00:00:00.000Z",
68
+ "updatedAt": "2026-01-01T00:00:00.000Z",
69
+ "createdBy": null,
70
+ "createdVia": null,
71
+ "lastUpdatedBy": null,
72
+ "lastUpdatedVia": null,
73
+ "tags": [
74
+ "work"
75
+ ],
76
+ "broken_links": []
77
+ },
78
+ [],
79
+ [
80
+ {
81
+ "id": "hidden-dup",
82
+ "path": "p1/Dup",
83
+ "extension": "md",
84
+ "createdAt": "2026-01-01T00:00:00.000Z",
85
+ "updatedAt": "2026-01-01T00:00:00.000Z",
86
+ "createdBy": null,
87
+ "createdVia": null,
88
+ "lastUpdatedBy": null,
89
+ "lastUpdatedVia": null,
90
+ "tags": [
91
+ "personal"
92
+ ],
93
+ "metadata": {},
94
+ "byteSize": 12,
95
+ "preview": "personal dup",
96
+ "displayTitle": "personal dup"
97
+ },
98
+ {
99
+ "id": "work-src",
100
+ "path": "work-src",
101
+ "extension": "md",
102
+ "createdAt": "2026-01-01T00:00:00.000Z",
103
+ "updatedAt": "2026-01-01T00:00:00.000Z",
104
+ "createdBy": null,
105
+ "createdVia": null,
106
+ "lastUpdatedBy": null,
107
+ "lastUpdatedVia": null,
108
+ "tags": [
109
+ "work"
110
+ ],
111
+ "metadata": {},
112
+ "byteSize": 11,
113
+ "preview": "src [[Dup]]",
114
+ "displayTitle": "src [[Dup]]"
115
+ }
116
+ ]
117
+ ]
118
+ }
@@ -0,0 +1,348 @@
1
+ {
2
+ "MCP": [
3
+ {
4
+ "id": "work-src",
5
+ "content": "src [[Dup]]",
6
+ "path": "work-src",
7
+ "extension": "md",
8
+ "metadata": {},
9
+ "createdAt": "2026-01-01T00:00:00.000Z",
10
+ "updatedAt": "2026-01-01T00:00:00.000Z",
11
+ "createdBy": null,
12
+ "createdVia": null,
13
+ "lastUpdatedBy": null,
14
+ "lastUpdatedVia": null,
15
+ "tags": [
16
+ "work"
17
+ ],
18
+ "linkCount": 1
19
+ },
20
+ [
21
+ {
22
+ "id": "hidden-dup",
23
+ "path": "p1/Dup",
24
+ "extension": "md",
25
+ "createdAt": "2026-01-01T00:00:00.000Z",
26
+ "updatedAt": "2026-01-01T00:00:00.000Z",
27
+ "createdBy": null,
28
+ "createdVia": null,
29
+ "lastUpdatedBy": null,
30
+ "lastUpdatedVia": null,
31
+ "tags": [
32
+ "personal"
33
+ ],
34
+ "metadata": {},
35
+ "byteSize": 12,
36
+ "preview": "personal dup",
37
+ "displayTitle": "personal dup",
38
+ "linkCount": 1
39
+ },
40
+ {
41
+ "id": "work-src",
42
+ "path": "work-src",
43
+ "extension": "md",
44
+ "createdAt": "2026-01-01T00:00:00.000Z",
45
+ "updatedAt": "2026-01-01T00:00:00.000Z",
46
+ "createdBy": null,
47
+ "createdVia": null,
48
+ "lastUpdatedBy": null,
49
+ "lastUpdatedVia": null,
50
+ "tags": [
51
+ "work"
52
+ ],
53
+ "metadata": {},
54
+ "byteSize": 11,
55
+ "preview": "src [[Dup]]",
56
+ "displayTitle": "src [[Dup]]",
57
+ "linkCount": 1
58
+ }
59
+ ],
60
+ {
61
+ "id": "work-src",
62
+ "content": "src [[Dup]]",
63
+ "path": "work-src",
64
+ "extension": "md",
65
+ "metadata": {},
66
+ "createdAt": "2026-01-01T00:00:00.000Z",
67
+ "updatedAt": "2026-01-01T00:00:00.000Z",
68
+ "createdBy": null,
69
+ "createdVia": null,
70
+ "lastUpdatedBy": null,
71
+ "lastUpdatedVia": null,
72
+ "tags": [
73
+ "work"
74
+ ],
75
+ "linkCount": 1
76
+ },
77
+ [
78
+ {
79
+ "id": "hidden-dup",
80
+ "path": "p1/Dup",
81
+ "extension": "md",
82
+ "createdAt": "2026-01-01T00:00:00.000Z",
83
+ "updatedAt": "2026-01-01T00:00:00.000Z",
84
+ "createdBy": null,
85
+ "createdVia": null,
86
+ "lastUpdatedBy": null,
87
+ "lastUpdatedVia": null,
88
+ "tags": [
89
+ "personal"
90
+ ],
91
+ "metadata": {},
92
+ "byteSize": 12,
93
+ "preview": "personal dup",
94
+ "displayTitle": "personal dup",
95
+ "linkCount": 0
96
+ },
97
+ {
98
+ "id": "work-src",
99
+ "path": "work-src",
100
+ "extension": "md",
101
+ "createdAt": "2026-01-01T00:00:00.000Z",
102
+ "updatedAt": "2026-01-01T00:00:00.000Z",
103
+ "createdBy": null,
104
+ "createdVia": null,
105
+ "lastUpdatedBy": null,
106
+ "lastUpdatedVia": null,
107
+ "tags": [
108
+ "work"
109
+ ],
110
+ "metadata": {},
111
+ "byteSize": 11,
112
+ "preview": "src [[Dup]]",
113
+ "displayTitle": "src [[Dup]]",
114
+ "linkCount": 1
115
+ }
116
+ ],
117
+ {
118
+ "id": "work-src",
119
+ "content": "src [[Dup]]",
120
+ "path": "work-src",
121
+ "extension": "md",
122
+ "metadata": {},
123
+ "createdAt": "2026-01-01T00:00:00.000Z",
124
+ "updatedAt": "2026-01-01T00:00:00.000Z",
125
+ "createdBy": null,
126
+ "createdVia": null,
127
+ "lastUpdatedBy": null,
128
+ "lastUpdatedVia": null,
129
+ "tags": [
130
+ "work"
131
+ ],
132
+ "linkCount": 0
133
+ },
134
+ [
135
+ {
136
+ "id": "hidden-dup",
137
+ "path": "p1/Dup",
138
+ "extension": "md",
139
+ "createdAt": "2026-01-01T00:00:00.000Z",
140
+ "updatedAt": "2026-01-01T00:00:00.000Z",
141
+ "createdBy": null,
142
+ "createdVia": null,
143
+ "lastUpdatedBy": null,
144
+ "lastUpdatedVia": null,
145
+ "tags": [
146
+ "personal"
147
+ ],
148
+ "metadata": {},
149
+ "byteSize": 12,
150
+ "preview": "personal dup",
151
+ "displayTitle": "personal dup",
152
+ "linkCount": 1
153
+ },
154
+ {
155
+ "id": "work-src",
156
+ "path": "work-src",
157
+ "extension": "md",
158
+ "createdAt": "2026-01-01T00:00:00.000Z",
159
+ "updatedAt": "2026-01-01T00:00:00.000Z",
160
+ "createdBy": null,
161
+ "createdVia": null,
162
+ "lastUpdatedBy": null,
163
+ "lastUpdatedVia": null,
164
+ "tags": [
165
+ "work"
166
+ ],
167
+ "metadata": {},
168
+ "byteSize": 11,
169
+ "preview": "src [[Dup]]",
170
+ "displayTitle": "src [[Dup]]",
171
+ "linkCount": 0
172
+ }
173
+ ]
174
+ ],
175
+ "REST": [
176
+ {
177
+ "id": "work-src",
178
+ "content": "src [[Dup]]",
179
+ "path": "work-src",
180
+ "extension": "md",
181
+ "metadata": {},
182
+ "createdAt": "2026-01-01T00:00:00.000Z",
183
+ "updatedAt": "2026-01-01T00:00:00.000Z",
184
+ "createdBy": null,
185
+ "createdVia": null,
186
+ "lastUpdatedBy": null,
187
+ "lastUpdatedVia": null,
188
+ "tags": [
189
+ "work"
190
+ ],
191
+ "linkCount": 1
192
+ },
193
+ [
194
+ {
195
+ "id": "hidden-dup",
196
+ "path": "p1/Dup",
197
+ "extension": "md",
198
+ "createdAt": "2026-01-01T00:00:00.000Z",
199
+ "updatedAt": "2026-01-01T00:00:00.000Z",
200
+ "createdBy": null,
201
+ "createdVia": null,
202
+ "lastUpdatedBy": null,
203
+ "lastUpdatedVia": null,
204
+ "tags": [
205
+ "personal"
206
+ ],
207
+ "metadata": {},
208
+ "byteSize": 12,
209
+ "preview": "personal dup",
210
+ "displayTitle": "personal dup",
211
+ "linkCount": 1
212
+ },
213
+ {
214
+ "id": "work-src",
215
+ "path": "work-src",
216
+ "extension": "md",
217
+ "createdAt": "2026-01-01T00:00:00.000Z",
218
+ "updatedAt": "2026-01-01T00:00:00.000Z",
219
+ "createdBy": null,
220
+ "createdVia": null,
221
+ "lastUpdatedBy": null,
222
+ "lastUpdatedVia": null,
223
+ "tags": [
224
+ "work"
225
+ ],
226
+ "metadata": {},
227
+ "byteSize": 11,
228
+ "preview": "src [[Dup]]",
229
+ "displayTitle": "src [[Dup]]",
230
+ "linkCount": 1
231
+ }
232
+ ],
233
+ {
234
+ "id": "work-src",
235
+ "content": "src [[Dup]]",
236
+ "path": "work-src",
237
+ "extension": "md",
238
+ "metadata": {},
239
+ "createdAt": "2026-01-01T00:00:00.000Z",
240
+ "updatedAt": "2026-01-01T00:00:00.000Z",
241
+ "createdBy": null,
242
+ "createdVia": null,
243
+ "lastUpdatedBy": null,
244
+ "lastUpdatedVia": null,
245
+ "tags": [
246
+ "work"
247
+ ],
248
+ "linkCount": 1
249
+ },
250
+ [
251
+ {
252
+ "id": "hidden-dup",
253
+ "path": "p1/Dup",
254
+ "extension": "md",
255
+ "createdAt": "2026-01-01T00:00:00.000Z",
256
+ "updatedAt": "2026-01-01T00:00:00.000Z",
257
+ "createdBy": null,
258
+ "createdVia": null,
259
+ "lastUpdatedBy": null,
260
+ "lastUpdatedVia": null,
261
+ "tags": [
262
+ "personal"
263
+ ],
264
+ "metadata": {},
265
+ "byteSize": 12,
266
+ "preview": "personal dup",
267
+ "displayTitle": "personal dup",
268
+ "linkCount": 0
269
+ },
270
+ {
271
+ "id": "work-src",
272
+ "path": "work-src",
273
+ "extension": "md",
274
+ "createdAt": "2026-01-01T00:00:00.000Z",
275
+ "updatedAt": "2026-01-01T00:00:00.000Z",
276
+ "createdBy": null,
277
+ "createdVia": null,
278
+ "lastUpdatedBy": null,
279
+ "lastUpdatedVia": null,
280
+ "tags": [
281
+ "work"
282
+ ],
283
+ "metadata": {},
284
+ "byteSize": 11,
285
+ "preview": "src [[Dup]]",
286
+ "displayTitle": "src [[Dup]]",
287
+ "linkCount": 1
288
+ }
289
+ ],
290
+ {
291
+ "id": "work-src",
292
+ "content": "src [[Dup]]",
293
+ "path": "work-src",
294
+ "extension": "md",
295
+ "metadata": {},
296
+ "createdAt": "2026-01-01T00:00:00.000Z",
297
+ "updatedAt": "2026-01-01T00:00:00.000Z",
298
+ "createdBy": null,
299
+ "createdVia": null,
300
+ "lastUpdatedBy": null,
301
+ "lastUpdatedVia": null,
302
+ "tags": [
303
+ "work"
304
+ ],
305
+ "linkCount": 0
306
+ },
307
+ [
308
+ {
309
+ "id": "hidden-dup",
310
+ "path": "p1/Dup",
311
+ "extension": "md",
312
+ "createdAt": "2026-01-01T00:00:00.000Z",
313
+ "updatedAt": "2026-01-01T00:00:00.000Z",
314
+ "createdBy": null,
315
+ "createdVia": null,
316
+ "lastUpdatedBy": null,
317
+ "lastUpdatedVia": null,
318
+ "tags": [
319
+ "personal"
320
+ ],
321
+ "metadata": {},
322
+ "byteSize": 12,
323
+ "preview": "personal dup",
324
+ "displayTitle": "personal dup",
325
+ "linkCount": 1
326
+ },
327
+ {
328
+ "id": "work-src",
329
+ "path": "work-src",
330
+ "extension": "md",
331
+ "createdAt": "2026-01-01T00:00:00.000Z",
332
+ "updatedAt": "2026-01-01T00:00:00.000Z",
333
+ "createdBy": null,
334
+ "createdVia": null,
335
+ "lastUpdatedBy": null,
336
+ "lastUpdatedVia": null,
337
+ "tags": [
338
+ "work"
339
+ ],
340
+ "metadata": {},
341
+ "byteSize": 11,
342
+ "preview": "src [[Dup]]",
343
+ "displayTitle": "src [[Dup]]",
344
+ "linkCount": 0
345
+ }
346
+ ]
347
+ ]
348
+ }
@@ -0,0 +1,86 @@
1
+ {
2
+ "MCP": {
3
+ "id": "work-src",
4
+ "content": "src [[Dup]]",
5
+ "path": "work-src",
6
+ "extension": "md",
7
+ "metadata": {},
8
+ "createdAt": "2026-01-01T00:00:00.000Z",
9
+ "updatedAt": "2026-01-01T00:00:00.000Z",
10
+ "createdBy": null,
11
+ "createdVia": null,
12
+ "lastUpdatedBy": null,
13
+ "lastUpdatedVia": null,
14
+ "tags": [
15
+ "work"
16
+ ],
17
+ "links": [
18
+ {
19
+ "sourceId": "work-src",
20
+ "targetId": "hidden-dup",
21
+ "relationship": "wikilink",
22
+ "createdAt": "2026-01-01T00:00:00.000Z",
23
+ "sourceNote": {
24
+ "id": "work-src",
25
+ "path": "work-src",
26
+ "createdAt": "2026-01-01T00:00:00.000Z",
27
+ "updatedAt": "2026-01-01T00:00:00.000Z",
28
+ "tags": [
29
+ "work"
30
+ ]
31
+ },
32
+ "targetNote": {
33
+ "id": "hidden-dup",
34
+ "path": "p1/Dup",
35
+ "createdAt": "2026-01-01T00:00:00.000Z",
36
+ "updatedAt": "2026-01-01T00:00:00.000Z",
37
+ "tags": [
38
+ "personal"
39
+ ]
40
+ }
41
+ }
42
+ ]
43
+ },
44
+ "REST": {
45
+ "id": "work-src",
46
+ "content": "src [[Dup]]",
47
+ "path": "work-src",
48
+ "extension": "md",
49
+ "metadata": {},
50
+ "createdAt": "2026-01-01T00:00:00.000Z",
51
+ "updatedAt": "2026-01-01T00:00:00.000Z",
52
+ "createdBy": null,
53
+ "createdVia": null,
54
+ "lastUpdatedBy": null,
55
+ "lastUpdatedVia": null,
56
+ "tags": [
57
+ "work"
58
+ ],
59
+ "links": [
60
+ {
61
+ "sourceId": "work-src",
62
+ "targetId": "hidden-dup",
63
+ "relationship": "wikilink",
64
+ "createdAt": "2026-01-01T00:00:00.000Z",
65
+ "sourceNote": {
66
+ "id": "work-src",
67
+ "path": "work-src",
68
+ "createdAt": "2026-01-01T00:00:00.000Z",
69
+ "updatedAt": "2026-01-01T00:00:00.000Z",
70
+ "tags": [
71
+ "work"
72
+ ]
73
+ },
74
+ "targetNote": {
75
+ "id": "hidden-dup",
76
+ "path": "p1/Dup",
77
+ "createdAt": "2026-01-01T00:00:00.000Z",
78
+ "updatedAt": "2026-01-01T00:00:00.000Z",
79
+ "tags": [
80
+ "personal"
81
+ ]
82
+ }
83
+ }
84
+ ]
85
+ }
86
+ }
@@ -0,0 +1,78 @@
1
+ {
2
+ "MCP": [
3
+ {
4
+ "id": "hidden-dup",
5
+ "path": "p1/Dup",
6
+ "extension": "md",
7
+ "createdAt": "2026-01-01T00:00:00.000Z",
8
+ "updatedAt": "2026-01-01T00:00:00.000Z",
9
+ "createdBy": null,
10
+ "createdVia": null,
11
+ "lastUpdatedBy": null,
12
+ "lastUpdatedVia": null,
13
+ "tags": [
14
+ "personal"
15
+ ],
16
+ "metadata": {},
17
+ "byteSize": 12,
18
+ "preview": "personal dup",
19
+ "displayTitle": "personal dup"
20
+ },
21
+ {
22
+ "id": "work-src",
23
+ "path": "work-src",
24
+ "extension": "md",
25
+ "createdAt": "2026-01-01T00:00:00.000Z",
26
+ "updatedAt": "2026-01-01T00:00:00.000Z",
27
+ "createdBy": null,
28
+ "createdVia": null,
29
+ "lastUpdatedBy": null,
30
+ "lastUpdatedVia": null,
31
+ "tags": [
32
+ "work"
33
+ ],
34
+ "metadata": {},
35
+ "byteSize": 11,
36
+ "preview": "src [[Dup]]",
37
+ "displayTitle": "src [[Dup]]"
38
+ }
39
+ ],
40
+ "REST": [
41
+ {
42
+ "id": "hidden-dup",
43
+ "path": "p1/Dup",
44
+ "extension": "md",
45
+ "createdAt": "2026-01-01T00:00:00.000Z",
46
+ "updatedAt": "2026-01-01T00:00:00.000Z",
47
+ "createdBy": null,
48
+ "createdVia": null,
49
+ "lastUpdatedBy": null,
50
+ "lastUpdatedVia": null,
51
+ "tags": [
52
+ "personal"
53
+ ],
54
+ "metadata": {},
55
+ "byteSize": 12,
56
+ "preview": "personal dup",
57
+ "displayTitle": "personal dup"
58
+ },
59
+ {
60
+ "id": "work-src",
61
+ "path": "work-src",
62
+ "extension": "md",
63
+ "createdAt": "2026-01-01T00:00:00.000Z",
64
+ "updatedAt": "2026-01-01T00:00:00.000Z",
65
+ "createdBy": null,
66
+ "createdVia": null,
67
+ "lastUpdatedBy": null,
68
+ "lastUpdatedVia": null,
69
+ "tags": [
70
+ "work"
71
+ ],
72
+ "metadata": {},
73
+ "byteSize": 11,
74
+ "preview": "src [[Dup]]",
75
+ "displayTitle": "src [[Dup]]"
76
+ }
77
+ ]
78
+ }
@@ -0,0 +1,6 @@
1
+ {
2
+ "REST": {
3
+ "unresolved": [],
4
+ "count": 0
5
+ }
6
+ }