prompt-api-polyfill 1.2.1 → 1.2.2

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/README.md CHANGED
@@ -142,7 +142,7 @@ npm install prompt-api-polyfill
142
142
  dtype: 'q4f16', // Quantization level
143
143
  env: {
144
144
  // Optional: Pass low-level Transformers.js environment overrides
145
- allowRemoteModels: false,
145
+ allowRemoteModels: true,
146
146
  backends: {
147
147
  onnx: {
148
148
  wasm: {
@@ -239,7 +239,7 @@ This repo ships with a template file:
239
239
 
240
240
  // Optional library-level overrides:
241
241
  "env": {
242
- "allowRemoteModels": false,
242
+ "allowRemoteModels": true,
243
243
  "backends": {
244
244
  "onnx": {
245
245
  "wasm": {
@@ -1,6 +1,6 @@
1
1
  import { initializeApp as Fe } from "firebase/app";
2
2
  import { VertexAIBackend as ze, GoogleAIBackend as Ue, getAI as je, getGenerativeModel as Ve, InferenceMode as We } from "firebase/ai";
3
- import { P as Ke, D as Ge } from "../chunks/defaults-CNQngzSd.js";
3
+ import { P as Ke, D as Ge } from "../chunks/defaults-_qJIFiOb.js";
4
4
  const qe = () => {
5
5
  };
6
6
  const be = function(t) {
@@ -1,5 +1,5 @@
1
1
  import { GoogleGenAI as s } from "@google/genai";
2
- import { P as a, D as i } from "../chunks/defaults-CNQngzSd.js";
2
+ import { P as a, D as i } from "../chunks/defaults-_qJIFiOb.js";
3
3
  class u extends a {
4
4
  #n;
5
5
  #e;
@@ -1,5 +1,5 @@
1
1
  import u from "openai";
2
- import { P as m, D as l } from "../chunks/defaults-CNQngzSd.js";
2
+ import { P as m, D as l } from "../chunks/defaults-_qJIFiOb.js";
3
3
  class y extends m {
4
4
  #e;
5
5
  constructor(t) {
@@ -1,5 +1,5 @@
1
1
  import { env as j, pipeline as z, TextStreamer as C } from "@huggingface/transformers";
2
- import { P as $, D as y } from "../chunks/defaults-CNQngzSd.js";
2
+ import { P as $, D as y } from "../chunks/defaults-_qJIFiOb.js";
3
3
  class I extends $ {
4
4
  #e;
5
5
  #t;
@@ -1,4 +1,4 @@
1
- class r {
1
+ class a {
2
2
  #e;
3
3
  /**
4
4
  * @param {string} modelName - The name of the model.
@@ -49,9 +49,9 @@ class r {
49
49
  throw new Error("Not implemented");
50
50
  }
51
51
  }
52
- const a = {
52
+ const r = {
53
53
  firebase: { modelName: "gemini-2.5-flash-lite" },
54
- gemini: { modelName: "gemini-2.0-flash-lite-preview-02-05" },
54
+ gemini: { modelName: "gemini-2.5-flash-lite" },
55
55
  openai: { modelName: "gpt-4o" },
56
56
  transformers: {
57
57
  modelName: "onnx-community/gemma-3-1b-it-ONNX-GQA",
@@ -60,6 +60,6 @@ const a = {
60
60
  }
61
61
  };
62
62
  export {
63
- a as D,
64
- r as P
63
+ r as D,
64
+ a as P
65
65
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "prompt-api-polyfill",
3
- "version": "1.2.1",
3
+ "version": "1.2.2",
4
4
  "description": "Polyfill for the Prompt API (`LanguageModel`) backed by Firebase AI Logic, Gemini API, OpenAI API, or Transformers.js.",
5
5
  "type": "module",
6
6
  "main": "./dist/prompt-api-polyfill.js",