@dudousxd/nestjs-agent-core 0.32.0 → 0.34.0
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 +3 -1
- package/dist/genui/index.d.cts +1 -1
- package/dist/genui/index.d.ts +1 -1
- package/dist/guardrails/index.d.cts +2 -2
- package/dist/guardrails/index.d.ts +2 -2
- package/dist/index.cjs +241 -5
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +77 -5
- package/dist/index.d.ts +77 -5
- package/dist/index.js +229 -5
- package/dist/index.js.map +1 -1
- package/dist/{processors-DQJ5sWw7.d.cts → processors-Bm2DniQ8.d.cts} +1 -1
- package/dist/{processors-BIVqOR1Q.d.ts → processors-CtrfAA0B.d.ts} +1 -1
- package/dist/{tool-BhhzEI40.d.cts → tool-C128TFWw.d.cts} +91 -2
- package/dist/{tool-BhhzEI40.d.ts → tool-C128TFWw.d.ts} +91 -2
- package/package.json +1 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { M as ModelMessage, A as Actor, d as ToolCallRequest } from './tool-
|
|
1
|
+
import { M as ModelMessage, A as Actor, d as ToolCallRequest } from './tool-C128TFWw.cjs';
|
|
2
2
|
|
|
3
3
|
/**
|
|
4
4
|
* The two seams that see a turn's traffic to and from the model: an {@link InputProcessor} rewrites
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { M as ModelMessage, A as Actor, d as ToolCallRequest } from './tool-
|
|
1
|
+
import { M as ModelMessage, A as Actor, d as ToolCallRequest } from './tool-C128TFWw.js';
|
|
2
2
|
|
|
3
3
|
/**
|
|
4
4
|
* The two seams that see a turn's traffic to and from the model: an {@link InputProcessor} rewrites
|
|
@@ -263,6 +263,40 @@ interface AgentIntake {
|
|
|
263
263
|
}
|
|
264
264
|
declare const DEFAULT_INTAKE_PREAMBLE = "A few questions before I start. I have pre-picked what I would choose, so confirming is enough.";
|
|
265
265
|
|
|
266
|
+
/**
|
|
267
|
+
* What a store knows about a tool call, read back when its message carries no result for it — see
|
|
268
|
+
* {@link import('./spi/agent-store.js').AgentStore.toolCallOutcomes}.
|
|
269
|
+
*/
|
|
270
|
+
interface ToolCallOutcome {
|
|
271
|
+
id: string;
|
|
272
|
+
status: ToolCallStatus;
|
|
273
|
+
output?: unknown;
|
|
274
|
+
error?: string;
|
|
275
|
+
}
|
|
276
|
+
/** What the model is told about a call whose turn died before the call was settled. */
|
|
277
|
+
declare const UNFINISHED_TOOL_CALL: string;
|
|
278
|
+
/** What is written on the row of a call whose run ended without settling it. */
|
|
279
|
+
declare const RUN_ENDED_BEFORE_TOOL_CALL = "the run ended before this tool call was settled";
|
|
280
|
+
/** The ids of every tool call in `messages` that the message asking for it holds no result for. */
|
|
281
|
+
declare function danglingToolCallIds(messages: readonly ModelMessage[]): string[];
|
|
282
|
+
/**
|
|
283
|
+
* Give every tool call in a thread's history a result.
|
|
284
|
+
*
|
|
285
|
+
* A turn writes its results onto the assistant message once the step's LAST tool has settled. A turn
|
|
286
|
+
* that dies before that — its run failed, its worker was killed, an approval was never answered and
|
|
287
|
+
* the run was abandoned — leaves an assistant message that asks for tools and is answered by
|
|
288
|
+
* nothing. A provider refuses a prompt shaped like that (a tool call must be followed by its
|
|
289
|
+
* result), so every LATER turn on the thread fails too, with an error about the stream rather than
|
|
290
|
+
* about the history: one dead turn makes the whole conversation unusable.
|
|
291
|
+
*
|
|
292
|
+
* Here each such call is settled from what is actually known: the call's own row where the store
|
|
293
|
+
* can read it (`outcomes` — a tool that DID run hands the model its real output, so it is not run a
|
|
294
|
+
* second time), and otherwise a result saying the call was never completed. Pure: the same messages
|
|
295
|
+
* and outcomes always produce the same prompt, so a replay composes what the first attempt did.
|
|
296
|
+
* Messages with nothing dangling are returned as they are.
|
|
297
|
+
*/
|
|
298
|
+
declare function settleDanglingToolCalls(messages: ModelMessage[], outcomes?: readonly ToolCallOutcome[]): ModelMessage[];
|
|
299
|
+
|
|
266
300
|
/**
|
|
267
301
|
* The structured live-stream vocabulary carried over the {@link SinkWriter} byte channel.
|
|
268
302
|
*
|
|
@@ -510,6 +544,17 @@ declare function encodeStreamEvent(event: AgentStreamEvent): Uint8Array;
|
|
|
510
544
|
* treats an unreadable frame as unclassifiable rather than guessing.
|
|
511
545
|
*/
|
|
512
546
|
declare function decodeStreamEvent(line: string): AgentStreamEvent | null;
|
|
547
|
+
/**
|
|
548
|
+
* The `code` of a failed run's `event: error` frame — what a client branches on, and translates.
|
|
549
|
+
* `quota_exceeded`, `output_rejected` and `structured_output_invalid` are outcomes the library words
|
|
550
|
+
* itself (their `message` is safe to show as it is); the rest are crashes, whose `message` is a
|
|
551
|
+
* generic sentence in production. Open-ended on purpose: a host's own runner may send other codes.
|
|
552
|
+
*/
|
|
553
|
+
type AgentStreamErrorCode = 'quota_exceeded' | 'output_rejected' | 'structured_output_invalid'
|
|
554
|
+
/** The durable runtime refused a checkpoint position: the run's journal and its code disagree. */
|
|
555
|
+
| 'replay_diverged'
|
|
556
|
+
/** A model call ended without producing anything. */
|
|
557
|
+
| 'model_no_output' | 'run_failed';
|
|
513
558
|
|
|
514
559
|
interface CreateThreadInput {
|
|
515
560
|
actor: Actor;
|
|
@@ -773,6 +818,21 @@ interface AgentStore {
|
|
|
773
818
|
setMessageFeedback?(messageId: string, feedback: MessageFeedback | null): Promise<void>;
|
|
774
819
|
recordToolCall(input: RecordToolCallInput): Promise<void>;
|
|
775
820
|
updateToolCall(input: UpdateToolCallInput): Promise<void>;
|
|
821
|
+
/**
|
|
822
|
+
* OPTIONAL: what is recorded about each of these calls — its status, and the output or error it
|
|
823
|
+
* settled with. Read when a thread's history holds a tool call its message has no result for (the
|
|
824
|
+
* turn died mid-step), so the next turn can be told what actually happened instead of being
|
|
825
|
+
* handed a call answered by nothing. Unknown ids are left out. Absent → such a call is put to the
|
|
826
|
+
* model as never completed.
|
|
827
|
+
*/
|
|
828
|
+
toolCallOutcomes?(toolCallIds: readonly string[]): Promise<ToolCallOutcome[]>;
|
|
829
|
+
/**
|
|
830
|
+
* OPTIONAL: settle every call of `runId` still awaiting a decision (`pending_approval`) as
|
|
831
|
+
* `failed` with `error`, and answer how many there were. Called when the run ends without
|
|
832
|
+
* settling them — it failed, or it was found dead — so an approval card never waits on a run that
|
|
833
|
+
* will not come back. Calls already settled are left alone, so a repeat changes nothing.
|
|
834
|
+
*/
|
|
835
|
+
failUnsettledToolCalls?(runId: string, error: string): Promise<number>;
|
|
776
836
|
/**
|
|
777
837
|
* OPTIONAL: the names of the tools whose approval someone asked to REMEMBER in this thread — an
|
|
778
838
|
* approved call persisted with `remember: true`. The loop approves a later call of one of them
|
|
@@ -912,11 +972,19 @@ interface EnqueueMessageInput {
|
|
|
912
972
|
/** `'tail'` (default) runs it after everything already waiting; `'head'` runs it next. */
|
|
913
973
|
at?: 'tail' | 'head';
|
|
914
974
|
}
|
|
915
|
-
/**
|
|
975
|
+
/**
|
|
976
|
+
* What a store may change on a waiting message (`PATCH <base>/queue/:messageId` sets the text and
|
|
977
|
+
* attachments). An omitted key leaves the field as it is.
|
|
978
|
+
*/
|
|
916
979
|
interface QueuedMessagePatch {
|
|
917
980
|
content?: string;
|
|
918
981
|
/** `null` drops every attachment. */
|
|
919
982
|
attachments?: MessageAttachment[] | null;
|
|
983
|
+
/**
|
|
984
|
+
* Mark (or unmark) the message as an interrupt — what `POST <base>/queue/:messageId/interrupt`
|
|
985
|
+
* does to a message that is already waiting, before it cancels the running turn for it.
|
|
986
|
+
*/
|
|
987
|
+
interrupt?: boolean;
|
|
920
988
|
}
|
|
921
989
|
/**
|
|
922
990
|
* A store that can hold a thread's queue of waiting messages, and admit ONE run per thread at a time.
|
|
@@ -1880,6 +1948,27 @@ interface AiToolCtx {
|
|
|
1880
1948
|
threadId: string;
|
|
1881
1949
|
runId: string;
|
|
1882
1950
|
requestId: string;
|
|
1951
|
+
/**
|
|
1952
|
+
* The id of the tool call this invocation serves. Absent where a tool is invoked outside a turn
|
|
1953
|
+
* (the MCP server, a direct `registry.invoke`).
|
|
1954
|
+
*/
|
|
1955
|
+
toolCallId?: string;
|
|
1956
|
+
/**
|
|
1957
|
+
* `<runId>:<toolCallId>` — the same value for every execution of THIS call, and for no other.
|
|
1958
|
+
*
|
|
1959
|
+
* A tool's side effect and the checkpoint that records it are two writes. Under the durable
|
|
1960
|
+
* runner a worker that dies between them leaves a call the journal does not know ran, and the
|
|
1961
|
+
* runtime's recovery runs it again; an in-step transient retry (a deadlock, a lock-wait timeout)
|
|
1962
|
+
* re-invokes it too. The library cannot make your write atomic with its journal — so it hands you
|
|
1963
|
+
* the key that makes the second attempt recognisable: pass it to whatever you call as its
|
|
1964
|
+
* idempotency key (a payment provider's `Idempotency-Key`, a unique column on the row you insert,
|
|
1965
|
+
* a workflow's `id`), and a re-execution lands on the first one's result instead of doing it
|
|
1966
|
+
* twice. Stable across replays and across pods: the run id is the run's own, and the call id
|
|
1967
|
+
* comes out of the journaled model step.
|
|
1968
|
+
*
|
|
1969
|
+
* Absent where a tool is invoked outside a turn (the MCP server, a direct `registry.invoke`).
|
|
1970
|
+
*/
|
|
1971
|
+
idempotencyKey?: string;
|
|
1883
1972
|
/** The name of the agent running this turn — provenance a tool can scope on (e.g. capability sets). */
|
|
1884
1973
|
agentName?: string;
|
|
1885
1974
|
pageContext?: PageContext;
|
|
@@ -1964,4 +2053,4 @@ interface ToolDescription {
|
|
|
1964
2053
|
inputSchema?: StandardSchemaV1;
|
|
1965
2054
|
}
|
|
1966
2055
|
|
|
1967
|
-
export {
|
|
2056
|
+
export { ASK_TOOL_DESCRIPTION as $, type Actor as A, type ThreadDetail as B, type ChatQueueStore as C, type DetachedDelivery as D, type ElicitationRequest as E, type ToolCallApprovalState as F, type EnqueueMessageInput as G, type HumanReply as H, type QueuedMessage as I, type QueuedMessagePatch as J, type QueuePause as K, type LlmStepEnvelope as L, type ModelMessage as M, type AppendMessageInput as N, type ToolResult as O, type PageContext as P, type QuotaState as Q, type RecordRunStartInput as R, type StoredMessage as S, type ToolSpec as T, type UpdateThreadInput as U, type MessageFeedback as V, type RecordToolCallInput as W, type ToolCallOutcome as X, type UpdateToolCallInput as Y, type RecordUsageInput as Z, ALL_AGENTS as _, type ToolHandler as a, releaseThreadRun as a$, ASK_TOOL_NAME as a0, type AgentApprovalRequest as a1, type AgentApprovalSettlement as a2, type AgentAttachmentConfig as a3, type AgentCatalogEntry as a4, type AgentClientConfig as a5, type AgentHistoryWindow as a6, type AgentStreamErrorCode as a7, type AskToolInput as a8, type ChatQueueState as a9, type ThreadTurnReader as aA, type ToolCallApprovalStatus as aB, type ToolCatalogEntry as aC, type ToolConfirmation as aD, type ToolDescription as aE, type ToolPresentationTone as aF, type ToolResultField as aG, type ToolResultView as aH, type ToolStepCtx as aI, type ToolTransientRetryNumbers as aJ, type ToolTransientRetryOptions as aK, UNFINISHED_TOOL_CALL as aL, type UsagePurpose as aM, askInputSchema as aN, askToolDefinition as aO, danglingToolCallIds as aP, decodeStreamEvent as aQ, encodeStreamEvent as aR, invokeWithTransientRetry as aS, isChatQueueStore as aT, isTransientToolError as aU, isTypedQuestion as aV, normalizeElicitationReply as aW, questionOptions as aX, queuedMessageView as aY, readElicitationInput as aZ, readElicitationQuestions as a_, DEFAULT_INTAKE_PREAMBLE as aa, DEFAULT_TOOL_TRANSIENT_RETRY_ATTEMPTS as ab, DEFAULT_TOOL_TRANSIENT_RETRY_BACKOFF_MS as ac, ELICITATION_INPUT_TYPES as ad, type ElicitationInput as ae, type ElicitationInputType as af, type ElicitationOption as ag, type ElicitationOutcome as ah, type ElicitationQuestion as ai, type ElicitationReply as aj, type ElicitationResult as ak, type HistoryPolicyContext as al, type HistorySelection as am, type HistorySummary as an, type InvokeWithTransientRetryOptions as ao, MAX_ASK_QUESTIONS as ap, type MessageFeedbackValue as aq, type MessageRole as ar, type PromptContext as as, type QueuePauseReason as at, type QueuedMessageView as au, type QuotaView as av, RUN_ENDED_BEFORE_TOOL_CALL as aw, type RecordRunEndInput as ax, type ThreadTurnPage as ay, type ThreadTurnQuery as az, type ToolPresentation as b, renderElicitationAnswers as b0, resolveElicitation as b1, resolveToolTransientRetryNumbers as b2, settleDanglingToolCalls as b3, settleElicitation as b4, validateElicitationAnswer as b5, validateElicitationValue as b6, type ToolDefinition as c, type ToolCallRequest as d, type MessageUsage as e, type AgentUiComponent as f, type AiToolCtx as g, type AgentStreamEvent as h, type AgentRunInput as i, type MessageAttachment as j, type ToolKind as k, type ToolCallStatus as l, type ToolCallApproval as m, type HistoryPolicy as n, type AgentDefinition as o, type AgentStore as p, type AgentDelegation as q, type ToolDescribeScope as r, type PromptBuilder as s, type PromptContributor as t, type ToolTransientRetrySetting as u, type AgentIntake as v, type Decision as w, type ToolStepEnvelope as x, type CreateThreadInput as y, type ThreadSummary as z };
|
|
@@ -263,6 +263,40 @@ interface AgentIntake {
|
|
|
263
263
|
}
|
|
264
264
|
declare const DEFAULT_INTAKE_PREAMBLE = "A few questions before I start. I have pre-picked what I would choose, so confirming is enough.";
|
|
265
265
|
|
|
266
|
+
/**
|
|
267
|
+
* What a store knows about a tool call, read back when its message carries no result for it — see
|
|
268
|
+
* {@link import('./spi/agent-store.js').AgentStore.toolCallOutcomes}.
|
|
269
|
+
*/
|
|
270
|
+
interface ToolCallOutcome {
|
|
271
|
+
id: string;
|
|
272
|
+
status: ToolCallStatus;
|
|
273
|
+
output?: unknown;
|
|
274
|
+
error?: string;
|
|
275
|
+
}
|
|
276
|
+
/** What the model is told about a call whose turn died before the call was settled. */
|
|
277
|
+
declare const UNFINISHED_TOOL_CALL: string;
|
|
278
|
+
/** What is written on the row of a call whose run ended without settling it. */
|
|
279
|
+
declare const RUN_ENDED_BEFORE_TOOL_CALL = "the run ended before this tool call was settled";
|
|
280
|
+
/** The ids of every tool call in `messages` that the message asking for it holds no result for. */
|
|
281
|
+
declare function danglingToolCallIds(messages: readonly ModelMessage[]): string[];
|
|
282
|
+
/**
|
|
283
|
+
* Give every tool call in a thread's history a result.
|
|
284
|
+
*
|
|
285
|
+
* A turn writes its results onto the assistant message once the step's LAST tool has settled. A turn
|
|
286
|
+
* that dies before that — its run failed, its worker was killed, an approval was never answered and
|
|
287
|
+
* the run was abandoned — leaves an assistant message that asks for tools and is answered by
|
|
288
|
+
* nothing. A provider refuses a prompt shaped like that (a tool call must be followed by its
|
|
289
|
+
* result), so every LATER turn on the thread fails too, with an error about the stream rather than
|
|
290
|
+
* about the history: one dead turn makes the whole conversation unusable.
|
|
291
|
+
*
|
|
292
|
+
* Here each such call is settled from what is actually known: the call's own row where the store
|
|
293
|
+
* can read it (`outcomes` — a tool that DID run hands the model its real output, so it is not run a
|
|
294
|
+
* second time), and otherwise a result saying the call was never completed. Pure: the same messages
|
|
295
|
+
* and outcomes always produce the same prompt, so a replay composes what the first attempt did.
|
|
296
|
+
* Messages with nothing dangling are returned as they are.
|
|
297
|
+
*/
|
|
298
|
+
declare function settleDanglingToolCalls(messages: ModelMessage[], outcomes?: readonly ToolCallOutcome[]): ModelMessage[];
|
|
299
|
+
|
|
266
300
|
/**
|
|
267
301
|
* The structured live-stream vocabulary carried over the {@link SinkWriter} byte channel.
|
|
268
302
|
*
|
|
@@ -510,6 +544,17 @@ declare function encodeStreamEvent(event: AgentStreamEvent): Uint8Array;
|
|
|
510
544
|
* treats an unreadable frame as unclassifiable rather than guessing.
|
|
511
545
|
*/
|
|
512
546
|
declare function decodeStreamEvent(line: string): AgentStreamEvent | null;
|
|
547
|
+
/**
|
|
548
|
+
* The `code` of a failed run's `event: error` frame — what a client branches on, and translates.
|
|
549
|
+
* `quota_exceeded`, `output_rejected` and `structured_output_invalid` are outcomes the library words
|
|
550
|
+
* itself (their `message` is safe to show as it is); the rest are crashes, whose `message` is a
|
|
551
|
+
* generic sentence in production. Open-ended on purpose: a host's own runner may send other codes.
|
|
552
|
+
*/
|
|
553
|
+
type AgentStreamErrorCode = 'quota_exceeded' | 'output_rejected' | 'structured_output_invalid'
|
|
554
|
+
/** The durable runtime refused a checkpoint position: the run's journal and its code disagree. */
|
|
555
|
+
| 'replay_diverged'
|
|
556
|
+
/** A model call ended without producing anything. */
|
|
557
|
+
| 'model_no_output' | 'run_failed';
|
|
513
558
|
|
|
514
559
|
interface CreateThreadInput {
|
|
515
560
|
actor: Actor;
|
|
@@ -773,6 +818,21 @@ interface AgentStore {
|
|
|
773
818
|
setMessageFeedback?(messageId: string, feedback: MessageFeedback | null): Promise<void>;
|
|
774
819
|
recordToolCall(input: RecordToolCallInput): Promise<void>;
|
|
775
820
|
updateToolCall(input: UpdateToolCallInput): Promise<void>;
|
|
821
|
+
/**
|
|
822
|
+
* OPTIONAL: what is recorded about each of these calls — its status, and the output or error it
|
|
823
|
+
* settled with. Read when a thread's history holds a tool call its message has no result for (the
|
|
824
|
+
* turn died mid-step), so the next turn can be told what actually happened instead of being
|
|
825
|
+
* handed a call answered by nothing. Unknown ids are left out. Absent → such a call is put to the
|
|
826
|
+
* model as never completed.
|
|
827
|
+
*/
|
|
828
|
+
toolCallOutcomes?(toolCallIds: readonly string[]): Promise<ToolCallOutcome[]>;
|
|
829
|
+
/**
|
|
830
|
+
* OPTIONAL: settle every call of `runId` still awaiting a decision (`pending_approval`) as
|
|
831
|
+
* `failed` with `error`, and answer how many there were. Called when the run ends without
|
|
832
|
+
* settling them — it failed, or it was found dead — so an approval card never waits on a run that
|
|
833
|
+
* will not come back. Calls already settled are left alone, so a repeat changes nothing.
|
|
834
|
+
*/
|
|
835
|
+
failUnsettledToolCalls?(runId: string, error: string): Promise<number>;
|
|
776
836
|
/**
|
|
777
837
|
* OPTIONAL: the names of the tools whose approval someone asked to REMEMBER in this thread — an
|
|
778
838
|
* approved call persisted with `remember: true`. The loop approves a later call of one of them
|
|
@@ -912,11 +972,19 @@ interface EnqueueMessageInput {
|
|
|
912
972
|
/** `'tail'` (default) runs it after everything already waiting; `'head'` runs it next. */
|
|
913
973
|
at?: 'tail' | 'head';
|
|
914
974
|
}
|
|
915
|
-
/**
|
|
975
|
+
/**
|
|
976
|
+
* What a store may change on a waiting message (`PATCH <base>/queue/:messageId` sets the text and
|
|
977
|
+
* attachments). An omitted key leaves the field as it is.
|
|
978
|
+
*/
|
|
916
979
|
interface QueuedMessagePatch {
|
|
917
980
|
content?: string;
|
|
918
981
|
/** `null` drops every attachment. */
|
|
919
982
|
attachments?: MessageAttachment[] | null;
|
|
983
|
+
/**
|
|
984
|
+
* Mark (or unmark) the message as an interrupt — what `POST <base>/queue/:messageId/interrupt`
|
|
985
|
+
* does to a message that is already waiting, before it cancels the running turn for it.
|
|
986
|
+
*/
|
|
987
|
+
interrupt?: boolean;
|
|
920
988
|
}
|
|
921
989
|
/**
|
|
922
990
|
* A store that can hold a thread's queue of waiting messages, and admit ONE run per thread at a time.
|
|
@@ -1880,6 +1948,27 @@ interface AiToolCtx {
|
|
|
1880
1948
|
threadId: string;
|
|
1881
1949
|
runId: string;
|
|
1882
1950
|
requestId: string;
|
|
1951
|
+
/**
|
|
1952
|
+
* The id of the tool call this invocation serves. Absent where a tool is invoked outside a turn
|
|
1953
|
+
* (the MCP server, a direct `registry.invoke`).
|
|
1954
|
+
*/
|
|
1955
|
+
toolCallId?: string;
|
|
1956
|
+
/**
|
|
1957
|
+
* `<runId>:<toolCallId>` — the same value for every execution of THIS call, and for no other.
|
|
1958
|
+
*
|
|
1959
|
+
* A tool's side effect and the checkpoint that records it are two writes. Under the durable
|
|
1960
|
+
* runner a worker that dies between them leaves a call the journal does not know ran, and the
|
|
1961
|
+
* runtime's recovery runs it again; an in-step transient retry (a deadlock, a lock-wait timeout)
|
|
1962
|
+
* re-invokes it too. The library cannot make your write atomic with its journal — so it hands you
|
|
1963
|
+
* the key that makes the second attempt recognisable: pass it to whatever you call as its
|
|
1964
|
+
* idempotency key (a payment provider's `Idempotency-Key`, a unique column on the row you insert,
|
|
1965
|
+
* a workflow's `id`), and a re-execution lands on the first one's result instead of doing it
|
|
1966
|
+
* twice. Stable across replays and across pods: the run id is the run's own, and the call id
|
|
1967
|
+
* comes out of the journaled model step.
|
|
1968
|
+
*
|
|
1969
|
+
* Absent where a tool is invoked outside a turn (the MCP server, a direct `registry.invoke`).
|
|
1970
|
+
*/
|
|
1971
|
+
idempotencyKey?: string;
|
|
1883
1972
|
/** The name of the agent running this turn — provenance a tool can scope on (e.g. capability sets). */
|
|
1884
1973
|
agentName?: string;
|
|
1885
1974
|
pageContext?: PageContext;
|
|
@@ -1964,4 +2053,4 @@ interface ToolDescription {
|
|
|
1964
2053
|
inputSchema?: StandardSchemaV1;
|
|
1965
2054
|
}
|
|
1966
2055
|
|
|
1967
|
-
export {
|
|
2056
|
+
export { ASK_TOOL_DESCRIPTION as $, type Actor as A, type ThreadDetail as B, type ChatQueueStore as C, type DetachedDelivery as D, type ElicitationRequest as E, type ToolCallApprovalState as F, type EnqueueMessageInput as G, type HumanReply as H, type QueuedMessage as I, type QueuedMessagePatch as J, type QueuePause as K, type LlmStepEnvelope as L, type ModelMessage as M, type AppendMessageInput as N, type ToolResult as O, type PageContext as P, type QuotaState as Q, type RecordRunStartInput as R, type StoredMessage as S, type ToolSpec as T, type UpdateThreadInput as U, type MessageFeedback as V, type RecordToolCallInput as W, type ToolCallOutcome as X, type UpdateToolCallInput as Y, type RecordUsageInput as Z, ALL_AGENTS as _, type ToolHandler as a, releaseThreadRun as a$, ASK_TOOL_NAME as a0, type AgentApprovalRequest as a1, type AgentApprovalSettlement as a2, type AgentAttachmentConfig as a3, type AgentCatalogEntry as a4, type AgentClientConfig as a5, type AgentHistoryWindow as a6, type AgentStreamErrorCode as a7, type AskToolInput as a8, type ChatQueueState as a9, type ThreadTurnReader as aA, type ToolCallApprovalStatus as aB, type ToolCatalogEntry as aC, type ToolConfirmation as aD, type ToolDescription as aE, type ToolPresentationTone as aF, type ToolResultField as aG, type ToolResultView as aH, type ToolStepCtx as aI, type ToolTransientRetryNumbers as aJ, type ToolTransientRetryOptions as aK, UNFINISHED_TOOL_CALL as aL, type UsagePurpose as aM, askInputSchema as aN, askToolDefinition as aO, danglingToolCallIds as aP, decodeStreamEvent as aQ, encodeStreamEvent as aR, invokeWithTransientRetry as aS, isChatQueueStore as aT, isTransientToolError as aU, isTypedQuestion as aV, normalizeElicitationReply as aW, questionOptions as aX, queuedMessageView as aY, readElicitationInput as aZ, readElicitationQuestions as a_, DEFAULT_INTAKE_PREAMBLE as aa, DEFAULT_TOOL_TRANSIENT_RETRY_ATTEMPTS as ab, DEFAULT_TOOL_TRANSIENT_RETRY_BACKOFF_MS as ac, ELICITATION_INPUT_TYPES as ad, type ElicitationInput as ae, type ElicitationInputType as af, type ElicitationOption as ag, type ElicitationOutcome as ah, type ElicitationQuestion as ai, type ElicitationReply as aj, type ElicitationResult as ak, type HistoryPolicyContext as al, type HistorySelection as am, type HistorySummary as an, type InvokeWithTransientRetryOptions as ao, MAX_ASK_QUESTIONS as ap, type MessageFeedbackValue as aq, type MessageRole as ar, type PromptContext as as, type QueuePauseReason as at, type QueuedMessageView as au, type QuotaView as av, RUN_ENDED_BEFORE_TOOL_CALL as aw, type RecordRunEndInput as ax, type ThreadTurnPage as ay, type ThreadTurnQuery as az, type ToolPresentation as b, renderElicitationAnswers as b0, resolveElicitation as b1, resolveToolTransientRetryNumbers as b2, settleDanglingToolCalls as b3, settleElicitation as b4, validateElicitationAnswer as b5, validateElicitationValue as b6, type ToolDefinition as c, type ToolCallRequest as d, type MessageUsage as e, type AgentUiComponent as f, type AiToolCtx as g, type AgentStreamEvent as h, type AgentRunInput as i, type MessageAttachment as j, type ToolKind as k, type ToolCallStatus as l, type ToolCallApproval as m, type HistoryPolicy as n, type AgentDefinition as o, type AgentStore as p, type AgentDelegation as q, type ToolDescribeScope as r, type PromptBuilder as s, type PromptContributor as t, type ToolTransientRetrySetting as u, type AgentIntake as v, type Decision as w, type ToolStepEnvelope as x, type CreateThreadInput as y, type ThreadSummary as z };
|