@wix/auto_sdk_legends_persona-chats 1.0.20 → 1.0.21

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.
@@ -1307,6 +1307,24 @@ interface SendChatMessageStreamedRequest {
1307
1307
  conversationLanguage?: string | null;
1308
1308
  /** Whether a Preview text answer cites the Knowledge items it used, in ChatMessage.citations. Ignored in other chats. */
1309
1309
  includeCitations?: boolean;
1310
+ /**
1311
+ * Function call results from the client, answering the function calls the previous request streamed. Read only with
1312
+ * stream_tool_turns.
1313
+ * @maxSize 30
1314
+ */
1315
+ functionCallResults?: FunctionCallResult[];
1316
+ /**
1317
+ * Tools the client can run, as in SendChatMessageRequest.client_tools. Read only with stream_tool_turns.
1318
+ * @maxSize 32
1319
+ */
1320
+ clientTools?: ClientToolDefinition[];
1321
+ /**
1322
+ * Stream tool turns: the request gets the tools the unary SendChatMessage would (chat_config.enabled_tool_names), its text
1323
+ * streams as {"content":…} frames while the model writes, and the turn ends with {"functionCalls":[…]} then
1324
+ * {"turn":"awaitingToolResults"}, or with {"turn":"ended","reply":…,"messageId":…}; {"textReset":true} clears the text shown
1325
+ * so far. Off (the default): the stream is as before, text frames only.
1326
+ */
1327
+ streamToolTurns?: boolean;
1310
1328
  }
1311
1329
  interface RawHttpResponse {
1312
1330
  body?: Uint8Array;
@@ -2823,6 +2841,24 @@ interface SendChatMessageStreamedOptions {
2823
2841
  conversationLanguage?: string | null;
2824
2842
  /** Whether a Preview text answer cites the Knowledge items it used, in ChatMessage.citations. Ignored in other chats. */
2825
2843
  includeCitations?: boolean;
2844
+ /**
2845
+ * Function call results from the client, answering the function calls the previous request streamed. Read only with
2846
+ * stream_tool_turns.
2847
+ * @maxSize 30
2848
+ */
2849
+ functionCallResults?: FunctionCallResult[];
2850
+ /**
2851
+ * Tools the client can run, as in SendChatMessageRequest.client_tools. Read only with stream_tool_turns.
2852
+ * @maxSize 32
2853
+ */
2854
+ clientTools?: ClientToolDefinition[];
2855
+ /**
2856
+ * Stream tool turns: the request gets the tools the unary SendChatMessage would (chat_config.enabled_tool_names), its text
2857
+ * streams as {"content":…} frames while the model writes, and the turn ends with {"functionCalls":[…]} then
2858
+ * {"turn":"awaitingToolResults"}, or with {"turn":"ended","reply":…,"messageId":…}; {"textReset":true} clears the text shown
2859
+ * so far. Off (the default): the stream is as before, text frames only.
2860
+ */
2861
+ streamToolTurns?: boolean;
2826
2862
  }
2827
2863
  /**
2828
2864
  * Persist a conversation message without running LLM orchestration.
@@ -1165,7 +1165,10 @@ async function sendChatMessageStreamed2(options) {
1165
1165
  metadata: options?.metadata,
1166
1166
  namespaceV2: options?.namespaceV2,
1167
1167
  conversationLanguage: options?.conversationLanguage,
1168
- includeCitations: options?.includeCitations
1168
+ includeCitations: options?.includeCitations,
1169
+ functionCallResults: options?.functionCallResults,
1170
+ clientTools: options?.clientTools,
1171
+ streamToolTurns: options?.streamToolTurns
1169
1172
  });
1170
1173
  const reqOpts = sendChatMessageStreamed(payload);
1171
1174
  sideEffects?.onSiteCall?.();
@@ -1187,7 +1190,10 @@ async function sendChatMessageStreamed2(options) {
1187
1190
  metadata: "$[0].metadata",
1188
1191
  namespaceV2: "$[0].namespaceV2",
1189
1192
  conversationLanguage: "$[0].conversationLanguage",
1190
- includeCitations: "$[0].includeCitations"
1193
+ includeCitations: "$[0].includeCitations",
1194
+ functionCallResults: "$[0].functionCallResults",
1195
+ clientTools: "$[0].clientTools",
1196
+ streamToolTurns: "$[0].streamToolTurns"
1191
1197
  },
1192
1198
  singleArgumentUnchanged: false
1193
1199
  },