@squidcloud/client 1.0.334 → 1.0.335
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/code-executor.public-types.d.ts +1 -0
- package/dist/typescript-client/src/agent/ai-agent-client-reference.d.ts +2 -3
- package/dist/typescript-client/src/ai-assistant-client.d.ts +4 -5
- package/dist/typescript-client/src/ai-audio-client.d.ts +1 -2
- package/dist/typescript-client/src/extraction-client.d.ts +1 -2
- package/dist/typescript-client/src/public-types.d.ts +1 -0
- package/dist/typescript-client/src/squid.d.ts +11 -6
- package/dist/typescript-client/src/storage-client.d.ts +2 -3
- package/dist/typescript-client/src/types.d.ts +0 -4
- package/dist/typescript-client/src/version.d.ts +1 -1
- package/package.json +1 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { AgentContextRequest, AiAgent, AiAgentChatOptions, AiAgentContext, AiChatModelName, AiConnectedAgentMetadata, AiObserveStatusOptions, AiSearchOptions, AiSearchResponse, AiStatusMessage, AiTranscribeAndAskResponse, UpsertAgentRequest } from '../../../internal-common/src/public-types/ai-agent.public-types';
|
|
2
|
-
import { BlobAndFilename } from '../types';
|
|
3
2
|
import { Observable } from 'rxjs';
|
|
4
3
|
import { AskOptionsWithoutVoice, AskWithVoiceResponse, ChatOptionsWithoutVoice, TranscribeAndAskWithVoiceResponse, TranscribeAndChatResponse } from './ai-agent-client.types';
|
|
5
4
|
export type UpsertAgentRequestParams = Omit<UpsertAgentRequest, 'id'>;
|
|
@@ -24,8 +23,8 @@ export declare class AiAgentReference {
|
|
|
24
23
|
listContexts(): Promise<Array<AiAgentContext>>;
|
|
25
24
|
deleteContext(contextId: string): Promise<void>;
|
|
26
25
|
deleteContexts(contextIds: Array<string>): Promise<void>;
|
|
27
|
-
upsertContext(contextRequest: AgentContextRequest, file?: File
|
|
28
|
-
upsertContexts(contextRequests: Array<AgentContextRequest>, files?: Array<File
|
|
26
|
+
upsertContext(contextRequest: AgentContextRequest, file?: File): Promise<void>;
|
|
27
|
+
upsertContexts(contextRequests: Array<AgentContextRequest>, files?: Array<File>): Promise<void>;
|
|
29
28
|
provideFeedback(feedback: string): Promise<void>;
|
|
30
29
|
resetFeedback(): Promise<void>;
|
|
31
30
|
chat(prompt: string, options?: ChatOptionsWithoutVoice): Observable<string>;
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { AssistantToolType, FunctionName, QueryAssistantOptions } from './public-types';
|
|
2
|
-
import { BlobAndFilename } from './types';
|
|
3
2
|
/**
|
|
4
3
|
* Client class for interacting with an AI Assistant server.
|
|
5
4
|
* Provides functionalities like creating and deleting assistants and threads,
|
|
@@ -51,10 +50,10 @@ export declare class AiAssistantClient {
|
|
|
51
50
|
/**
|
|
52
51
|
* Adds a file to an AI assistant that can be available for retrieval or code analyzer.
|
|
53
52
|
* @param assistantId - The ID of the assistant.
|
|
54
|
-
* @param file - The file
|
|
53
|
+
* @param file - The file to be added.
|
|
55
54
|
* @returns A promise that resolves to the ID of the added file.
|
|
56
55
|
*/
|
|
57
|
-
addFileToAssistant(assistantId: string, file: File
|
|
56
|
+
addFileToAssistant(assistantId: string, file: File): Promise<string>;
|
|
58
57
|
/**
|
|
59
58
|
* Removes a file from an AI assistant.
|
|
60
59
|
* @param assistantId - The ID of the assistant.
|
|
@@ -65,8 +64,8 @@ export declare class AiAssistantClient {
|
|
|
65
64
|
/**
|
|
66
65
|
* Adds a file to a specific thread of an AI assistant. These files can be used when asking a question in the thread.
|
|
67
66
|
* @param threadId - The ID of the thread.
|
|
68
|
-
* @param file - The file
|
|
67
|
+
* @param file - The file to be added.
|
|
69
68
|
* @returns A promise that resolves to the ID of the added file.
|
|
70
69
|
*/
|
|
71
|
-
addFileToThread(threadId: string, file: File
|
|
70
|
+
addFileToThread(threadId: string, file: File): Promise<string>;
|
|
72
71
|
}
|
|
@@ -1,11 +1,10 @@
|
|
|
1
1
|
import { AiAudioCreateSpeechOptions, AiAudioTranscribeOptions } from './public-types';
|
|
2
|
-
import { BlobAndFilename } from './types';
|
|
3
2
|
/**
|
|
4
3
|
* AiAudioClient provides methods for AI-driven audio processing,
|
|
5
4
|
* including speech transcription and text-to-speech synthesis.
|
|
6
5
|
*/
|
|
7
6
|
export declare class AiAudioClient {
|
|
8
7
|
private readonly rpcManager;
|
|
9
|
-
transcribe(file: File
|
|
8
|
+
transcribe(file: File, options?: AiAudioTranscribeOptions): Promise<string>;
|
|
10
9
|
createSpeech(input: string, options: AiAudioCreateSpeechOptions): Promise<File>;
|
|
11
10
|
}
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { BlobAndFilename } from './types';
|
|
2
1
|
import { DocumentTextDataResponse, ExtractDataFromDocumentFileOptions } from '../../internal-common/src/public-types/extraction.public-types';
|
|
3
2
|
/**
|
|
4
3
|
* ExtractionClient provides methods for extracting structured data
|
|
@@ -6,5 +5,5 @@ import { DocumentTextDataResponse, ExtractDataFromDocumentFileOptions } from '..
|
|
|
6
5
|
*/
|
|
7
6
|
export declare class ExtractionClient {
|
|
8
7
|
private readonly rpcManager;
|
|
9
|
-
extractDataFromDocumentFile(file: File
|
|
8
|
+
extractDataFromDocumentFile(file: File, options?: ExtractDataFromDocumentFileOptions): Promise<DocumentTextDataResponse>;
|
|
10
9
|
}
|
|
@@ -3,6 +3,7 @@ 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';
|
|
6
|
+
export * from '../../internal-common/src/public-types/code-executor.public-types';
|
|
6
7
|
export * from '../../internal-common/src/public-types/communication.public-types';
|
|
7
8
|
export * from '../../internal-common/src/public-types/context.public-types';
|
|
8
9
|
export * from '../../internal-common/src/public-types/document.public-types';
|
|
@@ -164,15 +164,20 @@ export declare class Squid {
|
|
|
164
164
|
*/
|
|
165
165
|
runInTransaction<T = any>(fn: (transactionId: TransactionId) => Promise<T>): Promise<T>;
|
|
166
166
|
/**
|
|
167
|
-
* Executes
|
|
167
|
+
* Executes a backend function identified by its name, passing the provided parameters, and returns a promise with
|
|
168
|
+
* the result.
|
|
168
169
|
*
|
|
169
|
-
* For
|
|
170
|
+
* For detailed information on backend functions in Squid, see the
|
|
170
171
|
* {@link https://docs.getsquid.ai/docs/backend/executables/ documentation}.
|
|
171
172
|
*
|
|
172
|
-
*
|
|
173
|
-
*
|
|
174
|
-
*
|
|
175
|
-
*
|
|
173
|
+
* Files support:
|
|
174
|
+
* - To send a file to the backend, simply include it as one of the parameters; it will be received as a {@link SquidFile}.
|
|
175
|
+
* - Arrays of files can also be passed directly as parameters.
|
|
176
|
+
*
|
|
177
|
+
* @param functionName - The name of the backend function to execute.
|
|
178
|
+
* @param params - A list of parameters to pass to the backend function.
|
|
179
|
+
* @returns A promise that resolves to the result of the backend function.
|
|
180
|
+
* @typeParam T - The expected type of the result returned by the backend function.
|
|
176
181
|
*/
|
|
177
182
|
executeFunction<T = any>(functionName: string, ...params: any[]): Promise<T>;
|
|
178
183
|
/**
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { BlobAndFilename } from './types';
|
|
2
1
|
import { IntegrationId } from '../../internal-common/src/public-types/communication.public-types';
|
|
3
2
|
export interface StorageFileUploadRequest {
|
|
4
3
|
integrationId: IntegrationId;
|
|
@@ -51,11 +50,11 @@ export declare class StorageClient {
|
|
|
51
50
|
* Uploads a file to a specified directory within the bucket.
|
|
52
51
|
*
|
|
53
52
|
* @param dirPathInBucket - The directory path within the bucket where the file should be uploaded.
|
|
54
|
-
* @param file - The file
|
|
53
|
+
* @param file - The file to upload.
|
|
55
54
|
* @param expirationInSeconds - Optional expiration time in seconds for the upload.
|
|
56
55
|
* @returns A promise that resolves to void when the upload is complete.
|
|
57
56
|
*/
|
|
58
|
-
uploadFile(dirPathInBucket: string, file: File
|
|
57
|
+
uploadFile(dirPathInBucket: string, file: File, expirationInSeconds?: number): Promise<void>;
|
|
59
58
|
/**
|
|
60
59
|
* Retrieves metadata for a file located in a specified path within the bucket.
|
|
61
60
|
*
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const SQUIDCLOUD_CLIENT_PACKAGE_VERSION = "1.0.
|
|
1
|
+
export declare const SQUIDCLOUD_CLIENT_PACKAGE_VERSION = "1.0.335";
|