toolroll 0.9.54 → 0.9.56
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/CHANGELOG.md +19 -0
- package/README.md +29 -12
- package/dist/action-ledger.d.ts +2 -4
- package/dist/action-ledger.js +2 -10
- package/dist/agent-onboard.js +4 -1
- package/dist/approval-policy.d.ts +5 -5
- package/dist/approval-policy.js +4 -4
- package/dist/approval-rules-ui.d.ts +3 -2
- package/dist/approval-rules-ui.js +17 -22
- package/dist/assignment-ui.d.ts +3 -2
- package/dist/assignment-ui.js +4 -11
- package/dist/backup-ui.d.ts +2 -1
- package/dist/backup-ui.js +16 -27
- package/dist/brand-mark.d.ts +3 -2
- package/dist/brand-mark.js +4 -4
- package/dist/browser/workspace.css +1 -1
- package/dist/browser/workspace.js +25 -25
- package/dist/browser-shell.d.ts +2 -1
- package/dist/browser-shell.js +9 -9
- package/dist/browser-workspace.d.ts +14 -15
- package/dist/browser-workspace.js +0 -3
- package/dist/budget-alerts.js +3 -3
- package/dist/chat-actions.d.ts +23 -18
- package/dist/chat-actions.js +110 -88
- package/dist/chat-ask.d.ts +2 -2
- package/dist/chat-ask.js +5 -5
- package/dist/chat-channel.d.ts +15 -15
- package/dist/chat-channel.js +20 -20
- package/dist/chat-controls.d.ts +0 -4
- package/dist/chat-controls.js +0 -1
- package/dist/chat-core.js +1 -1
- package/dist/chat-delivery-state.js +2 -2
- package/dist/chat-delivery.d.ts +2 -2
- package/dist/chat-delivery.js +27 -34
- package/dist/chat-flow.js +3 -3
- package/dist/chat-messages.d.ts +1 -1
- package/dist/chat-messages.js +4 -4
- package/dist/chat-migration.d.ts +1 -1
- package/dist/chat-migration.js +11 -11
- package/dist/chat-polish.d.ts +5 -4
- package/dist/chat-polish.js +9 -10
- package/dist/chat-rooms.js +3 -3
- package/dist/chat-warmth.d.ts +2 -2
- package/dist/check-levels-ui.d.ts +2 -1
- package/dist/check-levels-ui.js +26 -53
- package/dist/cli.d.ts +3 -1
- package/dist/cli.js +15 -10
- package/dist/coding-shipping-ui.d.ts +2 -1
- package/dist/coding-shipping-ui.js +6 -6
- package/dist/coding-ui.d.ts +3 -1
- package/dist/coding-ui.js +30 -29
- package/dist/contracts/chat-actions.d.ts +32 -27
- package/dist/contracts/chat-actions.js +29 -11
- package/dist/contracts/chat-content.d.ts +1 -1
- package/dist/contracts/chat-content.js +1 -1
- package/dist/contracts/chat-tables.js +4 -4
- package/dist/contracts/cli.d.ts +1 -3
- package/dist/contracts/console-api.d.ts +7 -7
- package/dist/contracts/console-api.js +13 -12
- package/dist/contracts/flow-propose.d.ts +3 -3
- package/dist/contracts/flow.d.ts +132 -125
- package/dist/contracts/flow.js +27 -12
- package/dist/contracts/health.d.ts +1 -3
- package/dist/contracts/lead-context.d.ts +1 -1
- package/dist/contracts/lead-context.js +2 -2
- package/dist/contracts/lead-tools.d.ts +20 -18
- package/dist/contracts/lead-tools.js +15 -15
- package/dist/contracts/stage-output.d.ts +1 -1
- package/dist/contracts/stage-output.js +1 -1
- package/dist/contracts/store-json.d.ts +23 -22
- package/dist/contracts/store-json.js +17 -17
- package/dist/contracts/{teammate-turn.d.ts → subagent-turn.d.ts} +5 -5
- package/dist/contracts/{teammate-turn.js → subagent-turn.js} +7 -7
- package/dist/control-ui.d.ts +5 -4
- package/dist/control-ui.js +9 -34
- package/dist/converse.d.ts +23 -23
- package/dist/converse.js +28 -28
- package/dist/coordinator-proposals.d.ts +2 -2
- package/dist/coordinator-proposals.js +1 -1
- package/dist/coordinator.js +1 -1
- package/dist/credentials-ui.d.ts +5 -4
- package/dist/credentials-ui.js +23 -24
- package/dist/demo-chat.d.ts +3 -3
- package/dist/demo-chat.js +29 -76
- package/dist/deprecations.d.ts +12 -0
- package/dist/deprecations.js +20 -0
- package/dist/desktop-update-gate.js +8 -4
- package/dist/desktop-update.js +6 -1
- package/dist/discord-chat.js +6 -6
- package/dist/discord-settings.d.ts +3 -2
- package/dist/discord-settings.js +17 -42
- package/dist/dispatch.d.ts +1 -1
- package/dist/dispatch.js +1 -1
- package/dist/envelope.js +10 -1
- package/dist/evidence-pack.d.ts +2 -1
- package/dist/evidence-pack.js +45 -49
- package/dist/export-ui.d.ts +7 -2
- package/dist/export-ui.js +4 -10
- package/dist/export.js +7 -7
- package/dist/flow-engine.d.ts +2 -2
- package/dist/flow-engine.js +21 -21
- package/dist/flow-gallery-ui.d.ts +4 -3
- package/dist/flow-gallery-ui.js +28 -43
- package/dist/flow-insights.d.ts +1 -1
- package/dist/flow-share.js +13 -8
- package/dist/flow-starters-ui.d.ts +2 -1
- package/dist/flow-starters-ui.js +12 -15
- package/dist/flow-steps.d.ts +5 -5
- package/dist/flow-steps.js +19 -19
- package/dist/flow-triggers.d.ts +2 -1
- package/dist/flow-triggers.js +17 -15
- package/dist/flows-cli.js +1 -1
- package/dist/flows-ui.d.ts +4 -3
- package/dist/flows-ui.js +38 -49
- package/dist/flows.js +21 -20
- package/dist/guides.js +112 -6
- package/dist/html.d.ts +76 -0
- package/dist/html.js +173 -0
- package/dist/integrations-ui.d.ts +2 -1
- package/dist/integrations-ui.js +19 -23
- package/dist/invoke.js +1 -1
- package/dist/kits-ui.d.ts +5 -4
- package/dist/kits-ui.js +22 -24
- package/dist/kits.d.ts +12 -12
- package/dist/kits.js +31 -31
- package/dist/knowledge-ui.d.ts +6 -5
- package/dist/knowledge-ui.js +26 -25
- package/dist/{mate-cli.d.ts → lead-cli.d.ts} +11 -11
- package/dist/{mate-cli.js → lead-cli.js} +38 -38
- package/dist/lead-commitments.js +4 -4
- package/dist/lead-context.d.ts +12 -2
- package/dist/lead-context.js +15 -17
- package/dist/{mate-contract.d.ts → lead-contract.d.ts} +3 -3
- package/dist/{mate-contract.js → lead-contract.js} +7 -6
- package/dist/{mate-doors.d.ts → lead-doors.d.ts} +6 -6
- package/dist/{mate-doors.js → lead-doors.js} +24 -24
- package/dist/lead-follow.d.ts +5 -5
- package/dist/lead-follow.js +9 -9
- package/dist/lead-people.d.ts +5 -5
- package/dist/lead-people.js +14 -14
- package/dist/{mate-progress.d.ts → lead-progress.d.ts} +9 -9
- package/dist/{mate-progress.js → lead-progress.js} +3 -3
- package/dist/{mate-tools.d.ts → lead-tools.d.ts} +19 -19
- package/dist/{mate-tools.js → lead-tools.js} +109 -101
- package/dist/{mate.d.ts → lead.d.ts} +27 -27
- package/dist/{mate.js → lead.js} +102 -102
- package/dist/ledger-view.d.ts +2 -1
- package/dist/ledger-view.js +27 -29
- package/dist/limits-ui.d.ts +3 -2
- package/dist/limits-ui.js +8 -8
- package/dist/live-bus.d.ts +50 -8
- package/dist/live-bus.js +133 -50
- package/dist/mcp-connect.d.ts +1 -1
- package/dist/mcp-connect.js +3 -3
- package/dist/mcp-core.js +1 -1
- package/dist/mcp-oauth.js +35 -36
- package/dist/memory-pass.d.ts +2 -2
- package/dist/memory-pass.js +7 -7
- package/dist/models-ui.d.ts +2 -1
- package/dist/models-ui.js +25 -35
- package/dist/monitoring-ui.d.ts +4 -3
- package/dist/monitoring-ui.js +13 -26
- package/dist/notification-rows.d.ts +2 -2
- package/dist/openrouter-models.d.ts +2 -1
- package/dist/openrouter-models.js +5 -9
- package/dist/operate.d.ts +3 -3
- package/dist/operate.js +46 -41
- package/dist/people-audit-ui.d.ts +2 -1
- package/dist/people-audit-ui.js +13 -13
- package/dist/policy-ui.d.ts +3 -2
- package/dist/policy-ui.js +17 -23
- package/dist/policy.d.ts +1 -1
- package/dist/principal.d.ts +1 -1
- package/dist/principal.js +2 -2
- package/dist/project-delete-ui.d.ts +4 -3
- package/dist/project-delete-ui.js +16 -28
- package/dist/project-delete.d.ts +1 -1
- package/dist/project-delete.js +26 -26
- package/dist/project-memory.js +1 -1
- package/dist/project-tools.d.ts +1 -1
- package/dist/project-tools.js +1 -1
- package/dist/pull-request-ui.d.ts +2 -1
- package/dist/pull-request-ui.js +17 -32
- package/dist/recipe-ui.d.ts +8 -7
- package/dist/recipe-ui.js +39 -32
- package/dist/release-adapters.d.ts +60 -0
- package/dist/release-adapters.js +435 -0
- package/dist/release-cli.d.ts +24 -0
- package/dist/release-cli.js +181 -0
- package/dist/release-gate.d.ts +80 -0
- package/dist/release-gate.js +150 -0
- package/dist/release-links.d.ts +29 -0
- package/dist/release-links.js +102 -0
- package/dist/release.d.ts +331 -0
- package/dist/release.js +550 -0
- package/dist/reply-shape.d.ts +2 -1
- package/dist/reply-shape.js +5 -5
- package/dist/repository-context-ui.d.ts +2 -1
- package/dist/repository-context-ui.js +2 -7
- package/dist/request-budget-ui.d.ts +2 -1
- package/dist/request-budget-ui.js +16 -16
- package/dist/result-review.d.ts +2 -3
- package/dist/result-review.js +3 -9
- package/dist/retention-ui.d.ts +7 -1
- package/dist/retention-ui.js +7 -11
- package/dist/retention.js +4 -4
- package/dist/scope.d.ts +2 -2
- package/dist/scout-report.d.ts +1 -1
- package/dist/scout-report.js +1 -1
- package/dist/serve.d.ts +11 -2
- package/dist/serve.js +105 -99
- package/dist/server/chat.d.ts +7 -10
- package/dist/server/chat.js +984 -1021
- package/dist/server/chrome.d.ts +291 -0
- package/dist/server/chrome.js +747 -0
- package/dist/server/console.css +2819 -0
- package/dist/server/flows.d.ts +2 -6
- package/dist/server/flows.js +854 -773
- package/dist/server/guards.d.ts +1 -1
- package/dist/server/guards.js +8 -5
- package/dist/server/handler-context.d.ts +1 -1
- package/dist/server/handler-context.js +1 -1
- package/dist/server/handler-registry.d.ts +8 -6
- package/dist/server/handler-registry.js +14 -2
- package/dist/server/http.d.ts +274 -0
- package/dist/server/http.js +239 -0
- package/dist/server/live.d.ts +34 -0
- package/dist/server/live.js +309 -0
- package/dist/server/pages.d.ts +2 -6
- package/dist/server/pages.js +808 -789
- package/dist/server/people-tokens.d.ts +1 -6
- package/dist/server/people-tokens.js +581 -573
- package/dist/server/remote.d.ts +4 -7
- package/dist/server/remote.js +39 -70
- package/dist/server/render-chat.d.ts +402 -0
- package/dist/server/render-chat.js +927 -0
- package/dist/server/render-pages.d.ts +535 -0
- package/dist/server/render-pages.js +1277 -0
- package/dist/server/render-people.d.ts +32 -0
- package/dist/server/render-people.js +121 -0
- package/dist/server/render-results.d.ts +744 -0
- package/dist/server/render-results.js +2237 -0
- package/dist/server/render-settings.d.ts +154 -0
- package/dist/server/render-settings.js +580 -0
- package/dist/server/render-tasks.d.ts +632 -0
- package/dist/server/render-tasks.js +2345 -0
- package/dist/server/request-context.d.ts +46 -0
- package/dist/server/request-context.js +17 -0
- package/dist/server/route-table.d.ts +25 -3
- package/dist/server/route-table.js +167 -77
- package/dist/server/runtime.d.ts +28 -20
- package/dist/server/runtime.js +7 -1
- package/dist/server/session.d.ts +138 -0
- package/dist/server/session.js +94 -0
- package/dist/server/settings.d.ts +1 -5
- package/dist/server/settings.js +2186 -2121
- package/dist/server/task-views.d.ts +11 -4
- package/dist/server/task-views.js +26 -22
- package/dist/server/tasks.d.ts +9 -9
- package/dist/server/tasks.js +1489 -1420
- package/dist/server-telemetry.d.ts +4 -3
- package/dist/server-telemetry.js +4 -8
- package/dist/setup-guide.d.ts +2 -2
- package/dist/skills-ui.d.ts +4 -3
- package/dist/skills-ui.js +14 -17
- package/dist/skills.d.ts +1 -1
- package/dist/skills.js +2 -1
- package/dist/slack-chat.d.ts +2 -2
- package/dist/slack-chat.js +6 -6
- package/dist/slack-settings.d.ts +3 -2
- package/dist/slack-settings.js +17 -42
- package/dist/spend-ui.d.ts +5 -4
- package/dist/spend-ui.js +17 -40
- package/dist/spend.d.ts +14 -14
- package/dist/spend.js +31 -31
- package/dist/sso-ui.d.ts +3 -2
- package/dist/sso-ui.js +26 -27
- package/dist/storage-ui.d.ts +2 -1
- package/dist/storage-ui.js +14 -33
- package/dist/store-baseline.d.ts +19 -0
- package/dist/store-baseline.js +2873 -0
- package/dist/store.d.ts +197 -249
- package/dist/store.js +747 -3084
- package/dist/subagent-admin.d.ts +53 -0
- package/dist/{teammate-admin.js → subagent-admin.js} +37 -37
- package/dist/{teammate-desk.d.ts → subagent-desk.d.ts} +22 -23
- package/dist/{teammate-desk.js → subagent-desk.js} +26 -35
- package/dist/{teammate-memory.d.ts → subagent-memory.d.ts} +17 -17
- package/dist/{teammate-memory.js → subagent-memory.js} +41 -41
- package/dist/{teammate-question.d.ts → subagent-question.d.ts} +6 -6
- package/dist/{teammate-question.js → subagent-question.js} +17 -17
- package/dist/{teammate-tools.d.ts → subagent-tools.d.ts} +18 -18
- package/dist/{teammate-tools.js → subagent-tools.js} +36 -36
- package/dist/{teammate-week.d.ts → subagent-week.d.ts} +10 -10
- package/dist/{teammate-week.js → subagent-week.js} +23 -23
- package/dist/{teammate-work.d.ts → subagent-work.d.ts} +21 -21
- package/dist/{teammate-work.js → subagent-work.js} +50 -50
- package/dist/subagents-ui.d.ts +22 -0
- package/dist/subagents-ui.js +137 -0
- package/dist/{teammates.d.ts → subagents.d.ts} +11 -11
- package/dist/{teammates.js → subagents.js} +21 -21
- package/dist/subscription-chat.d.ts +13 -13
- package/dist/subscription-chat.js +19 -19
- package/dist/surface.d.ts +19 -2
- package/dist/surface.js +20 -33
- package/dist/task-composer.d.ts +2 -1
- package/dist/task-composer.js +7 -7
- package/dist/task-status.d.ts +4 -3
- package/dist/task-status.js +15 -16
- package/dist/team-cli.d.ts +1 -0
- package/dist/team-cli.js +14 -2
- package/dist/team-http.d.ts +5 -9
- package/dist/team-http.js +5 -63
- package/dist/team-leads.js +13 -13
- package/dist/team-runtime.d.ts +2 -2
- package/dist/team-runtime.js +8 -8
- package/dist/team-ui.d.ts +2 -1
- package/dist/team-ui.js +2 -5
- package/dist/teams-chat.js +6 -6
- package/dist/teams-settings.d.ts +3 -2
- package/dist/teams-settings.js +20 -31
- package/dist/telegram-flow.d.ts +3 -3
- package/dist/telegram-flow.js +3 -3
- package/dist/{telegram-mate.d.ts → telegram-lead.d.ts} +5 -5
- package/dist/{telegram-mate.js → telegram-lead.js} +27 -27
- package/dist/telegram-settings.d.ts +3 -2
- package/dist/telegram-settings.js +14 -25
- package/dist/telegram-status.js +1 -1
- package/dist/telegram-team.d.ts +1 -1
- package/dist/telegram-team.js +5 -5
- package/dist/telegram.d.ts +1 -1
- package/dist/telegram.js +9 -30
- package/dist/text-limits.d.ts +18 -18
- package/dist/text-limits.js +18 -18
- package/dist/toolroll-update-ui.d.ts +3 -2
- package/dist/toolroll-update-ui.js +35 -39
- package/dist/toolroll-update.d.ts +8 -0
- package/dist/toolroll-update.js +45 -8
- package/dist/tools-ui.d.ts +5 -2
- package/dist/tools-ui.js +31 -31
- package/dist/when-html.d.ts +11 -3
- package/dist/when-html.js +5 -6
- package/dist/workspace-ui.d.ts +4 -2
- package/dist/workspace-ui.js +10 -10
- package/package.json +1 -2
- package/dist/server/shared.d.ts +0 -3151
- package/dist/server/shared.js +0 -12001
- package/dist/teammate-admin.d.ts +0 -53
- package/dist/teammates-ui.d.ts +0 -20
- package/dist/teammates-ui.js +0 -166
package/dist/browser-shell.d.ts
CHANGED
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import type { IncomingMessage, ServerResponse } from 'node:http';
|
|
2
2
|
import { type BrowserWorkspace } from './browser-workspace.js';
|
|
3
|
+
import { type Html } from './html.js';
|
|
3
4
|
export declare function browserAssetsAvailable(): boolean;
|
|
4
5
|
export declare function serveBrowserAsset(request: IncomingMessage, response: ServerResponse, path: string): boolean;
|
|
5
6
|
/** Retain the complete native document as the no-JavaScript/unloaded-bundle
|
|
6
7
|
* fallback. React replaces its root only once the local module has loaded.
|
|
7
8
|
* The data script is escaped for HTML parsing, not merely valid JSON. */
|
|
8
|
-
export declare function browserWorkspaceDocument(
|
|
9
|
+
export declare function browserWorkspaceDocument(document: Html, workspace: BrowserWorkspace, nonce: string, functionalScript: string): Html;
|
package/dist/browser-shell.js
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
/** The browser bundle is a presentation client. Only these fixed public assets
|
|
2
2
|
* are readable here; authenticated data stays in the existing page handlers. */
|
|
3
3
|
import { readFileSync } from 'node:fs';
|
|
4
|
-
import {
|
|
4
|
+
import {} from './browser-workspace.js';
|
|
5
|
+
import { html, jsonScript, replaceMarkup, scriptElement } from './html.js';
|
|
5
6
|
const assets = new Map();
|
|
6
7
|
function readAsset(name) {
|
|
7
8
|
// Compiled installation first; the second location supports source-based
|
|
@@ -47,16 +48,15 @@ export function serveBrowserAsset(request, response, path) {
|
|
|
47
48
|
/** Retain the complete native document as the no-JavaScript/unloaded-bundle
|
|
48
49
|
* fallback. React replaces its root only once the local module has loaded.
|
|
49
50
|
* The data script is escaped for HTML parsing, not merely valid JSON. */
|
|
50
|
-
export function browserWorkspaceDocument(
|
|
51
|
+
export function browserWorkspaceDocument(document, workspace, nonce, functionalScript) {
|
|
51
52
|
const initialize = `window.addEventListener('standing-orders:workspace-rendered',function initializeWorkspace(){window.removeEventListener('standing-orders:workspace-rendered',initializeWorkspace);${functionalScript}});`;
|
|
52
53
|
// A cross-page fade the browser gives up on rejects its promises; settle them from the head, before the
|
|
53
54
|
// first frame (the app's own listener arrives too late when a page is revealed before the bundle runs).
|
|
54
55
|
const settleFades = `(function(){function s(e){var f=e.viewTransition;if(f)[f.finished,f.ready,f.updateCallbackDone].forEach(function(p){if(p)p.catch(function(){})})}addEventListener('pageswap',s);addEventListener('pagereveal',s)})();`;
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
.replace('</body>', () => `</div><script type="application/json" id="standing-orders-workspace-data" nonce="${nonce}">${serializeBrowserWorkspace(workspace)}</script><script nonce="${nonce}">${initialize}</script><script type="module" src="/assets/workspace.js" nonce="${nonce}"></script></body>`);
|
|
56
|
+
// Each insertion is markup built here; the page's own markup (and its data) is never re-read as a pattern.
|
|
57
|
+
let out = replaceMarkup(document, /<\/head>/, () =>
|
|
58
|
+
// A page showing a password keeps to its one script (the sensitivity contract), so it goes without.
|
|
59
|
+
html `<link rel="stylesheet" href="/assets/workspace.css">${workspace.sensitive ? "" : scriptElement(settleFades, { nonce })}</head>`);
|
|
60
|
+
out = replaceMarkup(out, /<body>/, () => html `<body><div id="standing-orders-workspace">`);
|
|
61
|
+
return replaceMarkup(out, /<\/body>/, () => html `</div>${jsonScript(workspace, { id: "standing-orders-workspace-data", nonce })}${scriptElement(initialize, { nonce })}<script type="module" src="/assets/workspace.js" nonce="${nonce}"></script></body>`);
|
|
62
62
|
}
|
|
@@ -430,9 +430,9 @@ export type BrowserTaskView = {
|
|
|
430
430
|
} | null;
|
|
431
431
|
/** What the agent did last on the live run, and when; the page words it against its own clock (activity-line.ts). */
|
|
432
432
|
activity?: RunActivity | null;
|
|
433
|
-
/** The task's live
|
|
433
|
+
/** The task's live room (GET /live?room=task:<root>): change nudges and who else has it open. */
|
|
434
434
|
live?: {
|
|
435
|
-
|
|
435
|
+
room: string;
|
|
436
436
|
at: string | null;
|
|
437
437
|
} | null;
|
|
438
438
|
/** Stop, on the Building card: the exact live build's stop form (posts its run id). */
|
|
@@ -765,7 +765,7 @@ export type BrowserRunChecks = {
|
|
|
765
765
|
export type BrowserFlowStage = {
|
|
766
766
|
id: string;
|
|
767
767
|
title: string;
|
|
768
|
-
kind: "inbox" | "task" | "report" | "approval" | "check" | "pull-request" | "update" | "notify" | "sort" | "draft" | "request" | "email" | "tool" | "wait" | "
|
|
768
|
+
kind: "inbox" | "task" | "report" | "approval" | "check" | "pull-request" | "update" | "notify" | "sort" | "draft" | "request" | "email" | "tool" | "wait" | "subagent" | "send" | "choose" | "done";
|
|
769
769
|
zone: {
|
|
770
770
|
x: number;
|
|
771
771
|
y: number;
|
|
@@ -835,9 +835,9 @@ export type BrowserFlowStage = {
|
|
|
835
835
|
minutes: number;
|
|
836
836
|
to: string | null;
|
|
837
837
|
} | undefined;
|
|
838
|
-
/** v92: the
|
|
839
|
-
|
|
840
|
-
/** v96: a
|
|
838
|
+
/** v92: the subagent who decides (an approval zone) or handles (a subagent zone) it. */
|
|
839
|
+
subagent?: string | undefined;
|
|
840
|
+
/** v96: a subagent zone sends what the subagent writes back to whoever asked. */
|
|
841
841
|
reply?: boolean | undefined;
|
|
842
842
|
/** A "Person chooses" zone's buttons: each one's words and the zone it leads to ("end" ignores the card). */
|
|
843
843
|
options?: {
|
|
@@ -921,7 +921,7 @@ export type BrowserFlowCard = {
|
|
|
921
921
|
at: string;
|
|
922
922
|
label: string;
|
|
923
923
|
} | null;
|
|
924
|
-
/** v92: a
|
|
924
|
+
/** v92: a subagent's open question about this visit, and whether the viewer is the one asked. */
|
|
925
925
|
question?: {
|
|
926
926
|
id: number;
|
|
927
927
|
from: string;
|
|
@@ -932,13 +932,13 @@ export type BrowserFlowCard = {
|
|
|
932
932
|
}[];
|
|
933
933
|
askedOf: string;
|
|
934
934
|
mine: boolean;
|
|
935
|
-
/** v94: a tool call waiting for approval — why the
|
|
935
|
+
/** v94: a tool call waiting for approval — why the subagent wants it, and why it needs approval. */
|
|
936
936
|
call?: {
|
|
937
937
|
why: string;
|
|
938
938
|
rule: string;
|
|
939
939
|
} | null;
|
|
940
940
|
} | null;
|
|
941
|
-
/** v92: what the
|
|
941
|
+
/** v92: what the subagent said when it handed this decision to a person. */
|
|
942
942
|
handoff?: {
|
|
943
943
|
from: string;
|
|
944
944
|
note: string;
|
|
@@ -973,7 +973,7 @@ export type BrowserFlowCard = {
|
|
|
973
973
|
person: string;
|
|
974
974
|
at: string;
|
|
975
975
|
} | null;
|
|
976
|
-
/** v94: every tool call
|
|
976
|
+
/** v94: every tool call subagents made or asked to make on this card, oldest first: the receipts. */
|
|
977
977
|
calls?: {
|
|
978
978
|
id: number;
|
|
979
979
|
who: string;
|
|
@@ -983,8 +983,8 @@ export type BrowserFlowCard = {
|
|
|
983
983
|
why: string;
|
|
984
984
|
result: string | null;
|
|
985
985
|
at: string;
|
|
986
|
-
/** v97: the
|
|
987
|
-
|
|
986
|
+
/** v97: the subagent's id and the action that undoes this call, when a person can press Undo. */
|
|
987
|
+
subagent?: number;
|
|
988
988
|
undo?: string | null;
|
|
989
989
|
}[];
|
|
990
990
|
};
|
|
@@ -1065,8 +1065,8 @@ export type BrowserFlowView = {
|
|
|
1065
1065
|
me: string;
|
|
1066
1066
|
/** Whether sort zones can run: an OpenRouter key is saved in Settings → AI providers. */
|
|
1067
1067
|
sortReady: boolean;
|
|
1068
|
-
/** v92: the project's
|
|
1069
|
-
|
|
1068
|
+
/** v92: the project's subagents, to staff zones with. */
|
|
1069
|
+
subagents?: {
|
|
1070
1070
|
handle: string;
|
|
1071
1071
|
label: string;
|
|
1072
1072
|
name: string;
|
|
@@ -1276,7 +1276,6 @@ export type BrowserSignIn = {
|
|
|
1276
1276
|
};
|
|
1277
1277
|
/** Safe inside a script[type=application/json] element. JSON escaping alone
|
|
1278
1278
|
* does not stop the HTML parser from closing that element at </script>. */
|
|
1279
|
-
export declare function serializeBrowserWorkspace(workspace: BrowserWorkspace): string;
|
|
1280
1279
|
export declare const BROWSER_CREW_LIMIT = 40;
|
|
1281
1280
|
export type BrowserCrewOptions = {
|
|
1282
1281
|
evidenceRoot?: string;
|
|
@@ -9,9 +9,6 @@ export function needsYouLabelOf(count, projectName, saturated = false) {
|
|
|
9
9
|
}
|
|
10
10
|
/** Safe inside a script[type=application/json] element. JSON escaping alone
|
|
11
11
|
* does not stop the HTML parser from closing that element at </script>. */
|
|
12
|
-
export function serializeBrowserWorkspace(workspace) {
|
|
13
|
-
return JSON.stringify(workspace).replace(/</g, '\\u003c').replace(/\u2028/g, '\\u2028').replace(/\u2029/g, '\\u2029');
|
|
14
|
-
}
|
|
15
12
|
export const BROWSER_CREW_LIMIT = 40;
|
|
16
13
|
/** A bounded recent family list. The caller supplies its already admitted
|
|
17
14
|
* access; an optional project can only narrow it. Admission and family grouping
|
package/dist/budget-alerts.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { budgetLabel,
|
|
1
|
+
import { budgetLabel, subagentNames, usd } from "./spend.js";
|
|
2
2
|
const MARKS = [100, 80, 50];
|
|
3
3
|
export function budgetAlertPass(store, now) {
|
|
4
4
|
const { month, budgets } = store.monthSpend(now);
|
|
5
5
|
const sent = [];
|
|
6
|
-
const names =
|
|
6
|
+
const names = subagentNames(store.handle);
|
|
7
7
|
for (const budget of budgets) {
|
|
8
8
|
const mark = MARKS.find(one => budget.percent >= one);
|
|
9
9
|
if (mark === undefined)
|
|
@@ -13,7 +13,7 @@ export function budgetAlertPass(store, now) {
|
|
|
13
13
|
// A higher mark already sent this month covers this one.
|
|
14
14
|
if (MARKS.filter(one => one >= mark).some(one => store.handle.prepare("SELECT 1 AS hit FROM notification WHERE dedupe_key = ?").get(key(one)) !== undefined))
|
|
15
15
|
continue;
|
|
16
|
-
const label = budgetLabel(budget, budget.scope === "
|
|
16
|
+
const label = budgetLabel(budget, budget.scope === "subagent" ? names.get(Number(budget.key)) : undefined);
|
|
17
17
|
const fresh = store.enqueueNotification({
|
|
18
18
|
dedupeKey: key(mark), kind: "budget-alert", pushClass: "attention", link: `/spend?month=${month}`,
|
|
19
19
|
subject: `${label} budget: ${mark}% used`,
|
package/dist/chat-actions.d.ts
CHANGED
|
@@ -143,48 +143,53 @@ export declare const CHAT_ACTIONS: {
|
|
|
143
143
|
readonly protected: false;
|
|
144
144
|
readonly password: false;
|
|
145
145
|
};
|
|
146
|
-
readonly
|
|
147
|
-
readonly label: "Add
|
|
146
|
+
readonly subagent_create: {
|
|
147
|
+
readonly label: "Add subagent";
|
|
148
148
|
readonly protected: false;
|
|
149
149
|
readonly password: false;
|
|
150
150
|
};
|
|
151
|
-
readonly
|
|
151
|
+
readonly subagent_soul: {
|
|
152
152
|
readonly label: "Update soul file";
|
|
153
153
|
readonly protected: false;
|
|
154
154
|
readonly password: false;
|
|
155
155
|
};
|
|
156
|
-
readonly
|
|
157
|
-
readonly label: "Change
|
|
156
|
+
readonly subagent_state: {
|
|
157
|
+
readonly label: "Change subagent";
|
|
158
158
|
readonly protected: false;
|
|
159
159
|
readonly password: false;
|
|
160
160
|
};
|
|
161
|
-
readonly
|
|
162
|
-
readonly label: "Tell
|
|
161
|
+
readonly subagent_note: {
|
|
162
|
+
readonly label: "Tell subagent";
|
|
163
163
|
readonly protected: false;
|
|
164
164
|
readonly password: false;
|
|
165
165
|
};
|
|
166
|
-
readonly
|
|
167
|
-
readonly label: "
|
|
166
|
+
readonly subagent_ask: {
|
|
167
|
+
readonly label: "Ask subagent";
|
|
168
168
|
readonly protected: false;
|
|
169
169
|
readonly password: false;
|
|
170
170
|
};
|
|
171
|
-
readonly
|
|
172
|
-
readonly label: "
|
|
171
|
+
readonly subagent_answer: {
|
|
172
|
+
readonly label: "Answer subagent";
|
|
173
173
|
readonly protected: false;
|
|
174
174
|
readonly password: false;
|
|
175
175
|
};
|
|
176
|
-
readonly
|
|
177
|
-
readonly label: "Change
|
|
176
|
+
readonly subagent_tools: {
|
|
177
|
+
readonly label: "Change subagent's tools";
|
|
178
178
|
readonly protected: false;
|
|
179
179
|
readonly password: false;
|
|
180
180
|
};
|
|
181
|
-
readonly
|
|
182
|
-
readonly label: "Change
|
|
181
|
+
readonly subagent_memory: {
|
|
182
|
+
readonly label: "Change subagent's memory";
|
|
183
183
|
readonly protected: false;
|
|
184
184
|
readonly password: false;
|
|
185
185
|
};
|
|
186
|
-
readonly
|
|
187
|
-
readonly label: "
|
|
186
|
+
readonly subagent_routine: {
|
|
187
|
+
readonly label: "Change subagent's routines";
|
|
188
|
+
readonly protected: false;
|
|
189
|
+
readonly password: false;
|
|
190
|
+
};
|
|
191
|
+
readonly subagent_undo: {
|
|
192
|
+
readonly label: "Undo subagent's call";
|
|
188
193
|
readonly protected: false;
|
|
189
194
|
readonly password: false;
|
|
190
195
|
};
|
|
@@ -251,7 +256,7 @@ export declare function sharedActionReviewPath(id: number): string;
|
|
|
251
256
|
export declare function mintSharedActionReview(store: Store, who: VerifiedApprover, id: number, root: string, now: Date): {
|
|
252
257
|
payload: {
|
|
253
258
|
version: 1;
|
|
254
|
-
operation: "decision_record" | "decision_retire" | "flow_card_add" | "flow_card_approve" | "flow_card_assign" | "flow_card_cancel" | "flow_card_choose" | "flow_card_comment" | "flow_card_move" | "flow_card_send_back" | "flow_card_watch" | "flow_create" | "flow_edit" | "flow_script_save" | "flow_starter" | "flow_trigger_add" | "flow_trigger_pause" | "flow_trigger_remove" | "flow_trigger_resume" | "kit_setup" | "knowledge_instructions" | "knowledge_remove" | "knowledge_restore" | "knowledge_save" | "lead_about_you" | "result_accept" | "scope_approve" | "skill_disable" | "skill_enable" | "skill_import" | "skill_restore" | "skill_test" | "
|
|
259
|
+
operation: "decision_record" | "decision_retire" | "flow_card_add" | "flow_card_approve" | "flow_card_assign" | "flow_card_cancel" | "flow_card_choose" | "flow_card_comment" | "flow_card_move" | "flow_card_send_back" | "flow_card_watch" | "flow_create" | "flow_edit" | "flow_script_save" | "flow_starter" | "flow_trigger_add" | "flow_trigger_pause" | "flow_trigger_remove" | "flow_trigger_resume" | "kit_setup" | "knowledge_instructions" | "knowledge_remove" | "knowledge_restore" | "knowledge_save" | "lead_about_you" | "result_accept" | "scope_approve" | "skill_disable" | "skill_enable" | "skill_import" | "skill_restore" | "skill_test" | "subagent_answer" | "subagent_ask" | "subagent_create" | "subagent_memory" | "subagent_note" | "subagent_routine" | "subagent_soul" | "subagent_state" | "subagent_tools" | "subagent_undo" | "task_cancel" | "task_resume" | "tool_add" | "tool_remove";
|
|
255
260
|
request: {
|
|
256
261
|
[x: string]: unknown;
|
|
257
262
|
};
|