@versini/sassysaint-common 4.3.0 → 4.4.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.
Files changed (3) hide show
  1. package/dist/index.d.ts +62 -17
  2. package/dist/index.js +165 -136
  3. package/package.json +3 -3
package/dist/index.d.ts CHANGED
@@ -54,22 +54,6 @@ declare const PROVIDER_ROLE_MAP: {
54
54
  Google: string[];
55
55
  Perplexity: string[];
56
56
  };
57
- /**
58
- * List of all plans available.
59
- */
60
- declare const PLAN_FREE = "sassy:free";
61
- declare const PLAN_PLUS = "sassy:plus";
62
- declare const PLAN_PREMIUM = "sassy:advanced";
63
- /**
64
- * List of grants available.
65
- */
66
- declare const POLICY_GRANTS: {
67
- PLAN_FREE: string;
68
- PLAN_PLUS: string;
69
- PLAN_PREMIUM: string;
70
- REASONING: string;
71
- WEBSEARCH: string;
72
- };
73
57
  /**
74
58
  * Header string for Callisto Chat Id. Used to identify the chat in the server
75
59
  * when there is a client abort.
@@ -332,4 +316,65 @@ declare namespace index {
332
316
  export { type index_ClientCryptoKeyPair as ClientCryptoKeyPair, type index_CryptoConfig as CryptoConfig, index_CryptoError as CryptoError, type index_CryptoSession as CryptoSession, index_DEFAULT_CRYPTO_CONFIG as DEFAULT_CRYPTO_CONFIG, type index_EncryptedMessage as EncryptedMessage, type index_KeyExchangeResponse as KeyExchangeResponse, type index_RSAKeyGenParams as RSAKeyGenParams, type index_SerializablePublicKey as SerializablePublicKey, index_arrayBufferToBase64 as arrayBufferToBase64, index_base64ToArrayBuffer as base64ToArrayBuffer, index_canUseEncryption as canUseEncryption, index_debugLog as debugLog, index_decryptFromServer as decryptFromServer, index_encryptForServer as encryptForServer, index_establishCryptoSession as establishCryptoSession, index_exportPublicKey as exportPublicKey, index_generateClientKeyPair as generateClientKeyPair, index_generateDeviceId as generateDeviceId, index_importServerPublicKey as importServerPublicKey, index_isCryptoSessionValid as isCryptoSessionValid, index_isSecureContext as isSecureContext, index_isWebCryptoSupported as isWebCryptoSupported, index_safeParse as safeParse, index_safeStringify as safeStringify };
333
317
  }
334
318
 
335
- export { ALL_MODELS, ALL_PROVIDERS, ALL_REASONING_MODELS, APPLICATION_NAME, CALLISTO_CHAT_ID_HEADER, DEFAULT_PROVIDER, MODELS_PER_PROVIDER, MODEL_CLAUDE_HAIKU, MODEL_CLAUDE_SONNET, MODEL_GEMINI_FLASH, MODEL_GEMINI_PRO, MODEL_GPT, MODEL_GPT4_MINI, MODEL_O4_MINI, MODEL_SONAR, MODEL_SONAR_PRO, PLAN_FREE, PLAN_PLUS, PLAN_PREMIUM, POLICY_GRANTS, PROVIDER_ANTHROPIC, PROVIDER_GOOGLE, PROVIDER_MEMORY, PROVIDER_OPENAI, PROVIDER_PERPLEXITY, PROVIDER_ROLE_MAP, PROVIDER_SUMMARY, ROLE_ASSISTANT, ROLE_HIDDEN, ROLE_INTERNAL, ROLE_SYSTEM, ROLE_USER, SORT_BY_TIMESTAMP, SORT_BY_TOKEN_USAGE, index as crypto, findProvider };
319
+ /**
320
+ * List of all plans available.
321
+ */
322
+ declare const PLAN_FREE = "sassy:free";
323
+ declare const PLAN_PLUS = "sassy:plus";
324
+ declare const PLAN_PREMIUM = "sassy:advanced";
325
+ /**
326
+ * List of grants available (coarse grain). This is to be used by client with
327
+ * the isGranted() helper to check for feature availability via JWT
328
+ * capabilities.
329
+ */
330
+ declare const POLICY_GRANTS: {
331
+ PLAN_FREE: string;
332
+ PLAN_PLUS: string;
333
+ PLAN_PREMIUM: string;
334
+ REASONING: string;
335
+ };
336
+ /**
337
+ * Capability constants (single source of truth for string ids).
338
+ * NOTE: these map 1:1 to tool names in ALL_TOOLS from @sassysaint/tools
339
+ * therefore each tools needs to import this file to name its tool correctly.
340
+ */
341
+ declare const CAPABILITIES: {
342
+ readonly TOOL: {
343
+ readonly DATETIME: "getDateTime";
344
+ readonly IMAGES: "getImages";
345
+ readonly POLLUTION: "getAirPollution";
346
+ readonly WEATHER: "getWeather";
347
+ readonly URLCONTENTPARSER: "getUrlContent";
348
+ readonly MEMORIES: "getUserMemories";
349
+ readonly HUMANIZE: "humanize";
350
+ readonly WEBSEARCH: "getWebSearch";
351
+ readonly GITREPOSITORY: "getGitRepoDetails";
352
+ readonly HOTELS: "getHotelDetails";
353
+ readonly ATTACHMENTS: "tool:attachments";
354
+ };
355
+ };
356
+ /**
357
+ * Capability entitlement helper (client/server shared).
358
+ */
359
+ type CapabilityInput = string | readonly string[];
360
+ interface IsEntitledOptions {
361
+ /**
362
+ * Allow entitlement if ANY capability matches (OR). Default false = require
363
+ * ALL.
364
+ */
365
+ any?: boolean;
366
+ /**
367
+ * Pre-supplied Set; if absent we'll build one from `capabilities`.
368
+ */
369
+ set?: Set<string>;
370
+ }
371
+ interface EntitlementStateLike {
372
+ capabilities?: string[];
373
+ version?: number;
374
+ status?: string;
375
+ }
376
+ declare function isEntitlementLoaded(state: EntitlementStateLike | null | undefined): boolean;
377
+ declare function toCapabilitySet(capabilities: string[] | undefined | null): Set<string> | null;
378
+ declare function isEntitled(capabilitiesOrSet: string[] | Set<string> | null | undefined, required: CapabilityInput, options?: IsEntitledOptions): boolean;
379
+
380
+ export { ALL_MODELS, ALL_PROVIDERS, ALL_REASONING_MODELS, APPLICATION_NAME, CALLISTO_CHAT_ID_HEADER, CAPABILITIES, type CapabilityInput, DEFAULT_PROVIDER, type EntitlementStateLike, type IsEntitledOptions, MODELS_PER_PROVIDER, MODEL_CLAUDE_HAIKU, MODEL_CLAUDE_SONNET, MODEL_GEMINI_FLASH, MODEL_GEMINI_PRO, MODEL_GPT, MODEL_GPT4_MINI, MODEL_O4_MINI, MODEL_SONAR, MODEL_SONAR_PRO, PLAN_FREE, PLAN_PLUS, PLAN_PREMIUM, POLICY_GRANTS, PROVIDER_ANTHROPIC, PROVIDER_GOOGLE, PROVIDER_MEMORY, PROVIDER_OPENAI, PROVIDER_PERPLEXITY, PROVIDER_ROLE_MAP, PROVIDER_SUMMARY, ROLE_ASSISTANT, ROLE_HIDDEN, ROLE_INTERNAL, ROLE_SYSTEM, ROLE_USER, SORT_BY_TIMESTAMP, SORT_BY_TOKEN_USAGE, index as crypto, findProvider, isEntitled, isEntitlementLoaded, toCapabilitySet };
package/dist/index.js CHANGED
@@ -1,72 +1,66 @@
1
- const w = "system", s = "user", c = "assistant", re = "hidden", ne = "data", a = "OpenAI", i = "Anthropic", E = "Google", M = "Summary", g = "Memory", d = "Perplexity", oe = a, se = [
2
- a,
1
+ const D = "system", a = "user", c = "assistant", ne = "hidden", re = "data", i = "OpenAI", E = "Anthropic", y = "Google", T = "Summary", M = "Memory", u = "Perplexity", oe = i, se = [
3
2
  i,
4
- E
5
- ], A = "gpt-5", _ = "gpt-4.1-nano", m = "o4-mini", l = "claude-3-5-haiku-20241022", u = "claude-sonnet-4-20250514", R = "gemini-2.5-flash", p = "gemini-2.5-pro", f = "sonar", P = "sonar-pro", ce = [
6
- A,
3
+ E,
4
+ y
5
+ ], O = "gpt-5", p = "gpt-4.1-nano", w = "o4-mini", f = "claude-3-5-haiku-20241022", d = "claude-sonnet-4-20250514", _ = "gemini-2.5-flash", l = "gemini-2.5-pro", R = "sonar", P = "sonar-pro", ae = [
6
+ O,
7
+ p,
8
+ w,
9
+ f,
10
+ d,
7
11
  _,
8
- m,
9
12
  l,
10
- u,
11
13
  R,
12
- p,
13
- f,
14
14
  P
15
- ], ae = [
16
- A,
17
- u,
18
- p
19
- ], b = "claude-sonnet-4", h = "claude-3", T = "gpt-", N = "o3", v = "o4", C = "gemini", K = "sonar", U = {
20
- [i]: [
21
- b,
15
+ ], ce = [
16
+ O,
17
+ d,
18
+ l
19
+ ], m = "claude-sonnet-4", h = "claude-3", b = "gpt-", N = "o3", C = "o4", v = "gemini", U = "sonar", K = {
20
+ [E]: [
21
+ m,
22
22
  h
23
23
  ],
24
- [a]: [
25
- T,
24
+ [i]: [
25
+ b,
26
26
  N,
27
- v
27
+ C
28
28
  ],
29
- [E]: [C],
30
- [d]: [K]
29
+ [y]: [v],
30
+ [u]: [U]
31
31
  }, ie = {
32
- [a]: [_, A],
33
- [i]: [l, u],
34
- [E]: [R, p],
35
- [d]: [f, P]
32
+ [i]: [p, O],
33
+ [E]: [f, d],
34
+ [y]: [_, l],
35
+ [u]: [R, P]
36
36
  }, Ee = {
37
- [a]: [w, s, c],
38
- [i]: [s, c],
39
- [M]: [s, c],
40
- [g]: [s, c],
41
- [E]: [s, c],
42
- [d]: [s, c]
43
- }, k = "sassy:free", F = "sassy:plus", G = "sassy:advanced", V = "sassy:advanced:reasoning", Y = "sassy:advanced:websearch", ye = {
44
- PLAN_FREE: k,
45
- PLAN_PLUS: F,
46
- PLAN_PREMIUM: G,
47
- REASONING: V,
48
- WEBSEARCH: Y
49
- }, de = "x-callisto-chat-id", Ae = (r) => {
50
- for (const [e, n] of Object.entries(
51
- U
37
+ [i]: [D, a, c],
38
+ [E]: [a, c],
39
+ [T]: [a, c],
40
+ [M]: [a, c],
41
+ [y]: [a, c],
42
+ [u]: [a, c]
43
+ }, ye = "x-callisto-chat-id", Ae = (n) => {
44
+ for (const [e, r] of Object.entries(
45
+ K
52
46
  ))
53
- if (n.some((t) => r.startsWith(t)))
47
+ if (r.some((t) => n.startsWith(t)))
54
48
  return e;
55
49
  return null;
56
- }, ue = "timestamp", pe = "tokenUsage", Oe = "Callisto";
57
- class o extends Error {
58
- constructor(e, n, t) {
59
- super(e), this.code = n, this.originalError = t, this.name = "CryptoError";
50
+ }, ue = "timestamp", Oe = "tokenUsage", de = "Callisto";
51
+ class s extends Error {
52
+ constructor(e, r, t) {
53
+ super(e), this.code = r, this.originalError = t, this.name = "CryptoError";
60
54
  }
61
55
  }
62
- const S = {
56
+ const I = {
63
57
  keySize: 4096,
64
58
  debug: !1
65
59
  };
66
- async function x(r = {}) {
67
- const e = { ...S, ...r };
60
+ async function k(n = {}) {
61
+ const e = { ...I, ...n };
68
62
  try {
69
- const n = {
63
+ const r = {
70
64
  modulusLength: e.keySize,
71
65
  publicExponent: new Uint8Array([1, 0, 1]),
72
66
  // 65537
@@ -74,7 +68,7 @@ async function x(r = {}) {
74
68
  }, t = await crypto.subtle.generateKey(
75
69
  {
76
70
  name: "RSA-OAEP",
77
- ...n
71
+ ...r
78
72
  },
79
73
  !0,
80
74
  // extractable for public key export
@@ -92,32 +86,32 @@ async function x(r = {}) {
92
86
  publicKey: t.publicKey,
93
87
  privateKey: t.privateKey
94
88
  };
95
- } catch (n) {
96
- throw new o(
97
- `Failed to generate RSA key pair: ${n instanceof Error ? n.message : "Unknown error"}`,
89
+ } catch (r) {
90
+ throw new s(
91
+ `Failed to generate RSA key pair: ${r instanceof Error ? r.message : "Unknown error"}`,
98
92
  "KEY_GENERATION_FAILED",
99
- n instanceof Error ? n : void 0
93
+ r instanceof Error ? r : void 0
100
94
  );
101
95
  }
102
96
  }
103
- async function H(r) {
97
+ async function G(n) {
104
98
  try {
105
99
  return {
106
- jwk: await crypto.subtle.exportKey("jwk", r),
100
+ jwk: await crypto.subtle.exportKey("jwk", n),
107
101
  kty: "RSA",
108
102
  alg: "RSA-OAEP-256"
109
103
  };
110
104
  } catch (e) {
111
- throw new o(
105
+ throw new s(
112
106
  `Failed to export public key: ${e instanceof Error ? e.message : "Unknown error"}`,
113
107
  "KEY_IMPORT_FAILED",
114
108
  e instanceof Error ? e : void 0
115
109
  );
116
110
  }
117
111
  }
118
- async function I(r) {
112
+ async function S(n) {
119
113
  try {
120
- const e = JSON.parse(r);
114
+ const e = JSON.parse(n);
121
115
  return await crypto.subtle.importKey(
122
116
  "jwk",
123
117
  e,
@@ -130,166 +124,201 @@ async function I(r) {
130
124
  ["encrypt"]
131
125
  );
132
126
  } catch (e) {
133
- throw new o(
127
+ throw new s(
134
128
  `Failed to import server public key: ${e instanceof Error ? e.message : "Unknown error"}`,
135
129
  "KEY_IMPORT_FAILED",
136
130
  e instanceof Error ? e : void 0
137
131
  );
138
132
  }
139
133
  }
140
- async function X(r, e, n) {
134
+ async function F(n, e, r) {
141
135
  try {
142
- const O = new TextEncoder().encode(r), y = await crypto.subtle.encrypt(
136
+ const A = new TextEncoder().encode(n), o = await crypto.subtle.encrypt(
143
137
  {
144
138
  name: "RSA-OAEP"
145
139
  },
146
140
  e,
147
- O
141
+ A
148
142
  );
149
143
  return {
150
144
  data: btoa(
151
- String.fromCharCode(...new Uint8Array(y))
145
+ String.fromCharCode(...new Uint8Array(o))
152
146
  ),
153
147
  algorithm: "RSA-OAEP",
154
- keyId: n
148
+ keyId: r
155
149
  };
156
150
  } catch (t) {
157
- throw new o(
151
+ throw new s(
158
152
  `Failed to encrypt message for server: ${t instanceof Error ? t.message : "Unknown error"}`,
159
153
  "ENCRYPTION_FAILED",
160
154
  t instanceof Error ? t : void 0
161
155
  );
162
156
  }
163
157
  }
164
- async function $(r, e) {
158
+ async function H(n, e) {
165
159
  try {
166
- const n = Uint8Array.from(
167
- atob(r.data),
168
- (y) => y.charCodeAt(0)
160
+ const r = Uint8Array.from(
161
+ atob(n.data),
162
+ (o) => o.charCodeAt(0)
169
163
  ), t = await crypto.subtle.decrypt(
170
164
  {
171
165
  name: "RSA-OAEP"
172
166
  },
173
167
  e,
174
- n
168
+ r
175
169
  );
176
170
  return new TextDecoder().decode(t);
177
- } catch (n) {
178
- throw new o(
179
- `Failed to decrypt message from server: ${n instanceof Error ? n.message : "Unknown error"}`,
171
+ } catch (r) {
172
+ throw new s(
173
+ `Failed to decrypt message from server: ${r instanceof Error ? r.message : "Unknown error"}`,
180
174
  "DECRYPTION_FAILED",
181
- n instanceof Error ? n : void 0
175
+ r instanceof Error ? r : void 0
182
176
  );
183
177
  }
184
178
  }
185
- async function j(r, e, n) {
179
+ async function V(n, e, r) {
186
180
  try {
187
- const t = await I(
188
- r.serverPublicKey
181
+ const t = await S(
182
+ n.serverPublicKey
189
183
  );
190
184
  return {
191
185
  clientKeyPair: e,
192
186
  serverPublicKey: t,
193
- deviceId: n,
194
- serverKeyId: r.keyId,
187
+ deviceId: r,
188
+ serverKeyId: n.keyId,
195
189
  establishedAt: /* @__PURE__ */ new Date()
196
190
  };
197
191
  } catch (t) {
198
- throw new o(
192
+ throw new s(
199
193
  `Failed to establish crypto session: ${t instanceof Error ? t.message : "Unknown error"}`,
200
194
  "KEY_IMPORT_FAILED",
201
195
  t instanceof Error ? t : void 0
202
196
  );
203
197
  }
204
198
  }
205
- function B(r) {
206
- return !(!r || !r.clientKeyPair || !r.serverPublicKey);
199
+ function Y(n) {
200
+ return !(!n || !n.clientKeyPair || !n.serverPublicKey);
207
201
  }
208
- function z() {
209
- const r = Date.now().toString(36), e = new Uint8Array(8);
202
+ function x() {
203
+ const n = Date.now().toString(36), e = new Uint8Array(8);
210
204
  if (typeof window < "u" && window.crypto?.getRandomValues)
211
205
  window.crypto.getRandomValues(e);
212
206
  else
213
207
  for (let t = 0; t < e.length; t++)
214
208
  e[t] = Math.floor(Math.random() * 256);
215
- const n = Array.from(e).map((t) => t.toString(36)).join("");
216
- return `device_${r}_${n}`;
209
+ const r = Array.from(e).map((t) => t.toString(36)).join("");
210
+ return `device_${n}_${r}`;
217
211
  }
218
212
  function L() {
219
213
  return typeof window < "u" && typeof window.crypto < "u" && typeof window.crypto.subtle < "u";
220
214
  }
221
- function D() {
215
+ function g() {
222
216
  return typeof window < "u" && (window.isSecureContext || window.location.protocol === "https:");
223
217
  }
224
- function W() {
225
- return L() && D();
218
+ function X() {
219
+ return L() && g();
226
220
  }
227
- function J(r) {
228
- const e = new Uint8Array(r);
229
- let n = "";
221
+ function $(n) {
222
+ const e = new Uint8Array(n);
223
+ let r = "";
230
224
  for (let t = 0; t < e.byteLength; t++)
231
- n += String.fromCharCode(e[t]);
232
- return btoa(n);
225
+ r += String.fromCharCode(e[t]);
226
+ return btoa(r);
233
227
  }
234
- function q(r) {
235
- const e = atob(r), n = new Uint8Array(e.length);
228
+ function j(n) {
229
+ const e = atob(n), r = new Uint8Array(e.length);
236
230
  for (let t = 0; t < e.length; t++)
237
- n[t] = e.charCodeAt(t);
238
- return n.buffer;
231
+ r[t] = e.charCodeAt(t);
232
+ return r.buffer;
239
233
  }
240
- function Q(r) {
234
+ function B(n) {
241
235
  try {
242
- return JSON.stringify(r);
236
+ return JSON.stringify(n);
243
237
  } catch {
244
- return String(r);
238
+ return String(n);
245
239
  }
246
240
  }
247
- function Z(r) {
241
+ function z(n) {
248
242
  try {
249
- return JSON.parse(r);
243
+ return JSON.parse(n);
250
244
  } catch {
251
245
  return null;
252
246
  }
253
247
  }
254
- function ee(r, ...e) {
255
- typeof process < "u" && process.env && process.env.NODE_ENV === "development" && console.info(`🔐 [Crypto] ${r}`, ...e);
248
+ function W(n, ...e) {
249
+ typeof process < "u" && process.env && process.env.NODE_ENV === "development" && console.info(`🔐 [Crypto] ${n}`, ...e);
250
+ }
251
+ const le = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({ __proto__: null, CryptoError: s, DEFAULT_CRYPTO_CONFIG: I, arrayBufferToBase64: $, base64ToArrayBuffer: j, canUseEncryption: X, debugLog: W, decryptFromServer: H, encryptForServer: F, establishCryptoSession: V, exportPublicKey: G, generateClientKeyPair: k, generateDeviceId: x, importServerPublicKey: S, isCryptoSessionValid: Y, isSecureContext: g, isWebCryptoSupported: L, safeParse: z, safeStringify: B }, Symbol.toStringTag, { value: "Module" })), J = "sassy:free", Z = "sassy:plus", Q = "sassy:advanced", q = "sassy:advanced:reasoning", pe = {
252
+ PLAN_FREE: J,
253
+ PLAN_PLUS: Z,
254
+ PLAN_PREMIUM: Q,
255
+ REASONING: q
256
+ }, fe = {
257
+ TOOL: {
258
+ DATETIME: "getDateTime",
259
+ IMAGES: "getImages",
260
+ POLLUTION: "getAirPollution",
261
+ WEATHER: "getWeather",
262
+ URLCONTENTPARSER: "getUrlContent",
263
+ MEMORIES: "getUserMemories",
264
+ HUMANIZE: "humanize",
265
+ WEBSEARCH: "getWebSearch",
266
+ GITREPOSITORY: "getGitRepoDetails",
267
+ HOTELS: "getHotelDetails",
268
+ ATTACHMENTS: "tool:attachments"
269
+ }
270
+ };
271
+ function _e(n) {
272
+ return !!n && Array.isArray(n.capabilities) && n.capabilities.length >= 0;
273
+ }
274
+ function ee(n) {
275
+ return n ? new Set(n) : null;
276
+ }
277
+ function Re(n, e, r) {
278
+ if (!e || Array.isArray(e) && e.length === 0)
279
+ return !0;
280
+ const t = n instanceof Set ? n : ee(n);
281
+ return !t || t.size === 0 ? !1 : typeof e == "string" ? t.has(e) : r?.any === !0 ? e.some((o) => t.has(o)) : e.every((o) => t.has(o));
256
282
  }
257
- const _e = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({ __proto__: null, CryptoError: o, DEFAULT_CRYPTO_CONFIG: S, arrayBufferToBase64: J, base64ToArrayBuffer: q, canUseEncryption: W, debugLog: ee, decryptFromServer: $, encryptForServer: X, establishCryptoSession: j, exportPublicKey: H, generateClientKeyPair: x, generateDeviceId: z, importServerPublicKey: I, isCryptoSessionValid: B, isSecureContext: D, isWebCryptoSupported: L, safeParse: Z, safeStringify: Q }, Symbol.toStringTag, { value: "Module" }));
258
283
  export {
259
- ce as ALL_MODELS,
284
+ ae as ALL_MODELS,
260
285
  se as ALL_PROVIDERS,
261
- ae as ALL_REASONING_MODELS,
262
- Oe as APPLICATION_NAME,
263
- de as CALLISTO_CHAT_ID_HEADER,
286
+ ce as ALL_REASONING_MODELS,
287
+ de as APPLICATION_NAME,
288
+ ye as CALLISTO_CHAT_ID_HEADER,
289
+ fe as CAPABILITIES,
264
290
  oe as DEFAULT_PROVIDER,
265
291
  ie as MODELS_PER_PROVIDER,
266
- l as MODEL_CLAUDE_HAIKU,
267
- u as MODEL_CLAUDE_SONNET,
268
- R as MODEL_GEMINI_FLASH,
269
- p as MODEL_GEMINI_PRO,
270
- A as MODEL_GPT,
271
- _ as MODEL_GPT4_MINI,
272
- m as MODEL_O4_MINI,
273
- f as MODEL_SONAR,
292
+ f as MODEL_CLAUDE_HAIKU,
293
+ d as MODEL_CLAUDE_SONNET,
294
+ _ as MODEL_GEMINI_FLASH,
295
+ l as MODEL_GEMINI_PRO,
296
+ O as MODEL_GPT,
297
+ p as MODEL_GPT4_MINI,
298
+ w as MODEL_O4_MINI,
299
+ R as MODEL_SONAR,
274
300
  P as MODEL_SONAR_PRO,
275
- k as PLAN_FREE,
276
- F as PLAN_PLUS,
277
- G as PLAN_PREMIUM,
278
- ye as POLICY_GRANTS,
279
- i as PROVIDER_ANTHROPIC,
280
- E as PROVIDER_GOOGLE,
281
- g as PROVIDER_MEMORY,
282
- a as PROVIDER_OPENAI,
283
- d as PROVIDER_PERPLEXITY,
301
+ J as PLAN_FREE,
302
+ Z as PLAN_PLUS,
303
+ Q as PLAN_PREMIUM,
304
+ pe as POLICY_GRANTS,
305
+ E as PROVIDER_ANTHROPIC,
306
+ y as PROVIDER_GOOGLE,
307
+ M as PROVIDER_MEMORY,
308
+ i as PROVIDER_OPENAI,
309
+ u as PROVIDER_PERPLEXITY,
284
310
  Ee as PROVIDER_ROLE_MAP,
285
- M as PROVIDER_SUMMARY,
311
+ T as PROVIDER_SUMMARY,
286
312
  c as ROLE_ASSISTANT,
287
- re as ROLE_HIDDEN,
288
- ne as ROLE_INTERNAL,
289
- w as ROLE_SYSTEM,
290
- s as ROLE_USER,
313
+ ne as ROLE_HIDDEN,
314
+ re as ROLE_INTERNAL,
315
+ D as ROLE_SYSTEM,
316
+ a as ROLE_USER,
291
317
  ue as SORT_BY_TIMESTAMP,
292
- pe as SORT_BY_TOKEN_USAGE,
293
- _e as crypto,
294
- Ae as findProvider
318
+ Oe as SORT_BY_TOKEN_USAGE,
319
+ le as crypto,
320
+ Ae as findProvider,
321
+ Re as isEntitled,
322
+ _e as isEntitlementLoaded,
323
+ ee as toCapabilitySet
295
324
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@versini/sassysaint-common",
3
- "version": "4.3.0",
3
+ "version": "4.4.0",
4
4
  "license": "MIT",
5
5
  "author": "Arno Versini",
6
6
  "publishConfig": {
@@ -19,7 +19,7 @@
19
19
  "build:types": "tsup",
20
20
  "build": "npm-run-all --serial clean build:check build:js build:types",
21
21
  "clean": "rimraf dist tmp",
22
- "comments:fix": "comments src/**/*.ts* --merge-line-comments",
22
+ "comments:fix": "comments \"src/**/*.ts*\" --merge-line-comments",
23
23
  "dev:js": "vite build --watch --mode development",
24
24
  "dev:types": "tsup --watch src",
25
25
  "dev": "npm-run-all --parallel dev:js dev:types",
@@ -32,5 +32,5 @@
32
32
  "test:watch": "vitest",
33
33
  "watch": "npm-run-all dev"
34
34
  },
35
- "gitHead": "639ee1b0e2f051da5a348b43c6ebeec211399986"
35
+ "gitHead": "8e04dcba87baf260337a99820c5f7a32e5caf006"
36
36
  }