@modelprofile.com/flexharness-models 9.1.0 → 9.2.0

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.
@@ -13,8 +13,12 @@ export interface ISmartAiOptions {
13
13
  baseUrl?: string;
14
14
  providerOptions?: TSmartAiProviderOptions;
15
15
  }
16
- export interface IModelProvider<TOptions extends ISmartAiOptions = ISmartAiOptions> {
16
+ /**
17
+ * A provider of language models. `TModel` states the model version its `getModel` returns, so a provider
18
+ * that always answers with a V4 model says so and its callers need no version check.
19
+ */
20
+ export interface IModelProvider<TOptions extends ISmartAiOptions = ISmartAiOptions, TModel extends TSmartAiLanguageModel = TSmartAiLanguageModel> {
17
21
  readonly id: string;
18
- getModel(options: TOptions): TSmartAiLanguageModel;
22
+ getModel(options: TOptions): TModel;
19
23
  }
20
24
  export type { JSONObject, LanguageModelV3, LanguageModelV3Prompt, LanguageModelV4, LanguageModelV4Prompt } from '@ai-sdk/provider';
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "author": "Task Venture Capital GmbH",
3
3
  "license": "MIT",
4
4
  "name": "@modelprofile.com/flexharness-models",
5
- "version": "9.1.0",
5
+ "version": "9.2.0",
6
6
  "type": "module",
7
7
  "description": "Provider-independent model contracts, prompt caching and explicit model registration.",
8
8
  "main": "./dist_ts_models/index.js",
@@ -17,9 +17,16 @@ export interface ISmartAiOptions {
17
17
  providerOptions?: TSmartAiProviderOptions;
18
18
  }
19
19
 
20
- export interface IModelProvider<TOptions extends ISmartAiOptions = ISmartAiOptions> {
20
+ /**
21
+ * A provider of language models. `TModel` states the model version its `getModel` returns, so a provider
22
+ * that always answers with a V4 model says so and its callers need no version check.
23
+ */
24
+ export interface IModelProvider<
25
+ TOptions extends ISmartAiOptions = ISmartAiOptions,
26
+ TModel extends TSmartAiLanguageModel = TSmartAiLanguageModel,
27
+ > {
21
28
  readonly id: string;
22
- getModel(options: TOptions): TSmartAiLanguageModel;
29
+ getModel(options: TOptions): TModel;
23
30
  }
24
31
 
25
32
  export type { JSONObject, LanguageModelV3, LanguageModelV3Prompt, LanguageModelV4, LanguageModelV4Prompt } from '@ai-sdk/provider';