@promptbook/cli 0.75.3 → 0.75.5

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
@@ -37,7 +37,7 @@ var BOOK_LANGUAGE_VERSION = '1.0.0';
37
37
  *
38
38
  * @see https://github.com/webgptorg/promptbook
39
39
  */
40
- var PROMPTBOOK_ENGINE_VERSION = '0.75.2';
40
+ var PROMPTBOOK_ENGINE_VERSION = '0.75.4';
41
41
  /**
42
42
  * TODO: string_promptbook_version should be constrained to the all versions of Promptbook engine
43
43
  * Note: [💞] Ignore a discrepancy between file name and entity name
@@ -2215,6 +2215,42 @@ function createCollectionFromJson() {
2215
2215
  return new (SimplePipelineCollection.bind.apply(SimplePipelineCollection, __spreadArray([void 0], __read(promptbooks), false)))();
2216
2216
  }
2217
2217
 
2218
+ /**
2219
+ * This error indicates problems parsing the format value
2220
+ *
2221
+ * For example, when the format value is not a valid JSON or CSV
2222
+ * This is not thrown directly but in extended classes
2223
+ *
2224
+ * @public exported from `@promptbook/core`
2225
+ */
2226
+ var AbstractFormatError = /** @class */ (function (_super) {
2227
+ __extends(AbstractFormatError, _super);
2228
+ // Note: To allow instanceof do not put here error `name`
2229
+ // public readonly name = 'AbstractFormatError';
2230
+ function AbstractFormatError(message) {
2231
+ var _this = _super.call(this, message) || this;
2232
+ Object.setPrototypeOf(_this, AbstractFormatError.prototype);
2233
+ return _this;
2234
+ }
2235
+ return AbstractFormatError;
2236
+ }(Error));
2237
+
2238
+ /**
2239
+ * This error indicates problem with parsing of CSV
2240
+ *
2241
+ * @public exported from `@promptbook/core`
2242
+ */
2243
+ var CsvFormatError = /** @class */ (function (_super) {
2244
+ __extends(CsvFormatError, _super);
2245
+ function CsvFormatError(message) {
2246
+ var _this = _super.call(this, message) || this;
2247
+ _this.name = 'CsvFormatError';
2248
+ Object.setPrototypeOf(_this, CsvFormatError.prototype);
2249
+ return _this;
2250
+ }
2251
+ return CsvFormatError;
2252
+ }(AbstractFormatError));
2253
+
2218
2254
  /**
2219
2255
  * This error indicates that the pipeline collection cannot be propperly loaded
2220
2256
  *
@@ -2250,6 +2286,22 @@ var ExpectError = /** @class */ (function (_super) {
2250
2286
  return ExpectError;
2251
2287
  }(Error));
2252
2288
 
2289
+ /**
2290
+ * This error indicates that the promptbook can not retrieve knowledge from external sources
2291
+ *
2292
+ * @public exported from `@promptbook/core`
2293
+ */
2294
+ var KnowledgeScrapeError = /** @class */ (function (_super) {
2295
+ __extends(KnowledgeScrapeError, _super);
2296
+ function KnowledgeScrapeError(message) {
2297
+ var _this = _super.call(this, message) || this;
2298
+ _this.name = 'KnowledgeScrapeError';
2299
+ Object.setPrototypeOf(_this, KnowledgeScrapeError.prototype);
2300
+ return _this;
2301
+ }
2302
+ return KnowledgeScrapeError;
2303
+ }(Error));
2304
+
2253
2305
  /**
2254
2306
  * This error type indicates that some limit was reached
2255
2307
  *
@@ -2288,10 +2340,14 @@ var NotYetImplementedError = /** @class */ (function (_super) {
2288
2340
  * @public exported from `@promptbook/core`
2289
2341
  */
2290
2342
  var ERRORS = {
2291
- ExpectError: ExpectError,
2343
+ AbstractFormatError: AbstractFormatError,
2344
+ CsvFormatError: CsvFormatError,
2292
2345
  CollectionError: CollectionError,
2293
2346
  EnvironmentMismatchError: EnvironmentMismatchError,
2347
+ ExpectError: ExpectError,
2348
+ KnowledgeScrapeError: KnowledgeScrapeError,
2294
2349
  LimitReachedError: LimitReachedError,
2350
+ MissingToolsError: MissingToolsError,
2295
2351
  NotFoundError: NotFoundError,
2296
2352
  NotYetImplementedError: NotYetImplementedError,
2297
2353
  ParseError: ParseError,
@@ -2617,42 +2673,6 @@ function union() {
2617
2673
  function TODO_USE() {
2618
2674
  }
2619
2675
 
2620
- /**
2621
- * This error indicates problems parsing the format value
2622
- *
2623
- * For example, when the format value is not a valid JSON or CSV
2624
- * This is not thrown directly but in extended classes
2625
- *
2626
- * @public exported from `@promptbook/core`
2627
- */
2628
- var AbstractFormatError = /** @class */ (function (_super) {
2629
- __extends(AbstractFormatError, _super);
2630
- // Note: To allow instanceof do not put here error `name`
2631
- // public readonly name = 'AbstractFormatError';
2632
- function AbstractFormatError(message) {
2633
- var _this = _super.call(this, message) || this;
2634
- Object.setPrototypeOf(_this, AbstractFormatError.prototype);
2635
- return _this;
2636
- }
2637
- return AbstractFormatError;
2638
- }(Error));
2639
-
2640
- /**
2641
- * This error indicates problem with parsing of CSV
2642
- *
2643
- * @public exported from `@promptbook/core`
2644
- */
2645
- var CsvFormatError = /** @class */ (function (_super) {
2646
- __extends(CsvFormatError, _super);
2647
- function CsvFormatError(message) {
2648
- var _this = _super.call(this, message) || this;
2649
- _this.name = 'CsvFormatError';
2650
- Object.setPrototypeOf(_this, CsvFormatError.prototype);
2651
- return _this;
2652
- }
2653
- return CsvFormatError;
2654
- }(AbstractFormatError));
2655
-
2656
2676
  /**
2657
2677
  * @@@
2658
2678
  *
@@ -2693,7 +2713,7 @@ var CsvFormatDefinition = {
2693
2713
  case 0:
2694
2714
  csv = parse(value, __assign(__assign({}, settings), MANDATORY_CSV_SETTINGS));
2695
2715
  if (csv.errors.length !== 0) {
2696
- throw new CsvFormatError(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 "); }));
2716
+ throw new CsvFormatError(spaceTrim$1(function (block) { return "\n CSV parsing error\n\n Error(s) from CSV parsing:\n ".concat(block(csv.errors.map(function (error) { return error.message; }).join('\n\n')), "\n\n The CSV data:\n ").concat(block(value), "\n "); }));
2697
2717
  }
2698
2718
  return [4 /*yield*/, Promise.all(csv.data.map(function (row, index) { return __awaiter(_this, void 0, void 0, function () {
2699
2719
  var _a, _b;
@@ -2731,7 +2751,7 @@ var CsvFormatDefinition = {
2731
2751
  case 0:
2732
2752
  csv = parse(value, __assign(__assign({}, settings), MANDATORY_CSV_SETTINGS));
2733
2753
  if (csv.errors.length !== 0) {
2734
- throw new CsvFormatError(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 "); }));
2754
+ throw new CsvFormatError(spaceTrim$1(function (block) { return "\n CSV parsing error\n\n Error(s) from CSV parsing:\n ".concat(block(csv.errors.map(function (error) { return error.message; }).join('\n\n')), "\n\n The CSV data:\n ").concat(block(value), "\n "); }));
2735
2755
  }
2736
2756
  return [4 /*yield*/, Promise.all(csv.data.map(function (row, rowIndex) { return __awaiter(_this, void 0, void 0, function () {
2737
2757
  var _this = this;
@@ -4769,22 +4789,6 @@ function preparePersona(personaDescription, tools, options) {
4769
4789
  * TODO: [🏢] !! Check validity of `temperature` in pipeline
4770
4790
  */
4771
4791
 
4772
- /**
4773
- * This error indicates that the promptbook can not retrieve knowledge from external sources
4774
- *
4775
- * @public exported from `@promptbook/core`
4776
- */
4777
- var KnowledgeScrapeError = /** @class */ (function (_super) {
4778
- __extends(KnowledgeScrapeError, _super);
4779
- function KnowledgeScrapeError(message) {
4780
- var _this = _super.call(this, message) || this;
4781
- _this.name = 'KnowledgeScrapeError';
4782
- Object.setPrototypeOf(_this, KnowledgeScrapeError.prototype);
4783
- return _this;
4784
- }
4785
- return KnowledgeScrapeError;
4786
- }(Error));
4787
-
4788
4792
  /**
4789
4793
  * @@@
4790
4794
  *
@@ -4955,8 +4959,8 @@ var $scrapersRegister = new $Register('scraper_constructors');
4955
4959
  *
4956
4960
  * @private internal function of `createScrapersFromConfiguration` and `createScrapersFromEnv`
4957
4961
  */
4958
- function $registeredScrapersMessage() {
4959
- var e_1, _a, e_2, _b;
4962
+ function $registeredScrapersMessage(availableScrapers) {
4963
+ var e_1, _a, e_2, _b, e_3, _c;
4960
4964
  /**
4961
4965
  * Mixes registered scrapers from $scrapersMetadataRegister and $scrapersRegister
4962
4966
  */
@@ -4968,15 +4972,15 @@ function $registeredScrapersMessage() {
4968
4972
  all.push({ packageName: packageName, className: className, mimeTypes: mimeTypes, documentationUrl: documentationUrl, isAvilableInBrowser: isAvilableInBrowser });
4969
4973
  };
4970
4974
  try {
4971
- for (var _c = __values($scrapersMetadataRegister.list()), _d = _c.next(); !_d.done; _d = _c.next()) {
4972
- var _e = _d.value, packageName = _e.packageName, className = _e.className, mimeTypes = _e.mimeTypes, documentationUrl = _e.documentationUrl, isAvilableInBrowser = _e.isAvilableInBrowser;
4975
+ for (var _d = __values($scrapersMetadataRegister.list()), _e = _d.next(); !_e.done; _e = _d.next()) {
4976
+ var _f = _e.value, packageName = _f.packageName, className = _f.className, mimeTypes = _f.mimeTypes, documentationUrl = _f.documentationUrl, isAvilableInBrowser = _f.isAvilableInBrowser;
4973
4977
  _loop_1(packageName, className, mimeTypes, documentationUrl, isAvilableInBrowser);
4974
4978
  }
4975
4979
  }
4976
4980
  catch (e_1_1) { e_1 = { error: e_1_1 }; }
4977
4981
  finally {
4978
4982
  try {
4979
- if (_d && !_d.done && (_a = _c.return)) _a.call(_c);
4983
+ if (_e && !_e.done && (_a = _d.return)) _a.call(_d);
4980
4984
  }
4981
4985
  finally { if (e_1) throw e_1.error; }
4982
4986
  }
@@ -4987,18 +4991,31 @@ function $registeredScrapersMessage() {
4987
4991
  all.push({ packageName: packageName, className: className, mimeTypes: mimeTypes, documentationUrl: documentationUrl, isAvilableInBrowser: isAvilableInBrowser });
4988
4992
  };
4989
4993
  try {
4990
- for (var _f = __values($scrapersRegister.list()), _g = _f.next(); !_g.done; _g = _f.next()) {
4991
- var _h = _g.value, packageName = _h.packageName, className = _h.className, mimeTypes = _h.mimeTypes, documentationUrl = _h.documentationUrl, isAvilableInBrowser = _h.isAvilableInBrowser;
4994
+ for (var _g = __values($scrapersRegister.list()), _h = _g.next(); !_h.done; _h = _g.next()) {
4995
+ var _j = _h.value, packageName = _j.packageName, className = _j.className, mimeTypes = _j.mimeTypes, documentationUrl = _j.documentationUrl, isAvilableInBrowser = _j.isAvilableInBrowser;
4992
4996
  _loop_2(packageName, className, mimeTypes, documentationUrl, isAvilableInBrowser);
4993
4997
  }
4994
4998
  }
4995
4999
  catch (e_2_1) { e_2 = { error: e_2_1 }; }
4996
5000
  finally {
4997
5001
  try {
4998
- if (_g && !_g.done && (_b = _f.return)) _b.call(_f);
5002
+ if (_h && !_h.done && (_b = _g.return)) _b.call(_g);
4999
5003
  }
5000
5004
  finally { if (e_2) throw e_2.error; }
5001
5005
  }
5006
+ try {
5007
+ for (var availableScrapers_1 = __values(availableScrapers), availableScrapers_1_1 = availableScrapers_1.next(); !availableScrapers_1_1.done; availableScrapers_1_1 = availableScrapers_1.next()) {
5008
+ var metadata_1 = availableScrapers_1_1.value.metadata;
5009
+ all.push(metadata_1);
5010
+ }
5011
+ }
5012
+ catch (e_3_1) { e_3 = { error: e_3_1 }; }
5013
+ finally {
5014
+ try {
5015
+ if (availableScrapers_1_1 && !availableScrapers_1_1.done && (_c = availableScrapers_1.return)) _c.call(availableScrapers_1);
5016
+ }
5017
+ finally { if (e_3) throw e_3.error; }
5018
+ }
5002
5019
  var metadata = all.map(function (metadata) {
5003
5020
  var isMetadataAviailable = $scrapersMetadataRegister
5004
5021
  .list()
@@ -5012,42 +5029,44 @@ function $registeredScrapersMessage() {
5012
5029
  var packageName = _a.packageName, className = _a.className;
5013
5030
  return metadata.packageName === packageName && metadata.className === className;
5014
5031
  });
5015
- return __assign(__assign({}, metadata), { isMetadataAviailable: isMetadataAviailable, isInstalled: isInstalled });
5032
+ var isAvilableInTools = availableScrapers.some(function (_a) {
5033
+ var _b = _a.metadata, packageName = _b.packageName, className = _b.className;
5034
+ return metadata.packageName === packageName && metadata.className === className;
5035
+ });
5036
+ return __assign(__assign({}, metadata), { isMetadataAviailable: isMetadataAviailable, isInstalled: isInstalled, isAvilableInTools: isAvilableInTools });
5016
5037
  });
5017
5038
  if (metadata.length === 0) {
5018
- return "No scrapers are available";
5039
+ return spaceTrim$1("\n **No scrapers are available**\n\n This is a unexpected behavior, you are probably using some broken version of Promptbook\n At least there should be available the metadata of the scrapers\n ");
5019
5040
  }
5020
5041
  return spaceTrim$1(function (block) { return "\n Available scrapers are:\n ".concat(block(metadata
5021
5042
  .map(function (_a, i) {
5022
- var packageName = _a.packageName, className = _a.className, isMetadataAviailable = _a.isMetadataAviailable, isInstalled = _a.isInstalled, mimeTypes = _a.mimeTypes, isAvilableInBrowser = _a.isAvilableInBrowser;
5023
- var more;
5024
- // TODO: Use documentationUrl
5025
- if (just(false)) {
5026
- more = '';
5027
- }
5028
- else if (!isMetadataAviailable && !isInstalled) {
5029
- // TODO: [�][�] Maybe do allow to do auto-install if package not registered and not found
5030
- more = "*(not installed and no metadata, looks like a unexpected behavior)*";
5031
- }
5032
- else if (isMetadataAviailable && !isInstalled) {
5033
- // TODO: [�][�]
5034
- more = "*(not installed)*";
5035
- }
5036
- else if (!isMetadataAviailable && isInstalled) {
5037
- more = "*(no metadata, looks like a unexpected behavior)*";
5038
- }
5039
- else if (isMetadataAviailable && isInstalled) {
5040
- more = "(installed)";
5041
- }
5042
- else {
5043
- more = "*(unknown state, looks like a unexpected behavior)*";
5044
- }
5043
+ var packageName = _a.packageName, className = _a.className, isMetadataAviailable = _a.isMetadataAviailable, isInstalled = _a.isInstalled, mimeTypes = _a.mimeTypes, isAvilableInBrowser = _a.isAvilableInBrowser, isAvilableInTools = _a.isAvilableInTools;
5044
+ var more = [];
5045
+ // TODO: [🧠] Maybe use `documentationUrl`
5046
+ if (isMetadataAviailable) {
5047
+ more.push("\u2B1C Metadata registered");
5048
+ } // not else
5049
+ if (isInstalled) {
5050
+ more.push("\uD83D\uDFE9 Installed");
5051
+ } // not else
5052
+ if (isAvilableInTools) {
5053
+ more.push("\uD83D\uDFE6 Available in tools");
5054
+ } // not else
5055
+ if (!isMetadataAviailable && isInstalled) {
5056
+ more.push("When no metadata registered but scraper is installed, it is an unexpected behavior");
5057
+ } // not else
5058
+ if (!isInstalled && isAvilableInTools) {
5059
+ more.push("When the scraper is not installed but available in tools, it is an unexpected compatibility behavior");
5060
+ } // not else
5045
5061
  if (!isAvilableInBrowser) {
5046
- more += " *(not available in browser)*";
5062
+ more.push("Not usable in browser");
5047
5063
  }
5048
- return "".concat(i + 1, ") `").concat(className, "` from `").concat(packageName, "` compatible to scrape ").concat(mimeTypes.join(', '), " ").concat(more);
5064
+ var moreText = more.length === 0 ? '' : " *(".concat(more.join('; '), ")*");
5065
+ return "".concat(i + 1, ") `").concat(className, "` from `").concat(packageName, "` compatible to scrape ").concat(mimeTypes
5066
+ .map(function (mimeType) { return "\"".concat(mimeType, "\""); })
5067
+ .join(', ')).concat(moreText);
5049
5068
  })
5050
- .join('\n')), "\n "); });
5069
+ .join('\n')), "\n\n Legend:\n - \u2B1C **Metadata registered** means that Promptbook knows about the scraper, it is similar to registration in some registry\n - \uD83D\uDFE9 **Installed** means that you have imported package with particular scraper\n - \uD83D\uDFE6 **Available in tools** means that you have passed scraper as dependency into prepare or execution process\n\n "); });
5051
5070
  }
5052
5071
  /**
5053
5072
  * TODO: [®] DRY Register logic
@@ -5383,57 +5402,75 @@ function prepareKnowledgePieces(knowledgeSources, tools, options) {
5383
5402
  _a = options.maxParallelCount, maxParallelCount = _a === void 0 ? DEFAULT_MAX_PARALLEL_COUNT : _a, rootDirname = options.rootDirname, _b = options.isVerbose, isVerbose = _b === void 0 ? DEFAULT_IS_VERBOSE : _b;
5384
5403
  knowledgePreparedUnflatten = new Array(knowledgeSources.length);
5385
5404
  return [4 /*yield*/, forEachAsync(knowledgeSources, { maxParallelCount: maxParallelCount }, function (knowledgeSource, index) { return __awaiter(_this, void 0, void 0, function () {
5386
- var partialPieces, sourceHandler, _a, _b, scraper, partialPiecesUnchecked, e_1_1, pieces;
5387
- var e_1, _c;
5388
- return __generator(this, function (_d) {
5389
- switch (_d.label) {
5405
+ var partialPieces, sourceHandler, scrapers, _loop_1, scrapers_1, scrapers_1_1, scraper, state_1, e_1_1, pieces;
5406
+ var e_1, _a;
5407
+ return __generator(this, function (_b) {
5408
+ switch (_b.label) {
5390
5409
  case 0:
5391
5410
  partialPieces = null;
5392
5411
  return [4 /*yield*/, makeKnowledgeSourceHandler(knowledgeSource, tools, { rootDirname: rootDirname, isVerbose: isVerbose })];
5393
5412
  case 1:
5394
- sourceHandler = _d.sent();
5395
- _d.label = 2;
5413
+ sourceHandler = _b.sent();
5414
+ scrapers = arrayableToArray(tools.scrapers);
5415
+ _loop_1 = function (scraper) {
5416
+ var partialPiecesUnchecked;
5417
+ return __generator(this, function (_c) {
5418
+ switch (_c.label) {
5419
+ case 0:
5420
+ if (!scraper.metadata.mimeTypes.includes(sourceHandler.mimeType)
5421
+ // <- TODO: [🦔] Implement mime-type wildcards
5422
+ ) {
5423
+ return [2 /*return*/, "continue"];
5424
+ }
5425
+ return [4 /*yield*/, scraper.scrape(sourceHandler)];
5426
+ case 1:
5427
+ partialPiecesUnchecked = _c.sent();
5428
+ if (partialPiecesUnchecked !== null) {
5429
+ partialPieces = __spreadArray([], __read(partialPiecesUnchecked), false);
5430
+ return [2 /*return*/, "break"];
5431
+ }
5432
+ console.warn(spaceTrim$1(function (block) { return "\n Cannot scrape knowledge from source despite the scraper `".concat(scraper.metadata.className, "` supports the mime type \"").concat(sourceHandler.mimeType, "\".\n \n The source:\n > ").concat(block(knowledgeSource.sourceContent
5433
+ .split('\n')
5434
+ .map(function (line) { return "> ".concat(line); })
5435
+ .join('\n')), "\n\n ").concat(block($registeredScrapersMessage(scrapers)), "\n\n\n "); }));
5436
+ return [2 /*return*/];
5437
+ }
5438
+ });
5439
+ };
5440
+ _b.label = 2;
5396
5441
  case 2:
5397
- _d.trys.push([2, 7, 8, 9]);
5398
- _a = __values(arrayableToArray(tools.scrapers)), _b = _a.next();
5399
- _d.label = 3;
5442
+ _b.trys.push([2, 7, 8, 9]);
5443
+ scrapers_1 = __values(scrapers), scrapers_1_1 = scrapers_1.next();
5444
+ _b.label = 3;
5400
5445
  case 3:
5401
- if (!!_b.done) return [3 /*break*/, 6];
5402
- scraper = _b.value;
5403
- if (!scraper.metadata.mimeTypes.includes(sourceHandler.mimeType)
5404
- // <- TODO: [🦔] Implement mime-type wildcards
5405
- ) {
5406
- return [3 /*break*/, 5];
5407
- }
5408
- return [4 /*yield*/, scraper.scrape(sourceHandler)];
5446
+ if (!!scrapers_1_1.done) return [3 /*break*/, 6];
5447
+ scraper = scrapers_1_1.value;
5448
+ return [5 /*yield**/, _loop_1(scraper)];
5409
5449
  case 4:
5410
- partialPiecesUnchecked = _d.sent();
5411
- if (partialPiecesUnchecked !== null) {
5412
- partialPieces = __spreadArray([], __read(partialPiecesUnchecked), false);
5413
- // <- TODO: [🪓] Here should be no need for spreading new array, just `partialPieces = partialPiecesUnchecked`
5450
+ state_1 = _b.sent();
5451
+ if (state_1 === "break")
5414
5452
  return [3 /*break*/, 6];
5415
- }
5416
- _d.label = 5;
5453
+ _b.label = 5;
5417
5454
  case 5:
5418
- _b = _a.next();
5455
+ scrapers_1_1 = scrapers_1.next();
5419
5456
  return [3 /*break*/, 3];
5420
5457
  case 6: return [3 /*break*/, 9];
5421
5458
  case 7:
5422
- e_1_1 = _d.sent();
5459
+ e_1_1 = _b.sent();
5423
5460
  e_1 = { error: e_1_1 };
5424
5461
  return [3 /*break*/, 9];
5425
5462
  case 8:
5426
5463
  try {
5427
- if (_b && !_b.done && (_c = _a.return)) _c.call(_a);
5464
+ if (scrapers_1_1 && !scrapers_1_1.done && (_a = scrapers_1.return)) _a.call(scrapers_1);
5428
5465
  }
5429
5466
  finally { if (e_1) throw e_1.error; }
5430
5467
  return [7 /*endfinally*/];
5431
5468
  case 9:
5432
5469
  if (partialPieces === null) {
5433
- throw new KnowledgeScrapeError(spaceTrim$1(function (block) { return "\n Cannot scrape knowledge from source:\n \n > ".concat(block(knowledgeSource.sourceContent
5470
+ throw new KnowledgeScrapeError(spaceTrim$1(function (block) { return "\n Cannot scrape knowledge\n \n The source:\n > ".concat(block(knowledgeSource.sourceContent
5434
5471
  .split('\n')
5435
5472
  .map(function (line) { return "> ".concat(line); })
5436
- .join('\n')), "\n\n No scraper found for the mime type \"").concat(sourceHandler.mimeType, "\"\n\n ").concat(block($registeredScrapersMessage()), "\n\n\n "); }));
5473
+ .join('\n')), "\n\n No scraper found for the mime type \"").concat(sourceHandler.mimeType, "\"\n\n ").concat(block($registeredScrapersMessage(scrapers)), "\n\n\n "); }));
5437
5474
  }
5438
5475
  pieces = partialPieces.map(function (partialPiece) { return (__assign(__assign({}, partialPiece), { sources: [
5439
5476
  {