@promptbook/utils 0.50.0-7 → 0.50.0-9

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/esm/index.es.js CHANGED
@@ -403,7 +403,7 @@ function removeContentComments(content) {
403
403
  /**
404
404
  * The version of the Promptbook library
405
405
  */
406
- var PROMPTBOOK_VERSION = '0.50.0-6';
406
+ var PROMPTBOOK_VERSION = '0.50.0-8';
407
407
 
408
408
  /**
409
409
  * Parses the given script and returns the list of all used variables that are not defined in the script
@@ -25,6 +25,14 @@ export declare class OpenAiExecutionTools implements LlmExecutionTools {
25
25
  * Calls OpenAI API to use a complete model.
26
26
  */
27
27
  gptComplete(prompt: Prompt): Promise<PromptCompletionResult>;
28
+ /**
29
+ * Default model for chat variant.
30
+ */
31
+ private getDefaultChatModel;
32
+ /**
33
+ * Default model for completion variant.
34
+ */
35
+ private getDefaultCompletionModel;
28
36
  /**
29
37
  * List all available OpenAI models that can be used
30
38
  */
@@ -26,10 +26,11 @@ export type ModelRequirements = {
26
26
  * The model for text prompt
27
27
  *
28
28
  * Note: Model must be compatible with the model variant
29
+ * Note: If not specified, the best model for the variant will be used
29
30
  *
30
31
  * @example 'gpt-4', 'gpt-4-32k-0314', 'gpt-3.5-turbo-instruct',...
31
32
  */
32
- readonly modelName: string_model_name;
33
+ readonly modelName?: string_model_name;
33
34
  /**
34
35
  * Maximum number of tokens that can be generated by the model
35
36
  */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@promptbook/utils",
3
- "version": "0.50.0-7",
3
+ "version": "0.50.0-9",
4
4
  "description": "Library to supercharge your use of large language models",
5
5
  "private": false,
6
6
  "sideEffects": false,
package/umd/index.umd.js CHANGED
@@ -408,7 +408,7 @@
408
408
  /**
409
409
  * The version of the Promptbook library
410
410
  */
411
- var PROMPTBOOK_VERSION = '0.50.0-6';
411
+ var PROMPTBOOK_VERSION = '0.50.0-8';
412
412
 
413
413
  /**
414
414
  * Parses the given script and returns the list of all used variables that are not defined in the script
@@ -25,6 +25,14 @@ export declare class OpenAiExecutionTools implements LlmExecutionTools {
25
25
  * Calls OpenAI API to use a complete model.
26
26
  */
27
27
  gptComplete(prompt: Prompt): Promise<PromptCompletionResult>;
28
+ /**
29
+ * Default model for chat variant.
30
+ */
31
+ private getDefaultChatModel;
32
+ /**
33
+ * Default model for completion variant.
34
+ */
35
+ private getDefaultCompletionModel;
28
36
  /**
29
37
  * List all available OpenAI models that can be used
30
38
  */
@@ -26,10 +26,11 @@ export type ModelRequirements = {
26
26
  * The model for text prompt
27
27
  *
28
28
  * Note: Model must be compatible with the model variant
29
+ * Note: If not specified, the best model for the variant will be used
29
30
  *
30
31
  * @example 'gpt-4', 'gpt-4-32k-0314', 'gpt-3.5-turbo-instruct',...
31
32
  */
32
- readonly modelName: string_model_name;
33
+ readonly modelName?: string_model_name;
33
34
  /**
34
35
  * Maximum number of tokens that can be generated by the model
35
36
  */