apple-tools-mcp 2.1.5 → 3.0.1
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 +77 -2
- package/bin/apple-tools-http-proxy.js +15 -0
- package/bin/apple-tools-http.js +16 -0
- package/examples/com.apple-tools-http.plist +35 -0
- package/examples/config.json.example +5 -0
- package/examples/mcp-client.md +98 -0
- package/index.js +535 -469
- package/indexer.js +2 -2
- package/lib/calendarWrite.js +83 -27
- package/lib/config.js +29 -1
- package/lib/httpAuth.js +106 -0
- package/lib/httpStdioProxy.js +45 -0
- package/lib/httpTransport.js +71 -0
- package/lib/mailWrite.js +99 -21
- package/lib/processMode.js +42 -1
- package/package.json +16 -8
package/lib/mailWrite.js
CHANGED
|
@@ -182,6 +182,27 @@ export const MAIL_SE_PROBE_TIMEOUT_MS = 4000;
|
|
|
182
182
|
export const SYSTEM_EVENTS_AUTOMATION_PROBE_TIMEOUT_MS = 30000;
|
|
183
183
|
/** Compose osascript budget (make + keystroke + send). Far below the ~60s SE wedge. */
|
|
184
184
|
export const MAIL_COMPOSE_TIMEOUT_MS = 25000;
|
|
185
|
+
// Regression (2026-09-23): atmFindMessage's `messages of <box> whose message
|
|
186
|
+
// id is X` scan is genuinely slow on a large mailbox (observed 30-38s on a
|
|
187
|
+
// ~68,500-message account, even matching in the first/fastest box checked --
|
|
188
|
+
// this is a known AppleScript `whose`-filter characteristic, not specific to
|
|
189
|
+
// one mailbox choice). mail_mark / mail_archive / mail_trash had no explicit
|
|
190
|
+
// timeout at all (defaulting to the shared 30s DEFAULT_SCRIPT_TIMEOUT_MS),
|
|
191
|
+
// so they timed out before that scan could finish on this account. Widened
|
|
192
|
+
// with real margin over the observed worst case, while staying under the
|
|
193
|
+
// MCP client SDK's 60s default CallTool timeout (mail_send's fix comment
|
|
194
|
+
// above SENT_VERIFY_ATTEMPTS has the full story on why that ceiling matters).
|
|
195
|
+
export const MAIL_FIND_TIMEOUT_MS = 50000;
|
|
196
|
+
// Whole tool call must answer before the MCP client's default 60s CallTool
|
|
197
|
+
// timeout. 55s leaves the process time to format that answer.
|
|
198
|
+
export const MCP_CALL_DEADLINE_MS = 55000;
|
|
199
|
+
// mail_reply / mail_forward run atmFindMessage and then the send inside one
|
|
200
|
+
// osascript. The find alone has been observed at 30-38s, so a combined
|
|
201
|
+
// budget at that observed ceiling kills the script after the lookup and
|
|
202
|
+
// before send. Match the find-only budget (50s): a 38s lookup still has
|
|
203
|
+
// ~12s left for send. Verification after the script returns is capped to
|
|
204
|
+
// whatever remains under MCP_CALL_DEADLINE_MS, not a second full window.
|
|
205
|
+
export const MAIL_FIND_AND_SEND_TIMEOUT_MS = MAIL_FIND_TIMEOUT_MS;
|
|
185
206
|
export const MAIL_SE_APPLEEVENT_TIMEOUT_SEC = 8;
|
|
186
207
|
export const MAIL_APPLEEVENT_TIMEOUT_SEC = 15;
|
|
187
208
|
export const MAIL_SE_PROBE_APPLEEVENT_TIMEOUT_SEC = 3;
|
|
@@ -840,11 +861,41 @@ export const SENT_VERIFY_NOT_FOUND = "NOT_FOUND";
|
|
|
840
861
|
/** Older hang-recovery scripts returned FOUND to mean Sent. Still accepted. */
|
|
841
862
|
export const SENT_VERIFY_FOUND = "FOUND";
|
|
842
863
|
export const SENT_VERIFY_TIMEOUT_MS = 15000;
|
|
843
|
-
|
|
844
|
-
export const
|
|
864
|
+
/** Skip a poll that could not return before the call deadline. */
|
|
865
|
+
export const SENT_VERIFY_MIN_POLL_MS = 1000;
|
|
866
|
+
// Regression (2026-09-23): 6 consecutive real sends on an iCloud/IMAP
|
|
867
|
+
// account all delivered successfully, but each took a different, unbounded
|
|
868
|
+
// amount of time before Mail made the message queryable in Sent via
|
|
869
|
+
// AppleScript (observed: 20s, 20s, 30s, 65s, 47s, ~64s), even though Mail's
|
|
870
|
+
// `send` call itself returned in a few seconds. The old budget (3 attempts
|
|
871
|
+
// x 400ms = ~1.2s) gave up long before that and reported a false-negative
|
|
872
|
+
// failure on messages that really were delivered.
|
|
873
|
+
//
|
|
874
|
+
// A larger budget alone cannot fully fix this: the MCP client SDK's own
|
|
875
|
+
// default CallTool timeout is 60s (McpError -32001 "Request timed out"),
|
|
876
|
+
// confirmed by testing an attempts=30/retryMs=4000 (~120s worst case)
|
|
877
|
+
// budget against a real client -- the client gave up and errored while the
|
|
878
|
+
// server was still polling and about to find the (already-delivered)
|
|
879
|
+
// message. Any purely-synchronous verification longer than that ceiling is
|
|
880
|
+
// self-defeating: it cannot outrun the client's own timeout, and going past
|
|
881
|
+
// it only means the client sees a raw protocol timeout instead of a useful
|
|
882
|
+
// answer. So the budget below stays safely under that ceiling (well under
|
|
883
|
+
// 60s total including the initial send), and a miss within budget is
|
|
884
|
+
// reported as *unconfirmed*, not failed -- honesty over false confidence,
|
|
885
|
+
// since 9/9 real sends observed here eventually succeeded.
|
|
886
|
+
//
|
|
887
|
+
// Attempt count and sleep are a ceiling, not a guaranteed wait. Each poll
|
|
888
|
+
// also runs under SENT_VERIFY_TIMEOUT_MS (15s), so 6 x 15s plus the sleeps
|
|
889
|
+
// can blow past the 60s client timeout if a poll hangs. verifyQueuedMessage
|
|
890
|
+
// stops at MCP_CALL_DEADLINE_MS and shrinks each poll to the time left.
|
|
891
|
+
export const SENT_VERIFY_ATTEMPTS = 6;
|
|
892
|
+
export const SENT_VERIFY_RETRY_MS = 2000;
|
|
845
893
|
|
|
846
894
|
export const MAIL_VERIFY_MISS_GUIDANCE =
|
|
847
|
-
"Mail reported the send call succeeded,
|
|
895
|
+
"Mail reported the send call succeeded, and this account's Sent folder has been observed to take up to a minute or more to " +
|
|
896
|
+
"reflect a new message (iCloud/IMAP sync lag), longer than it is safe to block a single tool call for. This is not a known " +
|
|
897
|
+
"failure -- treat it as unconfirmed. Check Sent (and Outbox) before deciding whether to retry; retrying a message that " +
|
|
898
|
+
"already landed sends a second copy.";
|
|
848
899
|
|
|
849
900
|
function defaultSentVerifySleep(ms) {
|
|
850
901
|
if (!ms || ms <= 0) return;
|
|
@@ -853,11 +904,13 @@ function defaultSentVerifySleep(ms) {
|
|
|
853
904
|
|
|
854
905
|
/** Test hook: skip the retry delay without changing attempt count. */
|
|
855
906
|
export const sentVerifyClock = {
|
|
856
|
-
sleep: defaultSentVerifySleep
|
|
907
|
+
sleep: defaultSentVerifySleep,
|
|
908
|
+
now: () => Date.now()
|
|
857
909
|
};
|
|
858
910
|
|
|
859
911
|
export function resetSentVerifyClock() {
|
|
860
912
|
sentVerifyClock.sleep = defaultSentVerifySleep;
|
|
913
|
+
sentVerifyClock.now = () => Date.now();
|
|
861
914
|
}
|
|
862
915
|
|
|
863
916
|
/**
|
|
@@ -1158,10 +1211,12 @@ function pickSentVerifyScript({
|
|
|
1158
1211
|
* Compose matches require To + subject (Message-ID when available) — never
|
|
1159
1212
|
* subject alone. Returns a hit object or null. Verify failure is not success.
|
|
1160
1213
|
*/
|
|
1161
|
-
export function recoverIfInSent(match = {}) {
|
|
1214
|
+
export function recoverIfInSent(match = {}, { timeout = SENT_VERIFY_TIMEOUT_MS } = {}) {
|
|
1162
1215
|
const script = pickSentVerifyScript(match);
|
|
1163
1216
|
if (!script) return null;
|
|
1164
|
-
const
|
|
1217
|
+
const pollTimeout = Math.min(SENT_VERIFY_TIMEOUT_MS, Math.max(0, timeout));
|
|
1218
|
+
if (pollTimeout < SENT_VERIFY_MIN_POLL_MS) return null;
|
|
1219
|
+
const result = runAppleScript(script, { timeout: pollTimeout, appName: "Mail" });
|
|
1165
1220
|
if (!result.ok) return null;
|
|
1166
1221
|
return parseSentVerifyOutput(result.output);
|
|
1167
1222
|
}
|
|
@@ -1169,13 +1224,25 @@ export function recoverIfInSent(match = {}) {
|
|
|
1169
1224
|
/**
|
|
1170
1225
|
* Poll Sent/Outbox after a send that returned without throw.
|
|
1171
1226
|
*/
|
|
1172
|
-
export function verifyQueuedMessage(match = {}, {
|
|
1227
|
+
export function verifyQueuedMessage(match = {}, {
|
|
1228
|
+
attempts = SENT_VERIFY_ATTEMPTS,
|
|
1229
|
+
retryMs = SENT_VERIFY_RETRY_MS,
|
|
1230
|
+
deadlineMs = null
|
|
1231
|
+
} = {}) {
|
|
1232
|
+
const deadline = Number.isFinite(deadlineMs)
|
|
1233
|
+
? deadlineMs
|
|
1234
|
+
: sentVerifyClock.now() + MCP_CALL_DEADLINE_MS;
|
|
1173
1235
|
let last = null;
|
|
1174
1236
|
const n = Math.max(1, attempts);
|
|
1175
1237
|
for (let i = 0; i < n; i++) {
|
|
1176
|
-
|
|
1238
|
+
const remaining = deadline - sentVerifyClock.now();
|
|
1239
|
+
if (remaining < SENT_VERIFY_MIN_POLL_MS) break;
|
|
1240
|
+
last = recoverIfInSent(match, { timeout: Math.min(SENT_VERIFY_TIMEOUT_MS, remaining) });
|
|
1177
1241
|
if (last) return last;
|
|
1178
|
-
if (i
|
|
1242
|
+
if (i >= n - 1) break;
|
|
1243
|
+
const sleepFor = Math.min(retryMs, deadline - sentVerifyClock.now() - SENT_VERIFY_MIN_POLL_MS);
|
|
1244
|
+
if (sleepFor <= 0) break;
|
|
1245
|
+
sentVerifyClock.sleep(sleepFor);
|
|
1179
1246
|
}
|
|
1180
1247
|
return last;
|
|
1181
1248
|
}
|
|
@@ -1282,7 +1349,7 @@ function sendVerifiedSuccess({ action, successSummary, details, verified, recove
|
|
|
1282
1349
|
}
|
|
1283
1350
|
|
|
1284
1351
|
function verifyMissMessage(action, summary) {
|
|
1285
|
-
return `${action}
|
|
1352
|
+
return `${action}: unconfirmed — attempted to ${summary}. ${MAIL_VERIFY_MISS_GUIDANCE}`;
|
|
1286
1353
|
}
|
|
1287
1354
|
|
|
1288
1355
|
function finalizeMailWrite({
|
|
@@ -1297,15 +1364,20 @@ function finalizeMailWrite({
|
|
|
1297
1364
|
to = null,
|
|
1298
1365
|
messageId = null,
|
|
1299
1366
|
successSummary,
|
|
1300
|
-
details
|
|
1367
|
+
details,
|
|
1368
|
+
deadlineMs = null
|
|
1301
1369
|
}) {
|
|
1302
1370
|
const match = { inReplyTo, subject, forwardTo, to, messageId };
|
|
1371
|
+
const deadline = Number.isFinite(deadlineMs)
|
|
1372
|
+
? deadlineMs
|
|
1373
|
+
: sentVerifyClock.now() + MCP_CALL_DEADLINE_MS;
|
|
1374
|
+
const remaining = () => deadline - sentVerifyClock.now();
|
|
1303
1375
|
|
|
1304
1376
|
if (result.ok) {
|
|
1305
1377
|
if (!sendNow) {
|
|
1306
1378
|
return { ok: true, delivered: false, mailbox: null, message: writeSuccessMessage(action, successSummary, details) };
|
|
1307
1379
|
}
|
|
1308
|
-
const verified = verifyQueuedMessage(match);
|
|
1380
|
+
const verified = verifyQueuedMessage(match, { deadlineMs: deadline });
|
|
1309
1381
|
if (!verified) {
|
|
1310
1382
|
return { ok: false, delivered: false, mailbox: null, message: verifyMissMessage(action, summary) };
|
|
1311
1383
|
}
|
|
@@ -1313,7 +1385,7 @@ function finalizeMailWrite({
|
|
|
1313
1385
|
}
|
|
1314
1386
|
|
|
1315
1387
|
if (sendNow && isMailSendTimeout(result)) {
|
|
1316
|
-
const recovered = recoverIfInSent(match);
|
|
1388
|
+
const recovered = recoverIfInSent(match, { timeout: remaining() });
|
|
1317
1389
|
if (recovered) {
|
|
1318
1390
|
return sendVerifiedSuccess({ action, successSummary, details, verified: recovered, recovered: true });
|
|
1319
1391
|
}
|
|
@@ -1397,6 +1469,7 @@ export function mailCompose(args = {}, { draft = false, indexerMode = isIndexerM
|
|
|
1397
1469
|
html: bodyFormat === "html"
|
|
1398
1470
|
});
|
|
1399
1471
|
|
|
1472
|
+
const deadlineMs = sentVerifyClock.now() + MCP_CALL_DEADLINE_MS;
|
|
1400
1473
|
const result = runAppleScript(script, { timeout: MAIL_COMPOSE_TIMEOUT_MS, appName: "Mail" });
|
|
1401
1474
|
if (
|
|
1402
1475
|
!result.ok &&
|
|
@@ -1420,7 +1493,8 @@ export function mailCompose(args = {}, { draft = false, indexerMode = isIndexerM
|
|
|
1420
1493
|
cc: cc.addresses.join(", ") || undefined,
|
|
1421
1494
|
bcc: bcc.addresses.length ? `${bcc.addresses.length} recipient(s)` : undefined,
|
|
1422
1495
|
subject: truncate(subject.text, 150)
|
|
1423
|
-
}
|
|
1496
|
+
},
|
|
1497
|
+
deadlineMs
|
|
1424
1498
|
});
|
|
1425
1499
|
}
|
|
1426
1500
|
|
|
@@ -1475,9 +1549,10 @@ export function mailReply(args = {}) {
|
|
|
1475
1549
|
});
|
|
1476
1550
|
if (!plan.proceed) return plannedWriteResult(plan);
|
|
1477
1551
|
|
|
1552
|
+
const deadlineMs = sentVerifyClock.now() + MCP_CALL_DEADLINE_MS;
|
|
1478
1553
|
const result = runAppleScript(
|
|
1479
1554
|
buildReplyScript({ messageId: resolved.messageId, body: body.text, replyAll, sendNow }),
|
|
1480
|
-
{ timeout:
|
|
1555
|
+
{ timeout: MAIL_FIND_AND_SEND_TIMEOUT_MS, appName: "Mail" }
|
|
1481
1556
|
);
|
|
1482
1557
|
return finalizeMailWrite({
|
|
1483
1558
|
action,
|
|
@@ -1490,7 +1565,8 @@ export function mailReply(args = {}) {
|
|
|
1490
1565
|
details: {
|
|
1491
1566
|
message_id: resolved.messageId,
|
|
1492
1567
|
reply_all: String(replyAll)
|
|
1493
|
-
}
|
|
1568
|
+
},
|
|
1569
|
+
deadlineMs
|
|
1494
1570
|
});
|
|
1495
1571
|
}
|
|
1496
1572
|
|
|
@@ -1538,9 +1614,10 @@ export function mailForward(args = {}) {
|
|
|
1538
1614
|
});
|
|
1539
1615
|
if (!plan.proceed) return plannedWriteResult(plan);
|
|
1540
1616
|
|
|
1617
|
+
const deadlineMs = sentVerifyClock.now() + MCP_CALL_DEADLINE_MS;
|
|
1541
1618
|
const result = runAppleScript(
|
|
1542
1619
|
buildForwardScript({ messageId: resolved.messageId, to: to.addresses, body: body.text, sendNow }),
|
|
1543
|
-
{ timeout:
|
|
1620
|
+
{ timeout: MAIL_FIND_AND_SEND_TIMEOUT_MS, appName: "Mail" }
|
|
1544
1621
|
);
|
|
1545
1622
|
return finalizeMailWrite({
|
|
1546
1623
|
action,
|
|
@@ -1554,7 +1631,8 @@ export function mailForward(args = {}) {
|
|
|
1554
1631
|
details: {
|
|
1555
1632
|
message_id: resolved.messageId,
|
|
1556
1633
|
to: to.addresses.join(", ")
|
|
1557
|
-
}
|
|
1634
|
+
},
|
|
1635
|
+
deadlineMs
|
|
1558
1636
|
});
|
|
1559
1637
|
}
|
|
1560
1638
|
|
|
@@ -1586,7 +1664,7 @@ export function mailMark(args = {}) {
|
|
|
1586
1664
|
});
|
|
1587
1665
|
if (!plan.proceed) return plannedWriteResult(plan);
|
|
1588
1666
|
|
|
1589
|
-
const result = runAppleScript(buildMarkScript({ messageId: resolved.messageId, read: status === "read" }), { appName: "Mail" });
|
|
1667
|
+
const result = runAppleScript(buildMarkScript({ messageId: resolved.messageId, read: status === "read" }), { timeout: MAIL_FIND_TIMEOUT_MS, appName: "Mail" });
|
|
1590
1668
|
if (!result.ok) return { ok: false, message: failure(action, summary, result, []) };
|
|
1591
1669
|
|
|
1592
1670
|
return { ok: true, message: writeSuccessMessage(action, `marked as ${status}`, { message_id: resolved.messageId }) };
|
|
@@ -1637,7 +1715,7 @@ export function mailArchive(args = {}) {
|
|
|
1637
1715
|
mailboxNames: ["Archive", "All Mail", "Archived"],
|
|
1638
1716
|
allowDeleteFallback: false
|
|
1639
1717
|
}),
|
|
1640
|
-
{ appName: "Mail" }
|
|
1718
|
+
{ timeout: MAIL_FIND_TIMEOUT_MS, appName: "Mail" }
|
|
1641
1719
|
);
|
|
1642
1720
|
if (!result.ok) {
|
|
1643
1721
|
if (result.kind === "not_found" && String(result.error).includes("ARCHIVE_MAILBOX_NOT_FOUND")) {
|
|
@@ -1670,7 +1748,7 @@ export function mailTrash(args = {}) {
|
|
|
1670
1748
|
mailboxNames: ["Trash", "Deleted Messages", "Bin"],
|
|
1671
1749
|
allowDeleteFallback: true
|
|
1672
1750
|
}),
|
|
1673
|
-
{ appName: "Mail" }
|
|
1751
|
+
{ timeout: MAIL_FIND_TIMEOUT_MS, appName: "Mail" }
|
|
1674
1752
|
);
|
|
1675
1753
|
if (!result.ok) return { ok: false, message: failure(action, summary, result, []) };
|
|
1676
1754
|
|
package/lib/processMode.js
CHANGED
|
@@ -5,7 +5,12 @@
|
|
|
5
5
|
* Convenience bin: `apple-tools-indexer` (`bin/apple-tools-indexer.js`;
|
|
6
6
|
* detected via argv[1] or `--mode=indexer`).
|
|
7
7
|
* Permissions CLI: `apple-tools-mcp permissions` / `--mode=permissions`.
|
|
8
|
-
*
|
|
8
|
+
* HTTP transport: `node index.js --transport=http` or `apple-tools-http`
|
|
9
|
+
* (`bin/apple-tools-http.js`) — read-only-vs-write is unchanged, but every
|
|
10
|
+
* request needs a bearer token; see lib/httpAuth.js.
|
|
11
|
+
* Token CLI: `apple-tools-mcp http-token` prints (generating if needed) the
|
|
12
|
+
* Keychain-stored HTTP auth token, then exits.
|
|
13
|
+
* MCP stdio remains the default when none of the above is present.
|
|
9
14
|
*/
|
|
10
15
|
|
|
11
16
|
import path from "path";
|
|
@@ -74,3 +79,39 @@ export function isIndexerMode(argv = process.argv) {
|
|
|
74
79
|
const entry = argv[1] ? path.basename(argv[1]) : "";
|
|
75
80
|
return entry === "apple-tools-indexer" || entry === "apple-tools-indexer.js";
|
|
76
81
|
}
|
|
82
|
+
|
|
83
|
+
/**
|
|
84
|
+
* @param {string[]} [argv=process.argv]
|
|
85
|
+
* @returns {boolean}
|
|
86
|
+
*/
|
|
87
|
+
export function isHttpTokenMode(argv = process.argv) {
|
|
88
|
+
if (!Array.isArray(argv) || argv.length === 0) {
|
|
89
|
+
return false;
|
|
90
|
+
}
|
|
91
|
+
if (argv.includes("--mode=http-token")) {
|
|
92
|
+
return true;
|
|
93
|
+
}
|
|
94
|
+
return firstPositionalArg(argv) === "http-token";
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
/**
|
|
98
|
+
* @param {string[]} [argv=process.argv]
|
|
99
|
+
* @returns {boolean}
|
|
100
|
+
*/
|
|
101
|
+
export function isHttpMode(argv = process.argv) {
|
|
102
|
+
if (!Array.isArray(argv) || argv.length === 0) {
|
|
103
|
+
return false;
|
|
104
|
+
}
|
|
105
|
+
if (isPermissionsMode(argv) || isHttpTokenMode(argv)) {
|
|
106
|
+
return false;
|
|
107
|
+
}
|
|
108
|
+
if (argv.includes("--transport=http") || argv.includes("--mode=http")) {
|
|
109
|
+
return true;
|
|
110
|
+
}
|
|
111
|
+
const transportIdx = argv.indexOf("--transport");
|
|
112
|
+
if (transportIdx !== -1 && argv[transportIdx + 1] === "http") {
|
|
113
|
+
return true;
|
|
114
|
+
}
|
|
115
|
+
const entry = argv[1] ? path.basename(argv[1]) : "";
|
|
116
|
+
return entry === "apple-tools-http" || entry === "apple-tools-http.js";
|
|
117
|
+
}
|
package/package.json
CHANGED
|
@@ -1,12 +1,14 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "apple-tools-mcp",
|
|
3
|
-
"version": "
|
|
4
|
-
"description": "MCP server for semantic search and write actions across Apple Mail, Messages, Calendar, and Contacts",
|
|
3
|
+
"version": "3.0.1",
|
|
4
|
+
"description": "MCP server for semantic search and write actions across Apple Mail, Messages, Calendar, and Contacts. Speaks stdio (local) or bearer-token-authenticated Streamable HTTP (LAN / Tailscale).",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "index.js",
|
|
7
7
|
"bin": {
|
|
8
8
|
"apple-tools-mcp": "bin/apple-tools-mcp.js",
|
|
9
|
-
"apple-tools-indexer": "bin/apple-tools-indexer.js"
|
|
9
|
+
"apple-tools-indexer": "bin/apple-tools-indexer.js",
|
|
10
|
+
"apple-tools-http": "bin/apple-tools-http.js",
|
|
11
|
+
"apple-tools-http-proxy": "bin/apple-tools-http-proxy.js"
|
|
10
12
|
},
|
|
11
13
|
"author": "Peter Coates",
|
|
12
14
|
"license": "MIT",
|
|
@@ -28,7 +30,10 @@
|
|
|
28
30
|
"messages",
|
|
29
31
|
"imessage",
|
|
30
32
|
"semantic-search",
|
|
31
|
-
"macos"
|
|
33
|
+
"macos",
|
|
34
|
+
"streamable-http",
|
|
35
|
+
"remote-mcp",
|
|
36
|
+
"tailscale"
|
|
32
37
|
],
|
|
33
38
|
"engines": {
|
|
34
39
|
"node": ">=18.0.0"
|
|
@@ -46,6 +51,7 @@
|
|
|
46
51
|
"contacts.js",
|
|
47
52
|
"lib/",
|
|
48
53
|
"bin/",
|
|
54
|
+
"examples/",
|
|
49
55
|
"scripts/audit-index.js",
|
|
50
56
|
"scripts/smoke-writes.js",
|
|
51
57
|
"scripts/postinstall.js",
|
|
@@ -56,6 +62,8 @@
|
|
|
56
62
|
"start": "node index.js",
|
|
57
63
|
"indexer": "node index.js --mode=indexer",
|
|
58
64
|
"permissions": "node index.js permissions",
|
|
65
|
+
"http": "node index.js --transport=http",
|
|
66
|
+
"http-token": "node index.js http-token",
|
|
59
67
|
"postinstall": "node scripts/postinstall.js",
|
|
60
68
|
"build-index": "node -e \"import('./indexer.js').then(i=>i.rebuildIndex()).catch(e=>{console.error(e.message);process.exit(1)})\"",
|
|
61
69
|
"audit": "node scripts/audit-index.js",
|
|
@@ -82,14 +90,14 @@
|
|
|
82
90
|
"perf:dates": "vitest run tests/perf/date-parsing.perf.test.js"
|
|
83
91
|
},
|
|
84
92
|
"dependencies": {
|
|
93
|
+
"@huggingface/transformers": "^4.3.0",
|
|
85
94
|
"@lancedb/lancedb": "^0.22.3",
|
|
86
|
-
"@modelcontextprotocol/sdk": "^1.
|
|
87
|
-
"@xenova/transformers": "^2.17.2",
|
|
95
|
+
"@modelcontextprotocol/sdk": "^1.30.0",
|
|
88
96
|
"chrono-node": "^2.9.0"
|
|
89
97
|
},
|
|
90
98
|
"devDependencies": {
|
|
91
|
-
"vitest": "^2.1.0",
|
|
92
99
|
"@vitest/coverage-v8": "^2.1.0",
|
|
93
|
-
"fast-check": "^3.22.0"
|
|
100
|
+
"fast-check": "^3.22.0",
|
|
101
|
+
"vitest": "^2.1.0"
|
|
94
102
|
}
|
|
95
103
|
}
|