loopengine 0.3.74 → 0.3.76
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/core/http-notifier.js +8 -1
- package/dist/core/messaging/connector.d.ts +2 -0
- package/dist/core/messaging/connectors/slack/format.js +22 -6
- package/dist/core/messaging/connectors/telegram/format.js +26 -12
- package/dist/core/messaging/connectors/telegram/index.js +5 -0
- package/dist/core/messaging/engine.d.ts +13 -0
- package/dist/core/messaging/engine.js +40 -4
- package/dist/core/messaging/threads.d.ts +3 -0
- package/dist/core/messaging/threads.js +2 -2
- package/dist/index.d.ts +3 -2
- package/dist/index.js +3 -2
- package/package.json +1 -1
|
@@ -7,7 +7,7 @@ import { DatabaseApprover } from './http-notify-triggers/database.js';
|
|
|
7
7
|
import { RedisQueueApprover } from './http-notify-triggers/redis.js';
|
|
8
8
|
import { agentDirFor, createAgentEnv } from './agent-env.js';
|
|
9
9
|
import { notifierConfigFromFile, readActiveConnections, readNotifierFile } from './notifier-file.js';
|
|
10
|
-
import { recordThread } from './messaging/threads.js';
|
|
10
|
+
import { findThreadByPending, recordThread } from './messaging/threads.js';
|
|
11
11
|
import { recordTelegramMessage } from './messaging/connectors/telegram/store.js';
|
|
12
12
|
const EMPTY = {};
|
|
13
13
|
// Keyed by the AgentConfig object itself, not its httpNotifier field
|
|
@@ -190,6 +190,13 @@ function buildResolved(httpNotifier, agentDir) {
|
|
|
190
190
|
recordTelegramMessage(agentDir, { chat, id: messageId, root: root ?? messageId, fromBot: true, text });
|
|
191
191
|
if (pendingId && kind && !root)
|
|
192
192
|
recordThread(agentDir, { app: 'telegram', conversation: chat, ts: messageId, pendingId, kind });
|
|
193
|
+
// Its buttons are on its last message, recorded so a decision
|
|
194
|
+
// made by reply can take them away.
|
|
195
|
+
if (pendingId && root) {
|
|
196
|
+
const link = findThreadByPending(agentDir, pendingId);
|
|
197
|
+
if (link)
|
|
198
|
+
recordThread(agentDir, { ...link, buttonsTs: messageId });
|
|
199
|
+
}
|
|
193
200
|
},
|
|
194
201
|
});
|
|
195
202
|
return {
|
|
@@ -60,4 +60,6 @@ export interface MessagingConnector {
|
|
|
60
60
|
/** Replaces the request message itself (and its buttons) with the
|
|
61
61
|
* outcome, so nobody acts on a decision already made. Optional. */
|
|
62
62
|
replaceMessage?(conversation: string, ts: string, text: string): Promise<void>;
|
|
63
|
+
/** Takes a message's buttons away and leaves its text. Optional. */
|
|
64
|
+
removeButtons?(conversation: string, ts: string): Promise<void>;
|
|
63
65
|
}
|
|
@@ -11,15 +11,31 @@ const CLOSE = '\u0002';
|
|
|
11
11
|
// The agent's own writing (slackAgentText): formatted, links shown.
|
|
12
12
|
const OPEN_AGENT = '\u0003';
|
|
13
13
|
const CLOSE_AGENT = '\u0004';
|
|
14
|
-
const MARKERS = /[\u0001-\
|
|
14
|
+
const MARKERS = /[\u0001-\u0006]/g;
|
|
15
15
|
const KEEP = /(```[\s\S]*?```|`[^`\n]*`|\u0001[\s\S]*?\u0002|\u0003[\s\S]*?\u0004)/;
|
|
16
|
+
// Where a kept piece sits while the text around it is converted.
|
|
17
|
+
const SLOT = '\u0005';
|
|
18
|
+
const SLOT_END = '\u0006';
|
|
19
|
+
const SLOTS = /\u0005(\d+)\u0006/g;
|
|
16
20
|
export function toSlackMrkdwn(markdown) {
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
21
|
+
// The kept pieces (code, someone else's text, the agent's writing) are
|
|
22
|
+
// set aside while the rest is converted as one, so formatting around
|
|
23
|
+
// them pairs up: "**Answered by <name>:**", "~~<old value>~~".
|
|
24
|
+
const kept = [];
|
|
25
|
+
const prose = markdown
|
|
20
26
|
.split(KEEP)
|
|
21
|
-
.map((part, i) =>
|
|
22
|
-
|
|
27
|
+
.map((part, i) => {
|
|
28
|
+
if (i % 2 === 0)
|
|
29
|
+
return part;
|
|
30
|
+
kept.push(part);
|
|
31
|
+
return `${SLOT}${kept.length - 1}${SLOT_END}`;
|
|
32
|
+
})
|
|
33
|
+
.join('');
|
|
34
|
+
return convertProse(prose)
|
|
35
|
+
.replace(SLOTS, (_m, n) => {
|
|
36
|
+
const part = kept[Number(n)];
|
|
37
|
+
return part.startsWith(OPEN_AGENT) ? agentMrkdwn(part.slice(1, -1)) : part;
|
|
38
|
+
})
|
|
23
39
|
.replace(MARKERS, '');
|
|
24
40
|
}
|
|
25
41
|
// A run of Markdown table lines ("| a | b |").
|
|
@@ -10,8 +10,12 @@ const CLOSE = '\u0002';
|
|
|
10
10
|
// The agent's own writing (telegramAgentText): formatted, links shown.
|
|
11
11
|
const OPEN_AGENT = '\u0003';
|
|
12
12
|
const CLOSE_AGENT = '\u0004';
|
|
13
|
-
const MARKERS = /[\u0001-\
|
|
13
|
+
const MARKERS = /[\u0001-\u0006]/g;
|
|
14
14
|
const KEEP = /(```[\s\S]*?```|`[^`\n]*`|\u0001[\s\S]*?\u0002|\u0003[\s\S]*?\u0004)/;
|
|
15
|
+
// Where a kept piece sits while the text around it is converted.
|
|
16
|
+
const SLOT = '\u0005';
|
|
17
|
+
const SLOT_END = '\u0006';
|
|
18
|
+
const SLOTS = /\u0005(\d+)\u0006/g;
|
|
15
19
|
// Telegram's limit is 4096 characters of text after the tags are read;
|
|
16
20
|
// cutting the Markdown well short of it keeps the tags whole.
|
|
17
21
|
const MAX_MARKDOWN = 3800;
|
|
@@ -98,23 +102,33 @@ export function splitTelegramMarkdown(markdown, max = MAX_MARKDOWN - 100) {
|
|
|
98
102
|
}
|
|
99
103
|
export function toTelegramHtml(markdown) {
|
|
100
104
|
const cut = markdown.length > MAX_MARKDOWN ? markdown.slice(0, MAX_MARKDOWN).trimEnd() + '\n…' : markdown;
|
|
101
|
-
|
|
105
|
+
// The kept pieces (code, someone else's text, the agent's writing) are
|
|
106
|
+
// set aside while the rest is converted as one, so formatting around
|
|
107
|
+
// them pairs up: "**Question from <agent>:**" is bold.
|
|
108
|
+
const kept = [];
|
|
109
|
+
const prose = cut
|
|
102
110
|
.split(KEEP)
|
|
103
111
|
.map((part, i) => {
|
|
104
112
|
if (i % 2 === 0)
|
|
105
|
-
return
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
const plain = part.replace(MARKERS, '');
|
|
109
|
-
if (part.startsWith(OPEN))
|
|
110
|
-
return html(plain);
|
|
111
|
-
if (part.startsWith('```'))
|
|
112
|
-
return `<pre>${html(plain.slice(3, -3).replace(/^[\w-]*\n/, ''))}</pre>`;
|
|
113
|
-
return `<code>${html(plain.slice(1, -1))}</code>`;
|
|
113
|
+
return part;
|
|
114
|
+
kept.push(part);
|
|
115
|
+
return `${SLOT}${kept.length - 1}${SLOT_END}`;
|
|
114
116
|
})
|
|
115
|
-
.join('')
|
|
117
|
+
.join('');
|
|
118
|
+
return convertProse(prose)
|
|
119
|
+
.replace(SLOTS, (_m, n) => keptHtml(kept[Number(n)]))
|
|
116
120
|
.replace(MARKERS, '');
|
|
117
121
|
}
|
|
122
|
+
function keptHtml(part) {
|
|
123
|
+
if (part.startsWith(OPEN_AGENT))
|
|
124
|
+
return agentHtml(part.slice(1, -1));
|
|
125
|
+
const plain = part.replace(MARKERS, '');
|
|
126
|
+
if (part.startsWith(OPEN))
|
|
127
|
+
return html(plain);
|
|
128
|
+
if (part.startsWith('```'))
|
|
129
|
+
return `<pre>${html(plain.slice(3, -3).replace(/^[\w-]*\n/, ''))}</pre>`;
|
|
130
|
+
return `<code>${html(plain.slice(1, -1))}</code>`;
|
|
131
|
+
}
|
|
118
132
|
// A run of Markdown table lines ("| a | b |").
|
|
119
133
|
const TABLE = /((?:^[ \t]*\|.*\|[ \t]*(?:\n|$)){2,})/m;
|
|
120
134
|
/** The agent's Markdown: code and tables as fixed-width text, the rest
|
|
@@ -92,6 +92,11 @@ export function createTelegramConnector(botToken, agentDir) {
|
|
|
92
92
|
if (!edited.ok)
|
|
93
93
|
console.error('[loopengine] Telegram editMessageText failed:', edited.description);
|
|
94
94
|
},
|
|
95
|
+
async removeButtons(conversation, ts) {
|
|
96
|
+
const edited = await callTelegram(botToken, 'editMessageReplyMarkup', { chat_id: conversation, message_id: Number(ts), reply_markup: { inline_keyboard: [] } });
|
|
97
|
+
if (!edited.ok)
|
|
98
|
+
console.error('[loopengine] Telegram editMessageReplyMarkup failed:', edited.description);
|
|
99
|
+
},
|
|
95
100
|
};
|
|
96
101
|
}
|
|
97
102
|
/** Stops a clicked button's spinner, with a short note when there's one. */
|
|
@@ -51,6 +51,9 @@ export interface DecisionOutcome {
|
|
|
51
51
|
morePending?: boolean;
|
|
52
52
|
/** The agent's reply once the run finished. */
|
|
53
53
|
text?: string;
|
|
54
|
+
/** The run came from a job thread, which gets the run's own next
|
|
55
|
+
* request or result (core/messaging/jobs.ts), so nothing is added. */
|
|
56
|
+
inJob?: boolean;
|
|
54
57
|
}
|
|
55
58
|
/** Handles one person's message: a reply in a request's thread gets an
|
|
56
59
|
* answer; anything else is left alone. */
|
|
@@ -63,12 +66,22 @@ export declare function isPlainApproval(text: string): boolean;
|
|
|
63
66
|
/** For a decision made outside the thread (the request's own buttons):
|
|
64
67
|
* replaces the thread's message with buttons, if any, with `text`. */
|
|
65
68
|
export declare function settleThreadChoice(deps: MessagingDeps, pendingId: string, text: string): Promise<void>;
|
|
69
|
+
/** For a decision made away from the chat (the web link): replaces the
|
|
70
|
+
* request message, and any message with buttons in its thread, with
|
|
71
|
+
* `text`, so nobody acts on it there. Nothing when it wasn't posted in
|
|
72
|
+
* a chat. */
|
|
73
|
+
export declare function settleRequest(deps: MessagingDeps, pendingId: string, text: string): Promise<void>;
|
|
66
74
|
/** A click on one of the engine's own buttons (Approve as changed, Keep
|
|
67
75
|
* original, Confirm, Cancel) — the caller has already checked the
|
|
68
76
|
* person may decide. Returns what the clicked message should now say. */
|
|
69
77
|
export declare function handleMessagingAction(action: Exclude<MessagingAction, 'deny'>, pendingId: string, user: string, deps: MessagingDeps): Promise<string>;
|
|
70
78
|
/** What to say in the thread once a decision is recorded. */
|
|
71
79
|
export declare function outcomeText(decision: 'approve' | 'deny' | 'answer', who: string, outcome: DecisionOutcome, answer?: string): string;
|
|
80
|
+
/** What to add in the thread once a decision said there is in, if
|
|
81
|
+
* anything: nothing when the agent sent a new request, which speaks
|
|
82
|
+
* for itself (and is already above this), or when the run's job thread
|
|
83
|
+
* gets its outcome from the job. */
|
|
84
|
+
export declare function followUpText(outcome: DecisionOutcome): string | undefined;
|
|
72
85
|
/** The thread as chat messages: the agent's own replies as `assistant`,
|
|
73
86
|
* people's as `user` (with who said it), the request itself left out
|
|
74
87
|
* because the prompt already describes it. The newest message is
|
|
@@ -105,9 +105,14 @@ export async function handleInboundMessage(message, deps) {
|
|
|
105
105
|
]);
|
|
106
106
|
return;
|
|
107
107
|
}
|
|
108
|
-
const outcome = await deps.decide(link.pendingId, verdict.decision === 'answer' ? { kind: 'answer', answer: verdict.answer } : { kind: 'deny' });
|
|
109
108
|
const answer = verdict.decision === 'answer' ? connector.escape(verdict.answer) : undefined;
|
|
110
|
-
|
|
109
|
+
// Said before the decision goes in: the run carries on inside
|
|
110
|
+
// deps.decide and may post its next request before it returns.
|
|
111
|
+
await say(verdict.decision === 'deny' ? `Denied by ${who}. Letting the agent know…` : `Answered by ${who}: "${answer}". The agent is carrying on…`);
|
|
112
|
+
const outcome = await deps.decide(link.pendingId, verdict.decision === 'answer' ? { kind: 'answer', answer: verdict.answer } : { kind: 'deny' });
|
|
113
|
+
const after = followUpText(outcome);
|
|
114
|
+
if (after)
|
|
115
|
+
await say(after);
|
|
111
116
|
if (!outcome.error && !outcome.alreadyResolved) {
|
|
112
117
|
const what = link.kind === 'approval' ? `\`${item.tool}\`` : 'The question';
|
|
113
118
|
await replaceRequest(connector, link, `${what} was ${verdict.decision === 'deny' ? 'denied' : `answered ("${answer}")`} by ${who} in the thread.`);
|
|
@@ -199,7 +204,9 @@ async function runApproved(deps, link, tool, args, who) {
|
|
|
199
204
|
const edited = Boolean(link.proposedArgs);
|
|
200
205
|
await connector.postInThread(link.conversation, link.ts, `Approved${edited ? ' as changed' : ''} by ${who}. Running \`${tool}\` with:\n${formatArgs(args, connector.escape, await deps.toolSchema(tool))}`);
|
|
201
206
|
const outcome = await deps.decide(link.pendingId, { kind: 'approve', ...(edited ? { editedArgs: args } : {}) });
|
|
202
|
-
|
|
207
|
+
const after = followUpText(outcome);
|
|
208
|
+
if (after)
|
|
209
|
+
await connector.postInThread(link.conversation, link.ts, after);
|
|
203
210
|
if (!outcome.error && !outcome.alreadyResolved) {
|
|
204
211
|
await replaceRequest(connector, link, `\`${tool}\` was approved${edited ? ' as changed' : ''} by ${who} in the thread.`);
|
|
205
212
|
await settleChoice(deps, link, `Approved${edited ? ' as changed' : ''} by ${who}.`);
|
|
@@ -229,10 +236,24 @@ export async function settleThreadChoice(deps, pendingId, text) {
|
|
|
229
236
|
if (link)
|
|
230
237
|
await settleChoice(deps, link, text);
|
|
231
238
|
}
|
|
239
|
+
/** For a decision made away from the chat (the web link): replaces the
|
|
240
|
+
* request message, and any message with buttons in its thread, with
|
|
241
|
+
* `text`, so nobody acts on it there. Nothing when it wasn't posted in
|
|
242
|
+
* a chat. */
|
|
243
|
+
export async function settleRequest(deps, pendingId, text) {
|
|
244
|
+
const link = findThreadByPending(deps.agentDir, pendingId);
|
|
245
|
+
if (!link || link.app !== deps.connector.app)
|
|
246
|
+
return;
|
|
247
|
+
await replaceRequest(deps.connector, link, text);
|
|
248
|
+
await settleChoice(deps, link, text);
|
|
249
|
+
}
|
|
232
250
|
async function replaceRequest(connector, link, text) {
|
|
233
251
|
if (!connector.replaceMessage)
|
|
234
252
|
return;
|
|
235
253
|
await connector.replaceMessage(link.conversation, link.ts, text).catch((err) => console.error('[loopengine] could not update the request message:', err));
|
|
254
|
+
// A long request's buttons are on its last message.
|
|
255
|
+
if (link.buttonsTs && connector.removeButtons)
|
|
256
|
+
await connector.removeButtons(link.conversation, link.buttonsTs).catch((err) => console.error('[loopengine] could not update the request message:', err));
|
|
236
257
|
}
|
|
237
258
|
/** A click on one of the engine's own buttons (Approve as changed, Keep
|
|
238
259
|
* original, Confirm, Cancel) — the caller has already checked the
|
|
@@ -275,9 +296,24 @@ export function outcomeText(decision, who, outcome, answer) {
|
|
|
275
296
|
if (outcome.stillWaiting)
|
|
276
297
|
return `${what}. The agent is still waiting on another decision from the same step.`;
|
|
277
298
|
if (outcome.morePending)
|
|
278
|
-
return `${what}. The agent
|
|
299
|
+
return `${what}. The agent needed another decision and sent a new request.`;
|
|
279
300
|
return `${what}.${outcome.text ? `\n> ${outcome.text.replace(/\n/g, '\n> ')}` : ''}`;
|
|
280
301
|
}
|
|
302
|
+
/** What to add in the thread once a decision said there is in, if
|
|
303
|
+
* anything: nothing when the agent sent a new request, which speaks
|
|
304
|
+
* for itself (and is already above this), or when the run's job thread
|
|
305
|
+
* gets its outcome from the job. */
|
|
306
|
+
export function followUpText(outcome) {
|
|
307
|
+
if (outcome.error)
|
|
308
|
+
return `Couldn't record that: ${outcome.error}`;
|
|
309
|
+
if (outcome.alreadyResolved)
|
|
310
|
+
return 'This was already decided elsewhere.';
|
|
311
|
+
if (outcome.stillWaiting)
|
|
312
|
+
return 'The agent is still waiting on another decision from the same step.';
|
|
313
|
+
if (outcome.morePending || outcome.inJob)
|
|
314
|
+
return undefined;
|
|
315
|
+
return outcome.text ? `Done.\n> ${outcome.text.replace(/\n/g, '\n> ')}` : 'Done.';
|
|
316
|
+
}
|
|
281
317
|
/** The thread as chat messages: the agent's own replies as `assistant`,
|
|
282
318
|
* people's as `user` (with who said it), the request itself left out
|
|
283
319
|
* because the prompt already describes it. The newest message is
|
|
@@ -14,6 +14,9 @@ export interface ThreadLink {
|
|
|
14
14
|
* proposed change, a Confirm), so it can be replaced once the request
|
|
15
15
|
* is decided and its buttons don't linger. */
|
|
16
16
|
choiceTs?: string;
|
|
17
|
+
/** A long request goes out as several messages (Telegram), its
|
|
18
|
+
* buttons on the last: that message, when it isn't `ts`. */
|
|
19
|
+
buttonsTs?: string;
|
|
17
20
|
}
|
|
18
21
|
/** Appends one request's thread. Never throws: a request that can't be
|
|
19
22
|
* mapped still works through its buttons and link. */
|
|
@@ -12,8 +12,8 @@ function threadsFile(agentDir) {
|
|
|
12
12
|
export function recordThread(agentDir, link) {
|
|
13
13
|
try {
|
|
14
14
|
mkdirSync(join(agentDir, '.messaging'), { recursive: true });
|
|
15
|
-
const { app, conversation, ts, pendingId, kind, proposedArgs, choiceTs } = link;
|
|
16
|
-
appendFileSync(threadsFile(agentDir), JSON.stringify({ app, conversation, ts, pendingId, kind, ...(proposedArgs ? { proposedArgs } : {}), ...(choiceTs ? { choiceTs } : {}), at: new Date().toISOString() }) + '\n');
|
|
15
|
+
const { app, conversation, ts, pendingId, kind, proposedArgs, choiceTs, buttonsTs } = link;
|
|
16
|
+
appendFileSync(threadsFile(agentDir), JSON.stringify({ app, conversation, ts, pendingId, kind, ...(proposedArgs ? { proposedArgs } : {}), ...(choiceTs ? { choiceTs } : {}), ...(buttonsTs ? { buttonsTs } : {}), at: new Date().toISOString() }) + '\n');
|
|
17
17
|
}
|
|
18
18
|
catch (err) {
|
|
19
19
|
console.error('[loopengine] could not record the thread:', err instanceof Error ? err.message : err);
|
package/dist/index.d.ts
CHANGED
|
@@ -13,7 +13,7 @@ export { listDeliveries, recordDelivery, type NotifierDelivery } from '#core/not
|
|
|
13
13
|
export { describeNotifier } from '#core/http-notifier.js';
|
|
14
14
|
export { Scheduler, ScheduleError, FileSchedulerStore, getSchedulerStore, setSchedulerStore, createScheduledTask, listScheduledTasks, getScheduledTask, cancelScheduledTask, pauseScheduledTask, resumeScheduledTask, runScheduledTaskNow, setScheduledTaskNotify, deleteScheduledTask, nextScheduledWakeAt, moveScheduledTasksToTimeZone, importLegacyScheduledTasks, parseEvery, describeSchedule, type ScheduledTask, type ScheduledTaskRun, type ScheduledTaskStatus, type Schedule, type SchedulerStore, type FireTask, type CreateScheduledTaskInput } from '#core/scheduler.js';
|
|
15
15
|
export { NOTIFIER_SLACK_SIGNING_SECRET_VAR } from '#core/notifier-file.js';
|
|
16
|
-
export { firstSighting, handleInboundMessage, handleMessagingAction, settleThreadChoice, isPlainApproval, outcomeText, type MessagingDeps, type MessagingDecision, type DecisionOutcome } from '#core/messaging/engine.js';
|
|
16
|
+
export { firstSighting, handleInboundMessage, handleMessagingAction, settleRequest, settleThreadChoice, isPlainApproval, outcomeText, followUpText, type MessagingDeps, type MessagingDecision, type DecisionOutcome } from '#core/messaging/engine.js';
|
|
17
17
|
export { handleJobMessage, isJobMessage, settleJobThread, jobSessionId, findJobFor, type JobDeps, type JobTurn } from '#core/messaging/jobs.js';
|
|
18
18
|
export { formatArgs, formatChange, labelFor } from '#core/messaging/format-args.js';
|
|
19
19
|
export { decideReply, proposeEdit, describeChange, type ReplyDecision, type DecisionRequest } from '#core/messaging/decide.js';
|
|
@@ -105,7 +105,8 @@ export { readActauthConfig, addActauthRule, updateActauthRule, removeActauthRule
|
|
|
105
105
|
export type { ActauthRuleInput, ActauthConfigView } from './web/actauth-admin.js';
|
|
106
106
|
export { installAbility, upgradeAbility, removeAbility, listInstalledAbilities, backfillDependencies, configureAgentMcpTools, AbilityManifestError, AbilityVersionError, AbilityCollisionError, AbilityAlreadyInstalledError, AbilityNotInstalledError, } from './bin/ability-manager.js';
|
|
107
107
|
export type { InstalledAbilityRecord, AbilityEnvDecl, UpgradeFileResult, McpToolChoice } from './bin/ability-manager.js';
|
|
108
|
-
export { APP_CATALOG, AppToolsError, appCatalog, appServer, appTools, catalogServer, connectedApps, isAppAbility, loadAppIcons, refreshAppTools, setAppDefault, type AgentAppTools, type AppCatalogEntry, type AppTool, type AppView, type ConnectedApp, } from './core/mcp-apps.js';
|
|
108
|
+
export { APP_CATALOG, AppToolsError, appCatalog, appServer, appToolInputs, appTools, catalogServer, connectedApps, isAppAbility, loadAppIcons, refreshAppTools, setAppDefault, type AgentAppTools, type AppCatalogEntry, type AppTool, type AppView, type ConnectedApp, } from './core/mcp-apps.js';
|
|
109
|
+
export { UNATTENDED_NOTE } from './core/unattended.js';
|
|
109
110
|
export { searchPublicAbilities, fetchLatestAbilityVersion } from './web/abilities-admin.js';
|
|
110
111
|
export type { PublicAbilitySearchResult } from './web/abilities-admin.js';
|
|
111
112
|
export { AbilitySourceError, abilityOrigin, readAbilitySources, saveAbilitySource, removeAbilitySource, listSourceAbilities, sourceTokenVar, type AbilitySource, type SourceAbility, type AbilityOrigin } from './core/ability-sources.js';
|
package/dist/index.js
CHANGED
|
@@ -15,7 +15,7 @@ export { listDeliveries, recordDelivery } from '#core/notifier-deliveries.js';
|
|
|
15
15
|
export { describeNotifier } from '#core/http-notifier.js';
|
|
16
16
|
export { Scheduler, ScheduleError, FileSchedulerStore, getSchedulerStore, setSchedulerStore, createScheduledTask, listScheduledTasks, getScheduledTask, cancelScheduledTask, pauseScheduledTask, resumeScheduledTask, runScheduledTaskNow, setScheduledTaskNotify, deleteScheduledTask, nextScheduledWakeAt, moveScheduledTasksToTimeZone, importLegacyScheduledTasks, parseEvery, describeSchedule } from '#core/scheduler.js';
|
|
17
17
|
export { NOTIFIER_SLACK_SIGNING_SECRET_VAR } from '#core/notifier-file.js';
|
|
18
|
-
export { firstSighting, handleInboundMessage, handleMessagingAction, settleThreadChoice, isPlainApproval, outcomeText } from '#core/messaging/engine.js';
|
|
18
|
+
export { firstSighting, handleInboundMessage, handleMessagingAction, settleRequest, settleThreadChoice, isPlainApproval, outcomeText, followUpText } from '#core/messaging/engine.js';
|
|
19
19
|
export { handleJobMessage, isJobMessage, settleJobThread, jobSessionId, findJobFor } from '#core/messaging/jobs.js';
|
|
20
20
|
export { formatArgs, formatChange, labelFor } from '#core/messaging/format-args.js';
|
|
21
21
|
export { decideReply, proposeEdit, describeChange } from '#core/messaging/decide.js';
|
|
@@ -94,7 +94,8 @@ export { readSkill, writeSkill, deleteSkill, SkillInvalidIdError, SkillNotFoundE
|
|
|
94
94
|
export { listDeclaredEnvVars, setEnvVar, unsetEnvVar, setAgentEnvVar, unsetAgentEnvVar, agentScopedEnvVarName, EnvVarNameError } from './web/env-admin.js';
|
|
95
95
|
export { readActauthConfig, addActauthRule, updateActauthRule, removeActauthRule, setDefaultDecision, ActauthRuleExistsError, ActauthRuleNotFoundError, } from './web/actauth-admin.js';
|
|
96
96
|
export { installAbility, upgradeAbility, removeAbility, listInstalledAbilities, backfillDependencies, configureAgentMcpTools, AbilityManifestError, AbilityVersionError, AbilityCollisionError, AbilityAlreadyInstalledError, AbilityNotInstalledError, } from './bin/ability-manager.js';
|
|
97
|
-
export { APP_CATALOG, AppToolsError, appCatalog, appServer, appTools, catalogServer, connectedApps, isAppAbility, loadAppIcons, refreshAppTools, setAppDefault, } from './core/mcp-apps.js';
|
|
97
|
+
export { APP_CATALOG, AppToolsError, appCatalog, appServer, appToolInputs, appTools, catalogServer, connectedApps, isAppAbility, loadAppIcons, refreshAppTools, setAppDefault, } from './core/mcp-apps.js';
|
|
98
|
+
export { UNATTENDED_NOTE } from './core/unattended.js';
|
|
98
99
|
export { searchPublicAbilities, fetchLatestAbilityVersion } from './web/abilities-admin.js';
|
|
99
100
|
// Private ability sources, the workspace's own abilities and each
|
|
100
101
|
// ability's details: the console's Abilities page and agent Abilities tab.
|