You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
throw error when fetching models because the model path is not concatenated correctly,
Each generated token will not be returned by dispatching callback function when it is generated, and the entire text will be returned only after the whole generation process is completed.
The other text generation examples (translation, summarize, image-to-text) also had problems getting each newly generated token even though the callback function was defined and passed to the pipeline.
Reproduction
clone the repo
cd examples/demo-site
change the @xenova/transformers.js -> "@huggingface/transformers": "^3.0.0-alpha.10" in package.json
npm i
cd examples/demo-site/node_modules/@hugginface/transformers && npm i
copy the webpack.config.js from the repo into the node_modules/@hugginface/transformers && npm run build
cd examples/demo-site && npm run build && npm run preview
The text was updated successfully, but these errors were encountered:
I submitted #903 to fix the bug in text-generation example, and root cause of the issue that newly generated token is not returned is similar, if this PR gets merged I can draft another patch to fix the rest of the text generation examples.
System Info
transformers.js :
@huggingface/[email protected]
browser: chrome
node: v20.17.0
Environment/Platform
Description
Test Generation
throw error when fetching models because the
model
path is not concatenated correctly,Each generated token will not be returned by dispatching callback function when it is generated, and the entire text will be returned only after the whole generation process is completed.
The other text generation examples (translation, summarize, image-to-text) also had problems getting each newly generated token even though the callback function was defined and passed to the
pipeline
.Reproduction
examples/demo-site
@xenova/transformers.js
->"@huggingface/transformers": "^3.0.0-alpha.10"
inpackage.json
npm i
examples/demo-site/node_modules/@hugginface/transformers
&&npm i
webpack.config.js
from the repo into thenode_modules/@hugginface/transformers
&&npm run build
cd examples/demo-site && npm run build && npm run preview
The text was updated successfully, but these errors were encountered: