@huggingface/transformers 3.0.0-alpha.18 → 3.0.0-alpha.19
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 +2 -2
- package/dist/transformers.cjs +1 -4
- package/dist/transformers.cjs.map +1 -1
- package/dist/transformers.js +1 -4
- package/dist/transformers.js.map +1 -1
- package/dist/transformers.min.cjs +2 -2
- package/dist/transformers.min.cjs.map +1 -1
- package/dist/transformers.min.js +2 -2
- package/dist/transformers.min.js.map +1 -1
- package/dist/transformers.min.mjs +2 -2
- package/dist/transformers.min.mjs.map +1 -1
- package/dist/transformers.mjs +1 -4
- package/dist/transformers.mjs.map +1 -1
- package/package.json +1 -1
- package/src/env.js +1 -1
- package/src/models.js +0 -3
- package/types/models.d.ts.map +1 -1
package/README.md
CHANGED
|
@@ -101,7 +101,7 @@ npm i @huggingface/transformers
|
|
|
101
101
|
Alternatively, you can use it in vanilla JS, without any bundler, by using a CDN or static hosting. For example, using [ES Modules](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Modules), you can import the library with:
|
|
102
102
|
```html
|
|
103
103
|
<script type="module">
|
|
104
|
-
import { pipeline } from 'https://cdn.jsdelivr.net/npm/@huggingface/transformers@3.0.0-alpha.
|
|
104
|
+
import { pipeline } from 'https://cdn.jsdelivr.net/npm/@huggingface/transformers@3.0.0-alpha.19';
|
|
105
105
|
</script>
|
|
106
106
|
```
|
|
107
107
|
|
|
@@ -134,7 +134,7 @@ Check out the Transformers.js [template](https://huggingface.co/new-space?templa
|
|
|
134
134
|
|
|
135
135
|
|
|
136
136
|
|
|
137
|
-
By default, Transformers.js uses [hosted pretrained models](https://huggingface.co/models?library=transformers.js) and [precompiled WASM binaries](https://cdn.jsdelivr.net/npm/@huggingface/transformers@3.0.0-alpha.
|
|
137
|
+
By default, Transformers.js uses [hosted pretrained models](https://huggingface.co/models?library=transformers.js) and [precompiled WASM binaries](https://cdn.jsdelivr.net/npm/@huggingface/transformers@3.0.0-alpha.19/dist/), which should work out-of-the-box. You can customize this as follows:
|
|
138
138
|
|
|
139
139
|
### Settings
|
|
140
140
|
|
package/dist/transformers.cjs
CHANGED
|
@@ -4449,7 +4449,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
4449
4449
|
|
|
4450
4450
|
|
|
4451
4451
|
|
|
4452
|
-
const VERSION = '3.0.0-alpha.
|
|
4452
|
+
const VERSION = '3.0.0-alpha.19';
|
|
4453
4453
|
|
|
4454
4454
|
// Check if various APIs are available (depends on environment)
|
|
4455
4455
|
const IS_BROWSER_ENV = typeof self !== 'undefined';
|
|
@@ -7005,9 +7005,6 @@ async function getSession(pretrained_model_name_or_path, fileName, options) {
|
|
|
7005
7005
|
/** @type {Record<string, import('onnxruntime-common').Tensor.DataLocation>} */
|
|
7006
7006
|
const preferredOutputLocation = {};
|
|
7007
7007
|
for (const key in shapes) {
|
|
7008
|
-
// TODO: For now, we keep encoder outputs on the CPU
|
|
7009
|
-
// (otherwise, this causes a memory leak or throws an error "Error: previous buffer is not registered")
|
|
7010
|
-
if (key.includes('encoder')) continue;
|
|
7011
7008
|
preferredOutputLocation[key] = 'gpu-buffer';
|
|
7012
7009
|
}
|
|
7013
7010
|
session_options.preferredOutputLocation = preferredOutputLocation;
|