@promptbook/markdown-utils 0.89.0 → 0.92.0-3

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.
@@ -87,6 +87,7 @@ import { FORMFACTOR_DEFINITIONS } from '../formfactors/index';
87
87
  import { MatcherFormfactorDefinition } from '../formfactors/matcher/MatcherFormfactorDefinition';
88
88
  import { SheetsFormfactorDefinition } from '../formfactors/sheets/SheetsFormfactorDefinition';
89
89
  import { TranslatorFormfactorDefinition } from '../formfactors/translator/TranslatorFormfactorDefinition';
90
+ import { filterModels } from '../llm-providers/_common/filterModels';
90
91
  import { $llmToolsMetadataRegister } from '../llm-providers/_common/register/$llmToolsMetadataRegister';
91
92
  import { $llmToolsRegister } from '../llm-providers/_common/register/$llmToolsRegister';
92
93
  import { createLlmToolsFromConfiguration } from '../llm-providers/_common/register/createLlmToolsFromConfiguration';
@@ -225,6 +226,7 @@ export { FORMFACTOR_DEFINITIONS };
225
226
  export { MatcherFormfactorDefinition };
226
227
  export { SheetsFormfactorDefinition };
227
228
  export { TranslatorFormfactorDefinition };
229
+ export { filterModels };
228
230
  export { $llmToolsMetadataRegister };
229
231
  export { $llmToolsRegister };
230
232
  export { createLlmToolsFromConfiguration };
@@ -0,0 +1,15 @@
1
+ import type { AvailableModel } from '../../execution/AvailableModel';
2
+ import type { LlmExecutionTools } from '../../execution/LlmExecutionTools';
3
+ /**
4
+ * Creates a wrapper around LlmExecutionTools that only exposes models matching the filter function
5
+ *
6
+ * @param llmTools The original LLM execution tools to wrap
7
+ * @param modelFilter Function that determines whether a model should be included
8
+ * @returns A new LlmExecutionTools instance with filtered models
9
+ *
10
+ * @public exported from `@promptbook/core`
11
+ */
12
+ export declare function filterModels<TLlmTools extends LlmExecutionTools>(llmTools: TLlmTools, modelFilter: (model: AvailableModel) => boolean): TLlmTools;
13
+ /**
14
+ * TODO: !!! [models] Test that this is working
15
+ */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@promptbook/markdown-utils",
3
- "version": "0.89.0",
3
+ "version": "0.92.0-3",
4
4
  "description": "It's time for a paradigm shift. The future of software in plain English, French or Latin",
5
5
  "private": false,
6
6
  "sideEffects": false,
package/umd/index.umd.js CHANGED
@@ -25,7 +25,7 @@
25
25
  * @generated
26
26
  * @see https://github.com/webgptorg/promptbook
27
27
  */
28
- const PROMPTBOOK_ENGINE_VERSION = '0.89.0';
28
+ const PROMPTBOOK_ENGINE_VERSION = '0.92.0-3';
29
29
  /**
30
30
  * TODO: string_promptbook_version should be constrained to the all versions of Promptbook engine
31
31
  * Note: [💞] Ignore a discrepancy between file name and entity name