utilitas 2000.3.45 → 2000.3.46

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.
package/lib/embedding.mjs CHANGED
@@ -142,6 +142,9 @@ const embed = async (input, options = {}) => {
142
142
  body.model = `${source ? `${source}/` : ''}${body.model}`;
143
143
  case OPENAI:
144
144
  resp = await client.embeddings.create(body);
145
+ break;
146
+ default:
147
+ throw new Error(`Unsupported provider: ${provider}`);
145
148
  }
146
149
  assert(resp?.data?.length, 'No embeddings returned.', 500);
147
150
  if (options?.raw) { return resp; }
package/lib/manifest.mjs CHANGED
@@ -1,7 +1,7 @@
1
1
  const manifest = {
2
2
  "name": "utilitas",
3
3
  "description": "Just another common utility for JavaScript.",
4
- "version": "2000.3.45",
4
+ "version": "2000.3.46",
5
5
  "private": false,
6
6
  "homepage": "https://github.com/Leask/utilitas",
7
7
  "main": "index.mjs",
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "utilitas",
3
3
  "description": "Just another common utility for JavaScript.",
4
- "version": "2000.3.45",
4
+ "version": "2000.3.46",
5
5
  "private": false,
6
6
  "homepage": "https://github.com/Leask/utilitas",
7
7
  "main": "index.mjs",