@promptbook/cli 0.69.0-11 → 0.69.0-12
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 +55 -60
- package/esm/index.es.js.map +1 -1
- package/esm/typings/src/_packages/core.index.d.ts +2 -0
- package/esm/typings/src/_packages/types.index.d.ts +4 -0
- package/esm/typings/src/config.d.ts +7 -0
- package/esm/typings/src/execution/createPipelineExecutor/00-CreatePipelineExecutorSettings.d.ts +7 -0
- package/esm/typings/src/formats/_common/FormatDefinition.d.ts +9 -6
- package/esm/typings/src/formats/_common/FormatSubvalueDefinition.d.ts +4 -3
- package/esm/typings/src/formats/csv/CsvFormatDefinition.d.ts +3 -1
- package/esm/typings/src/formats/csv/CsvSettings.d.ts +5 -0
- package/esm/typings/src/formats/index.d.ts +1 -1
- package/esm/typings/src/formats/json/JsonFormatDefinition.d.ts +3 -2
- package/esm/typings/src/formats/text/TextFormatDefinition.d.ts +3 -1
- package/esm/typings/src/formats/xml/XmlFormatDefinition.d.ts +3 -2
- package/esm/typings/src/utils/organization/{f.d.ts → empty_object.d.ts} +5 -1
- package/esm/typings/src/utils/organization/just_empty_object.d.ts +12 -0
- package/package.json +1 -1
- package/umd/index.umd.js +55 -60
- package/umd/index.umd.js.map +1 -1
package/esm/index.es.js
CHANGED
|
@@ -21,7 +21,7 @@ import OpenAI from 'openai';
|
|
|
21
21
|
/**
|
|
22
22
|
* The version of the Promptbook library
|
|
23
23
|
*/
|
|
24
|
-
var PROMPTBOOK_VERSION = '0.69.0-
|
|
24
|
+
var PROMPTBOOK_VERSION = '0.69.0-11';
|
|
25
25
|
// TODO: !!!! List here all the versions and annotate + put into script
|
|
26
26
|
|
|
27
27
|
/*! *****************************************************************************
|
|
@@ -503,6 +503,19 @@ var DEFAULT_REMOTE_URL = 'https://api.pavolhejny.com/';
|
|
|
503
503
|
*/
|
|
504
504
|
var DEFAULT_REMOTE_URL_PATH = '/promptbook/socket.io';
|
|
505
505
|
// <- TODO: [🧜♂️]
|
|
506
|
+
/**
|
|
507
|
+
* @@@
|
|
508
|
+
*
|
|
509
|
+
* @public exported from `@promptbook/core`
|
|
510
|
+
*/
|
|
511
|
+
var DEFAULT_CSV_SETTINGS = {
|
|
512
|
+
header: true,
|
|
513
|
+
delimiter: ',',
|
|
514
|
+
quoteChar: '"',
|
|
515
|
+
newline: '\n',
|
|
516
|
+
skipEmptyLines: true,
|
|
517
|
+
// encoding: 'utf8'
|
|
518
|
+
};
|
|
506
519
|
/**
|
|
507
520
|
* @@@
|
|
508
521
|
*
|
|
@@ -1051,7 +1064,7 @@ function forEachAsync(array, options, callbackfunction) {
|
|
|
1051
1064
|
});
|
|
1052
1065
|
}
|
|
1053
1066
|
|
|
1054
|
-
var PipelineCollection = [{title:"Prepare Knowledge from Markdown",pipelineUrl:"https://promptbook.studio/promptbook/prepare-knowledge-from-markdown.ptbk.md",promptbookVersion:"0.69.0-
|
|
1067
|
+
var PipelineCollection = [{title:"Prepare Knowledge from Markdown",pipelineUrl:"https://promptbook.studio/promptbook/prepare-knowledge-from-markdown.ptbk.md",promptbookVersion:"0.69.0-11",parameters:[{name:"knowledgeContent",description:"Markdown document content",isInput:true,isOutput:false},{name:"knowledgePieces",description:"The knowledge JSON object",isInput:false,isOutput:true}],templates:[{templateType:"PROMPT_TEMPLATE",name:"knowledge",title:"Knowledge",content:"You are experienced data researcher, extract the important knowledge from the document.\n\n# Rules\n\n- Make pieces of information concise, clear, and easy to understand\n- One piece of information should be approximately 1 paragraph\n- Divide the paragraphs by markdown horizontal lines ---\n- Omit irrelevant information\n- Group redundant information\n- Write just extracted information, nothing else\n\n# The document\n\nTake information from this document:\n\n> {knowledgeContent}",resultingParameterName:"knowledgePieces",dependentParameterNames:["knowledgeContent"]}],knowledgeSources:[],knowledgePieces:[],personas:[],preparations:[],sourceFile:"./promptbook-collection/prepare-knowledge-from-markdown.ptbk.md"},{title:"Prepare Keywords",pipelineUrl:"https://promptbook.studio/promptbook/prepare-knowledge-keywords.ptbk.md",promptbookVersion:"0.69.0-11",parameters:[{name:"knowledgePieceContent",description:"The content",isInput:true,isOutput:false},{name:"keywords",description:"Keywords separated by comma",isInput:false,isOutput:true}],templates:[{templateType:"PROMPT_TEMPLATE",name:"knowledge",title:"Knowledge",content:"You are experienced data researcher, detect the important keywords in the document.\n\n# Rules\n\n- Write just keywords separated by comma\n\n# The document\n\nTake information from this document:\n\n> {knowledgePieceContent}",resultingParameterName:"keywords",dependentParameterNames:["knowledgePieceContent"]}],knowledgeSources:[],knowledgePieces:[],personas:[],preparations:[],sourceFile:"./promptbook-collection/prepare-knowledge-keywords.ptbk.md"},{title:"Prepare Title",pipelineUrl:"https://promptbook.studio/promptbook/prepare-knowledge-title.ptbk.md",promptbookVersion:"0.69.0-11",parameters:[{name:"knowledgePieceContent",description:"The content",isInput:true,isOutput:false},{name:"title",description:"The title of the document",isInput:false,isOutput:true}],templates:[{templateType:"PROMPT_TEMPLATE",name:"knowledge",title:"Knowledge",content:"You are experienced content creator, write best title for the document.\n\n# Rules\n\n- Write just title, nothing else\n- Title should be concise and clear\n- Write maximum 5 words for the title\n\n# The document\n\n> {knowledgePieceContent}",resultingParameterName:"title",expectations:{words:{min:1,max:8}},dependentParameterNames:["knowledgePieceContent"]}],knowledgeSources:[],knowledgePieces:[],personas:[],preparations:[],sourceFile:"./promptbook-collection/prepare-knowledge-title.ptbk.md"},{title:"Prepare Keywords",pipelineUrl:"https://promptbook.studio/promptbook/prepare-persona.ptbk.md",promptbookVersion:"0.69.0-11",parameters:[{name:"availableModelNames",description:"List of available model names separated by comma (,)",isInput:true,isOutput:false},{name:"personaDescription",description:"Description of the persona",isInput:true,isOutput:false},{name:"modelRequirements",description:"Specific requirements for the model",isInput:false,isOutput:true}],templates:[{templateType:"PROMPT_TEMPLATE",name:"make-model-requirements",title:"Make modelRequirements",content:"You are experienced AI engineer, you need to create virtual assistant.\nWrite\n\n## Sample\n\n```json\n{\n\"modelName\": \"gpt-4o\",\n\"systemMessage\": \"You are experienced AI engineer and helpfull assistant.\",\n\"temperature\": 0.7\n}\n```\n\n## Instructions\n\n- Your output format is JSON object\n- Write just the JSON object, no other text should be present\n- It contains the following keys:\n - `modelName`: The name of the model to use\n - `systemMessage`: The system message to provide context to the model\n - `temperature`: The sampling temperature to use\n\n### Key `modelName`\n\nPick from the following models:\n\n- {availableModelNames}\n\n### Key `systemMessage`\n\nThe system message is used to communicate instructions or provide context to the model at the beginning of a conversation. It is displayed in a different format compared to user messages, helping the model understand its role in the conversation. The system message typically guides the model's behavior, sets the tone, or specifies desired output from the model. By utilizing the system message effectively, users can steer the model towards generating more accurate and relevant responses.\n\nFor example:\n\n> You are an experienced AI engineer and helpful assistant.\n\n> You are a friendly and knowledgeable chatbot.\n\n### Key `temperature`\n\nThe sampling temperature, between 0 and 1. Higher values like 0.8 will make the output more random, while lower values like 0.2 will make it more focused and deterministic. If set to 0, the model will use log probability to automatically increase the temperature until certain thresholds are hit.\n\nYou can pick a value between 0 and 2. For example:\n\n- `0.1`: Low temperature, extremely conservative and deterministic\n- `0.5`: Medium temperature, balanced between conservative and creative\n- `1.0`: High temperature, creative and bit random\n- `1.5`: Very high temperature, extremely creative and often chaotic and unpredictable\n- `2.0`: Maximum temperature, completely random and unpredictable, for some extreme creative use cases\n\n# The assistant\n\nTake this description of the persona:\n\n> {personaDescription}",resultingParameterName:"modelRequirements",format:"JSON",dependentParameterNames:["availableModelNames","personaDescription"]}],knowledgeSources:[],knowledgePieces:[],personas:[],preparations:[],sourceFile:"./promptbook-collection/prepare-persona.ptbk.md"}];
|
|
1055
1068
|
|
|
1056
1069
|
/**
|
|
1057
1070
|
* This error indicates that the promptbook in a markdown format cannot be parsed into a valid promptbook object
|
|
@@ -2791,41 +2804,36 @@ function TODO_USE() {
|
|
|
2791
2804
|
var CsvFormatDefinition = {
|
|
2792
2805
|
formatName: 'CSV',
|
|
2793
2806
|
aliases: ['SPREADSHEET', 'TABLE'],
|
|
2794
|
-
isValid: function (value, schema) {
|
|
2807
|
+
isValid: function (value, settings, schema) {
|
|
2808
|
+
// TODO: !!!!!! Implement CSV validation
|
|
2795
2809
|
TODO_USE(value /* <- TODO: Use value here */);
|
|
2810
|
+
TODO_USE(settings /* <- TODO: Use settings here */);
|
|
2796
2811
|
TODO_USE(schema /* <- TODO: Use schema here */);
|
|
2797
2812
|
return true;
|
|
2798
2813
|
},
|
|
2799
|
-
canBeValid: function (partialValue, schema) {
|
|
2814
|
+
canBeValid: function (partialValue, settings, schema) {
|
|
2800
2815
|
TODO_USE(partialValue /* <- TODO: Use partialValue here */);
|
|
2816
|
+
TODO_USE(settings /* <- TODO: Use settings here */);
|
|
2801
2817
|
TODO_USE(schema /* <- TODO: Use schema here */);
|
|
2802
2818
|
return true;
|
|
2803
2819
|
},
|
|
2804
|
-
heal: function (value, schema) {
|
|
2820
|
+
heal: function (value, settings, schema) {
|
|
2805
2821
|
TODO_USE(value /* <- TODO: Use partialValue here */);
|
|
2822
|
+
TODO_USE(settings /* <- TODO: Use settings here */);
|
|
2806
2823
|
TODO_USE(schema /* <- TODO: Use schema here */);
|
|
2807
2824
|
throw new Error('Not implemented');
|
|
2808
2825
|
},
|
|
2809
2826
|
subvalueDefinitions: [
|
|
2810
2827
|
{
|
|
2811
2828
|
subvalueName: 'ROW',
|
|
2812
|
-
mapValues: function (value, mapCallback) {
|
|
2829
|
+
mapValues: function (value, settings, mapCallback) {
|
|
2813
2830
|
return __awaiter(this, void 0, void 0, function () {
|
|
2814
2831
|
var csv, mappedData;
|
|
2815
2832
|
var _this = this;
|
|
2816
2833
|
return __generator(this, function (_a) {
|
|
2817
2834
|
switch (_a.label) {
|
|
2818
2835
|
case 0:
|
|
2819
|
-
csv = parse(value,
|
|
2820
|
-
header: true,
|
|
2821
|
-
delimiter: ',',
|
|
2822
|
-
quoteChar: '"',
|
|
2823
|
-
newline: '\r\n',
|
|
2824
|
-
skipEmptyLines: true,
|
|
2825
|
-
// encoding: 'utf8',
|
|
2826
|
-
// <- TODO: !!!!!! DEFAULT_CSV_OPTIONS
|
|
2827
|
-
// <- TODO: [🧠] How to define parsing options for formats, its different concept than schema
|
|
2828
|
-
});
|
|
2836
|
+
csv = parse(value, settings);
|
|
2829
2837
|
if (csv.errors.length !== 0) {
|
|
2830
2838
|
throw new ParseError(// <- TODO: !!!!!! Split PipelineParseError and FormatParseError -> CsvParseError
|
|
2831
2839
|
spaceTrim$1(function (block) { return "\n CSV parsing error\n\n ".concat(block(csv.errors.map(function (error) { return error.message; }).join('\n\n')), "\n "); }));
|
|
@@ -2839,25 +2847,18 @@ var CsvFormatDefinition = {
|
|
|
2839
2847
|
_a = [__assign({}, row)];
|
|
2840
2848
|
_b = {};
|
|
2841
2849
|
// <- TODO: !!!!!! Dynamic new column name and position
|
|
2850
|
+
// <- TODO: !!!!!! Check name collisions
|
|
2842
2851
|
return [4 /*yield*/, mapCallback(row, index)];
|
|
2843
2852
|
case 1: return [2 /*return*/, (__assign.apply(void 0, _a.concat([(_b.newColumn =
|
|
2844
2853
|
// <- TODO: !!!!!! Dynamic new column name and position
|
|
2854
|
+
// <- TODO: !!!!!! Check name collisions
|
|
2845
2855
|
_c.sent(), _b)])))];
|
|
2846
2856
|
}
|
|
2847
2857
|
});
|
|
2848
2858
|
}); }))];
|
|
2849
2859
|
case 1:
|
|
2850
2860
|
mappedData = _a.sent();
|
|
2851
|
-
return [2 /*return*/, unparse(mappedData,
|
|
2852
|
-
header: true,
|
|
2853
|
-
delimiter: ',',
|
|
2854
|
-
quoteChar: '"',
|
|
2855
|
-
newline: '\r\n',
|
|
2856
|
-
skipEmptyLines: true,
|
|
2857
|
-
// encoding: 'utf8',
|
|
2858
|
-
// <- TODO: !!!!!! DEFAULT_CSV_OPTIONS
|
|
2859
|
-
// <- TODO: [🧠] How to define parsing options for formats, its different concept than schema
|
|
2860
|
-
})];
|
|
2861
|
+
return [2 /*return*/, unparse(mappedData, settings)];
|
|
2861
2862
|
}
|
|
2862
2863
|
});
|
|
2863
2864
|
});
|
|
@@ -2865,23 +2866,14 @@ var CsvFormatDefinition = {
|
|
|
2865
2866
|
},
|
|
2866
2867
|
{
|
|
2867
2868
|
subvalueName: 'CELL',
|
|
2868
|
-
mapValues: function (value, mapCallback) {
|
|
2869
|
+
mapValues: function (value, settings, mapCallback) {
|
|
2869
2870
|
return __awaiter(this, void 0, void 0, function () {
|
|
2870
2871
|
var csv, mappedData;
|
|
2871
2872
|
var _this = this;
|
|
2872
2873
|
return __generator(this, function (_a) {
|
|
2873
2874
|
switch (_a.label) {
|
|
2874
2875
|
case 0:
|
|
2875
|
-
csv = parse(value,
|
|
2876
|
-
header: true,
|
|
2877
|
-
delimiter: ',',
|
|
2878
|
-
quoteChar: '"',
|
|
2879
|
-
newline: '\r\n',
|
|
2880
|
-
skipEmptyLines: true,
|
|
2881
|
-
// encoding: 'utf8',
|
|
2882
|
-
// <- TODO: !!!!!! DEFAULT_CSV_OPTIONS
|
|
2883
|
-
// <- TODO: [🧠] How to define parsing options for formats, its different concept than schema
|
|
2884
|
-
});
|
|
2876
|
+
csv = parse(value, settings);
|
|
2885
2877
|
if (csv.errors.length !== 0) {
|
|
2886
2878
|
throw new ParseError(// <- TODO: !!!!!! Split PipelineParseError and FormatParseError -> CsvParseError
|
|
2887
2879
|
spaceTrim$1(function (block) { return "\n CSV parsing error\n\n ".concat(block(csv.errors.map(function (error) { return error.message; }).join('\n\n')), "\n "); }));
|
|
@@ -2904,16 +2896,7 @@ var CsvFormatDefinition = {
|
|
|
2904
2896
|
}); }))];
|
|
2905
2897
|
case 1:
|
|
2906
2898
|
mappedData = _a.sent();
|
|
2907
|
-
return [2 /*return*/, unparse(mappedData,
|
|
2908
|
-
header: true,
|
|
2909
|
-
delimiter: ',',
|
|
2910
|
-
quoteChar: '"',
|
|
2911
|
-
newline: '\r\n',
|
|
2912
|
-
skipEmptyLines: true,
|
|
2913
|
-
// encoding: 'utf8',
|
|
2914
|
-
// <- TODO: !!!!!! DEFAULT_CSV_OPTIONS
|
|
2915
|
-
// <- TODO: [🧠] How to define parsing options for formats, its different concept than schema
|
|
2916
|
-
})];
|
|
2899
|
+
return [2 /*return*/, unparse(mappedData, settings)];
|
|
2917
2900
|
}
|
|
2918
2901
|
});
|
|
2919
2902
|
});
|
|
@@ -2958,17 +2941,20 @@ function isValidJsonString(value /* <- [👨⚖️] */) {
|
|
|
2958
2941
|
var JsonFormatDefinition = {
|
|
2959
2942
|
formatName: 'JSON',
|
|
2960
2943
|
mimeType: 'application/json',
|
|
2961
|
-
isValid: function (value, schema) {
|
|
2944
|
+
isValid: function (value, settings, schema) {
|
|
2962
2945
|
TODO_USE(schema /* <- TODO: Use schema here */);
|
|
2946
|
+
TODO_USE(settings /* <- TODO: Use settings here */);
|
|
2963
2947
|
return isValidJsonString(value);
|
|
2964
2948
|
},
|
|
2965
|
-
canBeValid: function (partialValue, schema) {
|
|
2949
|
+
canBeValid: function (partialValue, settings, schema) {
|
|
2966
2950
|
TODO_USE(partialValue /* <- TODO: Use partialValue here */);
|
|
2951
|
+
TODO_USE(settings /* <- TODO: Use settings here */);
|
|
2967
2952
|
TODO_USE(schema /* <- TODO: Use schema here */);
|
|
2968
2953
|
return true;
|
|
2969
2954
|
},
|
|
2970
|
-
heal: function (value, schema) {
|
|
2955
|
+
heal: function (value, settings, schema) {
|
|
2971
2956
|
TODO_USE(value /* <- TODO: Use partialValue here */);
|
|
2957
|
+
TODO_USE(settings /* <- TODO: Use settings here */);
|
|
2972
2958
|
TODO_USE(schema /* <- TODO: Use schema here */);
|
|
2973
2959
|
throw new Error('Not implemented');
|
|
2974
2960
|
},
|
|
@@ -2977,7 +2963,7 @@ var JsonFormatDefinition = {
|
|
|
2977
2963
|
/**
|
|
2978
2964
|
* TODO: [🧠] Maybe propper instance of object
|
|
2979
2965
|
* TODO: [0] Make string_serialized_json
|
|
2980
|
-
* TODO: [1] Make type for JSON Schema
|
|
2966
|
+
* TODO: [1] Make type for JSON Settings and Schema
|
|
2981
2967
|
* TODO: [🧠] What to use for validating JSONs - JSON Schema, ZoD, typescript types/interfaces,...?
|
|
2982
2968
|
* TODO: [🍓] In `JsonFormatDefinition` implement simple `isValid`
|
|
2983
2969
|
* TODO: [🍓] In `JsonFormatDefinition` implement partial `canBeValid`
|
|
@@ -3007,7 +2993,7 @@ var TextFormatDefinition = {
|
|
|
3007
2993
|
subvalueDefinitions: [
|
|
3008
2994
|
{
|
|
3009
2995
|
subvalueName: 'LINE',
|
|
3010
|
-
mapValues: function (value, mapCallback) {
|
|
2996
|
+
mapValues: function (value, settings, mapCallback) {
|
|
3011
2997
|
return __awaiter(this, void 0, void 0, function () {
|
|
3012
2998
|
var lines, mappedLines;
|
|
3013
2999
|
return __generator(this, function (_a) {
|
|
@@ -3033,6 +3019,7 @@ var TextFormatDefinition = {
|
|
|
3033
3019
|
],
|
|
3034
3020
|
};
|
|
3035
3021
|
/**
|
|
3022
|
+
* TODO: [1] Make type for XML Text and Schema
|
|
3036
3023
|
* TODO: [🧠][🤠] Here should be all words, characters, lines, paragraphs, pages aviable as subvalues
|
|
3037
3024
|
* TODO: [🍓] In `TextFormatDefinition` implement simple `isValid`
|
|
3038
3025
|
* TODO: [🍓] In `TextFormatDefinition` implement partial `canBeValid`
|
|
@@ -3049,18 +3036,21 @@ var TextFormatDefinition = {
|
|
|
3049
3036
|
var XmlFormatDefinition = {
|
|
3050
3037
|
formatName: 'XML',
|
|
3051
3038
|
mimeType: 'application/xml',
|
|
3052
|
-
isValid: function (value, schema) {
|
|
3039
|
+
isValid: function (value, settings, schema) {
|
|
3053
3040
|
TODO_USE(value /* <- TODO: Use value here */);
|
|
3041
|
+
TODO_USE(settings /* <- TODO: Use settings here */);
|
|
3054
3042
|
TODO_USE(schema /* <- TODO: Use schema here */);
|
|
3055
3043
|
return true;
|
|
3056
3044
|
},
|
|
3057
|
-
canBeValid: function (partialValue, schema) {
|
|
3045
|
+
canBeValid: function (partialValue, settings, schema) {
|
|
3058
3046
|
TODO_USE(partialValue /* <- TODO: Use partialValue here */);
|
|
3047
|
+
TODO_USE(settings /* <- TODO: Use settings here */);
|
|
3059
3048
|
TODO_USE(schema /* <- TODO: Use schema here */);
|
|
3060
3049
|
return true;
|
|
3061
3050
|
},
|
|
3062
|
-
heal: function (value, schema) {
|
|
3051
|
+
heal: function (value, settings, schema) {
|
|
3063
3052
|
TODO_USE(value /* <- TODO: Use partialValue here */);
|
|
3053
|
+
TODO_USE(settings /* <- TODO: Use settings here */);
|
|
3064
3054
|
TODO_USE(schema /* <- TODO: Use schema here */);
|
|
3065
3055
|
throw new Error('Not implemented');
|
|
3066
3056
|
},
|
|
@@ -3069,7 +3059,7 @@ var XmlFormatDefinition = {
|
|
|
3069
3059
|
/**
|
|
3070
3060
|
* TODO: [🧠] Maybe propper instance of object
|
|
3071
3061
|
* TODO: [0] Make string_serialized_xml
|
|
3072
|
-
* TODO: [1] Make type for XML Schema
|
|
3062
|
+
* TODO: [1] Make type for XML Settings and Schema
|
|
3073
3063
|
* TODO: [🧠] What to use for validating XMLs - XSD,...
|
|
3074
3064
|
* TODO: [🍓] In `XmlFormatDefinition` implement simple `isValid`
|
|
3075
3065
|
* TODO: [🍓] In `XmlFormatDefinition` implement partial `canBeValid`
|
|
@@ -3887,12 +3877,12 @@ function executeAttempts(options) {
|
|
|
3887
3877
|
*/
|
|
3888
3878
|
function executeFormatCells(options) {
|
|
3889
3879
|
return __awaiter(this, void 0, void 0, function () {
|
|
3890
|
-
var template, jokerParameterNames, parameters, priority, pipelineIdentification, parameterValue, formatDefinition, subvalueDefinition, resultString;
|
|
3880
|
+
var template, jokerParameterNames, parameters, priority, pipelineIdentification, settings, parameterValue, formatDefinition, subvalueDefinition, formatSettings, resultString;
|
|
3891
3881
|
var _this = this;
|
|
3892
3882
|
return __generator(this, function (_a) {
|
|
3893
3883
|
switch (_a.label) {
|
|
3894
3884
|
case 0:
|
|
3895
|
-
template = options.template, jokerParameterNames = options.jokerParameterNames, parameters = options.parameters, priority = options.priority, pipelineIdentification = options.pipelineIdentification;
|
|
3885
|
+
template = options.template, jokerParameterNames = options.jokerParameterNames, parameters = options.parameters, priority = options.priority, pipelineIdentification = options.pipelineIdentification, settings = options.settings;
|
|
3896
3886
|
if (template.foreach === undefined) {
|
|
3897
3887
|
return [2 /*return*/, /* not await */ executeAttempts(options)];
|
|
3898
3888
|
}
|
|
@@ -3921,7 +3911,11 @@ function executeFormatCells(options) {
|
|
|
3921
3911
|
.map(function (subvalueName) { return "- ".concat(subvalueName); })
|
|
3922
3912
|
.join('\n')), "\n\n [\u26F7] This should never happen because cell name should be validated during parsing\n\n ").concat(block(pipelineIdentification), "\n "); }));
|
|
3923
3913
|
}
|
|
3924
|
-
|
|
3914
|
+
if (formatDefinition.formatName === 'CSV') {
|
|
3915
|
+
formatSettings = settings.csvSettings;
|
|
3916
|
+
// <- TODO: !!!!!! More universal, make simmilar pattern for other formats for example \n vs \r\n in text
|
|
3917
|
+
}
|
|
3918
|
+
return [4 /*yield*/, subvalueDefinition.mapValues(parameterValue, formatSettings, function (subparameters, index) { return __awaiter(_this, void 0, void 0, function () {
|
|
3925
3919
|
var mappedParameters, allSubparameters, subresultString;
|
|
3926
3920
|
return __generator(this, function (_a) {
|
|
3927
3921
|
switch (_a.label) {
|
|
@@ -4556,7 +4550,7 @@ function executePipeline(options) {
|
|
|
4556
4550
|
function createPipelineExecutor(options) {
|
|
4557
4551
|
var _this = this;
|
|
4558
4552
|
var pipeline = options.pipeline, tools = options.tools, _a = options.settings, settings = _a === void 0 ? {} : _a;
|
|
4559
|
-
var _b = settings.maxExecutionAttempts, maxExecutionAttempts = _b === void 0 ? MAX_EXECUTION_ATTEMPTS : _b, _c = settings.maxParallelCount, maxParallelCount = _c === void 0 ? MAX_PARALLEL_COUNT : _c, _d = settings.
|
|
4553
|
+
var _b = settings.maxExecutionAttempts, maxExecutionAttempts = _b === void 0 ? MAX_EXECUTION_ATTEMPTS : _b, _c = settings.maxParallelCount, maxParallelCount = _c === void 0 ? MAX_PARALLEL_COUNT : _c, _d = settings.csvSettings, csvSettings = _d === void 0 ? DEFAULT_CSV_SETTINGS : _d, _e = settings.isVerbose, isVerbose = _e === void 0 ? IS_VERBOSE : _e, _f = settings.isNotPreparedWarningSupressed, isNotPreparedWarningSupressed = _f === void 0 ? false : _f;
|
|
4560
4554
|
validatePipeline(pipeline);
|
|
4561
4555
|
var pipelineIdentification = (function () {
|
|
4562
4556
|
// Note: This is a 😐 implementation of [🚞]
|
|
@@ -4591,6 +4585,7 @@ function createPipelineExecutor(options) {
|
|
|
4591
4585
|
settings: {
|
|
4592
4586
|
maxExecutionAttempts: maxExecutionAttempts,
|
|
4593
4587
|
maxParallelCount: maxParallelCount,
|
|
4588
|
+
csvSettings: csvSettings,
|
|
4594
4589
|
isVerbose: isVerbose,
|
|
4595
4590
|
isNotPreparedWarningSupressed: isNotPreparedWarningSupressed,
|
|
4596
4591
|
},
|