@promptbook/markdown-utils 0.92.0-20 → 0.92.0-21
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 +2 -5
- package/esm/index.es.js.map +1 -1
- package/esm/typings/src/_packages/core.index.d.ts +4 -0
- package/esm/typings/src/config.d.ts +8 -0
- package/esm/typings/src/formats/json/utils/jsonParse.d.ts +0 -3
- package/esm/typings/src/formfactors/completion/CompletionFormfactorDefinition.d.ts +29 -0
- package/esm/typings/src/formfactors/index.d.ts +28 -3
- package/esm/typings/src/high-level-abstractions/index.d.ts +2 -2
- package/esm/typings/src/migrations/migratePipeline.d.ts +2 -0
- package/package.json +1 -1
- package/umd/index.umd.js +2 -5
- package/umd/index.umd.js.map +1 -1
|
@@ -32,6 +32,7 @@ import { DEFAULT_IS_VERBOSE } from '../config';
|
|
|
32
32
|
import { SET_IS_VERBOSE } from '../config';
|
|
33
33
|
import { DEFAULT_IS_AUTO_INSTALLED } from '../config';
|
|
34
34
|
import { DEFAULT_GET_PIPELINE_COLLECTION_FUNCTION_NAME } from '../config';
|
|
35
|
+
import { DEFAULT_RPM } from '../config';
|
|
35
36
|
import { ORDER_OF_PIPELINE_JSON } from '../constants';
|
|
36
37
|
import { RESERVED_PARAMETER_NAMES } from '../constants';
|
|
37
38
|
import { compilePipeline } from '../conversion/compilePipeline';
|
|
@@ -81,6 +82,7 @@ import { MANDATORY_CSV_SETTINGS } from '../formats/csv/CsvSettings';
|
|
|
81
82
|
import { TextFormatParser } from '../formats/text/TextFormatParser';
|
|
82
83
|
import { BoilerplateFormfactorDefinition } from '../formfactors/_boilerplate/BoilerplateFormfactorDefinition';
|
|
83
84
|
import { ChatbotFormfactorDefinition } from '../formfactors/chatbot/ChatbotFormfactorDefinition';
|
|
85
|
+
import { CompletionFormfactorDefinition } from '../formfactors/completion/CompletionFormfactorDefinition';
|
|
84
86
|
import { GeneratorFormfactorDefinition } from '../formfactors/generator/GeneratorFormfactorDefinition';
|
|
85
87
|
import { GenericFormfactorDefinition } from '../formfactors/generic/GenericFormfactorDefinition';
|
|
86
88
|
import { ImageGeneratorFormfactorDefinition } from '../formfactors/image-generator/ImageGeneratorFormfactorDefinition';
|
|
@@ -175,6 +177,7 @@ export { DEFAULT_IS_VERBOSE };
|
|
|
175
177
|
export { SET_IS_VERBOSE };
|
|
176
178
|
export { DEFAULT_IS_AUTO_INSTALLED };
|
|
177
179
|
export { DEFAULT_GET_PIPELINE_COLLECTION_FUNCTION_NAME };
|
|
180
|
+
export { DEFAULT_RPM };
|
|
178
181
|
export { ORDER_OF_PIPELINE_JSON };
|
|
179
182
|
export { RESERVED_PARAMETER_NAMES };
|
|
180
183
|
export { compilePipeline };
|
|
@@ -224,6 +227,7 @@ export { MANDATORY_CSV_SETTINGS };
|
|
|
224
227
|
export { TextFormatParser };
|
|
225
228
|
export { BoilerplateFormfactorDefinition };
|
|
226
229
|
export { ChatbotFormfactorDefinition };
|
|
230
|
+
export { CompletionFormfactorDefinition };
|
|
227
231
|
export { GeneratorFormfactorDefinition };
|
|
228
232
|
export { GenericFormfactorDefinition };
|
|
229
233
|
export { ImageGeneratorFormfactorDefinition };
|
|
@@ -265,6 +265,14 @@ export declare const DEFAULT_IS_AUTO_INSTALLED = false;
|
|
|
265
265
|
* @public exported from `@promptbook/core`
|
|
266
266
|
*/
|
|
267
267
|
export declare const DEFAULT_GET_PIPELINE_COLLECTION_FUNCTION_NAME = "getPipelineCollection";
|
|
268
|
+
/**
|
|
269
|
+
* Default rate limits (requests per minute)
|
|
270
|
+
*
|
|
271
|
+
* Note: Adjust based on the provider tier you are have
|
|
272
|
+
*
|
|
273
|
+
* @public exported from `@promptbook/core`
|
|
274
|
+
*/
|
|
275
|
+
export declare const DEFAULT_RPM = 60;
|
|
268
276
|
/**
|
|
269
277
|
* @@@
|
|
270
278
|
*
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Completion is formfactor that emulates completion models
|
|
3
|
+
*
|
|
4
|
+
* @public exported from `@promptbook/core`
|
|
5
|
+
*/
|
|
6
|
+
export declare const CompletionFormfactorDefinition: {
|
|
7
|
+
readonly name: "COMPLETION";
|
|
8
|
+
readonly description: "@@@";
|
|
9
|
+
readonly documentationUrl: "https://github.com/webgptorg/promptbook/discussions/@@";
|
|
10
|
+
readonly pipelineInterface: {
|
|
11
|
+
readonly inputParameters: readonly [{
|
|
12
|
+
readonly name: "inputText";
|
|
13
|
+
readonly description: "Input text to be completed";
|
|
14
|
+
readonly isInput: true;
|
|
15
|
+
readonly isOutput: false;
|
|
16
|
+
}, {
|
|
17
|
+
readonly name: "instructions";
|
|
18
|
+
readonly description: "Additional instructions for the model, for example the required length, empty by default";
|
|
19
|
+
readonly isInput: true;
|
|
20
|
+
readonly isOutput: false;
|
|
21
|
+
}];
|
|
22
|
+
readonly outputParameters: readonly [{
|
|
23
|
+
readonly name: "followingText";
|
|
24
|
+
readonly description: "Text that follows the input text";
|
|
25
|
+
readonly isInput: false;
|
|
26
|
+
readonly isOutput: true;
|
|
27
|
+
}];
|
|
28
|
+
};
|
|
29
|
+
};
|
|
@@ -36,9 +36,6 @@ export declare const FORMFACTOR_DEFINITIONS: readonly [{
|
|
|
36
36
|
readonly outputParameters: readonly [{
|
|
37
37
|
readonly name: "title";
|
|
38
38
|
readonly description: "Title of the conversation";
|
|
39
|
-
/**
|
|
40
|
-
* Note: [💞] Ignore a discrepancy between file name and entity name
|
|
41
|
-
*/
|
|
42
39
|
readonly isInput: false;
|
|
43
40
|
readonly isOutput: true;
|
|
44
41
|
}, {
|
|
@@ -132,6 +129,11 @@ export declare const FORMFACTOR_DEFINITIONS: readonly [{
|
|
|
132
129
|
readonly isInput: true;
|
|
133
130
|
readonly isOutput: false;
|
|
134
131
|
}];
|
|
132
|
+
/**
|
|
133
|
+
* All available formfactor definitions
|
|
134
|
+
*
|
|
135
|
+
* @public exported from `@promptbook/core`
|
|
136
|
+
*/
|
|
135
137
|
readonly outputParameters: readonly [{
|
|
136
138
|
readonly name: "prompt";
|
|
137
139
|
readonly description: "Prompt to be used for image generation";
|
|
@@ -139,6 +141,29 @@ export declare const FORMFACTOR_DEFINITIONS: readonly [{
|
|
|
139
141
|
readonly isOutput: true;
|
|
140
142
|
}];
|
|
141
143
|
};
|
|
144
|
+
}, {
|
|
145
|
+
readonly name: "COMPLETION";
|
|
146
|
+
readonly description: "@@@";
|
|
147
|
+
readonly documentationUrl: "https://github.com/webgptorg/promptbook/discussions/@@";
|
|
148
|
+
readonly pipelineInterface: {
|
|
149
|
+
readonly inputParameters: readonly [{
|
|
150
|
+
readonly name: "inputText";
|
|
151
|
+
readonly description: "Input text to be completed";
|
|
152
|
+
readonly isInput: true;
|
|
153
|
+
readonly isOutput: false;
|
|
154
|
+
}, {
|
|
155
|
+
readonly name: "instructions";
|
|
156
|
+
readonly description: "Additional instructions for the model, for example the required length, empty by default";
|
|
157
|
+
readonly isInput: true;
|
|
158
|
+
readonly isOutput: false;
|
|
159
|
+
}];
|
|
160
|
+
readonly outputParameters: readonly [{
|
|
161
|
+
readonly name: "followingText";
|
|
162
|
+
readonly description: "Text that follows the input text";
|
|
163
|
+
readonly isInput: false;
|
|
164
|
+
readonly isOutput: true;
|
|
165
|
+
}];
|
|
166
|
+
};
|
|
142
167
|
}];
|
|
143
168
|
/**
|
|
144
169
|
* Note: [💞] Ignore a discrepancy between file name and entity name
|
|
@@ -23,7 +23,7 @@ export declare const HIGH_LEVEL_ABSTRACTIONS: readonly [{
|
|
|
23
23
|
path: string | null;
|
|
24
24
|
content: import("../pipeline/PipelineString").PipelineString;
|
|
25
25
|
}[];
|
|
26
|
-
readonly formfactorName?: "CHATBOT" | "GENERATOR" | "GENERIC" | "IMAGE_GENERATOR" | "EXPERIMENTAL_MATCHER" | "SHEETS" | "TRANSLATOR" | undefined;
|
|
26
|
+
readonly formfactorName?: "CHATBOT" | "COMPLETION" | "GENERATOR" | "GENERIC" | "IMAGE_GENERATOR" | "EXPERIMENTAL_MATCHER" | "SHEETS" | "TRANSLATOR" | undefined;
|
|
27
27
|
}>): void;
|
|
28
28
|
}, {
|
|
29
29
|
type: "SYNC";
|
|
@@ -45,7 +45,7 @@ export declare const HIGH_LEVEL_ABSTRACTIONS: readonly [{
|
|
|
45
45
|
path: string | null;
|
|
46
46
|
content: import("../pipeline/PipelineString").PipelineString;
|
|
47
47
|
}[];
|
|
48
|
-
readonly formfactorName?: "CHATBOT" | "GENERATOR" | "GENERIC" | "IMAGE_GENERATOR" | "EXPERIMENTAL_MATCHER" | "SHEETS" | "TRANSLATOR" | undefined;
|
|
48
|
+
readonly formfactorName?: "CHATBOT" | "COMPLETION" | "GENERATOR" | "GENERIC" | "IMAGE_GENERATOR" | "EXPERIMENTAL_MATCHER" | "SHEETS" | "TRANSLATOR" | undefined;
|
|
49
49
|
}>): void;
|
|
50
50
|
}];
|
|
51
51
|
/**
|
|
@@ -2,6 +2,8 @@ import type { PipelineJson } from '../pipeline/PipelineJson/PipelineJson';
|
|
|
2
2
|
/**
|
|
3
3
|
* Migrates the pipeline to the latest version
|
|
4
4
|
*
|
|
5
|
+
* Note: Migration does not do heavy lifting like calling the LLMs, just lightweight changes of the structure
|
|
6
|
+
*
|
|
5
7
|
* @public exported from `@promptbook/core`
|
|
6
8
|
*/
|
|
7
9
|
export declare function migratePipeline(deprecatedPipeline: PipelineJson): PipelineJson;
|
package/package.json
CHANGED
package/umd/index.umd.js
CHANGED
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
* @generated
|
|
26
26
|
* @see https://github.com/webgptorg/promptbook
|
|
27
27
|
*/
|
|
28
|
-
const PROMPTBOOK_ENGINE_VERSION = '0.92.0-
|
|
28
|
+
const PROMPTBOOK_ENGINE_VERSION = '0.92.0-21';
|
|
29
29
|
/**
|
|
30
30
|
* TODO: string_promptbook_version should be constrained to the all versions of Promptbook engine
|
|
31
31
|
* Note: [💞] Ignore a discrepancy between file name and entity name
|
|
@@ -2070,15 +2070,12 @@
|
|
|
2070
2070
|
}
|
|
2071
2071
|
throw new Error(spaceTrim__default["default"]((block) => `
|
|
2072
2072
|
${block(error.message)}
|
|
2073
|
-
|
|
2073
|
+
|
|
2074
2074
|
The JSON text:
|
|
2075
2075
|
${block(value)}
|
|
2076
2076
|
`));
|
|
2077
2077
|
}
|
|
2078
2078
|
}
|
|
2079
|
-
/**
|
|
2080
|
-
* TODO: !!!! Use in Promptbook.studio
|
|
2081
|
-
*/
|
|
2082
2079
|
|
|
2083
2080
|
/**
|
|
2084
2081
|
* Recursively converts JSON strings to JSON objects
|