@promptbook/remote-client 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 +19 -8
- 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 +19 -8
- 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/remote-client",
|
|
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/remote-client.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
|
"crypto-js": "4.2.0",
|
package/umd/index.umd.js
CHANGED
|
@@ -23,7 +23,7 @@
|
|
|
23
23
|
* @generated
|
|
24
24
|
* @see https://github.com/webgptorg/promptbook
|
|
25
25
|
*/
|
|
26
|
-
var PROMPTBOOK_ENGINE_VERSION = '0.82.0-
|
|
26
|
+
var PROMPTBOOK_ENGINE_VERSION = '0.82.0-3';
|
|
27
27
|
/**
|
|
28
28
|
* TODO: string_promptbook_version should be constrained to the all versions of Promptbook engine
|
|
29
29
|
* Note: [💞] Ignore a discrepancy between file name and entity name
|
|
@@ -428,6 +428,12 @@
|
|
|
428
428
|
* @public exported from `@promptbook/core`
|
|
429
429
|
*/
|
|
430
430
|
var DEFAULT_BOOK_TITLE = "\u2728 Untitled Book";
|
|
431
|
+
/**
|
|
432
|
+
* When the title of task is not provided, the default title is used
|
|
433
|
+
*
|
|
434
|
+
* @public exported from `@promptbook/core`
|
|
435
|
+
*/
|
|
436
|
+
var DEFAULT_TASK_TITLE = "Task";
|
|
431
437
|
/**
|
|
432
438
|
* Timeout for the connections in milliseconds
|
|
433
439
|
*
|
|
@@ -554,11 +560,17 @@
|
|
|
554
560
|
* @public exported from `@promptbook/utils`
|
|
555
561
|
*/
|
|
556
562
|
function deserializeError(error) {
|
|
563
|
+
var name = error.name, stack = error.stack;
|
|
564
|
+
var message = error.message;
|
|
557
565
|
var ErrorClass = ALL_ERRORS[error.name];
|
|
558
566
|
if (ErrorClass === undefined) {
|
|
559
|
-
|
|
567
|
+
ErrorClass = Error;
|
|
568
|
+
message = "".concat(name, ": ").concat(message);
|
|
569
|
+
}
|
|
570
|
+
if (stack !== undefined && stack !== '') {
|
|
571
|
+
message = spaceTrim__default["default"](function (block) { return "\n ".concat(block(message), "\n\n Original stack trace:\n ").concat(block(stack || ''), "\n "); });
|
|
560
572
|
}
|
|
561
|
-
return new ErrorClass(
|
|
573
|
+
return new ErrorClass(message);
|
|
562
574
|
}
|
|
563
575
|
|
|
564
576
|
/**
|
|
@@ -610,8 +622,7 @@
|
|
|
610
622
|
var socket, preparedPipeline;
|
|
611
623
|
return __generator(this, function (_a) {
|
|
612
624
|
switch (_a.label) {
|
|
613
|
-
case 0:
|
|
614
|
-
return [4 /*yield*/, createRemoteClient(options)];
|
|
625
|
+
case 0: return [4 /*yield*/, createRemoteClient(options)];
|
|
615
626
|
case 1:
|
|
616
627
|
socket = _a.sent();
|
|
617
628
|
socket.emit('preparePipeline-request', {
|
|
@@ -631,7 +642,7 @@
|
|
|
631
642
|
case 2:
|
|
632
643
|
preparedPipeline = _a.sent();
|
|
633
644
|
socket.disconnect();
|
|
634
|
-
// TODO:
|
|
645
|
+
// TODO: [🧠] Maybe do $exportJson
|
|
635
646
|
return [2 /*return*/, preparedPipeline];
|
|
636
647
|
}
|
|
637
648
|
});
|
|
@@ -5261,8 +5272,8 @@
|
|
|
5261
5272
|
isSectionTypeSet: false,
|
|
5262
5273
|
isTask: true,
|
|
5263
5274
|
taskType: undefined /* <- Note: [🍙] Putting here placeholder to keep `taskType` on top at final JSON */,
|
|
5264
|
-
name: getUniqueSectionName(section.title),
|
|
5265
|
-
title: section.title,
|
|
5275
|
+
name: getUniqueSectionName(section.title || DEFAULT_TASK_TITLE),
|
|
5276
|
+
title: section.title || DEFAULT_TASK_TITLE,
|
|
5266
5277
|
description: description_1,
|
|
5267
5278
|
content: content,
|
|
5268
5279
|
// <- TODO: [🍙] Some standard order of properties
|