@agimon-ai/po-team 0.0.0-alpha.221 → 0.0.0-alpha.223
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.
|
@@ -6394,7 +6394,8 @@ function formatCoordinatorPeers(scope, peers) {
|
|
|
6394
6394
|
"Questions about progress, status or what is going on mean these sessions, not only this chat: message them for what you need, then report from their replies as they arrive."
|
|
6395
6395
|
];
|
|
6396
6396
|
const hidden = ordered.length - shown.length;
|
|
6397
|
-
if (hidden > 0) lines.push(`${String(hidden)} more not shown: use network.list() to
|
|
6397
|
+
if (hidden > 0) lines.push(`${String(hidden)} more not shown: use network.list() to find reachable sessions.`);
|
|
6398
|
+
lines.push("Use brain.graph({ kind: 'peers' }) to look up peer capabilities.");
|
|
6398
6399
|
return lines;
|
|
6399
6400
|
}
|
|
6400
6401
|
/**
|
|
@@ -6403,7 +6404,7 @@ function formatCoordinatorPeers(scope, peers) {
|
|
|
6403
6404
|
* are the one exception: it needs their idle or working state to coordinate, and gets a new note when it moves.
|
|
6404
6405
|
*/
|
|
6405
6406
|
function formatTeamRoster({ groups, members, coordinator }) {
|
|
6406
|
-
const lines = coordinator ? formatCoordinatorPeers(coordinator.scope, coordinator.peers) : [];
|
|
6407
|
+
const lines = coordinator ? formatCoordinatorPeers(coordinator.scope, coordinator.peers.filter((peer) => peer.coordinated === true)) : [];
|
|
6407
6408
|
const own = sortedNames(groups);
|
|
6408
6409
|
if (own.length) lines.push(`Your session groups: ${own.join(", ")}.`);
|
|
6409
6410
|
const subagentLines = members.filter((member) => member.role !== "main").map((member) => {
|
|
@@ -6426,7 +6427,7 @@ function teamRosterNote(roster) {
|
|
|
6426
6427
|
* request tail, so the provider prompt cache keeps every earlier byte. Writes at the next tool step,
|
|
6427
6428
|
* or right away when the session is idle; a busy idle write returns undefined and the next boundary retries.
|
|
6428
6429
|
*/
|
|
6429
|
-
function createTeamRosterDelivery(read) {
|
|
6430
|
+
function createTeamRosterDelivery(read, onNotice) {
|
|
6430
6431
|
let delivered = "";
|
|
6431
6432
|
let boundary;
|
|
6432
6433
|
let tail = Promise.resolve();
|
|
@@ -6439,7 +6440,9 @@ function createTeamRosterDelivery(read) {
|
|
|
6439
6440
|
text: teamRosterNote(roster),
|
|
6440
6441
|
display: false
|
|
6441
6442
|
}) !== void 0) delivered = roster;
|
|
6442
|
-
}).catch(() =>
|
|
6443
|
+
}).catch((error) => {
|
|
6444
|
+
onNotice(`Team roster delivery failed: ${String(error)}`);
|
|
6445
|
+
});
|
|
6443
6446
|
return tail;
|
|
6444
6447
|
};
|
|
6445
6448
|
return {
|
|
@@ -7417,7 +7420,7 @@ const root = (0, _agimon_ai_po_core_extensionFile.defineRoot)(async ({ context,
|
|
|
7417
7420
|
scope: coordinatorScope,
|
|
7418
7421
|
peers: serverHost.context.sessionCommunication?.listPeers?.() ?? []
|
|
7419
7422
|
} } : {}
|
|
7420
|
-
}));
|
|
7423
|
+
}), (message) => serverHost.context.onNotice(message));
|
|
7421
7424
|
let publishedSummary;
|
|
7422
7425
|
/** Publishes the last user request as this session's summary, only when it changed. */
|
|
7423
7426
|
const publishSummary = async () => {
|
|
@@ -7594,7 +7597,7 @@ const root = (0, _agimon_ai_po_core_extensionFile.defineRoot)(async ({ context,
|
|
|
7594
7597
|
} catch (error) {
|
|
7595
7598
|
activityAttached = false;
|
|
7596
7599
|
execution.client.setStatus(TEAM_COST_STATUS, void 0);
|
|
7597
|
-
throw error;
|
|
7600
|
+
throw error instanceof Error ? error : new Error("Failed to bind the main Team session", { cause: error });
|
|
7598
7601
|
}
|
|
7599
7602
|
}
|
|
7600
7603
|
};
|