@50arms/platform-mcp 0.1.459 → 0.1.460
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/dist/listen.js +24 -0
- package/dist/machine-toolkit.js +1 -1
- package/package.json +1 -1
package/dist/listen.js
CHANGED
|
@@ -411,9 +411,15 @@ export function formatActivityLine(event) {
|
|
|
411
411
|
const FILED_NOT_READIED_INSTRUCTION = "Ready each now (order: depends_on), or open a problem if only a person can decide.";
|
|
412
412
|
/** DX-6277 - the label the filed ids sit under; the same words as the dashboard's `FILED_NOT_READIED_LABEL` (src/issues/agent-pause.ts). */
|
|
413
413
|
const FILED_NOT_READIED_LABEL = "Filed, not readied";
|
|
414
|
+
/** DX-7127 - the label the review-runnable ids sit under, and what to do about them: the gate is no build and no person's answer, so a dependency never holds it. */
|
|
415
|
+
const REVIEWABLE_LABEL = "Review runnable now";
|
|
416
|
+
const REVIEWABLE_INSTRUCTION = "start each card's named gate review (its next PRE gate) now: a depends_on never holds a review";
|
|
414
417
|
function isNudgeCardRef(value) {
|
|
415
418
|
return isRecord(value) && typeof value.id === "string" && typeof value.title === "string";
|
|
416
419
|
}
|
|
420
|
+
function isReviewableNudgeCardRefArray(value) {
|
|
421
|
+
return Array.isArray(value) && value.every((c) => isNudgeCardRef(c) && typeof c.gate === "string");
|
|
422
|
+
}
|
|
417
423
|
function isNudgeCardRefArray(value) {
|
|
418
424
|
return Array.isArray(value) && value.every(isNudgeCardRef);
|
|
419
425
|
}
|
|
@@ -433,11 +439,26 @@ export function invalidNudgeReason(value) {
|
|
|
433
439
|
return "held is not a {id,title}[] array";
|
|
434
440
|
if (!isNudgeCardRefArray(value.unreadied))
|
|
435
441
|
return "unreadied is not a {id,title}[] array";
|
|
442
|
+
if (!isReviewableNudgeCardRefArray(value.reviewable))
|
|
443
|
+
return "reviewable is not a {id,title,gate}[] array";
|
|
444
|
+
if (value.freeSlots !== null && !(typeof value.freeSlots === "number" && Number.isInteger(value.freeSlots) && value.freeSlots >= 0))
|
|
445
|
+
return "freeSlots is not a count or null";
|
|
436
446
|
return null;
|
|
437
447
|
}
|
|
438
448
|
function cardList(cards) {
|
|
439
449
|
return cards.map((c) => `${c.id} "${c.title}"`).join(", ");
|
|
440
450
|
}
|
|
451
|
+
function reviewableCardList(cards) {
|
|
452
|
+
return cards.map((c) => `${c.id} "${c.title}" [${c.gate}]`).join(", ");
|
|
453
|
+
}
|
|
454
|
+
/** DX-7127 - what the free slot count says about starting the reviews: how many may start at once, or that none may yet, or that nothing caps them. */
|
|
455
|
+
function freeSlotsSentence(freeSlots) {
|
|
456
|
+
if (freeSlots === null)
|
|
457
|
+
return "Pacing sets no agent cap for this account.";
|
|
458
|
+
if (freeSlots === 0)
|
|
459
|
+
return "No agent slot is free now: start them as slots free.";
|
|
460
|
+
return `${freeSlots} agent slot${freeSlots === 1 ? " is" : "s are"} free now: start up to that many at once.`;
|
|
461
|
+
}
|
|
441
462
|
function queuedCardList(cards) {
|
|
442
463
|
return cards.map((c) => `${c.id} "${c.title}" [${c.queueState}]`).join(", ");
|
|
443
464
|
}
|
|
@@ -478,6 +499,9 @@ export function formatNudgeLine(event) {
|
|
|
478
499
|
const parts = [];
|
|
479
500
|
if (event.unreadied.length > 0)
|
|
480
501
|
parts.push(`${FILED_NOT_READIED_LABEL} (${FILED_NOT_READIED_INSTRUCTION}): ${cardList(event.unreadied)}`);
|
|
502
|
+
// DX-7127 - the label and instruction come before the ids, like the filed part, so a cut never takes the instruction.
|
|
503
|
+
if (event.reviewable.length > 0)
|
|
504
|
+
parts.push(`${REVIEWABLE_LABEL} (${REVIEWABLE_INSTRUCTION}; ${freeSlotsSentence(event.freeSlots)}): ${reviewableCardList(event.reviewable)}`);
|
|
481
505
|
if (event.startable.length > 0)
|
|
482
506
|
parts.push(`startable: ${queuedCardList(event.startable)}`);
|
|
483
507
|
if (event.held.length > 0)
|
package/dist/machine-toolkit.js
CHANGED
|
@@ -443,7 +443,7 @@ function resolveToolkitVersion(stamped, readManifest) {
|
|
|
443
443
|
return stamped ?? readManifest();
|
|
444
444
|
}
|
|
445
445
|
var readOwnManifest = () => JSON.parse(readFileSync2(new URL("../../package.json", import.meta.url), "utf8")).version;
|
|
446
|
-
var TOOLKIT_VERSION = resolveToolkitVersion(false ? void 0 : "0.1.
|
|
446
|
+
var TOOLKIT_VERSION = resolveToolkitVersion(false ? void 0 : "0.1.460", readOwnManifest);
|
|
447
447
|
function envelope(now) {
|
|
448
448
|
return { contract_version: CONTRACT_VERSION, toolkit_version: TOOLKIT_VERSION, profile: PROFILE, measured_at: now.toISOString() };
|
|
449
449
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@50arms/platform-mcp",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.460",
|
|
4
4
|
"description": "Stdio MCP server fronting the 50 Arms dashboard API for agents (operator sessions and dispatched workers alike): the generic 50arms_api/50arms_api_list/50arms_api_spec tools reach any route the caller's credential may call, plus dedicated agent-specific tools (session_connect, request_permission, attach_file, and 50arms_slack_reply) (DX-3465, PLN-11 R-25).",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|