@dereekb/openrouter 14.0.1 → 14.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.
@@ -1,5 +1,5 @@
1
1
  import { MS_IN_DAY } from '@dereekb/util';
2
- import { firestoreModelIdentity, snapshotConverterFunctions, optionalFirestoreArray, firestoreNumber, optionalFirestoreNumber, firestoreEnum, optionalFirestoreString, firestoreString, optionalFirestoreDate, firestoreDate, optionalFirestoreBoolean, optionalFirestorePassthroughJsonField, firestoreArray, AbstractFirestoreDocument, AbstractFirestoreDocumentWithParent, inferredTargetModelParamsType, callModelFirebaseFunctionMapFactory, where, whereDateIsOnOrBefore, orderBy, limit } from '@dereekb/firebase';
2
+ import { firestoreModelIdentity, snapshotConverterFunctions, optionalFirestoreArray, firestoreNumber, optionalFirestoreNumber, firestoreEnum, optionalFirestoreString, firestoreString, optionalFirestoreDate, firestoreDate, optionalFirestoreBoolean, optionalFirestoreJsonStringField, firestoreArray, AbstractFirestoreDocument, AbstractFirestoreDocumentWithParent, inferredTargetModelParamsType, callModelFirebaseFunctionMapFactory, where, whereDateIsOnOrBefore, orderBy, limit } from '@dereekb/firebase';
3
3
  import { type } from 'arktype';
4
4
  import { clearable } from '@dereekb/model';
5
5
 
@@ -213,7 +213,7 @@ var openRouterPromptVersionConverter = snapshotConverterFunctions({
213
213
  m: optionalFirestoreArray({
214
214
  dontStoreIfEmpty: true
215
215
  }),
216
- c: optionalFirestorePassthroughJsonField(),
216
+ c: optionalFirestoreJsonStringField(),
217
217
  nt: optionalFirestoreString(),
218
218
  by: optionalFirestoreString(),
219
219
  lk: optionalFirestoreBoolean()
@@ -390,15 +390,15 @@ var openRouterRunTaskConverter = snapshotConverterFunctions({
390
390
  fa: optionalFirestoreArray({
391
391
  dontStoreIfEmpty: true
392
392
  }),
393
- co: optionalFirestorePassthroughJsonField(),
393
+ co: optionalFirestoreJsonStringField(),
394
394
  o: optionalFirestoreString(),
395
- j: optionalFirestorePassthroughJsonField(),
395
+ j: optionalFirestoreJsonStringField(),
396
396
  gi: optionalFirestoreArray({
397
397
  filterUnique: true,
398
398
  dontStoreIfEmpty: true
399
399
  }),
400
- u: optionalFirestorePassthroughJsonField(),
401
- e: optionalFirestorePassthroughJsonField(),
400
+ u: optionalFirestoreJsonStringField(),
401
+ e: optionalFirestoreJsonStringField(),
402
402
  msg: optionalFirestoreArray({
403
403
  dontStoreIfEmpty: true
404
404
  }),
@@ -1,14 +1,15 @@
1
1
  {
2
2
  "name": "@dereekb/openrouter/firebase",
3
- "version": "14.0.1",
3
+ "version": "14.2.0",
4
+ "sideEffects": false,
4
5
  "type": "module",
5
6
  "peerDependencies": {
6
- "@dereekb/date": "14.0.1",
7
- "@dereekb/firebase": "14.0.1",
8
- "@dereekb/model": "14.0.1",
9
- "@dereekb/openrouter": "14.0.1",
10
- "@dereekb/rxjs": "14.0.1",
11
- "@dereekb/util": "14.0.1",
7
+ "@dereekb/date": "14.2.0",
8
+ "@dereekb/firebase": "14.2.0",
9
+ "@dereekb/model": "14.2.0",
10
+ "@dereekb/openrouter": "14.2.0",
11
+ "@dereekb/rxjs": "14.2.0",
12
+ "@dereekb/util": "14.2.0",
12
13
  "arktype": "^2.2.0"
13
14
  },
14
15
  "exports": {
@@ -201,10 +201,15 @@ export interface OpenRouterPromptVersion {
201
201
  /**
202
202
  * Model configuration.
203
203
  *
204
- * Stored as PASSTHROUGH JSON, deliberately not a strict converter. OpenRouter's parameter surface
205
- * moves fast, and a strict converter would silently drop any field it did not know about — turning
206
- * every OpenRouter release into a config-corrupting event. `OpenRouterModelConfig` types it in
207
- * TypeScript for autocomplete and call-time validation instead: strict types in code, loose storage.
204
+ * Stored as a JSON STRING, deliberately not a strict converter. OpenRouter's parameter surface moves
205
+ * fast, and a strict converter would silently drop any field it did not know about — turning every
206
+ * OpenRouter release into a config-corrupting event. `OpenRouterModelConfig` types it in TypeScript
207
+ * for autocomplete and call-time validation instead: strict types in code, loose storage.
208
+ *
209
+ * A string rather than a native Firestore map because this config carries a json schema, and a map
210
+ * cannot hold every legal one: Firestore forbids an array inside an array, so an array-valued `enum`,
211
+ * `const`, `default`, or `examples` fails the write outright rather than degrading. Serializing costs
212
+ * queryability on the config's interior, which nothing wants, and buys back the whole json type system.
208
213
  *
209
214
  * @dbxModelVariable config
210
215
  */
@@ -1,17 +1,18 @@
1
1
  {
2
2
  "name": "@dereekb/openrouter/firebase-server",
3
- "version": "14.0.1",
3
+ "version": "14.2.0",
4
+ "sideEffects": false,
4
5
  "type": "module",
5
6
  "peerDependencies": {
6
- "@dereekb/analytics": "14.0.1",
7
- "@dereekb/date": "14.0.1",
8
- "@dereekb/firebase": "14.0.1",
9
- "@dereekb/firebase-server": "14.0.1",
10
- "@dereekb/model": "14.0.1",
11
- "@dereekb/nestjs": "14.0.1",
12
- "@dereekb/openrouter": "14.0.1",
13
- "@dereekb/rxjs": "14.0.1",
14
- "@dereekb/util": "14.0.1",
7
+ "@dereekb/analytics": "14.2.0",
8
+ "@dereekb/date": "14.2.0",
9
+ "@dereekb/firebase": "14.2.0",
10
+ "@dereekb/firebase-server": "14.2.0",
11
+ "@dereekb/model": "14.2.0",
12
+ "@dereekb/nestjs": "14.2.0",
13
+ "@dereekb/openrouter": "14.2.0",
14
+ "@dereekb/rxjs": "14.2.0",
15
+ "@dereekb/util": "14.2.0",
15
16
  "@nestjs/common": "^12.0.1",
16
17
  "@nestjs/config": "^12.0.0",
17
18
  "@openrouter/sdk": "^1.2.26",
package/package.json CHANGED
@@ -1,6 +1,7 @@
1
1
  {
2
2
  "name": "@dereekb/openrouter",
3
- "version": "14.0.1",
3
+ "version": "14.2.0",
4
+ "sideEffects": false,
4
5
  "type": "module",
5
6
  "exports": {
6
7
  "./firebase": {
@@ -21,7 +22,7 @@
21
22
  }
22
23
  },
23
24
  "peerDependencies": {
24
- "@dereekb/util": "14.0.1",
25
+ "@dereekb/util": "14.2.0",
25
26
  "@openrouter/sdk": "^1.2.26"
26
27
  },
27
28
  "module": "./index.esm.js",