@promptbook/node 0.82.0-2 → 0.82.0
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/README.md +0 -4
- package/esm/index.es.js +17 -5
- package/esm/index.es.js.map +1 -1
- package/esm/typings/src/_packages/core.index.d.ts +2 -0
- package/esm/typings/src/config.d.ts +6 -0
- package/package.json +2 -2
- package/umd/index.umd.js +17 -5
- package/umd/index.umd.js.map +1 -1
|
@@ -11,6 +11,7 @@ import { CLAIM } from '../config';
|
|
|
11
11
|
import { LOGO_LIGHT_SRC } from '../config';
|
|
12
12
|
import { LOGO_DARK_SRC } from '../config';
|
|
13
13
|
import { DEFAULT_BOOK_TITLE } from '../config';
|
|
14
|
+
import { DEFAULT_TASK_TITLE } from '../config';
|
|
14
15
|
import { MAX_FILENAME_LENGTH } from '../config';
|
|
15
16
|
import { DEFAULT_INTERMEDIATE_FILES_STRATEGY } from '../config';
|
|
16
17
|
import { DEFAULT_MAX_PARALLEL_COUNT } from '../config';
|
|
@@ -134,6 +135,7 @@ export { CLAIM };
|
|
|
134
135
|
export { LOGO_LIGHT_SRC };
|
|
135
136
|
export { LOGO_DARK_SRC };
|
|
136
137
|
export { DEFAULT_BOOK_TITLE };
|
|
138
|
+
export { DEFAULT_TASK_TITLE };
|
|
137
139
|
export { MAX_FILENAME_LENGTH };
|
|
138
140
|
export { DEFAULT_INTERMEDIATE_FILES_STRATEGY };
|
|
139
141
|
export { DEFAULT_MAX_PARALLEL_COUNT };
|
|
@@ -59,6 +59,12 @@ export declare const LOGO_DARK_SRC: string_url_image;
|
|
|
59
59
|
* @public exported from `@promptbook/core`
|
|
60
60
|
*/
|
|
61
61
|
export declare const DEFAULT_BOOK_TITLE = "\u2728 Untitled Book";
|
|
62
|
+
/**
|
|
63
|
+
* When the title of task is not provided, the default title is used
|
|
64
|
+
*
|
|
65
|
+
* @public exported from `@promptbook/core`
|
|
66
|
+
*/
|
|
67
|
+
export declare const DEFAULT_TASK_TITLE = "Task";
|
|
62
68
|
/**
|
|
63
69
|
* Warning message for the generated sections and files files
|
|
64
70
|
*
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@promptbook/node",
|
|
3
|
-
"version": "0.82.0
|
|
3
|
+
"version": "0.82.0",
|
|
4
4
|
"description": "It's time for a paradigm shift. The future of software in plain English, French or Latin",
|
|
5
5
|
"--note-0": " <- [🐊]",
|
|
6
6
|
"private": false,
|
|
@@ -54,7 +54,7 @@
|
|
|
54
54
|
"module": "./esm/index.es.js",
|
|
55
55
|
"typings": "./esm/typings/src/_packages/node.index.d.ts",
|
|
56
56
|
"peerDependencies": {
|
|
57
|
-
"@promptbook/core": "0.82.0
|
|
57
|
+
"@promptbook/core": "0.82.0"
|
|
58
58
|
},
|
|
59
59
|
"dependencies": {
|
|
60
60
|
"colors": "1.4.0",
|
package/umd/index.umd.js
CHANGED
|
@@ -45,7 +45,7 @@
|
|
|
45
45
|
* @generated
|
|
46
46
|
* @see https://github.com/webgptorg/promptbook
|
|
47
47
|
*/
|
|
48
|
-
var PROMPTBOOK_ENGINE_VERSION = '0.82.0-
|
|
48
|
+
var PROMPTBOOK_ENGINE_VERSION = '0.82.0-3';
|
|
49
49
|
/**
|
|
50
50
|
* TODO: string_promptbook_version should be constrained to the all versions of Promptbook engine
|
|
51
51
|
* Note: [💞] Ignore a discrepancy between file name and entity name
|
|
@@ -216,6 +216,12 @@
|
|
|
216
216
|
* @public exported from `@promptbook/core`
|
|
217
217
|
*/
|
|
218
218
|
var DEFAULT_BOOK_TITLE = "\u2728 Untitled Book";
|
|
219
|
+
/**
|
|
220
|
+
* When the title of task is not provided, the default title is used
|
|
221
|
+
*
|
|
222
|
+
* @public exported from `@promptbook/core`
|
|
223
|
+
*/
|
|
224
|
+
var DEFAULT_TASK_TITLE = "Task";
|
|
219
225
|
// <- TODO: [🧠] Better system for generator warnings - not always "code" and "by `@promptbook/cli`"
|
|
220
226
|
/**
|
|
221
227
|
* The maximum number of iterations for a loops
|
|
@@ -1841,11 +1847,17 @@
|
|
|
1841
1847
|
* @public exported from `@promptbook/utils`
|
|
1842
1848
|
*/
|
|
1843
1849
|
function deserializeError(error) {
|
|
1850
|
+
var name = error.name, stack = error.stack;
|
|
1851
|
+
var message = error.message;
|
|
1844
1852
|
var ErrorClass = ALL_ERRORS[error.name];
|
|
1845
1853
|
if (ErrorClass === undefined) {
|
|
1846
|
-
|
|
1854
|
+
ErrorClass = Error;
|
|
1855
|
+
message = "".concat(name, ": ").concat(message);
|
|
1856
|
+
}
|
|
1857
|
+
if (stack !== undefined && stack !== '') {
|
|
1858
|
+
message = spaceTrim__default["default"](function (block) { return "\n ".concat(block(message), "\n\n Original stack trace:\n ").concat(block(stack || ''), "\n "); });
|
|
1847
1859
|
}
|
|
1848
|
-
return new ErrorClass(
|
|
1860
|
+
return new ErrorClass(message);
|
|
1849
1861
|
}
|
|
1850
1862
|
|
|
1851
1863
|
/**
|
|
@@ -9097,8 +9109,8 @@
|
|
|
9097
9109
|
isSectionTypeSet: false,
|
|
9098
9110
|
isTask: true,
|
|
9099
9111
|
taskType: undefined /* <- Note: [🍙] Putting here placeholder to keep `taskType` on top at final JSON */,
|
|
9100
|
-
name: getUniqueSectionName(section.title),
|
|
9101
|
-
title: section.title,
|
|
9112
|
+
name: getUniqueSectionName(section.title || DEFAULT_TASK_TITLE),
|
|
9113
|
+
title: section.title || DEFAULT_TASK_TITLE,
|
|
9102
9114
|
description: description_1,
|
|
9103
9115
|
content: content,
|
|
9104
9116
|
// <- TODO: [🍙] Some standard order of properties
|