@promptbook/cli 0.71.0-14 → 0.71.0-15

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.
@@ -53,6 +53,4 @@ export type ExecutionTools = {
53
53
  };
54
54
  /**
55
55
  * TODO: !!!!!! Move here also the executables and make $provideXxxxForNode
56
- * TODO: [🍂] Maybe make llm = $provideLlmToolsFromEnv() without problem with bundle contaminated by only `@promptbook/node` and `@promptbook/cli` stuff
57
- * TODO: [🍂] Same with scrapers
58
56
  */
@@ -23,5 +23,4 @@ export declare function $provideLlmToolsFromEnv(options?: CreateLlmToolsFromConf
23
23
  * TODO: [🥃] Allow `ptbk make` without llm tools
24
24
  * TODO: This should be maybe not under `_common` but under `utils`
25
25
  * TODO: [®] DRY Register logic
26
- * TODO: [🍂] Maybe make llm = $provideLlmToolsFromEnv() without problem with bundle contaminated by only `@promptbook/node` and `@promptbook/cli` stuff
27
26
  */
@@ -9,7 +9,7 @@ import type { Scraper } from '../Scraper';
9
9
  *
10
10
  * @public exported from `@promptbook/node`
11
11
  */
12
- export declare function $provideScrapersForNode(tools: Pick<ExecutionTools, 'llm'>, options?: PrepareAndScrapeOptions): Promise<Array<Scraper>>;
12
+ export declare function $provideScrapersForNode(tools: Pick<ExecutionTools, 'fs' | 'llm'>, options?: PrepareAndScrapeOptions): Promise<Array<Scraper>>;
13
13
  /**
14
14
  * Note: [🟢] Code in this file should never be never released in packages that could be imported into browser environment
15
15
  */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@promptbook/cli",
3
- "version": "0.71.0-14",
3
+ "version": "0.71.0-15",
4
4
  "description": "Supercharge your use of large language models",
5
5
  "private": false,
6
6
  "sideEffects": false,
package/umd/index.umd.js CHANGED
@@ -39,7 +39,7 @@
39
39
  /**
40
40
  * The version of the Promptbook library
41
41
  */
42
- var PROMPTBOOK_VERSION = '0.71.0-13';
42
+ var PROMPTBOOK_VERSION = '0.71.0-14';
43
43
  // TODO: [main] !!!! List here all the versions and annotate + put into script
44
44
 
45
45
  /*! *****************************************************************************
@@ -8594,7 +8594,6 @@
8594
8594
  * TODO: [🥃] Allow `ptbk make` without llm tools
8595
8595
  * TODO: This should be maybe not under `_common` but under `utils`
8596
8596
  * TODO: [®] DRY Register logic
8597
- * TODO: [🍂] Maybe make llm = $provideLlmToolsFromEnv() without problem with bundle contaminated by only `@promptbook/node` and `@promptbook/cli` stuff
8598
8597
  */
8599
8598
 
8600
8599
  /**
@@ -9132,7 +9131,7 @@
9132
9131
  */
9133
9132
  function $provideExecutionToolsForNode(options) {
9134
9133
  return __awaiter(this, void 0, void 0, function () {
9135
- var llm, tools;
9134
+ var fs, llm, tools;
9136
9135
  var _a;
9137
9136
  return __generator(this, function (_b) {
9138
9137
  switch (_b.label) {
@@ -9140,12 +9139,13 @@
9140
9139
  if (!$isRunningInNode()) {
9141
9140
  throw new EnvironmentMismatchError('Function `$getExecutionToolsForNode` works only in Node.js environment');
9142
9141
  }
9142
+ fs = $provideFilesystemForNode();
9143
9143
  llm = $provideLlmToolsFromEnv(options);
9144
9144
  _a = {
9145
9145
  llm: llm,
9146
- fs: $provideFilesystemForNode()
9146
+ fs: fs
9147
9147
  };
9148
- return [4 /*yield*/, $provideScrapersForNode({ llm: llm }, options)];
9148
+ return [4 /*yield*/, $provideScrapersForNode({ fs: fs, llm: llm }, options)];
9149
9149
  case 1:
9150
9150
  tools = (_a.scrapers = _b.sent(),
9151
9151
  _a.script = [new JavascriptExecutionTools(options)],