@promptbook/cli 0.81.0-17 → 0.81.0-18

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
@@ -39,7 +39,7 @@ var BOOK_LANGUAGE_VERSION = '1.0.0';
39
39
  * @generated
40
40
  * @see https://github.com/webgptorg/promptbook
41
41
  */
42
- var PROMPTBOOK_ENGINE_VERSION = '0.81.0-16';
42
+ var PROMPTBOOK_ENGINE_VERSION = '0.81.0-17';
43
43
  /**
44
44
  * TODO: string_promptbook_version should be constrained to the all versions of Promptbook engine
45
45
  * Note: [💞] Ignore a discrepancy between file name and entity name
@@ -9846,7 +9846,7 @@ function precompilePipeline(pipelineString) {
9846
9846
  var returnStatement_1 = pipelineStringLines.pop();
9847
9847
  var prompt_1 = spaceTrim$1(pipelineStringLines.join('\n'));
9848
9848
  pipelineString = spaceTrim$1(function (block) { return "\n # ".concat(DEFAULT_TITLE /* <- TODO: !!!!!! Title for flat pipelines */, "\n\n ## Prompt\n\n ```\n ").concat(block(prompt_1), "\n ```\n\n ").concat(returnStatement_1, "\n "); });
9849
- // <- TODO: !!!!!! Use `book notation
9849
+ // <- TODO: !!!!!! Use book` notation
9850
9850
  // console.log(pipelineString);
9851
9851
  }
9852
9852
  // ==============
@@ -12361,7 +12361,7 @@ function executionReportJsonToString(executionReportJson, options) {
12361
12361
  */
12362
12362
  function $getCompiledBook(tools, pipelineSource, options) {
12363
12363
  return __awaiter(this, void 0, void 0, function () {
12364
- var fs, fetch, filePathRaw, filePath, filePathCandidates, filePathCandidates_1, filePathCandidates_1_1, filePathCandidate, pipelineString, pipelineJson, e_1_1, rootDirname, _loop_1, i, state_1, response_1, pipelineString, pipelineJson;
12364
+ var fs, fetch, filePathRaw, filePath, filePathCandidates, filePathCandidates_1, filePathCandidates_1_1, filePathCandidate, pipelineString, pipelineJson, e_1_1, rootDirname, _loop_1, i, state_1, response_1, pipelineString, pipelineJson, pipelineJson;
12365
12365
  var e_1, _a;
12366
12366
  var _this = this;
12367
12367
  return __generator(this, function (_b) {
@@ -12491,11 +12491,11 @@ function $getCompiledBook(tools, pipelineSource, options) {
12491
12491
  pipelineJson = _b.sent();
12492
12492
  return [2 /*return*/, pipelineJson];
12493
12493
  case 18:
12494
- // Strategy 4️⃣: If the pipelineSource is a PipelineString - try to parse it
12495
- if (just(false) /* <- TODO: !!!!!! Implement, use and export `isValidPipelineString` */) {
12496
- throw new NotYetImplementedError('Strategy 4️⃣: If the pipelineSource is a PipelineString - try to parse it');
12497
- } /* not else */
12498
- throw new NotFoundError(spaceTrim(function (block) { return "\n Book not found:\n ".concat(block(pipelineSource), "\n\n Pipelines can be loaded from:\n 1) As a file ./books/write-cv.book.md\n 2) As a URL https://promptbook.studio/hejny/write-cv.book.md found in ./books folder recursively\n 2) As a URL https://promptbook.studio/hejny/write-cv.book.md fetched from the internet\n 3) As a string\n\n\n "); }));
12494
+ return [4 /*yield*/, compilePipeline(pipelineSource, tools, __assign({ rootDirname: null }, options))];
12495
+ case 19:
12496
+ pipelineJson = _b.sent();
12497
+ return [2 /*return*/, pipelineJson];
12498
+ case 20: /* not else */ throw new NotFoundError(spaceTrim(function (block) { return "\n Book not found:\n ".concat(block(pipelineSource), "\n\n Pipelines can be loaded from:\n 1) As a file ./books/write-cv.book.md\n 2) As a URL https://promptbook.studio/hejny/write-cv.book.md found in ./books folder recursively\n 2) As a URL https://promptbook.studio/hejny/write-cv.book.md fetched from the internet\n 3) As a string\n\n\n "); }));
12499
12499
  }
12500
12500
  });
12501
12501
  });
@@ -16656,7 +16656,10 @@ var websiteScraperMetadata = $deepFreeze({
16656
16656
  className: 'WebsiteScraper',
16657
16657
  mimeTypes: ['text/html'],
16658
16658
  documentationUrl: 'https://github.com/webgptorg/promptbook/discussions/@@',
16659
- isAvilableInBrowser: false,
16659
+ isAvilableInBrowser: true,
16660
+ // <- TODO: !!!!!!! Is it available in browser?
16661
+ // <- TODO: !!!!!!! Is toggling this to true enough to make it available in browser?
16662
+ // <- TODO: Maybe make it available in browser
16660
16663
  requiredExecutables: [],
16661
16664
  }); /* <- Note: [🤛] */
16662
16665
  /**