@robota-sdk/agent-core 3.0.0-beta.86 → 3.0.0-beta.88

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.
Files changed (40) hide show
  1. package/CHANGELOG.md +36 -15
  2. package/README.md +56 -22
  3. package/dist/browser/{bounded-output-Bgx2Cgkx.js → bounded-output-BdWv9SX3.js} +2 -2
  4. package/dist/browser/bounded-output-BdWv9SX3.js.map +1 -0
  5. package/dist/browser/{command-executor-C0XXfBnt.js → command-executor-DIXaSMrr.js} +2 -2
  6. package/dist/{node/command-executor-d6DdfUTD.js.map → browser/command-executor-DIXaSMrr.js.map} +1 -1
  7. package/dist/browser/index.d.ts +140 -48
  8. package/dist/browser/index.d.ts.map +1 -1
  9. package/dist/browser/index.js +10 -9
  10. package/dist/browser/index.js.map +1 -1
  11. package/dist/node/{bounded-output-Bgx2Cgkx.js → bounded-output-BdWv9SX3.js} +2 -2
  12. package/dist/node/bounded-output-BdWv9SX3.js.map +1 -0
  13. package/dist/node/{command-executor-d6DdfUTD.js → command-executor-D_UBZHxh.js} +2 -2
  14. package/dist/{browser/command-executor-C0XXfBnt.js.map → node/command-executor-D_UBZHxh.js.map} +1 -1
  15. package/dist/node/{command-executor-CqAFpB-X.cjs → command-executor-wBgBdWXr.cjs} +1 -1
  16. package/dist/node/{http-executor-BFtXs8FP.cjs → http-executor-CeAAZotH.cjs} +1 -1
  17. package/dist/node/{index-CPwJEiFl.d.cts → index-CagopdzH.d.cts} +141 -49
  18. package/dist/node/index-CagopdzH.d.cts.map +1 -0
  19. package/dist/node/{index-DQrmrFn9.d.ts → index-CjyNzgQN.d.ts} +141 -49
  20. package/dist/node/index-CjyNzgQN.d.ts.map +1 -0
  21. package/dist/node/index.cjs +10 -9
  22. package/dist/node/index.d.cts +2 -2
  23. package/dist/node/index.d.ts +2 -2
  24. package/dist/node/index.js +12 -11
  25. package/dist/node/index.js.map +1 -1
  26. package/dist/node/node.cjs +1 -1
  27. package/dist/node/node.d.cts +13 -2
  28. package/dist/node/node.d.cts.map +1 -1
  29. package/dist/node/node.d.ts +13 -2
  30. package/dist/node/node.d.ts.map +1 -1
  31. package/dist/node/node.js +1 -1
  32. package/dist/node/node.js.map +1 -1
  33. package/dist/node/testing/index.d.cts +1 -1
  34. package/dist/node/testing/index.d.ts +1 -1
  35. package/dist/node/{verdict-decoder-DIHay1ul.cjs → verdict-decoder-DQqwwDE7.cjs} +1 -1
  36. package/package.json +10 -10
  37. package/dist/browser/bounded-output-Bgx2Cgkx.js.map +0 -1
  38. package/dist/node/bounded-output-Bgx2Cgkx.js.map +0 -1
  39. package/dist/node/index-CPwJEiFl.d.cts.map +0 -1
  40. package/dist/node/index-DQrmrFn9.d.ts.map +0 -1
@@ -129,7 +129,35 @@ interface IUriImageMessagePart {
129
129
  uri: string;
130
130
  mimeType?: string;
131
131
  }
132
- type TUniversalMessagePart = ITextMessagePart | IInlineImageMessagePart | IUriImageMessagePart;
132
+ /** An inline audio observation; provider support is determined by the adapter. */
133
+ interface IInlineAudioMessagePart {
134
+ type: 'audio_inline';
135
+ mimeType: string;
136
+ data: string;
137
+ }
138
+ /** An opaque reference, never authority to fetch its URI. */
139
+ interface IResourceLinkMessagePart {
140
+ type: 'resource_link';
141
+ uri: string;
142
+ name: string;
143
+ mimeType?: string;
144
+ title?: string;
145
+ description?: string;
146
+ size?: number;
147
+ }
148
+ /** Embedded untrusted resource content, tied to the contributor's opaque URI. */
149
+ type TEmbeddedResourceMessagePart = {
150
+ type: 'resource_embedded';
151
+ uri: string;
152
+ mimeType?: string;
153
+ } & ({
154
+ text: string;
155
+ blob?: never;
156
+ } | {
157
+ blob: string;
158
+ text?: never;
159
+ });
160
+ type TUniversalMessagePart = ITextMessagePart | IInlineImageMessagePart | IUriImageMessagePart | IInlineAudioMessagePart | IResourceLinkMessagePart | TEmbeddedResourceMessagePart;
133
161
  /**
134
162
  * Tool call (OpenAI tool calling format).
135
163
  */
@@ -263,7 +291,7 @@ type TProviderModelCapability = 'tools' | 'vision' |
263
291
  'json_object' | 'reasoning' | 'native_web' | 'streaming' |
264
292
  /**
265
293
  * CLI-1990: the vendor documents a server-side tool search — deferred definitions the API expands
266
- * on demand. Declaration-only in v1: Robota runs its own client-side catalog on every provider
294
+ * on demand. Declaration-only in v1: ConversationAgent runs its own client-side catalog on every provider
267
295
  * and emits no vendor block. The member exists so a later offload can be capability-gated in this
268
296
  * table rather than by provider name.
269
297
  */
@@ -353,9 +381,9 @@ type TErrorContextData = Record<string, string | number | boolean | Date | Error
353
381
  */
354
382
  type TErrorExternalInput = Error | string | Record<string, string | number | boolean> | null | undefined;
355
383
  /**
356
- * Base error class for all Robota errors
384
+ * Base error class for all ConversationAgent errors
357
385
  */
358
- declare abstract class RobotaError extends Error {
386
+ declare abstract class AgentRuntimeError extends Error {
359
387
  readonly context?: TErrorContextData | undefined;
360
388
  abstract readonly code: string;
361
389
  abstract readonly category: 'user' | 'system' | 'provider';
@@ -365,7 +393,7 @@ declare abstract class RobotaError extends Error {
365
393
  /**
366
394
  * Configuration related errors
367
395
  */
368
- declare class ConfigurationError extends RobotaError {
396
+ declare class ConfigurationError extends AgentRuntimeError {
369
397
  readonly code = "CONFIGURATION_ERROR";
370
398
  readonly category: "user";
371
399
  readonly recoverable = false;
@@ -374,7 +402,7 @@ declare class ConfigurationError extends RobotaError {
374
402
  /**
375
403
  * Input validation errors
376
404
  */
377
- declare class ValidationError extends RobotaError {
405
+ declare class ValidationError extends AgentRuntimeError {
378
406
  readonly field?: string | undefined;
379
407
  readonly code = "VALIDATION_ERROR";
380
408
  readonly category: "user";
@@ -389,7 +417,7 @@ declare class ValidationError extends RobotaError {
389
417
  * validation messages from the last attempt; `attempts` is the total number of
390
418
  * provider turns spent (initial + retries).
391
419
  */
392
- declare class StructuredOutputError extends RobotaError {
420
+ declare class StructuredOutputError extends AgentRuntimeError {
393
421
  readonly issues: string[];
394
422
  readonly attempts: number;
395
423
  readonly code = "STRUCTURED_OUTPUT_ERROR";
@@ -407,7 +435,7 @@ interface IProviderFailureDetails {
407
435
  /**
408
436
  * Provider related errors
409
437
  */
410
- declare class ProviderError extends RobotaError {
438
+ declare class ProviderError extends AgentRuntimeError {
411
439
  readonly provider: string;
412
440
  readonly originalError?: Error | undefined;
413
441
  readonly code = "PROVIDER_ERROR";
@@ -420,7 +448,7 @@ declare class ProviderError extends RobotaError {
420
448
  /**
421
449
  * Authentication errors
422
450
  */
423
- declare class AuthenticationError extends RobotaError {
451
+ declare class AuthenticationError extends AgentRuntimeError {
424
452
  readonly provider?: string | undefined;
425
453
  readonly code = "AUTHENTICATION_ERROR";
426
454
  readonly category: "user";
@@ -430,7 +458,7 @@ declare class AuthenticationError extends RobotaError {
430
458
  /**
431
459
  * Rate limit errors
432
460
  */
433
- declare class RateLimitError extends RobotaError {
461
+ declare class RateLimitError extends AgentRuntimeError {
434
462
  readonly retryAfter?: number | undefined;
435
463
  readonly provider?: string | undefined;
436
464
  readonly code = "RATE_LIMIT_ERROR";
@@ -441,7 +469,7 @@ declare class RateLimitError extends RobotaError {
441
469
  /**
442
470
  * Network/connectivity errors
443
471
  */
444
- declare class NetworkError extends RobotaError {
472
+ declare class NetworkError extends AgentRuntimeError {
445
473
  readonly originalError?: Error | undefined;
446
474
  /** `undefined` for a network failure with no provider context (e.g. a generic timeout). */
447
475
  readonly provider?: string | undefined;
@@ -455,7 +483,7 @@ declare class NetworkError extends RobotaError {
455
483
  /**
456
484
  * Tool execution errors
457
485
  */
458
- declare class ToolExecutionError extends RobotaError {
486
+ declare class ToolExecutionError extends AgentRuntimeError {
459
487
  readonly toolName: string;
460
488
  readonly originalError?: Error | undefined;
461
489
  readonly code = "TOOL_EXECUTION_ERROR";
@@ -472,13 +500,13 @@ declare class ToolExecutionError extends RobotaError {
472
500
  * `success: true, interrupted: true` — reporting a run that produced no answer as a success.
473
501
  *
474
502
  * Named rather than a bare `Error` for the reason the SPEC was reaching for by naming a type at all:
475
- * a caller must be able to tell "the agent looped" from "the network died". `RobotaError` carries
503
+ * a caller must be able to tell "the agent looped" from "the network died". `AgentRuntimeError` carries
476
504
  * `code`/`category`/`recoverable` out through CORE-027's failure path intact.
477
505
  *
478
506
  * `recoverable` is TRUE: the loop is a property of this turn's prompt and tool set, not of the
479
507
  * system, and a caller that varies either can reasonably try again.
480
508
  */
481
- declare class SameToolInputLoopError extends RobotaError {
509
+ declare class SameToolInputLoopError extends AgentRuntimeError {
482
510
  readonly toolName: string;
483
511
  readonly callCount: number;
484
512
  readonly maxSameToolInputs: number;
@@ -502,7 +530,7 @@ declare class SameToolInputLoopError extends RobotaError {
502
530
  * `recoverable` is TRUE: like `SameToolInputLoopError`, this is a property of this turn's prompt and
503
531
  * model response, not of the system, and a caller that varies either can reasonably try again.
504
532
  */
505
- declare class EmptyCompletionError extends RobotaError {
533
+ declare class EmptyCompletionError extends AgentRuntimeError {
506
534
  readonly round: number;
507
535
  readonly code = "EMPTY_COMPLETION";
508
536
  readonly category: "provider";
@@ -512,7 +540,7 @@ declare class EmptyCompletionError extends RobotaError {
512
540
  /**
513
541
  * Model not available errors
514
542
  */
515
- declare class ModelNotAvailableError extends RobotaError {
543
+ declare class ModelNotAvailableError extends AgentRuntimeError {
516
544
  /** `undefined` when the failure names no model — a provider adapter classifying a raw HTTP
517
545
  * response by status alone does not always know which model the vendor meant. */
518
546
  readonly model: string | undefined;
@@ -535,7 +563,7 @@ declare class ModelNotAvailableError extends RobotaError {
535
563
  /**
536
564
  * Circuit breaker open error
537
565
  */
538
- declare class CircuitBreakerOpenError extends RobotaError {
566
+ declare class CircuitBreakerOpenError extends AgentRuntimeError {
539
567
  readonly code = "CIRCUIT_BREAKER_OPEN";
540
568
  readonly category: "system";
541
569
  readonly recoverable = true;
@@ -544,7 +572,7 @@ declare class CircuitBreakerOpenError extends RobotaError {
544
572
  /**
545
573
  * Plugin errors
546
574
  */
547
- declare class PluginError extends RobotaError {
575
+ declare class PluginError extends AgentRuntimeError {
548
576
  readonly pluginName: string;
549
577
  readonly code = "PLUGIN_ERROR";
550
578
  readonly category: "system";
@@ -554,7 +582,7 @@ declare class PluginError extends RobotaError {
554
582
  /**
555
583
  * Storage related errors
556
584
  */
557
- declare class StorageError extends RobotaError {
585
+ declare class StorageError extends AgentRuntimeError {
558
586
  readonly code = "STORAGE_ERROR";
559
587
  readonly category: "system";
560
588
  readonly recoverable = true;
@@ -563,7 +591,7 @@ declare class StorageError extends RobotaError {
563
591
  /**
564
592
  * Cache integrity validation errors
565
593
  */
566
- declare class CacheIntegrityError extends RobotaError {
594
+ declare class CacheIntegrityError extends AgentRuntimeError {
567
595
  readonly code = "CACHE_INTEGRITY_ERROR";
568
596
  readonly category: "system";
569
597
  readonly recoverable = false;
@@ -1427,6 +1455,10 @@ declare function readModelFallbackNotice(data: Readonly<Record<string, unknown>>
1427
1455
  declare const TOOL_BODY_EVENTS: {
1428
1456
  readonly COMPLETED: "tool_body_completed";
1429
1457
  };
1458
+ /** Submission to scheduler selection or refusal; never permission or effect completion. */
1459
+ declare const TOOL_QUEUE_EVENTS: {
1460
+ readonly COMPLETED: "tool_queue_completed";
1461
+ };
1430
1462
  /** Content-free decision reached for one tool call before any body runs. */
1431
1463
  declare const TOOL_PERMISSION_EVENTS: {
1432
1464
  readonly DECIDED: "tool_permission_decided";
@@ -1566,7 +1598,22 @@ interface IDeferredToolCatalog {
1566
1598
  //#region src/interfaces/tool.d.ts
1567
1599
  /** Awaited host admission for effective parameters, immediately before a tool body. */
1568
1600
  type TToolEffectAdmission<TParameters = TToolParameters> = (parameters: TParameters) => Promise<void>;
1569
- type TToolContextExtensionValue = TUniversalValue | Date | Error | TLoggerData | TContextData | TToolParameters | TToolMetadata;
1601
+ /** Trusted caller scheduling; plugin annotations grant neither authority nor retry permission. */
1602
+ interface IToolCallScheduling {
1603
+ dependsOn?: readonly string[];
1604
+ /** Omitted means unknown shared state; an empty array explicitly declares independence. */
1605
+ resources?: readonly {
1606
+ key: string;
1607
+ access: 'read' | 'write';
1608
+ }[];
1609
+ }
1610
+ interface IToolExecutionPolicy {
1611
+ mode?: 'parallel' | 'sequential';
1612
+ maxConcurrency?: number;
1613
+ continueOnError?: boolean;
1614
+ scheduling?: ReadonlyMap<string, IToolCallScheduling>;
1615
+ }
1616
+ type TToolContextExtensionValue = TUniversalValue | Date | Error | TLoggerData | TContextData | TToolParameters | TToolMetadata | TUniversalMessagePart[];
1570
1617
  /**
1571
1618
  * Tool metadata structure - specific type definition
1572
1619
  */
@@ -1584,6 +1631,8 @@ type TToolMetadata = Record<string, string | number | boolean | string[] | numbe
1584
1631
  interface IToolResult {
1585
1632
  success: boolean;
1586
1633
  data?: TUniversalValue;
1634
+ /** Ordered observations accompanying structured data; images stay typed through history. */
1635
+ parts?: TUniversalMessagePart[];
1587
1636
  error?: string;
1588
1637
  metadata?: TToolMetadata;
1589
1638
  [key: string]: TToolContextExtensionValue | undefined;
@@ -1598,6 +1647,8 @@ interface IToolExecutionResult {
1598
1647
  toolName?: string;
1599
1648
  /** Execution result or data */
1600
1649
  result?: TUniversalValue;
1650
+ /** Ordered observations retained with the durable execution settlement. */
1651
+ parts?: TUniversalMessagePart[];
1601
1652
  /** Error message if execution failed */
1602
1653
  error?: string;
1603
1654
  /** Execution duration in milliseconds */
@@ -1736,7 +1787,18 @@ type TToolExecutor<TParams = TToolParameters, TResult = TUniversalValue> = (para
1736
1787
  /**
1737
1788
  * Base tool interface
1738
1789
  */
1790
+ /** Host-declared tool attribution. It identifies a source; it never grants execution authority. */
1791
+ interface IToolProvenance {
1792
+ readonly sourceId: string;
1793
+ readonly component: string;
1794
+ readonly origin: string;
1795
+ /** A declared source version, not proof of installed bytes. */
1796
+ readonly version?: string;
1797
+ readonly protocolVersion?: string;
1798
+ readonly generation?: string;
1799
+ }
1739
1800
  interface ITool {
1801
+ readonly provenance?: IToolProvenance;
1740
1802
  /** Tool schema */
1741
1803
  schema: IToolSchema;
1742
1804
  /**
@@ -2575,7 +2637,7 @@ interface IPluginContract<TOptions extends IPluginOptions = IPluginOptions, TSta
2575
2637
  /**
2576
2638
  * CORE-022: the single component-level disposal entry point. The base implementation
2577
2639
  * unsubscribes module events; overrides release owned resources (timers, sockets,
2578
- * storage) — always calling `super.dispose()`. Driven by `Robota.destroy()`.
2640
+ * storage) — always calling `super.dispose()`. Driven by `ConversationAgent.destroy()`.
2579
2641
  */
2580
2642
  dispose(): Promise<void>;
2581
2643
  cleanup?(): Promise<void>;
@@ -2675,7 +2737,7 @@ declare class ConsoleLogger implements ILogger {
2675
2737
  * This logger's own threshold. `undefined` means "follow the process-wide level".
2676
2738
  *
2677
2739
  * CORE-029: the field existed and nothing ever set it, so the only way to change a level was
2678
- * `setGlobalLogLevel` — and `Robota`'s constructor called it from `config.logging`, which meant one
2740
+ * `setGlobalLogLevel` — and `ConversationAgent`'s constructor called it from `config.logging`, which meant one
2679
2741
  * agent's per-agent setting silenced every other agent AND every other package in the process.
2680
2742
  * A per-agent option has to reach a per-agent logger.
2681
2743
  */
@@ -2687,7 +2749,7 @@ declare class ConsoleLogger implements ILogger {
2687
2749
  *
2688
2750
  * It used to be `logger || SilentLogger`, decided once in the constructor. No call site in the
2689
2751
  * repository ever passed one and there was no way to set one afterwards, so every diagnostic this
2690
- * package emits — 157 `logger.*` calls, including "Robota initialization failed" and every
2752
+ * package emits — 157 `logger.*` calls, including "ConversationAgent initialization failed" and every
2691
2753
  * catch-and-log-only path — went to `SilentLogger` by construction. Not "was not configured":
2692
2754
  * could not be.
2693
2755
  *
@@ -2782,6 +2844,7 @@ interface IAbstractTool<TParams = TToolParameters, TResult = IToolResult> {
2782
2844
  */
2783
2845
  interface IToolContract<TParameters = TToolParameters, TResult = IToolResult> {
2784
2846
  readonly schema: IToolSchema;
2847
+ readonly provenance?: IToolProvenance;
2785
2848
  execute(parameters: TParameters, context: IToolExecutionContext): Promise<TResult>;
2786
2849
  /**
2787
2850
  * Wrappers await admission exactly once with final canonical arguments after preconditions and before
@@ -2794,10 +2857,10 @@ interface IToolContract<TParameters = TToolParameters, TResult = IToolResult> {
2794
2857
  getName(): string;
2795
2858
  }
2796
2859
  /**
2797
- * Runtime tool instance contract used by Robota internals.
2860
+ * Runtime tool instance contract used by ConversationAgent internals.
2798
2861
  *
2799
2862
  * Tools passed into Agent configuration must support EventService injection
2800
- * so Robota can emit unified tool lifecycle events.
2863
+ * so ConversationAgent can emit unified tool lifecycle events.
2801
2864
  */
2802
2865
  interface IToolWithEventService<TParameters = TToolParameters, TResult = IToolResult> extends IToolContract<TParameters, TResult> {
2803
2866
  setEventService(eventService: IEventService | undefined): void;
@@ -2862,6 +2925,8 @@ interface IAgentConfig {
2862
2925
  toolChoice?: TToolChoice;
2863
2926
  };
2864
2927
  tools?: Array<IToolWithEventService>;
2928
+ /** Host-owned per-round policy. Absent declarations serialize unknown shared-state operations. */
2929
+ toolExecutionPolicy?: (calls: readonly IToolCall[]) => IToolExecutionPolicy;
2865
2930
  /**
2866
2931
  * CLI-1990: whether tools that declare `deferLoading` are withheld from the model until loaded.
2867
2932
  * `'auto'` (the default) decides by threshold — `resolveToolSearchMode` — so a small tool set is
@@ -3410,6 +3475,8 @@ interface IToolManager {
3410
3475
  * Execute a tool
3411
3476
  */
3412
3477
  executeTool(name: string, parameters: TToolParameters, context?: IToolExecutionContext): Promise<TUniversalValue>;
3478
+ /** Full result port; absent on legacy value-only manager implementations. */
3479
+ executeToolResult?(name: string, parameters: TToolParameters, context?: IToolExecutionContext): Promise<IToolResult>;
3413
3480
  /**
3414
3481
  * Check if tool exists
3415
3482
  */
@@ -3871,7 +3938,7 @@ interface ILocalExecutorConfig {
3871
3938
  /**
3872
3939
  * Configuration options for a remote executor.
3873
3940
  *
3874
- * @deprecated Robota ships no remote executor, so nothing reads this type. It stays exported only
3941
+ * @deprecated ConversationAgent ships no remote executor, so nothing reads this type. It stays exported only
3875
3942
  * so existing imports keep compiling; describe your own executor's options instead.
3876
3943
  */
3877
3944
  interface IRemoteExecutorConfig {
@@ -4018,7 +4085,7 @@ interface IFileSystemAsync {
4018
4085
  */
4019
4086
  /** A secret's name: the owning service and the account within it, both chosen by the caller. */
4020
4087
  interface ICredentialKey {
4021
- /** A namespace for the caller, e.g. `robota.remote-control`. */
4088
+ /** A namespace for the caller, e.g. `agent.remote-control`. */
4022
4089
  readonly service: string;
4023
4090
  /** The secret's name within that namespace. */
4024
4091
  readonly account: string;
@@ -4032,6 +4099,12 @@ interface ICredentialStore {
4032
4099
  delete(key: ICredentialKey): Promise<void>;
4033
4100
  }
4034
4101
  //#endregion
4102
+ //#region src/utils/tool-provenance.d.ts
4103
+ /** Copy only the declared public attribution, before handing control to a tool. */
4104
+ declare function snapshotToolProvenance(source?: IToolProvenance): IToolProvenance | undefined;
4105
+ /** The execution owner's attribution overrides any result-supplied claim. */
4106
+ declare function withToolProvenance(result: IToolResult, source?: IToolProvenance): IToolResult;
4107
+ //#endregion
4035
4108
  //#region src/abstracts/abstract-agent.d.ts
4036
4109
  declare abstract class AbstractAgent<TConfig = IAgentConfig, TContext = IRunOptions, TMessage = TUniversalMessage> implements IAgent<TConfig, TContext, TMessage> {
4037
4110
  protected history: TMessage[];
@@ -4555,6 +4628,7 @@ declare abstract class AbstractExecutor implements IExecutor {
4555
4628
  */
4556
4629
  declare abstract class AbstractTool<TParameters = TToolParameters, TResult = IToolResult> implements IToolWithEventService<TParameters, TResult> {
4557
4630
  abstract readonly schema: IToolSchema;
4631
+ readonly provenance?: IToolProvenance;
4558
4632
  /**
4559
4633
  * Logger for tool operations
4560
4634
  */
@@ -4715,7 +4789,7 @@ declare class ErrorUtils {
4715
4789
  /**
4716
4790
  * Create error from unknown value
4717
4791
  */
4718
- static fromUnknown(error: TErrorExternalInput, defaultMessage?: string): RobotaError;
4792
+ static fromUnknown(error: TErrorExternalInput, defaultMessage?: string): AgentRuntimeError;
4719
4793
  /**
4720
4794
  * Wrap external errors
4721
4795
  */
@@ -4803,7 +4877,7 @@ interface IPlatformShellResolutionRequest {
4803
4877
  readonly platform?: NodeJS.Platform;
4804
4878
  }
4805
4879
  /** An explicit executable whose basename has no supported command argument family. */
4806
- declare class UnsupportedShellError extends RobotaError {
4880
+ declare class UnsupportedShellError extends AgentRuntimeError {
4807
4881
  readonly executable: string;
4808
4882
  readonly code = "UNSUPPORTED_SHELL";
4809
4883
  readonly category: "user";
@@ -4845,9 +4919,9 @@ declare function toolTraceContextFor(traceContext: IRunTraceContext, toolBodyId:
4845
4919
  */
4846
4920
  declare function traceEnvFor(subprocessClass: TSubprocessTraceClass, traceContext: IRunTraceContext | undefined, spanId: string): ISubprocessTraceEnv | undefined;
4847
4921
  /**
4848
- * A fresh child environment: `base`, then Robota's trace, then `overrides`. When Robota's value
4922
+ * A fresh child environment: `base`, then ConversationAgent's trace, then `overrides`. When ConversationAgent's value
4849
4923
  * applies, the ambient `TRACESTATE` is dropped because it belongs to a different parent. When
4850
- * `overrides` sets its own `TRACEPARENT`, Robota's value does not apply and `base` passes unchanged.
4924
+ * `overrides` sets its own `TRACEPARENT`, ConversationAgent's value does not apply and `base` passes unchanged.
4851
4925
  * `base` itself is never modified.
4852
4926
  */
4853
4927
  declare function subprocessTraceEnvironment(base: Readonly<Record<string, string | undefined>>, traceEnv: ISubprocessTraceEnv | undefined, overrides?: Readonly<Record<string, string>>): Record<string, string | undefined>;
@@ -5495,10 +5569,13 @@ declare class ToolRegistry implements IToolRegistry {
5495
5569
  * circular runtime dependency (tools -> agents -> tools).
5496
5570
  */
5497
5571
  declare class FunctionTool implements IFunctionTool {
5572
+ private readonly resultExecutor?;
5498
5573
  readonly schema: IToolSchema;
5499
5574
  readonly fn: TToolExecutor;
5500
5575
  private eventService;
5501
- constructor(schema: IToolSchema, fn: TToolExecutor);
5576
+ constructor(schema: IToolSchema, fn: TToolExecutor, resultExecutor?: TToolExecutor<TToolParameters, IToolResult> | undefined);
5577
+ /** Register an envelope executor explicitly; ordinary function values remain domain data. */
5578
+ static fromResult(schema: IToolSchema, execute: TToolExecutor<TToolParameters, IToolResult>): FunctionTool;
5502
5579
  /**
5503
5580
  * Get tool name
5504
5581
  */
@@ -5546,11 +5623,11 @@ declare const DEFERRED_WITHOUT_LOADER_MESSAGE: string;
5546
5623
  */
5547
5624
  declare function assertResidentToolRemains(schemas: readonly IToolSchema[]): void;
5548
5625
  //#endregion
5549
- //#region src/core/robota-types.d.ts
5626
+ //#region src/core/agent-types.d.ts
5550
5627
  /**
5551
5628
  * Shared model configuration shape used in setModel / getModel. The system prompt is intentionally
5552
5629
  * absent: it is an agent-level concern (top-level `config.systemMessage`), updated live via
5553
- * `Robota.updateSystemPrompt`, not part of model config.
5630
+ * `ConversationAgent.updateSystemPrompt`, not part of model config.
5554
5631
  */
5555
5632
  interface IModelConfig {
5556
5633
  provider: string;
@@ -5595,7 +5672,7 @@ type TExecuteModuleResult = {
5595
5672
  duration?: number;
5596
5673
  };
5597
5674
  //#endregion
5598
- //#region src/core/robota-base.d.ts
5675
+ //#region src/core/conversation-agent-base.d.ts
5599
5676
  type TPlugin = IPluginContract<IPluginOptions, IPluginStats> & IPluginHooks;
5600
5677
  interface IModuleManagerProxy {
5601
5678
  registerModule(module: IModule, options?: TRegisterModuleOptions): Promise<void>;
@@ -5615,11 +5692,11 @@ interface IPluginManagerProxy {
5615
5692
  getPlugins(): TPlugin[];
5616
5693
  getPluginNames(): string[];
5617
5694
  }
5618
- declare abstract class RobotaBase extends AbstractAgent<IAgentConfig, IRunOptions, TUniversalMessage> {
5695
+ declare abstract class ConversationAgentBase extends AbstractAgent<IAgentConfig, IRunOptions, TUniversalMessage> {
5619
5696
  protected moduleManager: IModuleManagerProxy;
5620
5697
  protected pluginManager: IPluginManagerProxy;
5621
5698
  /**
5622
- * Narrowed from `AbstractAgent`'s optional `config`: a Robota agent always has one, assigned in the
5699
+ * Narrowed from `AbstractAgent`'s optional `config`: a ConversationAgent agent always has one, assigned in the
5623
5700
  * constructor. Declared HERE so `name` below can read it without a fallback that would lie.
5624
5701
  */
5625
5702
  protected config: IAgentConfig;
@@ -5765,6 +5842,8 @@ declare class Tools extends AbstractManager implements IToolManager {
5765
5842
  * Register a tool with schema and executor function
5766
5843
  */
5767
5844
  addTool(schema: IToolSchema, executor: TToolExecutor): void;
5845
+ /** Register a typed result executor without discarding its observations or failure envelope. */
5846
+ addResultTool(schema: IToolSchema, executor: TToolExecutor<TToolParameters, IToolResult>, provenance?: IToolProvenance): void;
5768
5847
  /**
5769
5848
  * Remove a tool by name
5770
5849
  */
@@ -5803,6 +5882,8 @@ declare class Tools extends AbstractManager implements IToolManager {
5803
5882
  * Execute a tool with parameters
5804
5883
  */
5805
5884
  executeTool(name: string, parameters: TToolParameters, context?: IToolExecutionContext): Promise<TUniversalValue>;
5885
+ /** Execute the full result envelope for runtime observation and durable settlement. */
5886
+ executeToolResult(name: string, parameters: TToolParameters, context?: IToolExecutionContext): Promise<IToolResult>;
5806
5887
  /**
5807
5888
  * Check if tool exists
5808
5889
  */
@@ -5825,7 +5906,7 @@ declare class Tools extends AbstractManager implements IToolManager {
5825
5906
  getToolCount(): number;
5826
5907
  }
5827
5908
  //#endregion
5828
- //#region src/core/robota-config-manager.d.ts
5909
+ //#region src/core/agent-config-manager.d.ts
5829
5910
  /** Agent statistics metadata type */
5830
5911
  type TAgentStatsMetadata = Record<string, string | number | boolean | Date | string[]>;
5831
5912
  //#endregion
@@ -5864,9 +5945,9 @@ declare const EXECUTION_EVENTS: {
5864
5945
  };
5865
5946
  declare const EXECUTION_EVENT_PREFIX: "execution";
5866
5947
  //#endregion
5867
- //#region src/core/robota-lifecycle.d.ts
5948
+ //#region src/core/agent-lifecycle.d.ts
5868
5949
  /** Dependencies required by getStats. @internal */
5869
- interface IRobotaStatsDeps {
5950
+ interface IAgentStatsDeps {
5870
5951
  readonly name: string;
5871
5952
  readonly version: string;
5872
5953
  readonly conversationId: string;
@@ -5879,7 +5960,7 @@ interface IRobotaStatsDeps {
5879
5960
  getHistory(): TUniversalMessage[];
5880
5961
  }
5881
5962
  /** Build comprehensive agent statistics. @internal */
5882
- declare function buildAgentStats(deps: IRobotaStatsDeps): {
5963
+ declare function buildAgentStats(deps: IAgentStatsDeps): {
5883
5964
  name: string;
5884
5965
  version: string;
5885
5966
  conversationId: string;
@@ -5897,9 +5978,9 @@ interface IDestroyResult {
5897
5978
  errors: Error[];
5898
5979
  }
5899
5980
  //#endregion
5900
- //#region src/core/robota.d.ts
5981
+ //#region src/core/conversation-agent.d.ts
5901
5982
  /** @public */
5902
- declare class Robota extends RobotaBase implements IAgent<IAgentConfig, IRunOptions, TUniversalMessage> {
5983
+ declare class ConversationAgent extends ConversationAgentBase implements IAgent<IAgentConfig, IRunOptions, TUniversalMessage> {
5903
5984
  readonly version: string;
5904
5985
  private aiProviders;
5905
5986
  private tools;
@@ -5942,14 +6023,14 @@ declare class Robota extends RobotaBase implements IAgent<IAgentConfig, IRunOpti
5942
6023
  */
5943
6024
  resumeToolCalls(value: IResumeToolCallsOptions): Promise<IResumeToolCallsResult>;
5944
6025
  /**
5945
- * Concurrency contract (CORE-012): a Robota instance owns ONE conversation history, so
6026
+ * Concurrency contract (CORE-012): a ConversationAgent instance owns ONE conversation history, so
5946
6027
  * concurrent `run`/`runStream` calls on the same instance are serialized on an internal queue —
5947
6028
  * a call issued while another is in flight waits its turn (its `signal` is honored while queued).
5948
6029
  * Interleaved histories are therefore impossible by construction.
5949
6030
  *
5950
6031
  * Structured output (CORE-015): with `options.output` set the promise resolves to the validated
5951
6032
  * object (typed `z.infer<S>` for a Zod schema) instead of a string. Note the structured typing
5952
- * is visible on `Robota` directly; through the generic `IAgent` interface the return type stays
6033
+ * is visible on `ConversationAgent` directly; through the generic `IAgent` interface the return type stays
5953
6034
  * `Promise<string>`.
5954
6035
  */
5955
6036
  run<S extends ZodType>(input: string, options: TRunOptionsWithOutput<S>): Promise<TypeOf<S>>;
@@ -6916,10 +6997,17 @@ declare const UNCLASSIFIED_TOOL_FALLBACK: Record<TPermissionMode, TPermissionDec
6916
6997
  declare const PROTECTED_DIRECTORY_NAMES: readonly string[];
6917
6998
  /** Files that configure git, npm, MCP servers or the user's shell, wherever they sit. */
6918
6999
  declare const PROTECTED_FILE_NAMES: readonly string[];
7000
+ /** Additional host-owned state protection; common repository and shell protection always applies. */
7001
+ interface IPathProtectionPolicy {
7002
+ readonly protectedDirectoryNames: readonly string[];
7003
+ readonly protectedPaths: readonly string[];
7004
+ readonly writableWorktreeContainers: readonly string[];
7005
+ }
6919
7006
  /** Whether a path names a protected directory, something inside one, or a protected file. */
6920
- declare function isProtectedPath(path: string): boolean;
7007
+ declare function isProtectedPath(path: string, context?: ICriticalPathContext): boolean;
6921
7008
  /** Where a removal is judged from. Either may be unknown; what is unknown is not guessed. */
6922
7009
  interface ICriticalPathContext {
7010
+ readonly pathProtection?: IPathProtectionPolicy;
6923
7011
  /** The session's execution root. */
6924
7012
  cwd?: string;
6925
7013
  /** The user's home directory. */
@@ -7628,5 +7716,9 @@ declare function decodeHookVerdict(raw: string, source: THookDefinition['type'],
7628
7716
  /** Does a hook that reached no verdict block at this event? */
7629
7717
  declare function isEnforcing(event: THookEvent): boolean;
7630
7718
  //#endregion
7631
- export { AGENT_EVENTS, AGENT_EVENT_PREFIX, AbstractAIProvider, AbstractAgent, AbstractEventService, AbstractExecutor, AbstractManager, AbstractPlugin, AbstractTool, AgentFactory, AgentTemplates, AuthenticationError, CONFIRM_NO, CONFIRM_YES, CONTEXT_ESTIMATE_CHARS_PER_TOKEN, CacheIntegrityError, CircuitBreakerOpenError, ConfigurationError, ConsoleLogger, ConversationHistory, ConversationStore, DEFAULT_ABSTRACT_EVENT_SERVICE, DEFAULT_BACKGROUND_PERMISSION_POLICY, DEFAULT_CONTEXT_WINDOW, DEFAULT_MAX_OUTPUT, DEFAULT_TOOL_RESULT_HARD_CHARS, DEFAULT_TOOL_RESULT_WARNING_CHARS, DEFERRED_WITHOUT_LOADER_MESSAGE, DefaultEventService, ENV_REFERENCE_PREFIX, EVENT_EMITTER_EVENTS, EXECUTION_EVENTS, EXECUTION_EVENT_PREFIX, EmptyCompletionError, ErrorUtils, EventEmitterPlugin, EventHistoryModule, ExecutionJournalError, ExecutionProxy, ExecutionRecoveryError, ExecutionSuspendedError, FunctionTool, GuardrailExecutor, type IAIProvider, type IAIProviderInstance, type IAIProviderManager, type IAbstractTool, type IAbstractToolOptions, type IActionDefault, type IActionOption, type IActionRequest, type IAgent, type IAgentConfig, type IAgentCreationStats, type IAgentEventData, type IAgentFactoryOptions, type IAgentHookDefinition, type IAgentLifecycleEvents, type IAgentTemplate, type IAssistantMessage, type IAssistantUsageMetadata, type IBaseEventData, type IBaseMessage, type IBoundedOutput, type IBoundedOutputOptions, type ICacheEntry, type ICacheKey, type ICacheOptions, type ICacheStats, type ICacheStorage, type IChatExecutionRequest, type IChatOptions, type ICommandHookDefinition, type IContextOptions, type IContextTokenEstimate, type IContextTokenEstimateOptions, type IContextTokenUsage, type IContextWindowState, type IConversationContext, type IConversationResponse, type IConversationService, type IConversationServiceOptions, type ICredentialKey, type ICredentialStore, type ICriticalPathContext, type IDeferredToolCatalog, type IDestroyResult, type IDirent, type IEventContext, type IEventEmitterEventData, type IEventEmitterHierarchicalEventData, type IEventEmitterMetrics, type IEventEmitterMetricsSnapshot, type IEventEmitterPlugin, type IEventEmitterPluginOptions, type IEventHistoryModule, type IEventHistoryRecord, type IEventHistorySnapshot, type IEventObjectValue, type IEventService, type IEventServiceOwnerBinding, type IExecutionContinuationState, type IExecutionEventData, type IExecutionJournal, type IExecutionProxyConfig, type IExecutionRoundCheckpoint, type IExecutor, IExecutorAwareProviderConfig, type IExecutorChatResult, type IExecutorStreamMessageEvent, type IExecutorStreamTerminalEvent, type IFileSystem, type IFileSystemAsync, type IFunctionTool, type IGroupChatOrchestrationSpec, type IGuardrailHookDefinition, type IGuardrailResult, type IHandoffOrchestrationSpec, type IHierarchicalOrchestrationSpec, type IHistoryEntry, type IHookGroup, type IHookInput, type IHookTypeExecutor, type IHttpHookDefinition, type IImageComposeRequest, type IImageEditRequest, type IImageGenerationProvider, type IImageGenerationRequest, type IImageGenerationResult, type IInlineImageInputSource, type IInlineImageMessagePart, type IJsonSchemaOutput, type ILocalExecutorConfig, ILogger, ILoggerOptions, IManagerLifecycleOptions, type IMediaOutputRef, type IMediaProviderConfig, type IMediaProviderCredentialRequirement, type IMediaProviderDefinition, type IMediaProviderOverrides, type IMessageTokenUsage, type IModelCapabilityDeviation, type IModelDefinition, type IModelEffortCapability, type IModelEffortOutcome, type IModelEffortResolution, type IModelFallbackNotice, type IModelJournalContext, type IModelPrice, type IModelRef, type IObjectParameterSchema, type IOpenAPIToolConfig, type IOrchestrationDelegation, type IOrchestrationEventData, type IOrchestrationRunResult, type IOrchestrationStep, type IOrchestrationStepResult, type IOutboundTraceContext, type IOwnerPathSegment, type IParallelOrchestrationSpec, type IParameterRule, type IParameterSchema, type IParameterValidationResult, type IPermissionEvaluationContext, type IPermissionLists, type IPermissionPatternProblem, type IPermissionPolicyContext, type IPermissionPolicyProjection, IPlatformShell, IPlatformShellResolutionRequest, type IPlugin, type IPluginConfig, type IPluginContext, type IPluginContract, type IPluginData, type IPluginErrorContext, type IPluginExecutionContext, type IPluginExecutionResult, type IPluginHooks, type IPluginOptions, type IPluginStats, type IProgressReportingTool, type IPromptHookDefinition, type IProviderCapabilities, type IProviderCapabilityTable, type IProviderCredentialRequirement, type IProviderDefinition, type IProviderDefinitionConfig, type IProviderEndpoint, type IProviderFailureClassification, IProviderFailureDetails, type IProviderFunctionCallingCapability, type IProviderMediaError, type IProviderModelCatalog, type IProviderModelCatalogEntry, type IProviderModelEffortTable, type IProviderNativeRawPayloadEvent, type IProviderNativeWebToolCapabilities, type IProviderNativeWebToolCapability, type IProviderNativeWebToolRequest, type IProviderOptions, type IProviderProbeResult, type IProviderProfileConfig, type IProviderProfileDefaults, type IProviderRequest, IProviderRuntimeConfig, type IProviderSetupHelpLink, type IProviderSetupStepDefinition, type IProviderSpecificOptions, type IProviderStructuredOutputCapability, type IRawProviderResponse, type IReadOnlyCommandContext, type IRecoverableExecutionJournal, type IRegistryOwnedLifecycle, type IRegistryTransactionError, type IRegistryTransactionStep, type IRemoteExecutorConfig, type IResponseFormatConfig, type IResumeExecutionOptions, type IResumeToolCallsOptions, type IResumeToolCallsResult, type IRunOptions, type IRunTraceContext, type ISchemaClosureChange, type ISchemaClosureOptions, type ISchemaConversionOptions, type ISequentialOrchestrationSpec, type ISession, type ISessionUsageTotals, ISimpleValidationResult, type ISpanCompletionEventData, type ISpinner, type IStats, type IStreamExecutionRequest, type IStreamingChunk, type IStructuredOutputResolutionInput, type IStructuredOutputSpec, type ISubprocessTraceEnv, type ISystemMessage, type ITemplateApplicationResult, type ITerminalOutput, type ITextMessagePart, type ITokenUsage, type ITokenUsageWithCacheRead, type ITool, type IToolActionIdentity, type IToolCall, type IToolContinuation, type IToolContinuationPrompt, type IToolContract, type IToolEventData, type IToolExecutionContext, type IToolExecutionRequest, type IToolExecutionResult, type IToolExecutionStep, type IToolFactory, type IToolManager, type IToolMessage, type IToolPermissionArgument, type IToolPermissionProfile, type IToolRegistry, type IToolResult, type IToolResultAdmissionOptions, type IToolResultSpillStore, type IToolSchema, type IToolSchemaProjection, type IToolSchemaProjectionChange, type IToolSchemaProjectionProfile, type IToolWaitRequest, type IToolWaitResponse, type IToolWaitState, type IToolWithEventService, type IUniversalObjectValue, type IUriImageInputSource, type IUriImageMessagePart, type IUserInteraction, type IUserMessage, IUtilLogEntry, type IVerifiedProviderCallUsage, type IVideoGenerationProvider, type IVideoGenerationRequest, type IVideoJobAccepted, type IVideoJobSnapshot, type IZodParseResult, type IZodSchema, type IZodSchemaDef, InMemoryEventEmitterMetrics, LocalExecutor, MAX_TOOL_RESULT_CHARS, MODEL_EFFORT_VALUES, MODEL_PRICES, MessageConverter, ModelNotAvailableError, NetworkError, ORCHESTRATION_EVENTS, ORCHESTRATION_EVENT_PREFIX, ObservableEventService, PARAMETER_SCHEMA_KEYWORDS, PERMISSIVE_TOOL_SCHEMA_PROFILE, PROTECTED_DIRECTORY_NAMES, PROTECTED_FILE_NAMES, PROVIDER_CALL_EVENTS, PROVIDER_FALLBACK_EVENTS, PluginCategory, PluginError, PluginPriority, ProviderError, RISK_CLASS_POLICY, RateLimitError, Robota, RobotaError, SPAN_EVENTS, SPAN_EVENT_PREFIX, STRICT_TOOL_SCHEMA_PROFILE, SameToolInputLoopError, SilentLogger, StorageError, StructuredEventService, StructuredOutputError, TASK_EVENTS, TASK_EVENT_PREFIX, type TActionResponse, type TArgumentKind, type TBackgroundPermissionPolicy, TComplexConfigValue, TConfigData, TConfigValue, TContextData, type TConversationContextMetadata, type TEnvResolver, TErrorContextData, TErrorExternalInput, type TEventEmitterListener, type TEventExtensionValue, type TEventListener, type TEventLoggerData, type TEventName, type TEventUniversalValue, type TExecutionEventCallback, type TExecutionEventData, type TExecutionEventName, type TExecutionJournalRecord, type TExecutionRecoveryErrorCode, type TExecutorStreamEvent, type TGuardrail, type THookDefinition, type THookEvent, type THookOutcome, type THooksConfig, type TImageInputSource, type TJSONSchemaEnum, type TJSONSchemaKind, type TJournalModelOptions, TLoggerData, type TManagerToolParameters, type TMatchDirection, TMessageConverterRegistry, TMessageFormatConverter, type TMessageState, TMetadata, TMetadataValue, type TModelEffort, type TModelEffortDisposition, type TModelEffortNativeControl, type TModelEffortOutcomeCallback, type TModelEffortProviderDispatch, type TModelEffortSelection, type TModelFallbackCallback, TOOL_BODY_EVENTS, TOOL_EVENTS, TOOL_EVENT_PREFIX, TOOL_PERMISSION_EVENTS, TOOL_SCHEMA_PROJECTION_MAX_DEPTH, TOOL_SCHEMA_PROJECTION_MAX_NODES, TOOL_SEARCH_TOOL_NAME, type TOrchestrationEvent, type TOrchestrationPrimitive, type TOutputRetention, type TParameterDefaultValue, type TPermissionDecision, type TPermissionMode, type TPrimitiveValue, type TProviderConfigValue, type TProviderCredentialField, type TProviderFailureReason, TProviderLoggingData, type TProviderMediaResult, TProviderMessage, type TProviderModelCapability, type TProviderModelCatalogStatus, type TProviderModelLifecycle, type TProviderNativeRawPayload, type TProviderNativeRawPayloadCallback, type TProviderNativeRawPayloadKind, type TProviderOptionValueBase, type TProviderSetupField, type TProviderSetupHelpLinkKind, type TProviderUsageProvenance, TRUST_TO_MODE, type TResolveInWorkspace, type TResponseMetadata, type TRoleModelMap, type TSessionEndReason, TShellKind, type TSpanEvent, type TStructuredOutputMechanism, type TStructuredOutputProvenance, type TStructuredOutputSchema, type TStructuredOutputValidation, type TSubprocessTraceClass, type TTextDeltaCallback, type TTimerId, type TToolArgs, type TToolChoice, type TToolEffectAdmission, type TToolExecutionFunction, type TToolExecutionParameters, type TToolExecutor, type TToolMetadata, TToolParameters, type TToolProgressCallback, type TToolResultAdmissionErrorCode, type TToolRiskClass, type TToolSchemaProjectionOutcome, type TToolSchemaProjectionProfileBase, type TToolSearchMode, type TToolSearchSetting, type TTrustLevel, type TUniversalArrayValue, type TUniversalMessage, type TUniversalMessageMetadata, type TUniversalMessagePart, type TUniversalMessageRole, type TUniversalValue, type TUserEvent, TUtilLogLevel, ToolExecutionError, ToolRegistry, ToolResultAdmissionError, TypeUtils, UNCLASSIFIED_TOOL_FALLBACK, USER_EVENTS, USER_EVENT_PREFIX, UnsupportedShellError, ValidationError, Validator, admitToolResult, allowRulesForAutoMode, applyPresetToolLists, assertProviderNativeWebToolsAvailable, assertResidentToolRemains, bindEventServiceOwner, bindWithOwnerPath, buildTraceparent, calculateModelCost, callJournaledProvider, chatEntryToMessage, classifyProviderFailure, clearRegisteredToolProfiles, closeObjectSchemas, collectAssistantUsageMetadata, composeEventName, confirmAction, createAssistantMessage, createBoundedOutput, createDefaultProviderCapabilities, createExecutionProxy, createImageProviderFromDefinition, createLogger, createModelEffortOutcome, createProviderFromConfig, createRecordEnvResolver, createSystemMessage, createToolMessage, createUserMessage, createVideoProviderFromDefinition, decodeHookVerdict, estimateBlendedCostPer1000, estimateContextTokensFromMessages, estimateSerializedContextTokens, estimateToolSchemaTokens, evaluatePermission, extractEnumValues, findInvalidPermissionPatterns, findMediaProviderDefinition, findModelDefinition, findPermissionPatternWarnings, findProviderDefinition, formatEnvReference, formatSupportedProviderTypes, formatTokenCount, generateSpanId, getGlobalLogLevel, getGlobalLoggerSink, getMessagesForAPI, getModelContextWindow, getModelMaxOutput, getModelName, getProviderCapabilities, getProviderCredentialRequirement, getSchemaTypeName, getToolEstimatedDuration, getToolExecutionSteps, getToolPermissionProfile, hasUsableSecretReference, hasValidationConstraints, hashToolSchema, isAbortFailure, isAssistantMessage, isBroadExecutionAllowRule, isChatEntry, isConfirmed, isDefaultEventService, isEnforcing, isEnvReference, isExecutionControlError, isImageGenerationProvider, isMediaProviderDefinition, isMintedSpanId, isModelEffort, isProgressReportingTool, isProtectedPath, isReadOnlyCommandLine, isRegistryTransactionError, isSystemMessage, isToolDeniedOutright, isToolMessage, isUserMessage, isVideoGenerationProvider, lifecycleOf, logger, lookupModelPrice, matchesAnyPattern, messageToHistoryEntry, modelDeclaresCapability, multiSelectAction, normalizeProviderConfig, normalizeStructuredOutput, outboundTraceContextFor, parseParameterRule, parseStructuredResponseText, peerDriverOf, printablePeerDriver, processEnvResolver, projectPermissionPolicy, projectToolSchema, providerCallSpanId, readModelFallbackNotice, readProviderFailureDetails, readTokenUsageFromMessage, readTokenUsageFromMetadata, registerModelMetadata, registerToolPermissionProfile, removesCriticalPath, requiresFreshApproval, resolveEnvReference, resolveMediaProviderConfig, resolveModelCapabilities, resolveModelCapability, resolveModelEffort, resolvePlatformShell, resolveStructuredOutputCapability, runHooks, runRegistryTransaction, scrubSecrets, selectAction, setGlobalLogLevel, setGlobalLoggerSink, setToolProgressCallback, shellArgumentForDisplay, spanIdFromMintedId, splitCommandSegments, startPeriodicTask, stopPeriodicTask, subprocessTraceEnvironment, sumHistoryUsage, sumMessagesUsage, textAction, toProviderError, toolNameMatches, toolNamesToPatterns, toolTraceContextFor, traceEnvFor, traceHeadersFor, validateAgainstJsonSchema, validateAgentConfig, validateApiKey, validateModelName, validatePermissionPattern, validateProviderName, validateUserInput, verifiedProviderCallUsage, wasToolResultAdmitted, withEventEmission, zodToJsonSchema };
7719
+ //#region src/utils/non-visual-observation-text.d.ts
7720
+ /** Text projection for adapters without native resource or audio payload support. Never resolves URIs. */
7721
+ declare function nonVisualObservationText(part: TUniversalMessagePart): string | undefined;
7722
+ //#endregion
7723
+ export { AGENT_EVENTS, AGENT_EVENT_PREFIX, AbstractAIProvider, AbstractAgent, AbstractEventService, AbstractExecutor, AbstractManager, AbstractPlugin, AbstractTool, AgentFactory, AgentRuntimeError, AgentTemplates, AuthenticationError, CONFIRM_NO, CONFIRM_YES, CONTEXT_ESTIMATE_CHARS_PER_TOKEN, CacheIntegrityError, CircuitBreakerOpenError, ConfigurationError, ConsoleLogger, ConversationAgent, ConversationAgent as Robota, ConversationHistory, ConversationStore, DEFAULT_ABSTRACT_EVENT_SERVICE, DEFAULT_BACKGROUND_PERMISSION_POLICY, DEFAULT_CONTEXT_WINDOW, DEFAULT_MAX_OUTPUT, DEFAULT_TOOL_RESULT_HARD_CHARS, DEFAULT_TOOL_RESULT_WARNING_CHARS, DEFERRED_WITHOUT_LOADER_MESSAGE, DefaultEventService, ENV_REFERENCE_PREFIX, EVENT_EMITTER_EVENTS, EXECUTION_EVENTS, EXECUTION_EVENT_PREFIX, EmptyCompletionError, ErrorUtils, EventEmitterPlugin, EventHistoryModule, ExecutionJournalError, ExecutionProxy, ExecutionRecoveryError, ExecutionSuspendedError, FunctionTool, GuardrailExecutor, type IAIProvider, type IAIProviderInstance, type IAIProviderManager, type IAbstractTool, type IAbstractToolOptions, type IActionDefault, type IActionOption, type IActionRequest, type IAgent, type IAgentConfig, type IAgentCreationStats, type IAgentEventData, type IAgentFactoryOptions, type IAgentHookDefinition, type IAgentLifecycleEvents, type IAgentTemplate, type IAssistantMessage, type IAssistantUsageMetadata, type IBaseEventData, type IBaseMessage, type IBoundedOutput, type IBoundedOutputOptions, type ICacheEntry, type ICacheKey, type ICacheOptions, type ICacheStats, type ICacheStorage, type IChatExecutionRequest, type IChatOptions, type ICommandHookDefinition, type IContextOptions, type IContextTokenEstimate, type IContextTokenEstimateOptions, type IContextTokenUsage, type IContextWindowState, type IConversationContext, type IConversationResponse, type IConversationService, type IConversationServiceOptions, type ICredentialKey, type ICredentialStore, type ICriticalPathContext, type IDeferredToolCatalog, type IDestroyResult, type IDirent, type IEventContext, type IEventEmitterEventData, type IEventEmitterHierarchicalEventData, type IEventEmitterMetrics, type IEventEmitterMetricsSnapshot, type IEventEmitterPlugin, type IEventEmitterPluginOptions, type IEventHistoryModule, type IEventHistoryRecord, type IEventHistorySnapshot, type IEventObjectValue, type IEventService, type IEventServiceOwnerBinding, type IExecutionContinuationState, type IExecutionEventData, type IExecutionJournal, type IExecutionProxyConfig, type IExecutionRoundCheckpoint, type IExecutor, IExecutorAwareProviderConfig, type IExecutorChatResult, type IExecutorStreamMessageEvent, type IExecutorStreamTerminalEvent, type IFileSystem, type IFileSystemAsync, type IFunctionTool, type IGroupChatOrchestrationSpec, type IGuardrailHookDefinition, type IGuardrailResult, type IHandoffOrchestrationSpec, type IHierarchicalOrchestrationSpec, type IHistoryEntry, type IHookGroup, type IHookInput, type IHookTypeExecutor, type IHttpHookDefinition, type IImageComposeRequest, type IImageEditRequest, type IImageGenerationProvider, type IImageGenerationRequest, type IImageGenerationResult, type IInlineAudioMessagePart, type IInlineImageInputSource, type IInlineImageMessagePart, type IJsonSchemaOutput, type ILocalExecutorConfig, ILogger, ILoggerOptions, IManagerLifecycleOptions, type IMediaOutputRef, type IMediaProviderConfig, type IMediaProviderCredentialRequirement, type IMediaProviderDefinition, type IMediaProviderOverrides, type IMessageTokenUsage, type IModelCapabilityDeviation, type IModelDefinition, type IModelEffortCapability, type IModelEffortOutcome, type IModelEffortResolution, type IModelFallbackNotice, type IModelJournalContext, type IModelPrice, type IModelRef, type IObjectParameterSchema, type IOpenAPIToolConfig, type IOrchestrationDelegation, type IOrchestrationEventData, type IOrchestrationRunResult, type IOrchestrationStep, type IOrchestrationStepResult, type IOutboundTraceContext, type IOwnerPathSegment, type IParallelOrchestrationSpec, type IParameterRule, type IParameterSchema, type IParameterValidationResult, type IPathProtectionPolicy, type IPermissionEvaluationContext, type IPermissionLists, type IPermissionPatternProblem, type IPermissionPolicyContext, type IPermissionPolicyProjection, IPlatformShell, IPlatformShellResolutionRequest, type IPlugin, type IPluginConfig, type IPluginContext, type IPluginContract, type IPluginData, type IPluginErrorContext, type IPluginExecutionContext, type IPluginExecutionResult, type IPluginHooks, type IPluginOptions, type IPluginStats, type IProgressReportingTool, type IPromptHookDefinition, type IProviderCapabilities, type IProviderCapabilityTable, type IProviderCredentialRequirement, type IProviderDefinition, type IProviderDefinitionConfig, type IProviderEndpoint, type IProviderFailureClassification, IProviderFailureDetails, type IProviderFunctionCallingCapability, type IProviderMediaError, type IProviderModelCatalog, type IProviderModelCatalogEntry, type IProviderModelEffortTable, type IProviderNativeRawPayloadEvent, type IProviderNativeWebToolCapabilities, type IProviderNativeWebToolCapability, type IProviderNativeWebToolRequest, type IProviderOptions, type IProviderProbeResult, type IProviderProfileConfig, type IProviderProfileDefaults, type IProviderRequest, IProviderRuntimeConfig, type IProviderSetupHelpLink, type IProviderSetupStepDefinition, type IProviderSpecificOptions, type IProviderStructuredOutputCapability, type IRawProviderResponse, type IReadOnlyCommandContext, type IRecoverableExecutionJournal, type IRegistryOwnedLifecycle, type IRegistryTransactionError, type IRegistryTransactionStep, type IRemoteExecutorConfig, type IResourceLinkMessagePart, type IResponseFormatConfig, type IResumeExecutionOptions, type IResumeToolCallsOptions, type IResumeToolCallsResult, type IRunOptions, type IRunTraceContext, type ISchemaClosureChange, type ISchemaClosureOptions, type ISchemaConversionOptions, type ISequentialOrchestrationSpec, type ISession, type ISessionUsageTotals, ISimpleValidationResult, type ISpanCompletionEventData, type ISpinner, type IStats, type IStreamExecutionRequest, type IStreamingChunk, type IStructuredOutputResolutionInput, type IStructuredOutputSpec, type ISubprocessTraceEnv, type ISystemMessage, type ITemplateApplicationResult, type ITerminalOutput, type ITextMessagePart, type ITokenUsage, type ITokenUsageWithCacheRead, type ITool, type IToolActionIdentity, type IToolCall, type IToolCallScheduling, type IToolContinuation, type IToolContinuationPrompt, type IToolContract, type IToolEventData, type IToolExecutionContext, type IToolExecutionPolicy, type IToolExecutionRequest, type IToolExecutionResult, type IToolExecutionStep, type IToolFactory, type IToolManager, type IToolMessage, type IToolPermissionArgument, type IToolPermissionProfile, type IToolProvenance, type IToolRegistry, type IToolResult, type IToolResultAdmissionOptions, type IToolResultSpillStore, type IToolSchema, type IToolSchemaProjection, type IToolSchemaProjectionChange, type IToolSchemaProjectionProfile, type IToolWaitRequest, type IToolWaitResponse, type IToolWaitState, type IToolWithEventService, type IUniversalObjectValue, type IUriImageInputSource, type IUriImageMessagePart, type IUserInteraction, type IUserMessage, IUtilLogEntry, type IVerifiedProviderCallUsage, type IVideoGenerationProvider, type IVideoGenerationRequest, type IVideoJobAccepted, type IVideoJobSnapshot, type IZodParseResult, type IZodSchema, type IZodSchemaDef, InMemoryEventEmitterMetrics, LocalExecutor, MAX_TOOL_RESULT_CHARS, MODEL_EFFORT_VALUES, MODEL_PRICES, MessageConverter, ModelNotAvailableError, NetworkError, ORCHESTRATION_EVENTS, ORCHESTRATION_EVENT_PREFIX, ObservableEventService, PARAMETER_SCHEMA_KEYWORDS, PERMISSIVE_TOOL_SCHEMA_PROFILE, PROTECTED_DIRECTORY_NAMES, PROTECTED_FILE_NAMES, PROVIDER_CALL_EVENTS, PROVIDER_FALLBACK_EVENTS, PluginCategory, PluginError, PluginPriority, ProviderError, RISK_CLASS_POLICY, RateLimitError, SPAN_EVENTS, SPAN_EVENT_PREFIX, STRICT_TOOL_SCHEMA_PROFILE, SameToolInputLoopError, SilentLogger, StorageError, StructuredEventService, StructuredOutputError, TASK_EVENTS, TASK_EVENT_PREFIX, type TActionResponse, type TArgumentKind, type TBackgroundPermissionPolicy, TComplexConfigValue, TConfigData, TConfigValue, TContextData, type TConversationContextMetadata, type TEmbeddedResourceMessagePart, type TEnvResolver, TErrorContextData, TErrorExternalInput, type TEventEmitterListener, type TEventExtensionValue, type TEventListener, type TEventLoggerData, type TEventName, type TEventUniversalValue, type TExecutionEventCallback, type TExecutionEventData, type TExecutionEventName, type TExecutionJournalRecord, type TExecutionRecoveryErrorCode, type TExecutorStreamEvent, type TGuardrail, type THookDefinition, type THookEvent, type THookOutcome, type THooksConfig, type TImageInputSource, type TJSONSchemaEnum, type TJSONSchemaKind, type TJournalModelOptions, TLoggerData, type TManagerToolParameters, type TMatchDirection, TMessageConverterRegistry, TMessageFormatConverter, type TMessageState, TMetadata, TMetadataValue, type TModelEffort, type TModelEffortDisposition, type TModelEffortNativeControl, type TModelEffortOutcomeCallback, type TModelEffortProviderDispatch, type TModelEffortSelection, type TModelFallbackCallback, TOOL_BODY_EVENTS, TOOL_EVENTS, TOOL_EVENT_PREFIX, TOOL_PERMISSION_EVENTS, TOOL_QUEUE_EVENTS, TOOL_SCHEMA_PROJECTION_MAX_DEPTH, TOOL_SCHEMA_PROJECTION_MAX_NODES, TOOL_SEARCH_TOOL_NAME, type TOrchestrationEvent, type TOrchestrationPrimitive, type TOutputRetention, type TParameterDefaultValue, type TPermissionDecision, type TPermissionMode, type TPrimitiveValue, type TProviderConfigValue, type TProviderCredentialField, type TProviderFailureReason, TProviderLoggingData, type TProviderMediaResult, TProviderMessage, type TProviderModelCapability, type TProviderModelCatalogStatus, type TProviderModelLifecycle, type TProviderNativeRawPayload, type TProviderNativeRawPayloadCallback, type TProviderNativeRawPayloadKind, type TProviderOptionValueBase, type TProviderSetupField, type TProviderSetupHelpLinkKind, type TProviderUsageProvenance, TRUST_TO_MODE, type TResolveInWorkspace, type TResponseMetadata, type TRoleModelMap, type TSessionEndReason, TShellKind, type TSpanEvent, type TStructuredOutputMechanism, type TStructuredOutputProvenance, type TStructuredOutputSchema, type TStructuredOutputValidation, type TSubprocessTraceClass, type TTextDeltaCallback, type TTimerId, type TToolArgs, type TToolChoice, type TToolEffectAdmission, type TToolExecutionFunction, type TToolExecutionParameters, type TToolExecutor, type TToolMetadata, TToolParameters, type TToolProgressCallback, type TToolResultAdmissionErrorCode, type TToolRiskClass, type TToolSchemaProjectionOutcome, type TToolSchemaProjectionProfileBase, type TToolSearchMode, type TToolSearchSetting, type TTrustLevel, type TUniversalArrayValue, type TUniversalMessage, type TUniversalMessageMetadata, type TUniversalMessagePart, type TUniversalMessageRole, type TUniversalValue, type TUserEvent, TUtilLogLevel, ToolExecutionError, ToolRegistry, ToolResultAdmissionError, TypeUtils, UNCLASSIFIED_TOOL_FALLBACK, USER_EVENTS, USER_EVENT_PREFIX, UnsupportedShellError, ValidationError, Validator, admitToolResult, allowRulesForAutoMode, applyPresetToolLists, assertProviderNativeWebToolsAvailable, assertResidentToolRemains, bindEventServiceOwner, bindWithOwnerPath, buildTraceparent, calculateModelCost, callJournaledProvider, chatEntryToMessage, classifyProviderFailure, clearRegisteredToolProfiles, closeObjectSchemas, collectAssistantUsageMetadata, composeEventName, confirmAction, createAssistantMessage, createBoundedOutput, createDefaultProviderCapabilities, createExecutionProxy, createImageProviderFromDefinition, createLogger, createModelEffortOutcome, createProviderFromConfig, createRecordEnvResolver, createSystemMessage, createToolMessage, createUserMessage, createVideoProviderFromDefinition, decodeHookVerdict, estimateBlendedCostPer1000, estimateContextTokensFromMessages, estimateSerializedContextTokens, estimateToolSchemaTokens, evaluatePermission, extractEnumValues, findInvalidPermissionPatterns, findMediaProviderDefinition, findModelDefinition, findPermissionPatternWarnings, findProviderDefinition, formatEnvReference, formatSupportedProviderTypes, formatTokenCount, generateSpanId, getGlobalLogLevel, getGlobalLoggerSink, getMessagesForAPI, getModelContextWindow, getModelMaxOutput, getModelName, getProviderCapabilities, getProviderCredentialRequirement, getSchemaTypeName, getToolEstimatedDuration, getToolExecutionSteps, getToolPermissionProfile, hasUsableSecretReference, hasValidationConstraints, hashToolSchema, isAbortFailure, isAssistantMessage, isBroadExecutionAllowRule, isChatEntry, isConfirmed, isDefaultEventService, isEnforcing, isEnvReference, isExecutionControlError, isImageGenerationProvider, isMediaProviderDefinition, isMintedSpanId, isModelEffort, isProgressReportingTool, isProtectedPath, isReadOnlyCommandLine, isRegistryTransactionError, isSystemMessage, isToolDeniedOutright, isToolMessage, isUserMessage, isVideoGenerationProvider, lifecycleOf, logger, lookupModelPrice, matchesAnyPattern, messageToHistoryEntry, modelDeclaresCapability, multiSelectAction, nonVisualObservationText, normalizeProviderConfig, normalizeStructuredOutput, outboundTraceContextFor, parseParameterRule, parseStructuredResponseText, peerDriverOf, printablePeerDriver, processEnvResolver, projectPermissionPolicy, projectToolSchema, providerCallSpanId, readModelFallbackNotice, readProviderFailureDetails, readTokenUsageFromMessage, readTokenUsageFromMetadata, registerModelMetadata, registerToolPermissionProfile, removesCriticalPath, requiresFreshApproval, resolveEnvReference, resolveMediaProviderConfig, resolveModelCapabilities, resolveModelCapability, resolveModelEffort, resolvePlatformShell, resolveStructuredOutputCapability, runHooks, runRegistryTransaction, scrubSecrets, selectAction, setGlobalLogLevel, setGlobalLoggerSink, setToolProgressCallback, shellArgumentForDisplay, snapshotToolProvenance, spanIdFromMintedId, splitCommandSegments, startPeriodicTask, stopPeriodicTask, subprocessTraceEnvironment, sumHistoryUsage, sumMessagesUsage, textAction, toProviderError, toolNameMatches, toolNamesToPatterns, toolTraceContextFor, traceEnvFor, traceHeadersFor, validateAgainstJsonSchema, validateAgentConfig, validateApiKey, validateModelName, validatePermissionPattern, validateProviderName, validateUserInput, verifiedProviderCallUsage, wasToolResultAdmitted, withEventEmission, withToolProvenance, zodToJsonSchema };
7632
7724
  //# sourceMappingURL=index.d.ts.map