@budibase/pro 3.31.2 → 3.31.4

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,7 +1,7 @@
1
1
  export * from "./utils";
2
2
  export * from "./prompts";
3
3
  export { parseResponseFormat } from "./models/openai";
4
- export { getLLM, getLLMConfig, getLLMOrThrow, LLMRequest } from "./llm";
4
+ export { getLLM, getLLMConfig, LLMRequest } from "./llm";
5
5
  export { LLM } from "./models/base";
6
6
  export * from "./prompts";
7
7
  export * from "./reasoningFallback";
package/dist/ai/llm.d.ts CHANGED
@@ -12,11 +12,6 @@ export declare function getLLMConfig(): Promise<LLMProviderConfig | undefined>;
12
12
  export declare function getLLM(options?: Omit<LLMConfigOptions, "model"> & {
13
13
  model?: string;
14
14
  }): Promise<LLM | undefined>;
15
- /**
16
- * @deprecated use the new `ai.sdk` instead
17
- */
18
- export declare function getLLMOrThrow(): Promise<LLM>;
19
- export declare function getOpenAIUsingLocalAPIKey(): Promise<LLM | undefined>;
20
15
  export declare class LLMRequest {
21
16
  messages: Message[];
22
17
  format?: ResponseFormat;
@@ -9,6 +9,5 @@ export declare class Anthropic extends LLM {
9
9
  private client;
10
10
  constructor(opts: LLMConfigOptions);
11
11
  firstTextBlock(message: AnthropicClient.Messages.Message): string | undefined;
12
- uploadFile(_data?: any, _filename?: string, _contentType?: string): Promise<string>;
13
12
  protected chatCompletion(request: LLMRequest): Promise<LLMFullResponse>;
14
13
  }
@@ -1,5 +1,4 @@
1
1
  import { LLMConfigOptions } from "@budibase/types";
2
- import { Readable } from "node:stream";
3
2
  import { LLMFullResponse, LLMPromptResponse } from "../../types/ai";
4
3
  import { LLMRequest } from "../llm";
5
4
  export declare abstract class LLM {
@@ -13,7 +12,6 @@ export declare abstract class LLM {
13
12
  abstract supportsFiles: boolean;
14
13
  protected abstract chatCompletion(request: LLMRequest): Promise<LLMFullResponse>;
15
14
  prompt(requestOrString: string | LLMRequest): Promise<LLMPromptResponse>;
16
- abstract uploadFile(data: Readable | Buffer, filename: string, contentType?: string): Promise<string>;
17
15
  chat(request: LLMRequest): Promise<LLMFullResponse>;
18
16
  summarizeText(prompt: string): Promise<LLMPromptResponse>;
19
17
  }
@@ -1,4 +1,3 @@
1
- import { Readable } from "node:stream";
2
1
  import { LLMFullResponse, LLMPromptResponse } from "../../types";
3
2
  import { LLMRequest } from "../llm";
4
3
  import { LLM } from "./base";
@@ -6,9 +5,6 @@ export declare class BudibaseAI extends LLM {
6
5
  supportsFiles: boolean;
7
6
  prompt(prompt: string | LLMRequest): Promise<LLMPromptResponse>;
8
7
  chat(prompt: LLMRequest): Promise<LLMFullResponse>;
9
- uploadFile(data: Readable | Buffer, filename: string, contentType: string): Promise<string>;
10
- protected uploadFileCloud(data: Readable | Buffer, filename: string, contentType: string): Promise<string>;
11
- protected uploadFileSelfHost(data: Readable | Buffer, filename: string, contentType: string): Promise<string>;
12
8
  protected chatCompletion(prompt: LLMRequest): Promise<LLMFullResponse>;
13
9
  protected chatCompletionCloud(prompt: LLMRequest): Promise<LLMFullResponse>;
14
10
  protected chatCompletionSelfHost(prompt: LLMRequest): Promise<LLMFullResponse>;
@@ -1,5 +1,4 @@
1
1
  import { LLMConfigOptions, ResponseFormat } from "@budibase/types";
2
- import { Readable } from "node:stream";
3
2
  import { default as openai, default as OpenAIClient } from "openai";
4
3
  import { LLMFullResponse } from "../../types/ai";
5
4
  import { LLMRequest } from "../llm";
@@ -17,6 +16,5 @@ export declare class OpenAI extends LLM {
17
16
  supportsFiles: boolean;
18
17
  protected getVerbosityForModel(): "low" | "medium" | undefined;
19
18
  protected getClient(opts: LLMConfigOptions): OpenAIClient;
20
- uploadFile(data: Readable | Buffer, filename: string, contentType?: string): Promise<string>;
21
19
  protected chatCompletion(request: LLMRequest): Promise<LLMFullResponse>;
22
20
  }