@squidcloud/client 1.0.227 → 1.0.229

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.
@@ -1 +1,7 @@
1
+ import { OpenAiResponseFormat } from './ai-chatbot.public-types';
1
2
  export type AssistantToolType = 'code_interpreter' | 'file_search';
3
+ /** The options for the AI assistant. */
4
+ export interface QueryAssistantOptions {
5
+ /** The format of the response from the AI model. Defaults to 'text' */
6
+ responseFormat?: OpenAiResponseFormat;
7
+ }
@@ -1,8 +1,8 @@
1
1
  /** The list of regions in Squid. */
2
- export declare const SQUID_REGIONS: readonly ["us-east-1.aws", "ap-south-1.aws"];
2
+ export declare const SQUID_REGIONS: readonly ["us-east-1.aws", "ap-south-1.aws", "us-central1.gcp"];
3
3
  /** Region type used by Squid. */
4
4
  export type SquidRegion = (typeof SQUID_REGIONS)[number];
5
5
  /** @deprecated: Use 'SQUID_REGIONS'. */
6
- export declare const SUPPORTED_SQUID_REGIONS: readonly ["us-east-1.aws", "ap-south-1.aws"];
6
+ export declare const SUPPORTED_SQUID_REGIONS: readonly ["us-east-1.aws", "ap-south-1.aws", "us-central1.gcp"];
7
7
  /** @deprecated: Use 'SquidRegion'. */
8
8
  export type SupportedSquidRegion = SquidRegion;
@@ -39,3 +39,10 @@ export declare function groupBy<T, K extends PropertyKey>(array: T[], getKey: (i
39
39
  export declare function pick<T extends object, K extends keyof T>(obj: T, keys: ReadonlyArray<K>): Pick<T, K>;
40
40
  /** Inverts the record: swaps keys and values. */
41
41
  export declare function invert<K extends string | number, V extends string | number>(record: Record<K, V>): Record<V, K>;
42
+ /**
43
+ * Creates an array of numbers (positive and/or negative) progressing from start up to, but not including, end.
44
+ * If end is less than start a zero-length range is created unless a negative step is specified.
45
+ *
46
+ * Same as lodash range but with an additional parameter: `maximumNumberOfItems`.
47
+ */
48
+ export declare function range(start: number, end: number, step: number, maximumNumberOfItems?: number): number[];
@@ -1,4 +1,4 @@
1
- import { AssistantToolType, FunctionName } from './public-types';
1
+ import { AssistantToolType, FunctionName, QueryAssistantOptions } from './public-types';
2
2
  import { BlobAndFilename } from './types';
3
3
  /**
4
4
  * Client class for interacting with an AI Assistant server.
@@ -44,9 +44,10 @@ export declare class AiAssistantClient {
44
44
  * @param prompt - The query prompt.
45
45
  * @param fileIds - Optional array of file IDs to include in the query. These file IDs need to be added using the
46
46
  * addFileToThread method.
47
+ * @param options - Optional query options.
47
48
  * @returns A promise that resolves to the assistant's response.
48
49
  */
49
- queryAssistant(assistantId: string, threadId: string, prompt: string, fileIds?: string[]): Promise<string>;
50
+ queryAssistant(assistantId: string, threadId: string, prompt: string, fileIds?: string[], options?: QueryAssistantOptions): Promise<string>;
50
51
  /**
51
52
  * Adds a file to an AI assistant that can be available for retrieval or code analyzer.
52
53
  * @param assistantId - The ID of the assistant.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@squidcloud/client",
3
- "version": "1.0.227",
3
+ "version": "1.0.229",
4
4
  "description": "A typescript implementation of the Squid client",
5
5
  "main": "dist/cjs/index.js",
6
6
  "types": "dist/typescript-client/src/index.d.ts",