@copilotkit/shared 1.73.0 → 1.73.2-canary.1790068297

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 (74) hide show
  1. package/README.md +22 -0
  2. package/dist/attachments/content.cjs +17 -0
  3. package/dist/attachments/content.cjs.map +1 -0
  4. package/dist/attachments/content.d.cts +9 -0
  5. package/dist/attachments/content.d.cts.map +1 -0
  6. package/dist/attachments/content.d.mts +9 -0
  7. package/dist/attachments/content.d.mts.map +1 -0
  8. package/dist/attachments/content.mjs +16 -0
  9. package/dist/attachments/content.mjs.map +1 -0
  10. package/dist/event-transforms/index.cjs +15 -0
  11. package/dist/event-transforms/index.d.cts +4 -0
  12. package/dist/event-transforms/index.d.mts +4 -0
  13. package/dist/event-transforms/index.mjs +5 -0
  14. package/dist/event-transforms/open-generative-ui-middleware.cjs +286 -0
  15. package/dist/event-transforms/open-generative-ui-middleware.cjs.map +1 -0
  16. package/dist/event-transforms/open-generative-ui-middleware.d.cts +60 -0
  17. package/dist/event-transforms/open-generative-ui-middleware.d.cts.map +1 -0
  18. package/dist/event-transforms/open-generative-ui-middleware.d.mts +60 -0
  19. package/dist/event-transforms/open-generative-ui-middleware.d.mts.map +1 -0
  20. package/dist/event-transforms/open-generative-ui-middleware.mjs +283 -0
  21. package/dist/event-transforms/open-generative-ui-middleware.mjs.map +1 -0
  22. package/dist/event-transforms/recorded-events.cjs +59 -0
  23. package/dist/event-transforms/recorded-events.cjs.map +1 -0
  24. package/dist/event-transforms/recorded-events.d.cts +23 -0
  25. package/dist/event-transforms/recorded-events.d.cts.map +1 -0
  26. package/dist/event-transforms/recorded-events.d.mts +23 -0
  27. package/dist/event-transforms/recorded-events.d.mts.map +1 -0
  28. package/dist/event-transforms/recorded-events.mjs +58 -0
  29. package/dist/event-transforms/recorded-events.mjs.map +1 -0
  30. package/dist/index.cjs +8 -0
  31. package/dist/index.cjs.map +1 -1
  32. package/dist/index.d.cts +3 -1
  33. package/dist/index.d.cts.map +1 -1
  34. package/dist/index.d.mts +3 -1
  35. package/dist/index.d.mts.map +1 -1
  36. package/dist/index.mjs +3 -1
  37. package/dist/index.mjs.map +1 -1
  38. package/dist/index.umd.js +224 -1
  39. package/dist/index.umd.js.map +1 -1
  40. package/dist/package.cjs +1 -1
  41. package/dist/package.mjs +1 -1
  42. package/dist/types/message.d.cts +3 -3
  43. package/dist/types/message.d.cts.map +1 -1
  44. package/dist/types/message.d.mts +3 -3
  45. package/dist/types/message.d.mts.map +1 -1
  46. package/dist/utils/index.cjs +1 -0
  47. package/dist/utils/index.cjs.map +1 -1
  48. package/dist/utils/index.d.cts +1 -0
  49. package/dist/utils/index.d.cts.map +1 -1
  50. package/dist/utils/index.d.mts +1 -0
  51. package/dist/utils/index.d.mts.map +1 -1
  52. package/dist/utils/index.mjs +1 -0
  53. package/dist/utils/index.mjs.map +1 -1
  54. package/dist/utils/row-render-keys.cjs +206 -0
  55. package/dist/utils/row-render-keys.cjs.map +1 -0
  56. package/dist/utils/row-render-keys.d.cts +65 -0
  57. package/dist/utils/row-render-keys.d.cts.map +1 -0
  58. package/dist/utils/row-render-keys.d.mts +65 -0
  59. package/dist/utils/row-render-keys.d.mts.map +1 -0
  60. package/dist/utils/row-render-keys.mjs +201 -0
  61. package/dist/utils/row-render-keys.mjs.map +1 -0
  62. package/package.json +12 -1
  63. package/src/__tests__/root-entry-browser-safety.test.ts +7 -1
  64. package/src/attachments/content.test.ts +48 -0
  65. package/src/attachments/content.ts +16 -0
  66. package/src/attachments/index.ts +2 -0
  67. package/src/event-transforms/index.ts +5 -0
  68. package/src/event-transforms/open-generative-ui-middleware.ts +392 -0
  69. package/src/event-transforms/recorded-events.test.ts +166 -0
  70. package/src/event-transforms/recorded-events.ts +74 -0
  71. package/src/utils/__tests__/row-render-keys.test.ts +388 -0
  72. package/src/utils/index.ts +1 -0
  73. package/src/utils/row-render-keys.ts +263 -0
  74. package/tsdown.config.ts +7 -4
package/dist/index.d.cts CHANGED
@@ -15,6 +15,7 @@ import { InspectorVisibilityOptions, shouldEnableInspector } from "./utils/inspe
15
15
  import { A2UIRuntimeInfo, AgentDescription, IntelligenceRuntimeInfo, MaybePromise, NonEmptyRecord, RUNTIME_MODE_INTELLIGENCE, RUNTIME_MODE_SSE, RuntimeEntitlementResponse, RuntimeInfo, RuntimeLicenseStatus, RuntimeMode, SingleRouteRuntimeInfo, ThreadEndpointRuntimeInfo } from "./utils/types.cjs";
16
16
  import { dataToUUID, isValidUUID, randomId, randomUUID } from "./utils/random-id.cjs";
17
17
  import { readBody } from "./utils/requests.cjs";
18
+ import { RowKeyStore, commitRowKeyStore, createRowKeyStore, pruneRowKeyStore, resolveRowRenderKeys, resolveRowRenderKeysById } from "./utils/row-render-keys.cjs";
18
19
  import { isMacOS, parseJson, partialJSONParse, phoenixExponentialBackoff, safeParseToolArgs, tryMap } from "./utils/index.cjs";
19
20
  import { AG_UI_CHANNEL_EVENT, COPILOT_CLOUD_API_URL, COPILOT_CLOUD_CHAT_URL, COPILOT_CLOUD_PUBLIC_API_KEY_HEADER, COPILOT_CLOUD_VERSION, DEFAULT_AGENT_ID } from "./constants/index.cjs";
20
21
  import { isTelemetryDisabled } from "./telemetry/telemetry-disabled.cjs";
@@ -25,6 +26,7 @@ import { TelemetryCapture, TelemetryIdentity } from "./telemetry/telemetry-clien
25
26
  import { DebugConfig, ResolvedDebugConfig, resolveDebugConfig } from "./debug.cjs";
26
27
  import { InferSchemaOutput, SchemaToJsonSchemaOptions, StandardJSONSchemaV1, StandardSchemaV1, schemaToJsonSchema } from "./standard-schema.cjs";
27
28
  import { Attachment, AttachmentModality, AttachmentUploadError, AttachmentUploadErrorReason, AttachmentUploadResult, AttachmentsConfig } from "./attachments/types.cjs";
29
+ import { createAttachmentContent } from "./attachments/content.cjs";
28
30
  import { exceedsMaxSize, formatFileSize, generateVideoThumbnail, getDocumentIcon, getModalityFromMimeType, getSourceUrl, matchesAcceptFilter, readFileAsBase64 } from "./attachments/utils.cjs";
29
31
  import { logger } from "./logger.cjs";
30
32
  import { FinalizeRunOptions, RunEventFinalizer, createRunEventFinalizer, finalizeRunEvents } from "./finalize-events.cjs";
@@ -65,5 +67,5 @@ interface LicenseContextValue {
65
67
  */
66
68
  declare function createLicenseContextValue(status: RuntimeLicenseStatus | null | undefined, runtimeEntitlements?: RuntimeEntitlementResponse): LicenseContextValue;
67
69
  //#endregion
68
- export { A2UIRuntimeInfo, A2UI_DEFAULT_DESIGN_GUIDELINES, A2UI_DEFAULT_GENERATION_GUIDELINES, AG_UI_CHANNEL_EVENT, AIMessage, Action, ActivityMessage, AgentDescription, AssistantMessage, Attachment, AttachmentModality, AttachmentUploadError, AttachmentUploadErrorReason, AttachmentUploadResult, AttachmentsConfig, AudioInputPart, BANNER_ERROR_NAMES, BaseCondition, COPILOTKIT_VERSION, COPILOT_CLOUD_API_URL, COPILOT_CLOUD_CHAT_URL, COPILOT_CLOUD_ERROR_NAMES, COPILOT_CLOUD_PUBLIC_API_KEY_HEADER, COPILOT_CLOUD_VERSION, CoAgentStateRenderHandler, CoAgentStateRenderHandlerArguments, ComparisonCondition, ComparisonRule, Condition, ConfigurationError, ConsoleColors, ConsoleStyles, CopilotCloudConfig, CopilotErrorEvent, CopilotErrorHandler, CopilotKitAgentDiscoveryError, CopilotKitApiDiscoveryError, CopilotKitError, CopilotKitErrorCode, CopilotKitLowLevelError, CopilotKitMisuseError, CopilotKitRemoteEndpointDiscoveryError, CopilotKitVersionMismatchError, CopilotRequestContext, DEFAULT_AGENT_ID, DebugConfig, type DebugEventEnvelope, DeveloperMessage, DocumentInputPart, ERROR_CONFIG, ERROR_NAMES, ErrorVisibility, ExistenceCondition, ExistenceRule, type FinalizeRunOptions, FunctionCallHandler, FunctionCallHandlerArguments, FunctionDefinition, ImageData, ImageInputPart, InferSchemaOutput, InputContent, InputContentDataSource, InputContentSource, InputContentUrlSource, InspectorLearningEvidence, InspectorLearningInsight, InspectorLearningPage, InspectorLearningRequestV1, InspectorLearningSkill, InspectorLearningSnapshotV1, InspectorMetadataV1, InspectorVisibilityOptions, IntelligenceRuntimeInfo, JSONSchema, JSONSchemaArray, JSONSchemaBoolean, JSONSchemaNumber, JSONSchemaObject, JSONSchemaString, JSONValue, type LambdaSendOptions, type LicenseChecker, LicenseContextValue, type LicenseFeatures, type LicenseOwner, type LicensePayload, type LicenseStatus, type LicenseTier, LogicalCondition, LogicalRule, MODEL_HOST_CLASSES, MappedParameterTypes, MaybePromise, Message, MissingPublicApiKeyError, ModelHostClass, NonEmptyRecord, Parameter, PartialBy, RUNTIME_MODE_INTELLIGENCE, RUNTIME_MODE_SSE, ReasoningMessage, RequiredBy, ResolvedCopilotKitError, ResolvedDebugConfig, Role, Rule, type RunEventFinalizer, RuntimeEntitlementResponse, RuntimeInfo, RuntimeLicenseStatus, RuntimeMode, SamplingMeta, SchemaToJsonSchemaOptions, Severity, SingleRouteRuntimeInfo, StandardJSONSchemaV1, StandardSchemaV1, SystemMessage, TELEMETRY_EMITTER_V1, TELEMETRY_EMITTER_V2, TELEMETRY_SURFACE_V1, TELEMETRY_SURFACE_V2, type TelemetryCapture, TelemetryEmitter, type TelemetryIdentity, TelemetrySurface, TelemetryTransport, TextInputPart, ThreadEndpointRuntimeInfo, ToolCall, ToolDefinition, ToolResult, TranscriptionErrorCode, type TranscriptionErrorResponse, TranscriptionErrors, UNSAMPLED_RATE, UpgradeRequiredError, UserMessage, VideoInputPart, actionParametersToJsonSchema, classifyModelHost, computeSamplingMeta, convertJsonSchemaToZodSchema, copyToClipboard, createLicenseContextValue, createRunEventFinalizer, dataToUUID, ensureStructuredError, exceedsMaxSize, executeConditions, finalizeRunEvents, firstNonBlankTelemetryId, formatFileSize, generateVideoThumbnail, getDocumentIcon, getModalityFromMimeType, getPossibleVersionMismatch, getSourceUrl, getZodParameters, isMacOS, isStructuredCopilotKitError, isTelemetryDisabled, isValidUUID, jsonSchemaToActionParameters, lambdaClient, logCopilotKitPlatformMessage, logStyled, logger, matchesAcceptFilter, parseAndWarnTelemetryId, parseInspectorLearningRequestV1, parseInspectorLearningSnapshotV1, parseInspectorLearningUrl, parseInspectorMetadataV1, parseJson, parseTelemetryIdFromLicense, partialJSONParse, phoenixExponentialBackoff, publicApiKeyRequired, randomId, randomUUID, readBody, readFileAsBase64, resolveDebugConfig, safeParseToolArgs, schemaToJsonSchema, shouldEnableInspector, styledConsole, tryMap };
70
+ export { A2UIRuntimeInfo, A2UI_DEFAULT_DESIGN_GUIDELINES, A2UI_DEFAULT_GENERATION_GUIDELINES, AG_UI_CHANNEL_EVENT, AIMessage, Action, ActivityMessage, AgentDescription, AssistantMessage, Attachment, AttachmentModality, AttachmentUploadError, AttachmentUploadErrorReason, AttachmentUploadResult, AttachmentsConfig, AudioInputPart, BANNER_ERROR_NAMES, BaseCondition, COPILOTKIT_VERSION, COPILOT_CLOUD_API_URL, COPILOT_CLOUD_CHAT_URL, COPILOT_CLOUD_ERROR_NAMES, COPILOT_CLOUD_PUBLIC_API_KEY_HEADER, COPILOT_CLOUD_VERSION, CoAgentStateRenderHandler, CoAgentStateRenderHandlerArguments, ComparisonCondition, ComparisonRule, Condition, ConfigurationError, ConsoleColors, ConsoleStyles, CopilotCloudConfig, CopilotErrorEvent, CopilotErrorHandler, CopilotKitAgentDiscoveryError, CopilotKitApiDiscoveryError, CopilotKitError, CopilotKitErrorCode, CopilotKitLowLevelError, CopilotKitMisuseError, CopilotKitRemoteEndpointDiscoveryError, CopilotKitVersionMismatchError, CopilotRequestContext, DEFAULT_AGENT_ID, DebugConfig, type DebugEventEnvelope, DeveloperMessage, DocumentInputPart, ERROR_CONFIG, ERROR_NAMES, ErrorVisibility, ExistenceCondition, ExistenceRule, type FinalizeRunOptions, FunctionCallHandler, FunctionCallHandlerArguments, FunctionDefinition, ImageData, ImageInputPart, InferSchemaOutput, InputContent, InputContentDataSource, InputContentSource, InputContentUrlSource, InspectorLearningEvidence, InspectorLearningInsight, InspectorLearningPage, InspectorLearningRequestV1, InspectorLearningSkill, InspectorLearningSnapshotV1, InspectorMetadataV1, InspectorVisibilityOptions, IntelligenceRuntimeInfo, JSONSchema, JSONSchemaArray, JSONSchemaBoolean, JSONSchemaNumber, JSONSchemaObject, JSONSchemaString, JSONValue, type LambdaSendOptions, type LicenseChecker, LicenseContextValue, type LicenseFeatures, type LicenseOwner, type LicensePayload, type LicenseStatus, type LicenseTier, LogicalCondition, LogicalRule, MODEL_HOST_CLASSES, MappedParameterTypes, MaybePromise, Message, MissingPublicApiKeyError, ModelHostClass, NonEmptyRecord, Parameter, PartialBy, RUNTIME_MODE_INTELLIGENCE, RUNTIME_MODE_SSE, ReasoningMessage, RequiredBy, ResolvedCopilotKitError, ResolvedDebugConfig, Role, RowKeyStore, Rule, type RunEventFinalizer, RuntimeEntitlementResponse, RuntimeInfo, RuntimeLicenseStatus, RuntimeMode, SamplingMeta, SchemaToJsonSchemaOptions, Severity, SingleRouteRuntimeInfo, StandardJSONSchemaV1, StandardSchemaV1, SystemMessage, TELEMETRY_EMITTER_V1, TELEMETRY_EMITTER_V2, TELEMETRY_SURFACE_V1, TELEMETRY_SURFACE_V2, type TelemetryCapture, TelemetryEmitter, type TelemetryIdentity, TelemetrySurface, TelemetryTransport, TextInputPart, ThreadEndpointRuntimeInfo, ToolCall, ToolDefinition, ToolResult, TranscriptionErrorCode, type TranscriptionErrorResponse, TranscriptionErrors, UNSAMPLED_RATE, UpgradeRequiredError, UserMessage, VideoInputPart, actionParametersToJsonSchema, classifyModelHost, commitRowKeyStore, computeSamplingMeta, convertJsonSchemaToZodSchema, copyToClipboard, createAttachmentContent, createLicenseContextValue, createRowKeyStore, createRunEventFinalizer, dataToUUID, ensureStructuredError, exceedsMaxSize, executeConditions, finalizeRunEvents, firstNonBlankTelemetryId, formatFileSize, generateVideoThumbnail, getDocumentIcon, getModalityFromMimeType, getPossibleVersionMismatch, getSourceUrl, getZodParameters, isMacOS, isStructuredCopilotKitError, isTelemetryDisabled, isValidUUID, jsonSchemaToActionParameters, lambdaClient, logCopilotKitPlatformMessage, logStyled, logger, matchesAcceptFilter, parseAndWarnTelemetryId, parseInspectorLearningRequestV1, parseInspectorLearningSnapshotV1, parseInspectorLearningUrl, parseInspectorMetadataV1, parseJson, parseTelemetryIdFromLicense, partialJSONParse, phoenixExponentialBackoff, pruneRowKeyStore, publicApiKeyRequired, randomId, randomUUID, readBody, readFileAsBase64, resolveDebugConfig, resolveRowRenderKeys, resolveRowRenderKeysById, safeParseToolArgs, schemaToJsonSchema, shouldEnableInspector, styledConsole, tryMap };
69
71
  //# sourceMappingURL=index.d.cts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.cts","names":[],"sources":["../src/index.ts"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;cAkDa,kBAAA;;;;;UA8BI,mBAAA;;EAEf,MAAA,EAAQ,oBAAA;;EAER,OAAA,EAAS,gBAAA;;EAET,YAAA,GAAe,OAAA;;EAEf,QAAA,GAAW,OAAA;AAAA;;;;AAtCb;;;;;AA8BA;;;;;;iBAwCgB,yBAAA,CACd,MAAA,EAAQ,oBAAA,qBACR,mBAAA,GAAsB,0BAAA,GACrB,mBAAA"}
1
+ {"version":3,"file":"index.d.cts","names":[],"sources":["../src/index.ts"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;cAkDa,kBAAA;;;;;UA8BI,mBAAA;;EAEf,MAAA,EAAQ,oBAAA;;EAER,OAAA,EAAS,gBAAA;;EAET,YAAA,GAAe,OAAA;;EAEf,QAAA,GAAW,OAAA;AAAA;;;;;;AAtCb;;;;;AA8BA;;;;iBAwCgB,yBAAA,CACd,MAAA,EAAQ,oBAAA,qBACR,mBAAA,GAAsB,0BAAA,GACrB,mBAAA"}
package/dist/index.d.mts CHANGED
@@ -15,6 +15,7 @@ import { InspectorVisibilityOptions, shouldEnableInspector } from "./utils/inspe
15
15
  import { A2UIRuntimeInfo, AgentDescription, IntelligenceRuntimeInfo, MaybePromise, NonEmptyRecord, RUNTIME_MODE_INTELLIGENCE, RUNTIME_MODE_SSE, RuntimeEntitlementResponse, RuntimeInfo, RuntimeLicenseStatus, RuntimeMode, SingleRouteRuntimeInfo, ThreadEndpointRuntimeInfo } from "./utils/types.mjs";
16
16
  import { dataToUUID, isValidUUID, randomId, randomUUID } from "./utils/random-id.mjs";
17
17
  import { readBody } from "./utils/requests.mjs";
18
+ import { RowKeyStore, commitRowKeyStore, createRowKeyStore, pruneRowKeyStore, resolveRowRenderKeys, resolveRowRenderKeysById } from "./utils/row-render-keys.mjs";
18
19
  import { isMacOS, parseJson, partialJSONParse, phoenixExponentialBackoff, safeParseToolArgs, tryMap } from "./utils/index.mjs";
19
20
  import { AG_UI_CHANNEL_EVENT, COPILOT_CLOUD_API_URL, COPILOT_CLOUD_CHAT_URL, COPILOT_CLOUD_PUBLIC_API_KEY_HEADER, COPILOT_CLOUD_VERSION, DEFAULT_AGENT_ID } from "./constants/index.mjs";
20
21
  import { isTelemetryDisabled } from "./telemetry/telemetry-disabled.mjs";
@@ -25,6 +26,7 @@ import { TelemetryCapture, TelemetryIdentity } from "./telemetry/telemetry-clien
25
26
  import { DebugConfig, ResolvedDebugConfig, resolveDebugConfig } from "./debug.mjs";
26
27
  import { InferSchemaOutput, SchemaToJsonSchemaOptions, StandardJSONSchemaV1, StandardSchemaV1, schemaToJsonSchema } from "./standard-schema.mjs";
27
28
  import { Attachment, AttachmentModality, AttachmentUploadError, AttachmentUploadErrorReason, AttachmentUploadResult, AttachmentsConfig } from "./attachments/types.mjs";
29
+ import { createAttachmentContent } from "./attachments/content.mjs";
28
30
  import { exceedsMaxSize, formatFileSize, generateVideoThumbnail, getDocumentIcon, getModalityFromMimeType, getSourceUrl, matchesAcceptFilter, readFileAsBase64 } from "./attachments/utils.mjs";
29
31
  import { logger } from "./logger.mjs";
30
32
  import { FinalizeRunOptions, RunEventFinalizer, createRunEventFinalizer, finalizeRunEvents } from "./finalize-events.mjs";
@@ -65,5 +67,5 @@ interface LicenseContextValue {
65
67
  */
66
68
  declare function createLicenseContextValue(status: RuntimeLicenseStatus | null | undefined, runtimeEntitlements?: RuntimeEntitlementResponse): LicenseContextValue;
67
69
  //#endregion
68
- export { A2UIRuntimeInfo, A2UI_DEFAULT_DESIGN_GUIDELINES, A2UI_DEFAULT_GENERATION_GUIDELINES, AG_UI_CHANNEL_EVENT, AIMessage, Action, ActivityMessage, AgentDescription, AssistantMessage, Attachment, AttachmentModality, AttachmentUploadError, AttachmentUploadErrorReason, AttachmentUploadResult, AttachmentsConfig, AudioInputPart, BANNER_ERROR_NAMES, BaseCondition, COPILOTKIT_VERSION, COPILOT_CLOUD_API_URL, COPILOT_CLOUD_CHAT_URL, COPILOT_CLOUD_ERROR_NAMES, COPILOT_CLOUD_PUBLIC_API_KEY_HEADER, COPILOT_CLOUD_VERSION, CoAgentStateRenderHandler, CoAgentStateRenderHandlerArguments, ComparisonCondition, ComparisonRule, Condition, ConfigurationError, ConsoleColors, ConsoleStyles, CopilotCloudConfig, CopilotErrorEvent, CopilotErrorHandler, CopilotKitAgentDiscoveryError, CopilotKitApiDiscoveryError, CopilotKitError, CopilotKitErrorCode, CopilotKitLowLevelError, CopilotKitMisuseError, CopilotKitRemoteEndpointDiscoveryError, CopilotKitVersionMismatchError, CopilotRequestContext, DEFAULT_AGENT_ID, DebugConfig, type DebugEventEnvelope, DeveloperMessage, DocumentInputPart, ERROR_CONFIG, ERROR_NAMES, ErrorVisibility, ExistenceCondition, ExistenceRule, type FinalizeRunOptions, FunctionCallHandler, FunctionCallHandlerArguments, FunctionDefinition, ImageData, ImageInputPart, InferSchemaOutput, InputContent, InputContentDataSource, InputContentSource, InputContentUrlSource, InspectorLearningEvidence, InspectorLearningInsight, InspectorLearningPage, InspectorLearningRequestV1, InspectorLearningSkill, InspectorLearningSnapshotV1, InspectorMetadataV1, InspectorVisibilityOptions, IntelligenceRuntimeInfo, JSONSchema, JSONSchemaArray, JSONSchemaBoolean, JSONSchemaNumber, JSONSchemaObject, JSONSchemaString, JSONValue, type LambdaSendOptions, type LicenseChecker, LicenseContextValue, type LicenseFeatures, type LicenseOwner, type LicensePayload, type LicenseStatus, type LicenseTier, LogicalCondition, LogicalRule, MODEL_HOST_CLASSES, MappedParameterTypes, MaybePromise, Message, MissingPublicApiKeyError, ModelHostClass, NonEmptyRecord, Parameter, PartialBy, RUNTIME_MODE_INTELLIGENCE, RUNTIME_MODE_SSE, ReasoningMessage, RequiredBy, ResolvedCopilotKitError, ResolvedDebugConfig, Role, Rule, type RunEventFinalizer, RuntimeEntitlementResponse, RuntimeInfo, RuntimeLicenseStatus, RuntimeMode, SamplingMeta, SchemaToJsonSchemaOptions, Severity, SingleRouteRuntimeInfo, StandardJSONSchemaV1, StandardSchemaV1, SystemMessage, TELEMETRY_EMITTER_V1, TELEMETRY_EMITTER_V2, TELEMETRY_SURFACE_V1, TELEMETRY_SURFACE_V2, type TelemetryCapture, TelemetryEmitter, type TelemetryIdentity, TelemetrySurface, TelemetryTransport, TextInputPart, ThreadEndpointRuntimeInfo, ToolCall, ToolDefinition, ToolResult, TranscriptionErrorCode, type TranscriptionErrorResponse, TranscriptionErrors, UNSAMPLED_RATE, UpgradeRequiredError, UserMessage, VideoInputPart, actionParametersToJsonSchema, classifyModelHost, computeSamplingMeta, convertJsonSchemaToZodSchema, copyToClipboard, createLicenseContextValue, createRunEventFinalizer, dataToUUID, ensureStructuredError, exceedsMaxSize, executeConditions, finalizeRunEvents, firstNonBlankTelemetryId, formatFileSize, generateVideoThumbnail, getDocumentIcon, getModalityFromMimeType, getPossibleVersionMismatch, getSourceUrl, getZodParameters, isMacOS, isStructuredCopilotKitError, isTelemetryDisabled, isValidUUID, jsonSchemaToActionParameters, lambdaClient, logCopilotKitPlatformMessage, logStyled, logger, matchesAcceptFilter, parseAndWarnTelemetryId, parseInspectorLearningRequestV1, parseInspectorLearningSnapshotV1, parseInspectorLearningUrl, parseInspectorMetadataV1, parseJson, parseTelemetryIdFromLicense, partialJSONParse, phoenixExponentialBackoff, publicApiKeyRequired, randomId, randomUUID, readBody, readFileAsBase64, resolveDebugConfig, safeParseToolArgs, schemaToJsonSchema, shouldEnableInspector, styledConsole, tryMap };
70
+ export { A2UIRuntimeInfo, A2UI_DEFAULT_DESIGN_GUIDELINES, A2UI_DEFAULT_GENERATION_GUIDELINES, AG_UI_CHANNEL_EVENT, AIMessage, Action, ActivityMessage, AgentDescription, AssistantMessage, Attachment, AttachmentModality, AttachmentUploadError, AttachmentUploadErrorReason, AttachmentUploadResult, AttachmentsConfig, AudioInputPart, BANNER_ERROR_NAMES, BaseCondition, COPILOTKIT_VERSION, COPILOT_CLOUD_API_URL, COPILOT_CLOUD_CHAT_URL, COPILOT_CLOUD_ERROR_NAMES, COPILOT_CLOUD_PUBLIC_API_KEY_HEADER, COPILOT_CLOUD_VERSION, CoAgentStateRenderHandler, CoAgentStateRenderHandlerArguments, ComparisonCondition, ComparisonRule, Condition, ConfigurationError, ConsoleColors, ConsoleStyles, CopilotCloudConfig, CopilotErrorEvent, CopilotErrorHandler, CopilotKitAgentDiscoveryError, CopilotKitApiDiscoveryError, CopilotKitError, CopilotKitErrorCode, CopilotKitLowLevelError, CopilotKitMisuseError, CopilotKitRemoteEndpointDiscoveryError, CopilotKitVersionMismatchError, CopilotRequestContext, DEFAULT_AGENT_ID, DebugConfig, type DebugEventEnvelope, DeveloperMessage, DocumentInputPart, ERROR_CONFIG, ERROR_NAMES, ErrorVisibility, ExistenceCondition, ExistenceRule, type FinalizeRunOptions, FunctionCallHandler, FunctionCallHandlerArguments, FunctionDefinition, ImageData, ImageInputPart, InferSchemaOutput, InputContent, InputContentDataSource, InputContentSource, InputContentUrlSource, InspectorLearningEvidence, InspectorLearningInsight, InspectorLearningPage, InspectorLearningRequestV1, InspectorLearningSkill, InspectorLearningSnapshotV1, InspectorMetadataV1, InspectorVisibilityOptions, IntelligenceRuntimeInfo, JSONSchema, JSONSchemaArray, JSONSchemaBoolean, JSONSchemaNumber, JSONSchemaObject, JSONSchemaString, JSONValue, type LambdaSendOptions, type LicenseChecker, LicenseContextValue, type LicenseFeatures, type LicenseOwner, type LicensePayload, type LicenseStatus, type LicenseTier, LogicalCondition, LogicalRule, MODEL_HOST_CLASSES, MappedParameterTypes, MaybePromise, Message, MissingPublicApiKeyError, ModelHostClass, NonEmptyRecord, Parameter, PartialBy, RUNTIME_MODE_INTELLIGENCE, RUNTIME_MODE_SSE, ReasoningMessage, RequiredBy, ResolvedCopilotKitError, ResolvedDebugConfig, Role, RowKeyStore, Rule, type RunEventFinalizer, RuntimeEntitlementResponse, RuntimeInfo, RuntimeLicenseStatus, RuntimeMode, SamplingMeta, SchemaToJsonSchemaOptions, Severity, SingleRouteRuntimeInfo, StandardJSONSchemaV1, StandardSchemaV1, SystemMessage, TELEMETRY_EMITTER_V1, TELEMETRY_EMITTER_V2, TELEMETRY_SURFACE_V1, TELEMETRY_SURFACE_V2, type TelemetryCapture, TelemetryEmitter, type TelemetryIdentity, TelemetrySurface, TelemetryTransport, TextInputPart, ThreadEndpointRuntimeInfo, ToolCall, ToolDefinition, ToolResult, TranscriptionErrorCode, type TranscriptionErrorResponse, TranscriptionErrors, UNSAMPLED_RATE, UpgradeRequiredError, UserMessage, VideoInputPart, actionParametersToJsonSchema, classifyModelHost, commitRowKeyStore, computeSamplingMeta, convertJsonSchemaToZodSchema, copyToClipboard, createAttachmentContent, createLicenseContextValue, createRowKeyStore, createRunEventFinalizer, dataToUUID, ensureStructuredError, exceedsMaxSize, executeConditions, finalizeRunEvents, firstNonBlankTelemetryId, formatFileSize, generateVideoThumbnail, getDocumentIcon, getModalityFromMimeType, getPossibleVersionMismatch, getSourceUrl, getZodParameters, isMacOS, isStructuredCopilotKitError, isTelemetryDisabled, isValidUUID, jsonSchemaToActionParameters, lambdaClient, logCopilotKitPlatformMessage, logStyled, logger, matchesAcceptFilter, parseAndWarnTelemetryId, parseInspectorLearningRequestV1, parseInspectorLearningSnapshotV1, parseInspectorLearningUrl, parseInspectorMetadataV1, parseJson, parseTelemetryIdFromLicense, partialJSONParse, phoenixExponentialBackoff, pruneRowKeyStore, publicApiKeyRequired, randomId, randomUUID, readBody, readFileAsBase64, resolveDebugConfig, resolveRowRenderKeys, resolveRowRenderKeysById, safeParseToolArgs, schemaToJsonSchema, shouldEnableInspector, styledConsole, tryMap };
69
71
  //# sourceMappingURL=index.d.mts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.mts","names":[],"sources":["../src/index.ts"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;cAkDa,kBAAA;;;;;UA8BI,mBAAA;;EAEf,MAAA,EAAQ,oBAAA;;EAER,OAAA,EAAS,gBAAA;;EAET,YAAA,GAAe,OAAA;;EAEf,QAAA,GAAW,OAAA;AAAA;;;;AAtCb;;;;;AA8BA;;;;;;iBAwCgB,yBAAA,CACd,MAAA,EAAQ,oBAAA,qBACR,mBAAA,GAAsB,0BAAA,GACrB,mBAAA"}
1
+ {"version":3,"file":"index.d.mts","names":[],"sources":["../src/index.ts"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;cAkDa,kBAAA;;;;;UA8BI,mBAAA;;EAEf,MAAA,EAAQ,oBAAA;;EAER,OAAA,EAAS,gBAAA;;EAET,YAAA,GAAe,OAAA;;EAEf,QAAA,GAAW,OAAA;AAAA;;;;;;AAtCb;;;;;AA8BA;;;;iBAwCgB,yBAAA,CACd,MAAA,EAAQ,oBAAA,qBACR,mBAAA,GAAsB,0BAAA,GACrB,mBAAA"}
package/dist/index.mjs CHANGED
@@ -9,6 +9,7 @@ import { shouldEnableInspector } from "./utils/inspector-visibility.mjs";
9
9
  import { RUNTIME_MODE_INTELLIGENCE, RUNTIME_MODE_SSE } from "./utils/types.mjs";
10
10
  import { dataToUUID, isValidUUID, randomId, randomUUID } from "./utils/random-id.mjs";
11
11
  import { readBody } from "./utils/requests.mjs";
12
+ import { commitRowKeyStore, createRowKeyStore, pruneRowKeyStore, resolveRowRenderKeys, resolveRowRenderKeysById } from "./utils/row-render-keys.mjs";
12
13
  import { isMacOS, parseJson, partialJSONParse, phoenixExponentialBackoff, safeParseToolArgs, tryMap } from "./utils/index.mjs";
13
14
  import { AG_UI_CHANNEL_EVENT, COPILOT_CLOUD_API_URL, COPILOT_CLOUD_CHAT_URL, COPILOT_CLOUD_PUBLIC_API_KEY_HEADER, COPILOT_CLOUD_VERSION, DEFAULT_AGENT_ID } from "./constants/index.mjs";
14
15
  import { isTelemetryDisabled } from "./telemetry/telemetry-disabled.mjs";
@@ -17,6 +18,7 @@ import { MODEL_HOST_CLASSES, classifyModelHost } from "./telemetry/model-host.mj
17
18
  import { firstNonBlankTelemetryId, lambdaClient, parseAndWarnTelemetryId, parseTelemetryIdFromLicense } from "./telemetry/lambda-client.mjs";
18
19
  import { resolveDebugConfig } from "./debug.mjs";
19
20
  import { schemaToJsonSchema } from "./standard-schema.mjs";
21
+ import { createAttachmentContent } from "./attachments/content.mjs";
20
22
  import { exceedsMaxSize, formatFileSize, generateVideoThumbnail, getDocumentIcon, getModalityFromMimeType, getSourceUrl, matchesAcceptFilter, readFileAsBase64 } from "./attachments/utils.mjs";
21
23
  import { logger } from "./logger.mjs";
22
24
  import { createRunEventFinalizer, finalizeRunEvents } from "./finalize-events.mjs";
@@ -64,5 +66,5 @@ function createLicenseContextValue(status, runtimeEntitlements) {
64
66
  }
65
67
 
66
68
  //#endregion
67
- export { A2UI_DEFAULT_DESIGN_GUIDELINES, A2UI_DEFAULT_GENERATION_GUIDELINES, AG_UI_CHANNEL_EVENT, BANNER_ERROR_NAMES, COPILOTKIT_VERSION, COPILOT_CLOUD_API_URL, COPILOT_CLOUD_CHAT_URL, COPILOT_CLOUD_ERROR_NAMES, COPILOT_CLOUD_PUBLIC_API_KEY_HEADER, COPILOT_CLOUD_VERSION, ConfigurationError, ConsoleColors, ConsoleStyles, CopilotKitAgentDiscoveryError, CopilotKitApiDiscoveryError, CopilotKitError, CopilotKitErrorCode, CopilotKitLowLevelError, CopilotKitMisuseError, CopilotKitRemoteEndpointDiscoveryError, CopilotKitVersionMismatchError, DEFAULT_AGENT_ID, ERROR_CONFIG, ERROR_NAMES, ErrorVisibility, MODEL_HOST_CLASSES, MissingPublicApiKeyError, RUNTIME_MODE_INTELLIGENCE, RUNTIME_MODE_SSE, ResolvedCopilotKitError, Severity, TELEMETRY_EMITTER_V1, TELEMETRY_EMITTER_V2, TELEMETRY_SURFACE_V1, TELEMETRY_SURFACE_V2, TranscriptionErrorCode, TranscriptionErrors, UNSAMPLED_RATE, UpgradeRequiredError, actionParametersToJsonSchema, classifyModelHost, computeSamplingMeta, convertJsonSchemaToZodSchema, copyToClipboard, createLicenseContextValue, createRunEventFinalizer, dataToUUID, ensureStructuredError, exceedsMaxSize, executeConditions, finalizeRunEvents, firstNonBlankTelemetryId, formatFileSize, generateVideoThumbnail, getDocumentIcon, getModalityFromMimeType, getPossibleVersionMismatch, getSourceUrl, getZodParameters, isMacOS, isStructuredCopilotKitError, isTelemetryDisabled, isValidUUID, jsonSchemaToActionParameters, lambdaClient, logCopilotKitPlatformMessage, logStyled, logger, matchesAcceptFilter, parseAndWarnTelemetryId, parseInspectorLearningRequestV1, parseInspectorLearningSnapshotV1, parseInspectorLearningUrl, parseInspectorMetadataV1, parseJson, parseTelemetryIdFromLicense, partialJSONParse, phoenixExponentialBackoff, publicApiKeyRequired, randomId, randomUUID, readBody, readFileAsBase64, resolveDebugConfig, safeParseToolArgs, schemaToJsonSchema, shouldEnableInspector, styledConsole, tryMap };
69
+ export { A2UI_DEFAULT_DESIGN_GUIDELINES, A2UI_DEFAULT_GENERATION_GUIDELINES, AG_UI_CHANNEL_EVENT, BANNER_ERROR_NAMES, COPILOTKIT_VERSION, COPILOT_CLOUD_API_URL, COPILOT_CLOUD_CHAT_URL, COPILOT_CLOUD_ERROR_NAMES, COPILOT_CLOUD_PUBLIC_API_KEY_HEADER, COPILOT_CLOUD_VERSION, ConfigurationError, ConsoleColors, ConsoleStyles, CopilotKitAgentDiscoveryError, CopilotKitApiDiscoveryError, CopilotKitError, CopilotKitErrorCode, CopilotKitLowLevelError, CopilotKitMisuseError, CopilotKitRemoteEndpointDiscoveryError, CopilotKitVersionMismatchError, DEFAULT_AGENT_ID, ERROR_CONFIG, ERROR_NAMES, ErrorVisibility, MODEL_HOST_CLASSES, MissingPublicApiKeyError, RUNTIME_MODE_INTELLIGENCE, RUNTIME_MODE_SSE, ResolvedCopilotKitError, Severity, TELEMETRY_EMITTER_V1, TELEMETRY_EMITTER_V2, TELEMETRY_SURFACE_V1, TELEMETRY_SURFACE_V2, TranscriptionErrorCode, TranscriptionErrors, UNSAMPLED_RATE, UpgradeRequiredError, actionParametersToJsonSchema, classifyModelHost, commitRowKeyStore, computeSamplingMeta, convertJsonSchemaToZodSchema, copyToClipboard, createAttachmentContent, createLicenseContextValue, createRowKeyStore, createRunEventFinalizer, dataToUUID, ensureStructuredError, exceedsMaxSize, executeConditions, finalizeRunEvents, firstNonBlankTelemetryId, formatFileSize, generateVideoThumbnail, getDocumentIcon, getModalityFromMimeType, getPossibleVersionMismatch, getSourceUrl, getZodParameters, isMacOS, isStructuredCopilotKitError, isTelemetryDisabled, isValidUUID, jsonSchemaToActionParameters, lambdaClient, logCopilotKitPlatformMessage, logStyled, logger, matchesAcceptFilter, parseAndWarnTelemetryId, parseInspectorLearningRequestV1, parseInspectorLearningSnapshotV1, parseInspectorLearningUrl, parseInspectorMetadataV1, parseJson, parseTelemetryIdFromLicense, partialJSONParse, phoenixExponentialBackoff, pruneRowKeyStore, publicApiKeyRequired, randomId, randomUUID, readBody, readFileAsBase64, resolveDebugConfig, resolveRowRenderKeys, resolveRowRenderKeysById, safeParseToolArgs, schemaToJsonSchema, shouldEnableInspector, styledConsole, tryMap };
68
70
  //# sourceMappingURL=index.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.mjs","names":["packageJson.version"],"sources":["../src/index.ts"],"sourcesContent":["export * from \"./types\";\nexport * from \"./utils\";\nexport * from \"./constants\";\n// Telemetry is split deliberately. `TelemetryClient` imports\n// `@segment/analytics-node`, which imports `node-fetch`, which imports the\n// Node built-ins `stream`, `http`, `https` and `zlib`. Browser bundlers\n// resolve the whole module graph before they tree-shake, so re-exporting\n// that module here made every browser build of a dependent package print\n// \"Module ... has been externalized for browser compatibility\" warnings,\n// even when the consumer never touched telemetry (#4151). Only the\n// browser-safe telemetry surface is re-exported from this entry. Server\n// code that needs the client imports it from `@copilotkit/shared/telemetry`.\n// This mirrors the license-verifier note below.\nexport { isTelemetryDisabled } from \"./telemetry/telemetry-disabled\";\nexport * from \"./telemetry/sampling\";\n// Pure string classification with no imports, so it carries no runtime edge\n// into browser builds — same reasoning as `sampling` above.\nexport * from \"./telemetry/model-host\";\nexport {\n firstNonBlankTelemetryId,\n lambdaClient,\n parseTelemetryIdFromLicense,\n parseAndWarnTelemetryId,\n} from \"./telemetry/lambda-client\";\nexport type { LambdaSendOptions } from \"./telemetry/lambda-client\";\n// Types only: erased at build time, so they add no runtime edge to\n// `telemetry-client.ts` and therefore none to @segment/analytics-node.\nexport type {\n TelemetryCapture,\n TelemetryIdentity,\n} from \"./telemetry/telemetry-client\";\nexport * from \"./debug\";\nexport * from \"./standard-schema\";\nexport * from \"./attachments\";\n\nexport { logger } from \"./logger\";\nexport {\n createRunEventFinalizer,\n finalizeRunEvents,\n type FinalizeRunOptions,\n type RunEventFinalizer,\n} from \"./finalize-events\";\n\nexport {\n TranscriptionErrorCode,\n TranscriptionErrors,\n type TranscriptionErrorResponse,\n} from \"./transcription-errors\";\n\nimport * as packageJson from \"../package.json\";\nexport const COPILOTKIT_VERSION = packageJson.version;\n\n// Re-export only types from license-verifier (types are erased at compile time,\n// so they don't pull in the Node-only `crypto` dependency into client bundles).\n// Server-side packages (e.g. @copilotkit/runtime) should import runtime functions\n// like createLicenseChecker and getLicenseWarningHeader directly from\n// @copilotkit/license-verifier.\nexport type {\n LicenseChecker,\n LicenseStatus,\n LicensePayload,\n LicenseFeatures,\n LicenseTier,\n LicenseOwner,\n} from \"@copilotkit/license-verifier\";\n\nimport type { LicensePayload } from \"@copilotkit/license-verifier\";\nimport type {\n RuntimeEntitlementResponse,\n RuntimeLicenseStatus,\n} from \"./utils/types\";\n\n// LicenseContextValue was dropped from license-verifier's public API in\n// 0.3.0, so it is defined here. The context shape is owned by this package\n// anyway via createLicenseContextValue below.\n\n/**\n * License context value exposed to child components.\n * Frontend providers create their own context using this shape.\n */\nexport interface LicenseContextValue {\n /** Effective license status after structured entitlement precedence. Null until known. */\n status: RuntimeLicenseStatus | null;\n /** The license payload if available. Always null on the client; the payload stays server-side. */\n license: LicensePayload | null;\n /** Whether a feature is licensed. Ready entitlements override legacy status behavior. */\n checkFeature: (feature: string) => boolean;\n /** Get a numeric feature limit. Zero means unlimited; null means not applicable. */\n getLimit: (feature: string) => number | null;\n}\n\n/** Read a record value without traversing its prototype chain. */\nfunction getOwnRecordValue<Value>(\n record: Readonly<Record<string, Value>>,\n key: string,\n): Value | undefined {\n return Object.prototype.hasOwnProperty.call(record, key)\n ? record[key]\n : undefined;\n}\n\n/** Legacy UI surfaces that remain available for every active entitlement. */\nfunction isLegacyUiFeature(feature: string): boolean {\n return feature === \"chat\" || feature === \"popup\" || feature === \"sidebar\";\n}\n\n/**\n * Client-safe license context factory, driven by the license authority the\n * runtime reports via /info.\n *\n * A ready managed entitlement is authoritative in both directions. A ready\n * active self-hosted entitlement is also authoritative, while an inactive\n * self-hosted response preserves the legacy signed-license fallback. Active\n * entitlements supply feature grants and limits; authoritative inactive\n * entitlements deny every feature and limit. Older runtimes that report only a\n * status retain the legacy behavior: features are enabled unless the status is\n * \"expired\" or \"invalid\", and no limits are reported. This is inlined here to\n * avoid importing the full license-verifier bundle (which depends on Node's\n * `crypto`) into browser bundles.\n */\nexport function createLicenseContextValue(\n status: RuntimeLicenseStatus | null | undefined,\n runtimeEntitlements?: RuntimeEntitlementResponse,\n): LicenseContextValue {\n const readyEntitlement =\n runtimeEntitlements?.status === \"ready\"\n ? runtimeEntitlements.entitlement\n : null;\n const hasUsableSelfHostedLegacyFallback =\n readyEntitlement &&\n !readyEntitlement.active &&\n readyEntitlement.source === \"selfHostedDeploymentLicense\" &&\n (status === \"valid\" || status === \"expiring\");\n const featureAuthority =\n readyEntitlement && !hasUsableSelfHostedLegacyFallback\n ? readyEntitlement\n : null;\n const activeEntitlement = featureAuthority?.active ? featureAuthority : null;\n const resolvedStatus = activeEntitlement\n ? \"valid\"\n : readyEntitlement?.source === \"managedOrgSubscription\" ||\n readyEntitlement?.source === \"awsMarketplaceDeploymentLicense\"\n ? \"none\"\n : featureAuthority\n ? (status ?? \"none\")\n : (status ?? null);\n const featuresEnabled =\n resolvedStatus !== \"expired\" && resolvedStatus !== \"invalid\";\n\n return {\n status: resolvedStatus,\n license: null,\n checkFeature: (feature) =>\n featureAuthority\n ? activeEntitlement\n ? feature === \"threads\" &&\n Object.prototype.hasOwnProperty.call(\n activeEntitlement.limits,\n \"threads.max_count\",\n )\n ? true\n : (getOwnRecordValue(activeEntitlement.features, feature) ??\n isLegacyUiFeature(feature))\n : false\n : featuresEnabled,\n getLimit: (feature) =>\n activeEntitlement\n ? (getOwnRecordValue(activeEntitlement.limits, feature) ?? null)\n : null,\n };\n}\n\nexport {\n A2UI_DEFAULT_GENERATION_GUIDELINES,\n A2UI_DEFAULT_DESIGN_GUIDELINES,\n} from \"./a2ui-prompts\";\n\nexport type { DebugEventEnvelope } from \"./debug-event-envelope\";\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;AAkDA,MAAa,qBAAqBA;;AA0ClC,SAAS,kBACP,QACA,KACmB;AACnB,QAAO,OAAO,UAAU,eAAe,KAAK,QAAQ,IAAI,GACpD,OAAO,OACP;;;AAIN,SAAS,kBAAkB,SAA0B;AACnD,QAAO,YAAY,UAAU,YAAY,WAAW,YAAY;;;;;;;;;;;;;;;;AAiBlE,SAAgB,0BACd,QACA,qBACqB;CACrB,MAAM,mBACJ,qBAAqB,WAAW,UAC5B,oBAAoB,cACpB;CACN,MAAM,oCACJ,oBACA,CAAC,iBAAiB,UAClB,iBAAiB,WAAW,kCAC3B,WAAW,WAAW,WAAW;CACpC,MAAM,mBACJ,oBAAoB,CAAC,oCACjB,mBACA;CACN,MAAM,oBAAoB,kBAAkB,SAAS,mBAAmB;CACxE,MAAM,iBAAiB,oBACnB,UACA,kBAAkB,WAAW,4BAC3B,kBAAkB,WAAW,oCAC7B,SACA,mBACG,UAAU,SACV,UAAU;CACnB,MAAM,kBACJ,mBAAmB,aAAa,mBAAmB;AAErD,QAAO;EACL,QAAQ;EACR,SAAS;EACT,eAAe,YACb,mBACI,oBACE,YAAY,aACZ,OAAO,UAAU,eAAe,KAC9B,kBAAkB,QAClB,oBACD,GACC,OACC,kBAAkB,kBAAkB,UAAU,QAAQ,IACvD,kBAAkB,QAAQ,GAC5B,QACF;EACN,WAAW,YACT,oBACK,kBAAkB,kBAAkB,QAAQ,QAAQ,IAAI,OACzD;EACP"}
1
+ {"version":3,"file":"index.mjs","names":["packageJson.version"],"sources":["../src/index.ts"],"sourcesContent":["export * from \"./types\";\nexport * from \"./utils\";\nexport * from \"./constants\";\n// Telemetry is split deliberately. `TelemetryClient` imports\n// `@segment/analytics-node`, which imports `node-fetch`, which imports the\n// Node built-ins `stream`, `http`, `https` and `zlib`. Browser bundlers\n// resolve the whole module graph before they tree-shake, so re-exporting\n// that module here made every browser build of a dependent package print\n// \"Module ... has been externalized for browser compatibility\" warnings,\n// even when the consumer never touched telemetry (#4151). Only the\n// browser-safe telemetry surface is re-exported from this entry. Server\n// code that needs the client imports it from `@copilotkit/shared/telemetry`.\n// This mirrors the license-verifier note below.\nexport { isTelemetryDisabled } from \"./telemetry/telemetry-disabled\";\nexport * from \"./telemetry/sampling\";\n// Pure string classification with no imports, so it carries no runtime edge\n// into browser builds — same reasoning as `sampling` above.\nexport * from \"./telemetry/model-host\";\nexport {\n firstNonBlankTelemetryId,\n lambdaClient,\n parseTelemetryIdFromLicense,\n parseAndWarnTelemetryId,\n} from \"./telemetry/lambda-client\";\nexport type { LambdaSendOptions } from \"./telemetry/lambda-client\";\n// Types only: erased at build time, so they add no runtime edge to\n// `telemetry-client.ts` and therefore none to @segment/analytics-node.\nexport type {\n TelemetryCapture,\n TelemetryIdentity,\n} from \"./telemetry/telemetry-client\";\nexport * from \"./debug\";\nexport * from \"./standard-schema\";\nexport * from \"./attachments\";\n\nexport { logger } from \"./logger\";\nexport {\n createRunEventFinalizer,\n finalizeRunEvents,\n type FinalizeRunOptions,\n type RunEventFinalizer,\n} from \"./finalize-events\";\n\nexport {\n TranscriptionErrorCode,\n TranscriptionErrors,\n type TranscriptionErrorResponse,\n} from \"./transcription-errors\";\n\nimport * as packageJson from \"../package.json\";\nexport const COPILOTKIT_VERSION = packageJson.version;\n\n// Re-export only types from license-verifier (types are erased at compile time,\n// so they don't pull in the Node-only `crypto` dependency into client bundles).\n// Server-side packages (e.g. @copilotkit/runtime) should import runtime functions\n// like createLicenseChecker and getLicenseWarningHeader directly from\n// @copilotkit/license-verifier.\nexport type {\n LicenseChecker,\n LicenseStatus,\n LicensePayload,\n LicenseFeatures,\n LicenseTier,\n LicenseOwner,\n} from \"@copilotkit/license-verifier\";\n\nimport type { LicensePayload } from \"@copilotkit/license-verifier\";\nimport type {\n RuntimeEntitlementResponse,\n RuntimeLicenseStatus,\n} from \"./utils/types\";\n\n// LicenseContextValue was dropped from license-verifier's public API in\n// 0.3.0, so it is defined here. The context shape is owned by this package\n// anyway via createLicenseContextValue below.\n\n/**\n * License context value exposed to child components.\n * Frontend providers create their own context using this shape.\n */\nexport interface LicenseContextValue {\n /** Effective license status after structured entitlement precedence. Null until known. */\n status: RuntimeLicenseStatus | null;\n /** The license payload if available. Always null on the client; the payload stays server-side. */\n license: LicensePayload | null;\n /** Whether a feature is licensed. Ready entitlements override legacy status behavior. */\n checkFeature: (feature: string) => boolean;\n /** Get a numeric feature limit. Zero means unlimited; null means not applicable. */\n getLimit: (feature: string) => number | null;\n}\n\n/** Read a record value without traversing its prototype chain. */\nfunction getOwnRecordValue<Value>(\n record: Readonly<Record<string, Value>>,\n key: string,\n): Value | undefined {\n return Object.prototype.hasOwnProperty.call(record, key)\n ? record[key]\n : undefined;\n}\n\n/** Legacy UI surfaces that remain available for every active entitlement. */\nfunction isLegacyUiFeature(feature: string): boolean {\n return feature === \"chat\" || feature === \"popup\" || feature === \"sidebar\";\n}\n\n/**\n * Client-safe license context factory, driven by the license authority the\n * runtime reports via /info.\n *\n * A ready managed entitlement is authoritative in both directions. A ready\n * active self-hosted entitlement is also authoritative, while an inactive\n * self-hosted response preserves the legacy signed-license fallback. Active\n * entitlements supply feature grants and limits; authoritative inactive\n * entitlements deny every feature and limit. Older runtimes that report only a\n * status retain the legacy behavior: features are enabled unless the status is\n * \"expired\" or \"invalid\", and no limits are reported. This is inlined here to\n * avoid importing the full license-verifier bundle (which depends on Node's\n * `crypto`) into browser bundles.\n */\nexport function createLicenseContextValue(\n status: RuntimeLicenseStatus | null | undefined,\n runtimeEntitlements?: RuntimeEntitlementResponse,\n): LicenseContextValue {\n const readyEntitlement =\n runtimeEntitlements?.status === \"ready\"\n ? runtimeEntitlements.entitlement\n : null;\n const hasUsableSelfHostedLegacyFallback =\n readyEntitlement &&\n !readyEntitlement.active &&\n readyEntitlement.source === \"selfHostedDeploymentLicense\" &&\n (status === \"valid\" || status === \"expiring\");\n const featureAuthority =\n readyEntitlement && !hasUsableSelfHostedLegacyFallback\n ? readyEntitlement\n : null;\n const activeEntitlement = featureAuthority?.active ? featureAuthority : null;\n const resolvedStatus = activeEntitlement\n ? \"valid\"\n : readyEntitlement?.source === \"managedOrgSubscription\" ||\n readyEntitlement?.source === \"awsMarketplaceDeploymentLicense\"\n ? \"none\"\n : featureAuthority\n ? (status ?? \"none\")\n : (status ?? null);\n const featuresEnabled =\n resolvedStatus !== \"expired\" && resolvedStatus !== \"invalid\";\n\n return {\n status: resolvedStatus,\n license: null,\n checkFeature: (feature) =>\n featureAuthority\n ? activeEntitlement\n ? feature === \"threads\" &&\n Object.prototype.hasOwnProperty.call(\n activeEntitlement.limits,\n \"threads.max_count\",\n )\n ? true\n : (getOwnRecordValue(activeEntitlement.features, feature) ??\n isLegacyUiFeature(feature))\n : false\n : featuresEnabled,\n getLimit: (feature) =>\n activeEntitlement\n ? (getOwnRecordValue(activeEntitlement.limits, feature) ?? null)\n : null,\n };\n}\n\nexport {\n A2UI_DEFAULT_GENERATION_GUIDELINES,\n A2UI_DEFAULT_DESIGN_GUIDELINES,\n} from \"./a2ui-prompts\";\n\nexport type { DebugEventEnvelope } from \"./debug-event-envelope\";\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAkDA,MAAa,qBAAqBA;;AA0ClC,SAAS,kBACP,QACA,KACmB;AACnB,QAAO,OAAO,UAAU,eAAe,KAAK,QAAQ,IAAI,GACpD,OAAO,OACP;;;AAIN,SAAS,kBAAkB,SAA0B;AACnD,QAAO,YAAY,UAAU,YAAY,WAAW,YAAY;;;;;;;;;;;;;;;;AAiBlE,SAAgB,0BACd,QACA,qBACqB;CACrB,MAAM,mBACJ,qBAAqB,WAAW,UAC5B,oBAAoB,cACpB;CACN,MAAM,oCACJ,oBACA,CAAC,iBAAiB,UAClB,iBAAiB,WAAW,kCAC3B,WAAW,WAAW,WAAW;CACpC,MAAM,mBACJ,oBAAoB,CAAC,oCACjB,mBACA;CACN,MAAM,oBAAoB,kBAAkB,SAAS,mBAAmB;CACxE,MAAM,iBAAiB,oBACnB,UACA,kBAAkB,WAAW,4BAC3B,kBAAkB,WAAW,oCAC7B,SACA,mBACG,UAAU,SACV,UAAU;CACnB,MAAM,kBACJ,mBAAmB,aAAa,mBAAmB;AAErD,QAAO;EACL,QAAQ;EACR,SAAS;EACT,eAAe,YACb,mBACI,oBACE,YAAY,aACZ,OAAO,UAAU,eAAe,KAC9B,kBAAkB,QAClB,oBACD,GACC,OACC,kBAAkB,kBAAkB,UAAU,QAAQ,IACvD,kBAAkB,QAAQ,GAC5B,QACF;EACN,WAAW,YACT,oBACK,kBAAkB,kBAAkB,QAAQ,QAAQ,IAAI,OACzD;EACP"}
package/dist/index.umd.js CHANGED
@@ -1222,6 +1222,209 @@ ${getSeeMoreMarkdown(troubleshootingLink)}`;
1222
1222
  }
1223
1223
  }
1224
1224
 
1225
+ //#endregion
1226
+ //#region src/utils/row-render-keys.ts
1227
+ /**
1228
+ * Stable per-row view keys for chat transcripts, across backends that re-key a
1229
+ * message mid-stream. Shared by every frontend package, because the defect and
1230
+ * the correlation signal are in the message stream, not in any one framework.
1231
+ *
1232
+ * ## The problem
1233
+ *
1234
+ * A message's canonical `id` is not stable within a turn. LangChain stamps a
1235
+ * placeholder id on the first streamed chunk when the provider didn't supply
1236
+ * one (`chat_models.py`: `if chunk.message.id is None: chunk.message.id =
1237
+ * "lc_run-" + "-" + run_id`), then prefers any provider-assigned id it sees
1238
+ * while merging chunks (`messages/ai.py`, "Ranks are defined by the order of
1239
+ * preference"). The `MESSAGES_SNAPSHOT` therefore carries the provider's final
1240
+ * id (e.g. `resp_…`) for a message the client already knows as `lc_run--…`.
1241
+ *
1242
+ * Every framework destroys and recreates a row whose key changes, so keying
1243
+ * rows by `id` turned that swap into the visible HITL chat flash, where a
1244
+ * rendered approval card appears to reset during a tool's
1245
+ * `executing → complete` transition.
1246
+ *
1247
+ * This is provider-conditional: providers that stamp an id on every chunk (so
1248
+ * `chunk.message.id is None` never holds) never trigger a rename.
1249
+ *
1250
+ * ## The approach
1251
+ *
1252
+ * Tool-call ids survive the rename, so they are used as *anchors*: the first
1253
+ * message seen carrying a given tool call records the key it was assigned, and
1254
+ * any later message carrying that same tool call reuses it. The store is an
1255
+ * override table consulted before falling back to `message.id`. Resolving only
1256
+ * reads it; each render that reaches the DOM then records what it rendered:
1257
+ *
1258
+ * ```text
1259
+ * render 1 id=lc_run--1 no tools key = message.id = lc_run--1
1260
+ * commit 1 store {}
1261
+ * render 2 id=lc_run--1 tc call_A key = message.id = lc_run--1
1262
+ * commit 2 store { tc:call_A -> lc_run--1 }
1263
+ * render 3 id=resp_1 tc call_A key = store[tc:call_A]
1264
+ * = lc_run--1 (row survives)
1265
+ * commit 3 store unchanged
1266
+ * ```
1267
+ *
1268
+ * Recording the anchor at commit 2 — while the id is still stable — is what
1269
+ * makes render 3 resolvable. Note the fix does not depend on render 2
1270
+ * existing: a message born already carrying a tool call anchors on the first
1271
+ * render that commits it, under whatever id it holds then.
1272
+ *
1273
+ * ## Why an override table rather than keying rows by tool-call id
1274
+ *
1275
+ * Deriving the key from the tool call directly (`tc:<id>` whenever a tool call
1276
+ * is present) needs no state, but changes the key the moment a tool call
1277
+ * *appears* — so an assistant message that streams text and then calls a tool
1278
+ * is torn down on that transition, for every provider, whether or not it
1279
+ * renames. That trades a conditional flash for an unconditional one. Recording
1280
+ * an override keeps the key the row already had.
1281
+ *
1282
+ * ## Cost
1283
+ *
1284
+ * The store holds only `tc:<toolCallId>` entries, so a conversation with no
1285
+ * tool calls keeps an empty store and behaviour byte-identical to keying by
1286
+ * `id`. Size is bounded to the tool calls of the currently-rendered messages
1287
+ * (see `pruneRowKeyStore`), not the conversation length. Deleting the store
1288
+ * reverts to plain `id` keying.
1289
+ *
1290
+ * ## Known gaps
1291
+ *
1292
+ * - A text-only assistant message has no anchor, so it still re-keys. No
1293
+ * client-side correlation signal exists for it; the fix is stable ids
1294
+ * upstream.
1295
+ * - If the tool call's arrival and the id swap land in the same update, the
1296
+ * intermediate state never renders, the anchor is never recorded, and the
1297
+ * row is recreated as before. Correlating in the event-apply layer (i.e. in
1298
+ * the AG-UI client, which observes every intermediate state) would be immune.
1299
+ */
1300
+ const TOOL_ANCHOR_PREFIX = "tc:";
1301
+ function createRowKeyStore() {
1302
+ return {
1303
+ overrides: /* @__PURE__ */ new Map(),
1304
+ ambiguous: /* @__PURE__ */ new Set()
1305
+ };
1306
+ }
1307
+ /**
1308
+ * Anchors a message contributes. Only assistant tool calls qualify: LangChain's
1309
+ * id preference applies when merging `AIMessageChunk`s, so user message ids are
1310
+ * not renamed, and `role: "tool"` messages are not rendered as rows. Every tool
1311
+ * call is used (not just the first) so the anchor survives tool-call reordering
1312
+ * between snapshots.
1313
+ */
1314
+ function toolAnchorsOf(message) {
1315
+ if ((message === null || message === void 0 ? void 0 : message.role) !== "assistant") return [];
1316
+ const toolCalls = message.toolCalls;
1317
+ if (!(toolCalls === null || toolCalls === void 0 ? void 0 : toolCalls.length)) return [];
1318
+ const anchors = [];
1319
+ for (const toolCall of toolCalls) if (toolCall === null || toolCall === void 0 ? void 0 : toolCall.id) anchors.push(`${TOOL_ANCHOR_PREFIX}${toolCall.id}`);
1320
+ return anchors;
1321
+ }
1322
+ /**
1323
+ * Resolves the row key for every message, returned by position.
1324
+ *
1325
+ * Pure: it reads `store` and never writes to it. Every framework here may
1326
+ * evaluate a render pass whose result never reaches the DOM — an abandoned
1327
+ * concurrent render in React, a discarded `computed` evaluation in Vue or
1328
+ * Angular. An anchor recorded by such a pass would vend its key to the pass
1329
+ * that does render, re-keying the row the user is looking at, which is the
1330
+ * teardown this module exists to prevent. Anchors are recorded by
1331
+ * `commitRowKeyStore`, from whichever phase each framework runs after the DOM
1332
+ * is updated.
1333
+ *
1334
+ * Uniqueness is structural rather than assumed: a caller that does not
1335
+ * deduplicate can pass two rows with the same id, and an override can vend a
1336
+ * key equal to a later message's own id.
1337
+ */
1338
+ function resolveRowRenderKeys(store, messages) {
1339
+ const keys = [];
1340
+ const claimed = /* @__PURE__ */ new Set();
1341
+ messages.forEach((message, index) => {
1342
+ var _key;
1343
+ const anchors = toolAnchorsOf(message);
1344
+ let key;
1345
+ for (const anchor of anchors) {
1346
+ if (store.ambiguous.has(anchor)) continue;
1347
+ const recorded = store.overrides.get(anchor);
1348
+ if (recorded !== void 0 && !claimed.has(recorded)) {
1349
+ key = recorded;
1350
+ break;
1351
+ }
1352
+ }
1353
+ (_key = key) !== null && _key !== void 0 || (key = (message === null || message === void 0 ? void 0 : message.id) || `index-${index}`);
1354
+ if (claimed.has(key)) {
1355
+ let suffix = 2;
1356
+ while (claimed.has(`${key}:${suffix}`)) suffix += 1;
1357
+ key = `${key}:${suffix}`;
1358
+ }
1359
+ keys.push(key);
1360
+ claimed.add(key);
1361
+ });
1362
+ return keys;
1363
+ }
1364
+ /**
1365
+ * `message.id` → row key, for callers that render by message rather than by
1366
+ * position. `messages` must be deduplicated: duplicate ids would overwrite
1367
+ * each other in the returned map.
1368
+ */
1369
+ function resolveRowRenderKeysById(store, messages) {
1370
+ const keys = resolveRowRenderKeys(store, messages);
1371
+ const byId = /* @__PURE__ */ new Map();
1372
+ messages.forEach((message, index) => {
1373
+ const key = keys[index];
1374
+ if (key !== void 0) byId.set(message.id, key);
1375
+ });
1376
+ return byId;
1377
+ }
1378
+ /**
1379
+ * Records the anchors of a rendered list, then bounds the store to it. Call
1380
+ * from the phase that runs after the DOM is updated, never while resolving —
1381
+ * see `resolveRowRenderKeys`.
1382
+ *
1383
+ * Re-resolving here reproduces the keys the rows were rendered with, because
1384
+ * the store cannot change between a render and its own post-render phase.
1385
+ *
1386
+ * An anchor carried by two rows in the same list is marked ambiguous rather
1387
+ * than recorded. Recording it would give the first row's key to whichever row
1388
+ * outlived the other, and with it that row's DOM and component state.
1389
+ */
1390
+ function commitRowKeyStore(store, messages) {
1391
+ const keys = resolveRowRenderKeys(store, messages);
1392
+ const anchorCounts = /* @__PURE__ */ new Map();
1393
+ for (const message of messages) for (const anchor of toolAnchorsOf(message)) {
1394
+ var _anchorCounts$get;
1395
+ anchorCounts.set(anchor, ((_anchorCounts$get = anchorCounts.get(anchor)) !== null && _anchorCounts$get !== void 0 ? _anchorCounts$get : 0) + 1);
1396
+ }
1397
+ store.ambiguous.clear();
1398
+ for (const [anchor, count] of anchorCounts) if (count > 1) {
1399
+ store.ambiguous.add(anchor);
1400
+ store.overrides.delete(anchor);
1401
+ }
1402
+ messages.forEach((message, index) => {
1403
+ const key = keys[index];
1404
+ if (key === void 0) return;
1405
+ for (const anchor of toolAnchorsOf(message)) {
1406
+ if (store.ambiguous.has(anchor)) continue;
1407
+ if (!store.overrides.has(anchor)) store.overrides.set(anchor, key);
1408
+ }
1409
+ });
1410
+ pruneRowKeyStore(store, messages);
1411
+ }
1412
+ /**
1413
+ * Drops anchors no longer present in `messages`, bounding the store to the
1414
+ * tool calls of the currently-rendered messages. Called by
1415
+ * `commitRowKeyStore`; like it, this writes to the store and so belongs after
1416
+ * the DOM is updated, never while resolving.
1417
+ *
1418
+ * Pruned entries are unreachable by construction: `resolveRowRenderKeys` only
1419
+ * looks up anchors belonging to messages in the list it is given.
1420
+ */
1421
+ function pruneRowKeyStore(store, messages) {
1422
+ const live = /* @__PURE__ */ new Set();
1423
+ for (const message of messages) for (const anchor of toolAnchorsOf(message)) live.add(anchor);
1424
+ for (const anchor of store.overrides.keys()) if (!live.has(anchor)) store.overrides.delete(anchor);
1425
+ for (const anchor of store.ambiguous) if (!live.has(anchor)) store.ambiguous.delete(anchor);
1426
+ }
1427
+
1225
1428
  //#endregion
1226
1429
  //#region src/utils/index.ts
1227
1430
  /**
@@ -1624,6 +1827,20 @@ ${getSeeMoreMarkdown(troubleshootingLink)}`;
1624
1827
  throw new Error(`Cannot convert schema to JSON Schema. The schema (vendor: "${vendor}") does not implement Standard JSON Schema V1 and no zodToJsonSchema fallback is available. Use a library that supports Standard JSON Schema (e.g., Zod 3.24+, Valibot v1+, ArkType v2+) or pass a zodToJsonSchema function in options.`);
1625
1828
  }
1626
1829
 
1830
+ //#endregion
1831
+ //#region src/attachments/content.ts
1832
+ /** Build the AG-UI content part used when sending a ready attachment. */
1833
+ function createAttachmentContent(attachment) {
1834
+ return {
1835
+ type: attachment.type,
1836
+ source: attachment.source,
1837
+ metadata: {
1838
+ ...attachment.filename ? { filename: attachment.filename } : {},
1839
+ ...attachment.metadata
1840
+ }
1841
+ };
1842
+ }
1843
+
1627
1844
  //#endregion
1628
1845
  //#region src/attachments/utils.ts
1629
1846
  const DEFAULT_MAX_SIZE = 20 * 1024 * 1024;
@@ -1958,7 +2175,7 @@ ${getSeeMoreMarkdown(troubleshootingLink)}`;
1958
2175
 
1959
2176
  //#endregion
1960
2177
  //#region package.json
1961
- var version = "1.73.0";
2178
+ var version = "1.73.2-canary.1790068297";
1962
2179
 
1963
2180
  //#endregion
1964
2181
  //#region src/a2ui-prompts.ts
@@ -2164,10 +2381,13 @@ exports.UNSAMPLED_RATE = UNSAMPLED_RATE;
2164
2381
  exports.UpgradeRequiredError = UpgradeRequiredError;
2165
2382
  exports.actionParametersToJsonSchema = actionParametersToJsonSchema;
2166
2383
  exports.classifyModelHost = classifyModelHost;
2384
+ exports.commitRowKeyStore = commitRowKeyStore;
2167
2385
  exports.computeSamplingMeta = computeSamplingMeta;
2168
2386
  exports.convertJsonSchemaToZodSchema = convertJsonSchemaToZodSchema;
2169
2387
  exports.copyToClipboard = copyToClipboard;
2388
+ exports.createAttachmentContent = createAttachmentContent;
2170
2389
  exports.createLicenseContextValue = createLicenseContextValue;
2390
+ exports.createRowKeyStore = createRowKeyStore;
2171
2391
  exports.createRunEventFinalizer = createRunEventFinalizer;
2172
2392
  exports.dataToUUID = dataToUUID;
2173
2393
  exports.ensureStructuredError = ensureStructuredError;
@@ -2201,12 +2421,15 @@ exports.parseJson = parseJson;
2201
2421
  exports.parseTelemetryIdFromLicense = parseTelemetryIdFromLicense;
2202
2422
  exports.partialJSONParse = partialJSONParse;
2203
2423
  exports.phoenixExponentialBackoff = phoenixExponentialBackoff;
2424
+ exports.pruneRowKeyStore = pruneRowKeyStore;
2204
2425
  exports.publicApiKeyRequired = publicApiKeyRequired;
2205
2426
  exports.randomId = randomId;
2206
2427
  exports.randomUUID = randomUUID;
2207
2428
  exports.readBody = readBody;
2208
2429
  exports.readFileAsBase64 = readFileAsBase64;
2209
2430
  exports.resolveDebugConfig = resolveDebugConfig;
2431
+ exports.resolveRowRenderKeys = resolveRowRenderKeys;
2432
+ exports.resolveRowRenderKeysById = resolveRowRenderKeysById;
2210
2433
  exports.safeParseToolArgs = safeParseToolArgs;
2211
2434
  exports.schemaToJsonSchema = schemaToJsonSchema;
2212
2435
  exports.shouldEnableInspector = shouldEnableInspector;