@aws-amplify/data-schema 1.12.2 → 1.13.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/ai/ConversationSchemaTypes.js +19 -0
- package/dist/cjs/ai/ConversationSchemaTypes.js.map +1 -1
- package/dist/cjs/ai/types/ConversationStreamEvent.js +6 -0
- package/dist/cjs/ai/types/ConversationStreamEvent.js.map +1 -0
- package/dist/cjs/runtime/internals/ai/conversationStreamEventDeserializers.js +41 -0
- package/dist/cjs/runtime/internals/ai/conversationStreamEventDeserializers.js.map +1 -0
- package/dist/cjs/runtime/internals/ai/convertItemToConversation.js +2 -2
- package/dist/cjs/runtime/internals/ai/convertItemToConversation.js.map +1 -1
- package/dist/cjs/runtime/internals/ai/convertItemToConversationMessage.js +1 -1
- package/dist/cjs/runtime/internals/ai/convertItemToConversationMessage.js.map +1 -1
- package/dist/cjs/runtime/internals/ai/{createOnMessageFunction.js → createOnStreamEventFunction.js} +11 -7
- package/dist/cjs/runtime/internals/ai/createOnStreamEventFunction.js.map +1 -0
- package/dist/cjs/runtime/internals/ai/getCustomUserAgentDetails.js +1 -1
- package/dist/cjs/runtime/internals/ai/getCustomUserAgentDetails.js.map +1 -1
- package/dist/esm/ClientSchema/ai/ClientConversation.d.ts +2 -1
- package/dist/esm/ai/ConversationSchemaTypes.mjs +19 -0
- package/dist/esm/ai/ConversationSchemaTypes.mjs.map +1 -1
- package/dist/esm/ai/ConversationType.d.ts +9 -4
- package/dist/esm/ai/types/ConversationStreamEvent.d.ts +56 -0
- package/dist/esm/ai/types/ConversationStreamEvent.mjs +2 -0
- package/dist/esm/ai/types/ConversationStreamEvent.mjs.map +1 -0
- package/dist/esm/runtime/internals/ai/conversationStreamEventDeserializers.d.ts +6 -0
- package/dist/esm/runtime/internals/ai/conversationStreamEventDeserializers.mjs +38 -0
- package/dist/esm/runtime/internals/ai/conversationStreamEventDeserializers.mjs.map +1 -0
- package/dist/esm/runtime/internals/ai/convertItemToConversation.mjs +2 -2
- package/dist/esm/runtime/internals/ai/convertItemToConversation.mjs.map +1 -1
- package/dist/esm/runtime/internals/ai/convertItemToConversationMessage.mjs +1 -1
- package/dist/esm/runtime/internals/ai/convertItemToConversationMessage.mjs.map +1 -1
- package/dist/esm/runtime/internals/ai/createOnStreamEventFunction.d.ts +3 -0
- package/dist/esm/runtime/internals/ai/{createOnMessageFunction.mjs → createOnStreamEventFunction.mjs} +10 -6
- package/dist/esm/runtime/internals/ai/createOnStreamEventFunction.mjs.map +1 -0
- package/dist/esm/runtime/internals/ai/getCustomUserAgentDetails.d.ts +1 -1
- package/dist/esm/runtime/internals/ai/getCustomUserAgentDetails.mjs +1 -1
- package/dist/esm/runtime/internals/ai/getCustomUserAgentDetails.mjs.map +1 -1
- package/dist/meta/cjs.tsbuildinfo +1 -1
- package/package.json +1 -1
- package/src/ClientSchema/ai/ClientConversation.ts +2 -0
- package/src/ai/ConversationSchemaTypes.ts +21 -0
- package/src/ai/ConversationType.ts +10 -3
- package/src/ai/types/ConversationStreamEvent.ts +70 -0
- package/src/runtime/internals/ai/conversationStreamEventDeserializers.ts +62 -0
- package/src/runtime/internals/ai/convertItemToConversation.ts +2 -2
- package/src/runtime/internals/ai/convertItemToConversationMessage.ts +1 -1
- package/src/runtime/internals/ai/{createOnMessageFunction.ts → createOnStreamEventFunction.ts} +7 -5
- package/src/runtime/internals/ai/getCustomUserAgentDetails.ts +1 -1
- package/dist/cjs/runtime/internals/ai/createOnMessageFunction.js.map +0 -1
- package/dist/esm/runtime/internals/ai/createOnMessageFunction.d.ts +0 -3
- package/dist/esm/runtime/internals/ai/createOnMessageFunction.mjs.map +0 -1
package/package.json
CHANGED
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
import type {
|
|
5
5
|
Conversation,
|
|
6
6
|
ConversationMessage,
|
|
7
|
+
ConversationStreamEvent,
|
|
7
8
|
} from '../../ai/ConversationType';
|
|
8
9
|
import type { ClientSchemaProperty } from '../Core';
|
|
9
10
|
|
|
@@ -12,4 +13,5 @@ export interface ClientConversation
|
|
|
12
13
|
__entityType: 'customConversation';
|
|
13
14
|
type: Conversation;
|
|
14
15
|
messageType: ConversationMessage;
|
|
16
|
+
streamEventType: ConversationStreamEvent;
|
|
15
17
|
}
|
|
@@ -230,6 +230,25 @@ const ToolInputSchema = `type ToolInputSchema {
|
|
|
230
230
|
json: AWSJSON
|
|
231
231
|
}`;
|
|
232
232
|
|
|
233
|
+
const ConversationMessageStreamEvent = `type ConversationMessageStreamPart @aws_cognito_user_pools {
|
|
234
|
+
id: ID!
|
|
235
|
+
owner: String
|
|
236
|
+
conversationId: ID!
|
|
237
|
+
associatedUserMessageId: ID!
|
|
238
|
+
contentBlockIndex: Int!
|
|
239
|
+
contentBlockText: String
|
|
240
|
+
contentBlockDeltaIndex: Int
|
|
241
|
+
contentBlockToolUse: ToolUseBlock
|
|
242
|
+
contentBlockDoneAtIndex: Int
|
|
243
|
+
stopReason: String
|
|
244
|
+
errors: [ConversationTurnError]
|
|
245
|
+
}`;
|
|
246
|
+
|
|
247
|
+
const ConversationTurnError = `type ConversationTurnError @aws_cognito_user_pools {
|
|
248
|
+
message: String!
|
|
249
|
+
errorType: String!
|
|
250
|
+
}`;
|
|
251
|
+
|
|
233
252
|
export const conversationTypes: string[] = [
|
|
234
253
|
ConversationParticipantRole,
|
|
235
254
|
ConversationMessage,
|
|
@@ -262,4 +281,6 @@ export const conversationTypes: string[] = [
|
|
|
262
281
|
Tool,
|
|
263
282
|
ToolSpecification,
|
|
264
283
|
ToolInputSchema,
|
|
284
|
+
ConversationMessageStreamEvent,
|
|
285
|
+
ConversationTurnError,
|
|
265
286
|
];
|
|
@@ -12,6 +12,7 @@ import {
|
|
|
12
12
|
} from './types/ConversationMessageContent';
|
|
13
13
|
import { ToolConfiguration } from './types/ToolConfiguration';
|
|
14
14
|
import { AiModel } from '@aws-amplify/data-schema-types';
|
|
15
|
+
import { ConversationStreamErrorEvent, ConversationStreamEvent } from './types/ConversationStreamEvent';
|
|
15
16
|
|
|
16
17
|
export const brandName = 'conversationCustomOperation';
|
|
17
18
|
|
|
@@ -22,6 +23,7 @@ export interface ConversationMessage {
|
|
|
22
23
|
createdAt: string;
|
|
23
24
|
id: string;
|
|
24
25
|
role: 'user' | 'assistant';
|
|
26
|
+
associatedUserMessageId?: string;
|
|
25
27
|
}
|
|
26
28
|
|
|
27
29
|
// conversation route types
|
|
@@ -104,7 +106,10 @@ interface ConversationListMessagesInput {
|
|
|
104
106
|
nextToken?: string | null;
|
|
105
107
|
}
|
|
106
108
|
|
|
107
|
-
type
|
|
109
|
+
type ConversationOnStreamEventHandler = {
|
|
110
|
+
next: (event: ConversationStreamEvent) => void;
|
|
111
|
+
error: (error: ConversationStreamErrorEvent) => void;
|
|
112
|
+
};
|
|
108
113
|
|
|
109
114
|
export interface Conversation {
|
|
110
115
|
id: string;
|
|
@@ -132,9 +137,9 @@ export interface Conversation {
|
|
|
132
137
|
/**
|
|
133
138
|
* @experimental
|
|
134
139
|
*
|
|
135
|
-
* Subscribes to new
|
|
140
|
+
* Subscribes to new stream events on the current conversation.
|
|
136
141
|
*/
|
|
137
|
-
|
|
142
|
+
onStreamEvent: (handler: ConversationOnStreamEventHandler) => Subscription;
|
|
138
143
|
}
|
|
139
144
|
|
|
140
145
|
// schema definition input
|
|
@@ -185,3 +190,5 @@ function _conversation(input: ConversationInput): ConversationType {
|
|
|
185
190
|
export function conversation(input: ConversationInput): ConversationType {
|
|
186
191
|
return _conversation(input);
|
|
187
192
|
}
|
|
193
|
+
export { ConversationStreamEvent };
|
|
194
|
+
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
2
|
+
// SPDX-License-Identifier: Apache-2.0
|
|
3
|
+
|
|
4
|
+
import { ToolUseBlock } from "./contentBlocks";
|
|
5
|
+
|
|
6
|
+
export interface ConversationStreamTextEvent {
|
|
7
|
+
id: string;
|
|
8
|
+
conversationId: string;
|
|
9
|
+
associatedUserMessageId: string;
|
|
10
|
+
contentBlockIndex: number;
|
|
11
|
+
contentBlockDeltaIndex: number;
|
|
12
|
+
contentBlockDoneAtIndex?: never;
|
|
13
|
+
text: string;
|
|
14
|
+
toolUse?: never;
|
|
15
|
+
stopReason?: never;
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
export interface ConversationStreamToolUseEvent {
|
|
19
|
+
id: string;
|
|
20
|
+
conversationId: string;
|
|
21
|
+
associatedUserMessageId: string;
|
|
22
|
+
contentBlockIndex: number;
|
|
23
|
+
contentBlockDeltaIndex?: never;
|
|
24
|
+
contentBlockDoneAtIndex?: never;
|
|
25
|
+
text?: never;
|
|
26
|
+
toolUse: ToolUseBlock;
|
|
27
|
+
stopReason?: never;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
export interface ConversationStreamDoneAtIndexEvent {
|
|
31
|
+
id: string;
|
|
32
|
+
conversationId: string;
|
|
33
|
+
associatedUserMessageId: string;
|
|
34
|
+
contentBlockIndex: number;
|
|
35
|
+
contentBlockDoneAtIndex: number;
|
|
36
|
+
contentBlockDeltaIndex?: never;
|
|
37
|
+
text?: never;
|
|
38
|
+
toolUse?: never;
|
|
39
|
+
stopReason?: never;
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
export interface ConversationStreamTurnDoneEvent {
|
|
43
|
+
id: string;
|
|
44
|
+
conversationId: string;
|
|
45
|
+
associatedUserMessageId: string;
|
|
46
|
+
contentBlockIndex: number;
|
|
47
|
+
contentBlockDoneAtIndex?: never;
|
|
48
|
+
contentBlockDeltaIndex?: never;
|
|
49
|
+
text?: never;
|
|
50
|
+
toolUse?: never;
|
|
51
|
+
stopReason: string;
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
export interface ConversationStreamErrorEvent {
|
|
55
|
+
id: string;
|
|
56
|
+
conversationId: string;
|
|
57
|
+
associatedUserMessageId: string;
|
|
58
|
+
errors: ConversationTurnError[]
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
export interface ConversationTurnError {
|
|
62
|
+
message: string;
|
|
63
|
+
errorType: string;
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
export type ConversationStreamEvent =
|
|
67
|
+
| ConversationStreamTextEvent
|
|
68
|
+
| ConversationStreamToolUseEvent
|
|
69
|
+
| ConversationStreamDoneAtIndexEvent
|
|
70
|
+
| ConversationStreamTurnDoneEvent;
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
2
|
+
// SPDX-License-Identifier: Apache-2.0
|
|
3
|
+
|
|
4
|
+
import { ConversationStreamEvent } from "../../../ai/ConversationType";
|
|
5
|
+
import { ToolUseBlock } from "../../../ai/types/contentBlocks";
|
|
6
|
+
import { ConversationStreamErrorEvent } from "../../../ai/types/ConversationStreamEvent";
|
|
7
|
+
|
|
8
|
+
export const convertItemToConversationStreamEvent = ({
|
|
9
|
+
id,
|
|
10
|
+
conversationId,
|
|
11
|
+
associatedUserMessageId,
|
|
12
|
+
contentBlockIndex,
|
|
13
|
+
contentBlockDoneAtIndex,
|
|
14
|
+
contentBlockDeltaIndex,
|
|
15
|
+
contentBlockText,
|
|
16
|
+
contentBlockToolUse,
|
|
17
|
+
stopReason,
|
|
18
|
+
errors,
|
|
19
|
+
}: any): { next?: ConversationStreamEvent, error?: ConversationStreamErrorEvent } => {
|
|
20
|
+
if (errors) {
|
|
21
|
+
const error = {
|
|
22
|
+
id,
|
|
23
|
+
conversationId,
|
|
24
|
+
associatedUserMessageId,
|
|
25
|
+
errors,
|
|
26
|
+
};
|
|
27
|
+
return { error };
|
|
28
|
+
}
|
|
29
|
+
const next = removeNullsFromConversationStreamEvent({
|
|
30
|
+
id,
|
|
31
|
+
conversationId,
|
|
32
|
+
associatedUserMessageId,
|
|
33
|
+
contentBlockIndex,
|
|
34
|
+
contentBlockDoneAtIndex,
|
|
35
|
+
contentBlockDeltaIndex,
|
|
36
|
+
text: contentBlockText,
|
|
37
|
+
toolUse: deserializeToolUseBlock(contentBlockToolUse),
|
|
38
|
+
stopReason,
|
|
39
|
+
});
|
|
40
|
+
|
|
41
|
+
return { next };
|
|
42
|
+
};
|
|
43
|
+
|
|
44
|
+
const deserializeToolUseBlock = (
|
|
45
|
+
contentBlockToolUse: any,
|
|
46
|
+
): ToolUseBlock | undefined => {
|
|
47
|
+
if (contentBlockToolUse) {
|
|
48
|
+
const toolUseBlock = {
|
|
49
|
+
...contentBlockToolUse,
|
|
50
|
+
input: JSON.parse(contentBlockToolUse.input),
|
|
51
|
+
};
|
|
52
|
+
|
|
53
|
+
return toolUseBlock;
|
|
54
|
+
}
|
|
55
|
+
};
|
|
56
|
+
|
|
57
|
+
const removeNullsFromConversationStreamEvent = (
|
|
58
|
+
block: ConversationStreamEvent,
|
|
59
|
+
): ConversationStreamEvent =>
|
|
60
|
+
Object.fromEntries(
|
|
61
|
+
Object.entries(block).filter(([_, v]) => v !== null),
|
|
62
|
+
) as ConversationStreamEvent;
|
|
@@ -10,7 +10,7 @@ import type {
|
|
|
10
10
|
SchemaModel,
|
|
11
11
|
} from '../../bridge-types';
|
|
12
12
|
import { createListMessagesFunction } from './createListMessagesFunction';
|
|
13
|
-
import {
|
|
13
|
+
import { createOnStreamEventFunction } from './createOnStreamEventFunction';
|
|
14
14
|
import { createSendMessageFunction } from './createSendMessageFunction';
|
|
15
15
|
|
|
16
16
|
export const convertItemToConversation = (
|
|
@@ -36,7 +36,7 @@ export const convertItemToConversation = (
|
|
|
36
36
|
updatedAt: conversationUpdatedAt,
|
|
37
37
|
metadata: conversationMetadata,
|
|
38
38
|
name: conversationName,
|
|
39
|
-
|
|
39
|
+
onStreamEvent: createOnStreamEventFunction(
|
|
40
40
|
client as BaseBrowserClient,
|
|
41
41
|
modelIntrospection,
|
|
42
42
|
conversationId,
|
package/src/runtime/internals/ai/{createOnMessageFunction.ts → createOnStreamEventFunction.ts}
RENAMED
|
@@ -9,17 +9,17 @@ import {
|
|
|
9
9
|
ModelIntrospectionSchema,
|
|
10
10
|
} from '../../bridge-types';
|
|
11
11
|
import { customOpFactory } from '../operations/custom';
|
|
12
|
-
import { convertItemToConversationMessage } from './convertItemToConversationMessage';
|
|
13
12
|
import { AiAction, getCustomUserAgentDetails } from './getCustomUserAgentDetails';
|
|
13
|
+
import { convertItemToConversationStreamEvent } from './conversationStreamEventDeserializers';
|
|
14
14
|
|
|
15
|
-
export const
|
|
15
|
+
export const createOnStreamEventFunction =
|
|
16
16
|
(
|
|
17
17
|
client: BaseClient,
|
|
18
18
|
modelIntrospection: ModelIntrospectionSchema,
|
|
19
19
|
conversationId: string,
|
|
20
20
|
conversationRouteName: string,
|
|
21
21
|
getInternals: ClientInternalsGetter,
|
|
22
|
-
): Conversation['
|
|
22
|
+
): Conversation['onStreamEvent'] =>
|
|
23
23
|
(handler): Subscription => {
|
|
24
24
|
const { conversations } = modelIntrospection;
|
|
25
25
|
// Safe guard for standalone function. When called as part of client generation, this should never be falsy.
|
|
@@ -35,9 +35,11 @@ export const createOnMessageFunction =
|
|
|
35
35
|
subscribeSchema,
|
|
36
36
|
false,
|
|
37
37
|
getInternals,
|
|
38
|
-
getCustomUserAgentDetails(AiAction.
|
|
38
|
+
getCustomUserAgentDetails(AiAction.OnStreamEvent),
|
|
39
39
|
) as (args?: Record<string, any>) => Observable<any>;
|
|
40
40
|
return subscribeOperation({ conversationId }).subscribe((data) => {
|
|
41
|
-
|
|
41
|
+
const { next, error } = convertItemToConversationStreamEvent(data);
|
|
42
|
+
if (error) handler.error(error);
|
|
43
|
+
if (next) handler.next(next);
|
|
42
44
|
});
|
|
43
45
|
};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"createOnMessageFunction.js","sources":["../../../../../src/runtime/internals/ai/createOnMessageFunction.ts"],"sourcesContent":["\"use strict\";\n// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.createOnMessageFunction = void 0;\nconst custom_1 = require(\"../operations/custom\");\nconst convertItemToConversationMessage_1 = require(\"./convertItemToConversationMessage\");\nconst getCustomUserAgentDetails_1 = require(\"./getCustomUserAgentDetails\");\nconst createOnMessageFunction = (client, modelIntrospection, conversationId, conversationRouteName, getInternals) => (handler) => {\n const { conversations } = modelIntrospection;\n // Safe guard for standalone function. When called as part of client generation, this should never be falsy.\n if (!conversations) {\n return {};\n }\n const subscribeSchema = conversations[conversationRouteName].message.subscribe;\n const subscribeOperation = (0, custom_1.customOpFactory)(client, modelIntrospection, 'subscription', subscribeSchema, false, getInternals, (0, getCustomUserAgentDetails_1.getCustomUserAgentDetails)(getCustomUserAgentDetails_1.AiAction.OnMessage));\n return subscribeOperation({ conversationId }).subscribe((data) => {\n handler((0, convertItemToConversationMessage_1.convertItemToConversationMessage)(data));\n });\n};\nexports.createOnMessageFunction = createOnMessageFunction;\n"],"names":[],"mappings":";;AACA;AACA;AACA,MAAM,CAAC,cAAc,CAAC,OAAO,EAAE,YAAY,EAAE,EAAE,KAAK,EAAE,IAAI,EAAE,CAAC,CAAC;AAC9D,OAAO,CAAC,uBAAuB,GAAG,KAAK,CAAC,CAAC;AACzC,MAAM,QAAQ,GAAG,OAAO,CAAC,sBAAsB,CAAC,CAAC;AACjD,MAAM,kCAAkC,GAAG,OAAO,CAAC,oCAAoC,CAAC,CAAC;AACzF,MAAM,2BAA2B,GAAG,OAAO,CAAC,6BAA6B,CAAC,CAAC;AAC3E,MAAM,uBAAuB,GAAG,CAAC,MAAM,EAAE,kBAAkB,EAAE,cAAc,EAAE,qBAAqB,EAAE,YAAY,KAAK,CAAC,OAAO,KAAK;AAClI,IAAI,MAAM,EAAE,aAAa,EAAE,GAAG,kBAAkB,CAAC;AACjD;AACA,IAAI,IAAI,CAAC,aAAa,EAAE;AACxB,QAAQ,OAAO,EAAE,CAAC;AAClB,KAAK;AACL,IAAI,MAAM,eAAe,GAAG,aAAa,CAAC,qBAAqB,CAAC,CAAC,OAAO,CAAC,SAAS,CAAC;AACnF,IAAI,MAAM,kBAAkB,GAAG,IAAI,QAAQ,CAAC,eAAe,EAAE,MAAM,EAAE,kBAAkB,EAAE,cAAc,EAAE,eAAe,EAAE,KAAK,EAAE,YAAY,EAAE,IAAI,2BAA2B,CAAC,yBAAyB,EAAE,2BAA2B,CAAC,QAAQ,CAAC,SAAS,CAAC,CAAC,CAAC;AAC3P,IAAI,OAAO,kBAAkB,CAAC,EAAE,cAAc,EAAE,CAAC,CAAC,SAAS,CAAC,CAAC,IAAI,KAAK;AACtE,QAAQ,OAAO,CAAC,IAAI,kCAAkC,CAAC,gCAAgC,EAAE,IAAI,CAAC,CAAC,CAAC;AAChG,KAAK,CAAC,CAAC;AACP,CAAC,CAAC;AACF,OAAO,CAAC,uBAAuB,GAAG,uBAAuB;;"}
|
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
import type { Conversation } from '../../../ai/ConversationType';
|
|
2
|
-
import { BaseClient, ClientInternalsGetter, ModelIntrospectionSchema } from '../../bridge-types';
|
|
3
|
-
export declare const createOnMessageFunction: (client: BaseClient, modelIntrospection: ModelIntrospectionSchema, conversationId: string, conversationRouteName: string, getInternals: ClientInternalsGetter) => Conversation['onMessage'];
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"createOnMessageFunction.mjs","sources":["../../../../../src/runtime/internals/ai/createOnMessageFunction.ts"],"sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\nimport { customOpFactory } from '../operations/custom';\nimport { convertItemToConversationMessage } from './convertItemToConversationMessage';\nimport { AiAction, getCustomUserAgentDetails } from './getCustomUserAgentDetails';\nexport const createOnMessageFunction = (client, modelIntrospection, conversationId, conversationRouteName, getInternals) => (handler) => {\n const { conversations } = modelIntrospection;\n // Safe guard for standalone function. When called as part of client generation, this should never be falsy.\n if (!conversations) {\n return {};\n }\n const subscribeSchema = conversations[conversationRouteName].message.subscribe;\n const subscribeOperation = customOpFactory(client, modelIntrospection, 'subscription', subscribeSchema, false, getInternals, getCustomUserAgentDetails(AiAction.OnMessage));\n return subscribeOperation({ conversationId }).subscribe((data) => {\n handler(convertItemToConversationMessage(data));\n });\n};\n"],"names":[],"mappings":";;;;AAAA;AACA;AAIY,MAAC,uBAAuB,GAAG,CAAC,MAAM,EAAE,kBAAkB,EAAE,cAAc,EAAE,qBAAqB,EAAE,YAAY,KAAK,CAAC,OAAO,KAAK;AACzI,IAAI,MAAM,EAAE,aAAa,EAAE,GAAG,kBAAkB,CAAC;AACjD;AACA,IAAI,IAAI,CAAC,aAAa,EAAE;AACxB,QAAQ,OAAO,EAAE,CAAC;AAClB,KAAK;AACL,IAAI,MAAM,eAAe,GAAG,aAAa,CAAC,qBAAqB,CAAC,CAAC,OAAO,CAAC,SAAS,CAAC;AACnF,IAAI,MAAM,kBAAkB,GAAG,eAAe,CAAC,MAAM,EAAE,kBAAkB,EAAE,cAAc,EAAE,eAAe,EAAE,KAAK,EAAE,YAAY,EAAE,yBAAyB,CAAC,QAAQ,CAAC,SAAS,CAAC,CAAC,CAAC;AAChL,IAAI,OAAO,kBAAkB,CAAC,EAAE,cAAc,EAAE,CAAC,CAAC,SAAS,CAAC,CAAC,IAAI,KAAK;AACtE,QAAQ,OAAO,CAAC,gCAAgC,CAAC,IAAI,CAAC,CAAC,CAAC;AACxD,KAAK,CAAC,CAAC;AACP;;;;"}
|