@economic/agents-react 1.1.6 → 1.1.7
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/index.d.mts +17 -10
- package/dist/index.mjs +1 -1
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -214,6 +214,20 @@ type AgentConnectionState = {
|
|
|
214
214
|
type: AgentConnectionType;
|
|
215
215
|
subAgentName?: string;
|
|
216
216
|
};
|
|
217
|
+
type ChatSummary = {
|
|
218
|
+
name: string;
|
|
219
|
+
title?: string;
|
|
220
|
+
summary?: string;
|
|
221
|
+
created_at: number;
|
|
222
|
+
updated_at: number;
|
|
223
|
+
};
|
|
224
|
+
type MessageRating = {
|
|
225
|
+
message_id: string;
|
|
226
|
+
rating: number;
|
|
227
|
+
comment?: string;
|
|
228
|
+
created_at: number;
|
|
229
|
+
updated_at: number;
|
|
230
|
+
};
|
|
217
231
|
//#endregion
|
|
218
232
|
//#region src/useAgent.d.ts
|
|
219
233
|
interface UseAgentOptions {
|
|
@@ -284,17 +298,10 @@ declare function useChat<ToolContext extends Record<string, unknown>>(options: U
|
|
|
284
298
|
isToolContinuation: boolean;
|
|
285
299
|
};
|
|
286
300
|
rateMessage: (messageId: string, rating: number, comment?: string) => Promise<unknown>;
|
|
287
|
-
getMessageRatings: () => Promise<
|
|
301
|
+
getMessageRatings: () => Promise<MessageRating[]>;
|
|
288
302
|
};
|
|
289
303
|
//#endregion
|
|
290
304
|
//#region src/useAssistant.d.ts
|
|
291
|
-
type ChatSummary = {
|
|
292
|
-
name: string;
|
|
293
|
-
title?: string;
|
|
294
|
-
summary?: string;
|
|
295
|
-
created_at: number;
|
|
296
|
-
updated_at: number;
|
|
297
|
-
};
|
|
298
305
|
interface UseAssistantOptions<ToolContext extends Record<string, unknown> = Record<string, unknown>> extends Omit<UseChatOptions<ToolContext>, "actorId" | "getInitialMessages"> {}
|
|
299
306
|
declare function useAssistant<ToolContext extends Record<string, unknown>>(options: UseAssistantOptions<ToolContext>): {
|
|
300
307
|
currentChatName: string | undefined;
|
|
@@ -336,8 +343,8 @@ declare function useAssistant<ToolContext extends Record<string, unknown>>(optio
|
|
|
336
343
|
isToolContinuation: boolean;
|
|
337
344
|
};
|
|
338
345
|
rateMessage: (messageId: string, rating: number, comment?: string) => Promise<unknown>;
|
|
339
|
-
getMessageRatings: () => Promise<
|
|
346
|
+
getMessageRatings: () => Promise<MessageRating[]>;
|
|
340
347
|
};
|
|
341
348
|
};
|
|
342
349
|
//#endregion
|
|
343
|
-
export { type AgentConnectionState, type AgentConnectionStatus, type AgentConnectionType, type ChatSummary, useAgent, useAssistant, useChat };
|
|
350
|
+
export { type AgentConnectionState, type AgentConnectionStatus, type AgentConnectionType, type ChatSummary, type MessageRating, useAgent, useAssistant, useChat };
|
package/dist/index.mjs
CHANGED