@squidcloud/client 1.0.315 → 1.0.317
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/index.js +1 -1
- package/dist/internal-common/src/public-types/{ai-chatbot.public-types.d.ts → ai-agent.public-types.d.ts} +45 -15
- package/dist/internal-common/src/public-types/ai-assistant.public-types.d.ts +1 -1
- package/dist/internal-common/src/public-types/ai-matchmaking.types.d.ts +1 -1
- package/dist/internal-common/src/public-types/integrations/{ai_chatbot.public-types.d.ts → ai_agent.public-types.d.ts} +6 -7
- package/dist/typescript-client/src/admin-client.d.ts +0 -4
- package/dist/typescript-client/src/ai-agent-client.d.ts +76 -74
- package/dist/typescript-client/src/ai-matchmaking-client.d.ts +0 -2
- package/dist/typescript-client/src/ai.types.d.ts +1 -0
- package/dist/typescript-client/src/personal-storage-client.d.ts +1 -1
- package/dist/typescript-client/src/public-types.d.ts +2 -2
- package/dist/typescript-client/src/version.d.ts +1 -1
- package/package.json +1 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { FunctionName, FunctionNameWithContext } from './bundle-data.public-types';
|
|
2
2
|
import { AiAgentId, IntegrationId } from './communication.public-types';
|
|
3
|
-
import {
|
|
3
|
+
import { IntegrationType } from './integration.public-types';
|
|
4
4
|
/** The supported OpenAI models */
|
|
5
5
|
export declare const OPENAI_CHAT_MODEL_NAMES: readonly ["gpt-4o", "gpt-4o-mini", "o1", "o1-mini", "o3-mini"];
|
|
6
6
|
export declare const GEMINI_CHAT_MODEL_NAMES: readonly ["gemini-1.5-pro", "gemini-1.5-flash"];
|
|
@@ -105,14 +105,44 @@ export interface AiFileUrl {
|
|
|
105
105
|
type: AiFileUrlType;
|
|
106
106
|
url: string;
|
|
107
107
|
}
|
|
108
|
-
|
|
109
|
-
|
|
108
|
+
export interface AiConnectedIntegrationMetadata {
|
|
109
|
+
integrationId: IntegrationId;
|
|
110
|
+
/** Type of the connected integration. */
|
|
111
|
+
integrationType: IntegrationType;
|
|
112
|
+
/**
|
|
113
|
+
* Description of the connected integration for the parent agent context.
|
|
114
|
+
* Works as AI function description.
|
|
115
|
+
* If not provided the default one is used.
|
|
116
|
+
*/
|
|
117
|
+
description?: string;
|
|
118
|
+
}
|
|
119
|
+
export interface AiConnectedAgentMetadata {
|
|
120
|
+
agentId: AiAgentId;
|
|
121
|
+
/**
|
|
122
|
+
* Description of the connected agent for the parent agent context.
|
|
123
|
+
* Works as AI function description.
|
|
124
|
+
*/
|
|
125
|
+
description: string;
|
|
126
|
+
}
|
|
127
|
+
/** Quotas for a single AI chat prompt (`ask()` method call). */
|
|
128
|
+
export interface AiChatPromptQuotas {
|
|
129
|
+
/**
|
|
130
|
+
* Maximum depth of AI call recursion allowed.
|
|
131
|
+
* Recursion occurs when one AI agent calls another.
|
|
132
|
+
* Note that, for simplicity of implementation, this option guarantees only the maximum recursion depth,
|
|
133
|
+
* not the total number of nested AI calls.
|
|
134
|
+
* Default: 5.
|
|
135
|
+
*/
|
|
136
|
+
maxAiCallStackSize: number;
|
|
137
|
+
}
|
|
138
|
+
/** The options for the AI chat method. */
|
|
139
|
+
export interface AiAgentChatOptions {
|
|
110
140
|
/** The maximum number of tokens to use when making the request to the AI model. Default to the max tokens the model can accept. */
|
|
111
141
|
maxTokens?: number;
|
|
112
142
|
/** A unique chat ID, if the same chat ID is used again and history is not disabled, it will continue the conversation. */
|
|
113
143
|
chatId?: string;
|
|
114
144
|
/**
|
|
115
|
-
* Disables history for the
|
|
145
|
+
* Disables history for the agent, so each question is answered as
|
|
116
146
|
* if it were the first question in the conversation.
|
|
117
147
|
* Default to false.
|
|
118
148
|
*/
|
|
@@ -188,7 +218,7 @@ export interface AiTranscribeAndAskWithVoiceResponse {
|
|
|
188
218
|
export interface AiTranscribeAndChatResponse {
|
|
189
219
|
transcribedPrompt: string;
|
|
190
220
|
}
|
|
191
|
-
/** The options for the AI
|
|
221
|
+
/** The options for the AI agent search method. */
|
|
192
222
|
export interface AiSearchOptions {
|
|
193
223
|
/** The prompt to search for */
|
|
194
224
|
prompt: string;
|
|
@@ -202,11 +232,11 @@ export interface AiSearchRequest {
|
|
|
202
232
|
profileId: string;
|
|
203
233
|
integrationId: IntegrationId;
|
|
204
234
|
}
|
|
205
|
-
export type
|
|
206
|
-
export type
|
|
207
|
-
export type
|
|
208
|
-
export interface
|
|
209
|
-
type:
|
|
235
|
+
export type AiMutationType = 'insert' | 'update' | 'delete' | 'append' | 'feedback';
|
|
236
|
+
export type AiResourceType = 'instruction' | 'profile' | 'context' | 'contexts';
|
|
237
|
+
export type AiAgentContextType = 'text' | 'url' | 'file';
|
|
238
|
+
export interface AiAgentContextBase {
|
|
239
|
+
type: AiAgentContextType;
|
|
210
240
|
data: string;
|
|
211
241
|
metadata?: AiContextMetadata;
|
|
212
242
|
password?: string;
|
|
@@ -219,16 +249,16 @@ export interface AiSearchResultChunk {
|
|
|
219
249
|
metadata?: AiContextMetadata;
|
|
220
250
|
score: number;
|
|
221
251
|
}
|
|
222
|
-
export interface
|
|
252
|
+
export interface AiAgentTextContext extends AiAgentContextBase {
|
|
223
253
|
type: 'text';
|
|
224
254
|
}
|
|
225
|
-
export interface
|
|
255
|
+
export interface AiAgentUrlContext extends AiAgentContextBase {
|
|
226
256
|
type: 'url';
|
|
227
257
|
extractImages?: boolean;
|
|
228
258
|
minImageWidth?: number;
|
|
229
259
|
minImageHeight?: number;
|
|
230
260
|
}
|
|
231
|
-
export interface
|
|
261
|
+
export interface AiAgentFileContext extends AiAgentContextBase {
|
|
232
262
|
type: 'file';
|
|
233
263
|
extractImages?: boolean;
|
|
234
264
|
minImageWidth?: number;
|
|
@@ -236,11 +266,11 @@ export interface AiChatbotFileContext extends AiChatbotContextBase {
|
|
|
236
266
|
fullPageAsImage?: boolean;
|
|
237
267
|
extractionModel?: AiChatModelName;
|
|
238
268
|
}
|
|
239
|
-
export declare class
|
|
269
|
+
export declare class AiAgentChatContext {
|
|
240
270
|
readonly prompt?: string;
|
|
241
271
|
readonly profileId: AiAgentId;
|
|
242
272
|
}
|
|
243
|
-
export type
|
|
273
|
+
export type AiAgentContext = AiAgentTextContext | AiAgentUrlContext | AiAgentFileContext;
|
|
244
274
|
export type AiContextMetadataValue = number | string | boolean | undefined;
|
|
245
275
|
export type AiContextMetadataValueArray = AiContextMetadataValue[];
|
|
246
276
|
export interface AiContextMetadataEqFilter {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { OpenAiResponseFormat } from './ai-
|
|
1
|
+
import { OpenAiResponseFormat } from './ai-agent.public-types';
|
|
2
2
|
import { FunctionName } from './bundle-data.public-types';
|
|
3
3
|
export type AssistantToolType = 'code_interpreter' | 'file_search';
|
|
4
4
|
/** The options for the AI assistant. */
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { AiContextMetadata, AiContextMetadataFilter } from './ai-
|
|
1
|
+
import { AiContextMetadata, AiContextMetadataFilter } from './ai-agent.public-types';
|
|
2
2
|
/**
|
|
3
3
|
* Represents a category in the matchmaker.
|
|
4
4
|
* The description is used by the AI to extract features from the content.
|
|
@@ -1,10 +1,9 @@
|
|
|
1
|
-
import { AiChatModelName, AiEmbeddingsModelName, VectorDbType } from '../ai-
|
|
1
|
+
import { AiChatModelName, AiConnectedAgentMetadata, AiConnectedIntegrationMetadata, AiEmbeddingsModelName, VectorDbType } from '../ai-agent.public-types';
|
|
2
2
|
import { FunctionName } from '../bundle-data.public-types';
|
|
3
|
-
|
|
4
|
-
export type AiChatbotConfiguration = {
|
|
3
|
+
export type AiAgentConfiguration = {
|
|
5
4
|
apiKey?: string;
|
|
6
5
|
};
|
|
7
|
-
export type
|
|
6
|
+
export type AiAgentMetadata = {
|
|
8
7
|
modelName: AiChatModelName;
|
|
9
8
|
description?: string;
|
|
10
9
|
isPublic: boolean;
|
|
@@ -23,13 +22,13 @@ export type AiChatbotProfileMetadata = {
|
|
|
23
22
|
connectedIntegrations?: Array<AiConnectedIntegrationMetadata>;
|
|
24
23
|
auditLog?: boolean;
|
|
25
24
|
};
|
|
26
|
-
export type
|
|
25
|
+
export type AiAgentContextMetadata = {
|
|
27
26
|
title: string;
|
|
28
27
|
text: string;
|
|
29
28
|
preview: boolean;
|
|
30
29
|
sizeBytes?: number;
|
|
31
30
|
type?: 'text' | 'url' | 'file';
|
|
32
31
|
};
|
|
33
|
-
export type
|
|
32
|
+
export type MutableAiAgentMetadataFieldsType = keyof Pick<AiAgentMetadata, 'modelName' | 'description' | 'isPublic' | 'functions' | 'connectedAgents' | 'connectedIntegrations' | 'auditLog'>;
|
|
34
33
|
/** List of fields that can be updated in runtime via API. */
|
|
35
|
-
export declare const
|
|
34
|
+
export declare const MUTABLE_AI_AGENT_METADATA_FIELDS: Array<MutableAiAgentMetadataFieldsType>;
|
|
@@ -1,15 +1,11 @@
|
|
|
1
1
|
import { IntegrationClient } from './integration-client';
|
|
2
|
-
import { RpcManager } from './rpc.manager';
|
|
3
2
|
import { SecretClient } from './secret.client';
|
|
4
|
-
import { SquidRegion } from '../../internal-common/src/public-types/regions.public-types';
|
|
5
|
-
import { AppId } from '../../internal-common/src/public-types/communication.public-types';
|
|
6
3
|
export declare class AdminClient {
|
|
7
4
|
private readonly rpcManager;
|
|
8
5
|
private readonly region;
|
|
9
6
|
private readonly appId;
|
|
10
7
|
private readonly integrationClient;
|
|
11
8
|
private readonly secretClient;
|
|
12
|
-
constructor(rpcManager: RpcManager, region: SquidRegion, appId: AppId);
|
|
13
9
|
integrations(): IntegrationClient;
|
|
14
10
|
secrets(): SecretClient;
|
|
15
11
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { AiAgentChatOptions, AiAgentContext, AiAgentId, AiAgentMetadata, AiObserveStatusOptions, AiSearchOptions, AiSearchResponse, AiStatusMessage, AiTranscribeAndAskResponse, AiTranscribeAndChatResponse, MUTABLE_AI_AGENT_METADATA_FIELDS } from './public-types';
|
|
2
2
|
import { Observable } from 'rxjs';
|
|
3
3
|
import { BlobAndFilename } from './types';
|
|
4
4
|
export interface TranscribeAndChatResponse {
|
|
@@ -18,24 +18,24 @@ export interface ChatInternalResponse {
|
|
|
18
18
|
responseStream: Observable<string>;
|
|
19
19
|
serverResponse?: Promise<AiTranscribeAndChatResponse>;
|
|
20
20
|
}
|
|
21
|
-
export type ChatOptionsWithoutVoice = Omit<
|
|
22
|
-
export type AskOptionsWithoutVoice = Omit<
|
|
21
|
+
export type ChatOptionsWithoutVoice = Omit<AiAgentChatOptions, 'voiceOptions'>;
|
|
22
|
+
export type AskOptionsWithoutVoice = Omit<AiAgentChatOptions, 'voiceOptions' | 'smoothTyping'>;
|
|
23
23
|
export declare class AiAgentClient {
|
|
24
24
|
private readonly rpcManager;
|
|
25
25
|
private readonly socketManager;
|
|
26
26
|
private readonly ongoingChatSequences;
|
|
27
27
|
private readonly statusUpdates;
|
|
28
28
|
/**
|
|
29
|
-
* Retrieves a
|
|
30
|
-
* can be used to create and update
|
|
31
|
-
* and
|
|
29
|
+
* Retrieves a reference to an agent with the specified ID.
|
|
30
|
+
* The returned agent reference can be used to create and update the agent,
|
|
31
|
+
* add instructions and context, and initiate chats.
|
|
32
32
|
*
|
|
33
|
-
* @param id - The
|
|
34
|
-
* @returns
|
|
33
|
+
* @param id - The ID of the agent.
|
|
34
|
+
* @returns A reference to the agent.
|
|
35
35
|
*/
|
|
36
|
-
|
|
36
|
+
agent(id: AiAgentId): AiAgentReference;
|
|
37
37
|
/**
|
|
38
|
-
* Sends a prompt to the specified
|
|
38
|
+
* Sends a prompt to the specified agent id.
|
|
39
39
|
*
|
|
40
40
|
* @param agentId - The agent id.
|
|
41
41
|
* @param prompt - The prompt.
|
|
@@ -46,11 +46,11 @@ export declare class AiAgentClient {
|
|
|
46
46
|
chat(agentId: AiAgentId, prompt: string, options?: ChatOptionsWithoutVoice): Observable<string>;
|
|
47
47
|
transcribeAndChat(agentId: AiAgentId, fileToTranscribe: File, options?: ChatOptionsWithoutVoice): Promise<TranscribeAndChatResponse>;
|
|
48
48
|
private chatInternal;
|
|
49
|
-
search(agentId:
|
|
49
|
+
search(agentId: AiAgentId, options: AiSearchOptions): Promise<AiSearchResponse>;
|
|
50
50
|
/**
|
|
51
|
-
* Sends a prompt to the specified
|
|
51
|
+
* Sends a prompt to the specified agent id and returns the response as a Promise of string.
|
|
52
52
|
*
|
|
53
|
-
* @param agentId - The agent id
|
|
53
|
+
* @param agentId - The agent id.
|
|
54
54
|
* @param prompt - The prompt.
|
|
55
55
|
* @param options - The options to send to the chat model.
|
|
56
56
|
* @returns A promise that resolves when the chat is complete. The resolved value is the entire response.
|
|
@@ -58,53 +58,52 @@ export declare class AiAgentClient {
|
|
|
58
58
|
ask(agentId: AiAgentId, prompt: string, options?: AskOptionsWithoutVoice): Promise<string>;
|
|
59
59
|
observeStatusUpdates(agentId: AiAgentId, options?: AiObserveStatusOptions): Observable<AiStatusMessage>;
|
|
60
60
|
transcribeAndAsk(agentId: AiAgentId, fileToTranscribe: File, options?: AskOptionsWithoutVoice): Promise<AiTranscribeAndAskResponse>;
|
|
61
|
-
transcribeAndAskWithVoiceResponse(agentId: AiAgentId, fileToTranscribe: File, options?: Omit<
|
|
62
|
-
askWithVoiceResponse(agentId: AiAgentId, prompt: string, options?: Omit<
|
|
63
|
-
askInternal<T>(agentId: AiAgentId, prompt: string | File, isVoiceResponse: boolean, options?: Omit<
|
|
61
|
+
transcribeAndAskWithVoiceResponse(agentId: AiAgentId, fileToTranscribe: File, options?: Omit<AiAgentChatOptions, 'smoothTyping'>): Promise<TranscribeAndAskWithVoiceResponse>;
|
|
62
|
+
askWithVoiceResponse(agentId: AiAgentId, prompt: string, options?: Omit<AiAgentChatOptions, 'smoothTyping'>): Promise<AskWithVoiceResponse>;
|
|
63
|
+
askInternal<T>(agentId: AiAgentId, prompt: string | File, isVoiceResponse: boolean, options?: Omit<AiAgentChatOptions, 'smoothTyping'>): Promise<T>;
|
|
64
64
|
private handleChatResponse;
|
|
65
65
|
private handleStatusMessage;
|
|
66
66
|
private createStatusSubject;
|
|
67
67
|
}
|
|
68
68
|
export interface AiChatBotContextData {
|
|
69
69
|
title: string;
|
|
70
|
-
context:
|
|
70
|
+
context: AiAgentContext;
|
|
71
71
|
}
|
|
72
72
|
export interface AiChatBotContextDataWithId extends AiChatBotContextData {
|
|
73
73
|
id?: string;
|
|
74
74
|
}
|
|
75
|
-
export type
|
|
75
|
+
export type AiAgentData = Pick<AiAgentMetadata, (typeof MUTABLE_AI_AGENT_METADATA_FIELDS)[number]>;
|
|
76
76
|
export interface InstructionData {
|
|
77
77
|
instruction: string;
|
|
78
78
|
}
|
|
79
79
|
export declare class AiAgentReference {
|
|
80
80
|
private readonly client;
|
|
81
81
|
private readonly integrationId;
|
|
82
|
-
private readonly
|
|
83
|
-
private readonly rpcManager;
|
|
82
|
+
private readonly agentId;
|
|
84
83
|
/**
|
|
85
|
-
* Sends a prompt to the current
|
|
84
|
+
* Sends a prompt to the current agent.
|
|
86
85
|
*
|
|
87
86
|
* @param prompt - The prompt.
|
|
88
87
|
* @param options - The chat options.
|
|
89
88
|
* @returns An observable that emits when a new response token is received. The emitted value is the entire response
|
|
90
89
|
* that has been received so far.
|
|
91
90
|
*/
|
|
92
|
-
chat(prompt: string, options?:
|
|
93
|
-
transcribeAndChat(fileToTranscribe: File, options?:
|
|
91
|
+
chat(prompt: string, options?: AiAgentChatOptions): Observable<string>;
|
|
92
|
+
transcribeAndChat(fileToTranscribe: File, options?: AiAgentChatOptions): Promise<TranscribeAndChatResponse>;
|
|
94
93
|
/**
|
|
95
|
-
* Sends a prompt to the current
|
|
94
|
+
* Sends a prompt to the current agent and returns the response.
|
|
96
95
|
* @param prompt - The prompt.
|
|
97
96
|
* @param options - The chat options.
|
|
98
97
|
*/
|
|
99
|
-
ask(prompt: string, options?: Omit<
|
|
98
|
+
ask(prompt: string, options?: Omit<AiAgentChatOptions, 'smoothTyping'>): Promise<string>;
|
|
100
99
|
observeStatusUpdates(options?: AiObserveStatusOptions): Observable<AiStatusMessage>;
|
|
101
100
|
transcribeAndAsk(fileToTranscribe: File, options?: AskOptionsWithoutVoice): Promise<AiTranscribeAndAskResponse>;
|
|
102
|
-
transcribeAndAskWithVoiceResponse(fileToTranscribe: File, options?: Omit<
|
|
103
|
-
askWithVoiceResponse(prompt: string, options?: Omit<
|
|
101
|
+
transcribeAndAskWithVoiceResponse(fileToTranscribe: File, options?: Omit<AiAgentChatOptions, 'smoothTyping'>): Promise<TranscribeAndAskWithVoiceResponse>;
|
|
102
|
+
askWithVoiceResponse(prompt: string, options?: Omit<AiAgentChatOptions, 'smoothTyping'>): Promise<AskWithVoiceResponse>;
|
|
104
103
|
search(options: AiSearchOptions): Promise<AiSearchResponse>;
|
|
105
104
|
/**
|
|
106
|
-
* Retrieves a context reference for the current
|
|
107
|
-
* to the
|
|
105
|
+
* Retrieves a context reference for the current agent. A context reference can be used to add a new context entry
|
|
106
|
+
* to the agent, or update/delete an existing entry context.
|
|
108
107
|
*
|
|
109
108
|
* @param id - The id of the context entry. If no id is passed, an id will be
|
|
110
109
|
* generated and the reference will point to a new context entry.
|
|
@@ -113,8 +112,8 @@ export declare class AiAgentReference {
|
|
|
113
112
|
context(id?: string): AiAgentContextReference;
|
|
114
113
|
insertContexts(contexts: Array<AiChatBotContextDataWithId>, files?: Array<File | BlobAndFilename>): Promise<void>;
|
|
115
114
|
/**
|
|
116
|
-
* Retrieves an instruction reference for the current
|
|
117
|
-
* instruction entry to the
|
|
115
|
+
* Retrieves an instruction reference for the current agent. An instruction reference can be used to add a new
|
|
116
|
+
* instruction entry to the agent, or update/delete an existing instruction entry.
|
|
118
117
|
*
|
|
119
118
|
* @param id - The id of the instruction entry. If no id is passed, an id will be
|
|
120
119
|
* generated and the reference will point to a new instruction entry.
|
|
@@ -122,32 +121,33 @@ export declare class AiAgentReference {
|
|
|
122
121
|
*/
|
|
123
122
|
instruction(id?: string): AiAgentInstructionReference;
|
|
124
123
|
/**
|
|
125
|
-
*
|
|
124
|
+
* Creates a new AI Agent.
|
|
125
|
+
* This will result in an error if an agent already exists with the same id.
|
|
126
126
|
*
|
|
127
|
-
* @param data An object containing options for creating the
|
|
127
|
+
* @param data An object containing options for creating the agent.
|
|
128
128
|
* @param data.modelName - The name of the AI model (`gpt-3.5, `gpt-4`, `claude-3-5-sonnet-latest` or
|
|
129
129
|
* `claude-3-5-haiku-latest`, `gemini-1.5-pro` `gemini-1.5-flash`).
|
|
130
|
-
* @param data.isPublic - Whether the chat functionality of the
|
|
131
|
-
* @returns A promise that resolves when the
|
|
130
|
+
* @param data.isPublic - Whether the chat functionality of the agent can be accessed without security rules.
|
|
131
|
+
* @returns A promise that resolves when the agent is successfully created.
|
|
132
132
|
*/
|
|
133
|
-
|
|
133
|
+
create(data: AiAgentData): Promise<void>;
|
|
134
134
|
/**
|
|
135
|
-
* Updates an existing
|
|
136
|
-
* current
|
|
135
|
+
* Updates an existing agent.
|
|
136
|
+
* An error will be thrown if the agent has not yet been created for the current agent ID.
|
|
137
137
|
*
|
|
138
|
-
* @param data An object containing options for updating the
|
|
139
|
-
* @param data.modelName - The name of the OpenAI model (`gpt-3.5
|
|
140
|
-
* `claude-3-5-haiku-latest`, `gemini-1.5-pro
|
|
141
|
-
* @param data.isPublic - Whether the chat functionality of the
|
|
142
|
-
* @param file - The file to
|
|
143
|
-
* @returns A promise that resolves when the
|
|
138
|
+
* @param data - An object containing options for updating the agent.
|
|
139
|
+
* @param data.modelName - The name of the OpenAI model (`gpt-3.5`, `gpt-4`, `claude-3-5-sonnet-latest`,
|
|
140
|
+
* `claude-3-5-haiku-latest`, `gemini-1.5-pro`, or `gemini-1.5-flash`).
|
|
141
|
+
* @param data.isPublic - Whether the chat functionality of the agent can be accessed without security rules.
|
|
142
|
+
* @param file - The file to upload (optional).
|
|
143
|
+
* @returns A promise that resolves when the agent is successfully updated.
|
|
144
144
|
*/
|
|
145
|
-
update(data: Partial<
|
|
145
|
+
update(data: Partial<AiAgentData>, file?: File | BlobAndFilename): Promise<void>;
|
|
146
146
|
/**
|
|
147
|
-
* Deletes an existing
|
|
148
|
-
* current
|
|
147
|
+
* Deletes an existing agent.
|
|
148
|
+
* Throws an error if the agent has not been created for the current agent ID.
|
|
149
149
|
*
|
|
150
|
-
* @returns A promise that resolves when the
|
|
150
|
+
* @returns A promise that resolves when the agent is successfully deleted.
|
|
151
151
|
*/
|
|
152
152
|
delete(): Promise<void>;
|
|
153
153
|
feedback(feedback: string): Promise<void>;
|
|
@@ -156,71 +156,73 @@ export declare class AiAgentReference {
|
|
|
156
156
|
export declare class AiAgentContextReference {
|
|
157
157
|
private readonly client;
|
|
158
158
|
private readonly integrationId;
|
|
159
|
-
private readonly
|
|
159
|
+
private readonly agentId;
|
|
160
160
|
private readonly id;
|
|
161
161
|
/**
|
|
162
|
-
* Adds a new context entry to the
|
|
163
|
-
* the same
|
|
162
|
+
* Adds a new context entry to the agent.
|
|
163
|
+
* Throws an error if an entry with the same ID already exists.
|
|
164
164
|
*
|
|
165
|
-
* @param data An object containing options for creating the entry.
|
|
165
|
+
* @param data - An object containing options for creating the entry.
|
|
166
166
|
* @param data.title - The title of the entry.
|
|
167
167
|
* @param data.context - The context data.
|
|
168
|
-
* @param file - The file to
|
|
169
|
-
* @returns A promise that resolves when the context is successfully created.
|
|
168
|
+
* @param file - The file to upload (optional).
|
|
169
|
+
* @returns A promise that resolves when the context entry is successfully created.
|
|
170
170
|
*/
|
|
171
171
|
insert(data: AiChatBotContextData, file?: File | BlobAndFilename): Promise<void>;
|
|
172
172
|
/**
|
|
173
|
-
* Appends data to an existing context entry on the
|
|
173
|
+
* Appends data to an existing context entry on the agent.
|
|
174
|
+
* This will result in an error if an entry is not found.
|
|
175
|
+
*
|
|
174
176
|
* @param data An object containing options for appending the entry.
|
|
175
177
|
* @param file - The file to append.
|
|
176
178
|
*/
|
|
177
179
|
append(data: AiChatBotContextData, file?: File): Promise<void>;
|
|
178
180
|
/**
|
|
179
|
-
* Updates an existing context entry
|
|
180
|
-
*
|
|
181
|
+
* Updates an existing context entry for the agent.
|
|
182
|
+
* Throws an error if an entry with the specified context ID does not exist.
|
|
181
183
|
*
|
|
182
|
-
* @param data An object containing options for updating the entry.
|
|
184
|
+
* @param data - An object containing options for updating the entry.
|
|
183
185
|
* @param data.title - The title of the entry.
|
|
184
186
|
* @param data.context - The context data.
|
|
185
|
-
* @returns A promise that resolves when the context is successfully updated.
|
|
187
|
+
* @returns A promise that resolves when the context entry is successfully updated.
|
|
186
188
|
*/
|
|
187
189
|
update(data: Partial<AiChatBotContextData>): Promise<void>;
|
|
188
190
|
/**
|
|
189
|
-
* Deletes an existing context entry
|
|
190
|
-
*
|
|
191
|
+
* Deletes an existing context entry for the agent.
|
|
192
|
+
* Throws an error if an entry with the specified context ID does not exist.
|
|
191
193
|
*
|
|
192
|
-
* @returns A promise that resolves when the context is successfully deleted.
|
|
194
|
+
* @returns A promise that resolves when the context entry is successfully deleted.
|
|
193
195
|
*/
|
|
194
196
|
delete(): Promise<void>;
|
|
195
197
|
}
|
|
196
198
|
export declare class AiAgentInstructionReference {
|
|
197
199
|
private readonly client;
|
|
198
200
|
private readonly integrationId;
|
|
199
|
-
private readonly
|
|
201
|
+
private readonly agentId;
|
|
200
202
|
private readonly id;
|
|
201
203
|
/**
|
|
202
|
-
* Adds a new instruction entry to the
|
|
203
|
-
* the same
|
|
204
|
+
* Adds a new instruction entry to the agent.
|
|
205
|
+
* Throws an error if an entry with the same ID already exists.
|
|
204
206
|
*
|
|
205
|
-
* @param data An object containing options for creating the entry.
|
|
207
|
+
* @param data - An object containing options for creating the entry.
|
|
206
208
|
* @param data.instruction - The instruction data.
|
|
207
|
-
* @returns A promise that resolves when the instruction is successfully created.
|
|
209
|
+
* @returns A promise that resolves when the instruction entry is successfully created.
|
|
208
210
|
*/
|
|
209
211
|
insert(data: InstructionData): Promise<void>;
|
|
210
212
|
/**
|
|
211
|
-
* Updates an existing instruction entry
|
|
212
|
-
*
|
|
213
|
+
* Updates an existing instruction entry for the agent.
|
|
214
|
+
* Throws an error if an entry with the specified instruction ID does not exist.
|
|
213
215
|
*
|
|
214
|
-
* @param data An object containing options for updating the entry.
|
|
216
|
+
* @param data - An object containing options for updating the entry.
|
|
215
217
|
* @param data.instruction - The instruction data.
|
|
216
|
-
* @returns A promise that resolves when the instruction is successfully updated.
|
|
218
|
+
* @returns A promise that resolves when the instruction entry is successfully updated.
|
|
217
219
|
*/
|
|
218
220
|
update(data: InstructionData): Promise<void>;
|
|
219
221
|
/**
|
|
220
|
-
* Deletes an existing instruction entry
|
|
221
|
-
*
|
|
222
|
+
* Deletes an existing instruction entry for the agent.
|
|
223
|
+
* Throws an error if an entry with the specified instruction ID does not exist.
|
|
222
224
|
*
|
|
223
|
-
* @returns A promise that resolves when the instruction is successfully deleted.
|
|
225
|
+
* @returns A promise that resolves when the instruction entry is successfully deleted.
|
|
224
226
|
*/
|
|
225
227
|
delete(): Promise<void>;
|
|
226
228
|
}
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { RpcManager } from './rpc.manager';
|
|
2
1
|
import { MmEntity, MmEntityMatch, MmFindMatchesOptions, MmListEntitiesOptions, MmMatchMaker } from '../../internal-common/src/public-types/ai-matchmaking.types';
|
|
3
2
|
/**
|
|
4
3
|
* Client for the AI Matchmaking service. This service allows you to create matchmakers and insert entities into them.
|
|
@@ -6,7 +5,6 @@ import { MmEntity, MmEntityMatch, MmFindMatchesOptions, MmListEntitiesOptions, M
|
|
|
6
5
|
*/
|
|
7
6
|
export declare class AiMatchMakingClient {
|
|
8
7
|
private readonly rpcManager;
|
|
9
|
-
constructor(rpcManager: RpcManager);
|
|
10
8
|
/**
|
|
11
9
|
* Creates a new matchmaker with the given id, description, and categories.
|
|
12
10
|
* @param matchMaker The matchmaker to create.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { AiContextMetadata } from '../../internal-common/src/public-types/ai-
|
|
1
|
+
import { AiContextMetadata } from '../../internal-common/src/public-types/ai-agent.public-types';
|
|
2
2
|
import { DocumentTextDataResponse } from '../../internal-common/src/public-types/extraction.public-types';
|
|
3
3
|
interface PsGetAccessTokenResponse {
|
|
4
4
|
accessToken: string;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export * from '../../internal-common/src/public-types/ai-assistant.public-types';
|
|
2
|
-
export * from '../../internal-common/src/public-types/ai-
|
|
2
|
+
export * from '../../internal-common/src/public-types/ai-agent.public-types';
|
|
3
3
|
export * from '../../internal-common/src/public-types/api-client.public-types';
|
|
4
4
|
export * from '../../internal-common/src/public-types/application.public-types';
|
|
5
5
|
export * from '../../internal-common/src/public-types/bundle-data.public-types';
|
|
@@ -8,7 +8,7 @@ export * from '../../internal-common/src/public-types/context.public-types';
|
|
|
8
8
|
export * from '../../internal-common/src/public-types/document.public-types';
|
|
9
9
|
export * from '../../internal-common/src/public-types/http-status.enum';
|
|
10
10
|
export * from '../../internal-common/src/public-types/integration.public-types';
|
|
11
|
-
export * from '../../internal-common/src/public-types/integrations/
|
|
11
|
+
export * from '../../internal-common/src/public-types/integrations/ai_agent.public-types';
|
|
12
12
|
export * from '../../internal-common/src/public-types/integrations/api.public-types';
|
|
13
13
|
export * from '../../internal-common/src/public-types/metric.public-types';
|
|
14
14
|
export * from '../../internal-common/src/public-types/mutation.public-types';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const SQUIDCLOUD_CLIENT_PACKAGE_VERSION = "1.0.
|
|
1
|
+
export declare const SQUIDCLOUD_CLIENT_PACKAGE_VERSION = "1.0.317";
|