Repository navigation
fix(deps): upgrade @atjsh/llmlingua-2 to 2.0.5 and drop @tensorflow/tfjs - #10610
Conversation
…fjs from the LLMLingua SLM stack @atjsh/llmlingua-2@2.0.5 adds official Transformers.js v4 support (peers "@huggingface/transformers": "^3.5.2 || ^4.0.0") and 2.0.4+ no longer requires @tensorflow/tfjs, restoring compatibility with OmniRoute's Transformers.js v4 while removing the largest single contributor to the optional runtime footprint. Updates the worker gate comments, colocate/standalone/optional-pack scripts, Docker standalone validation, dependency allowlist, tests, and docs (COMPRESSION_ENGINES.md, release checklists + i18n). Closes cheaper-inference#10536.
d28170d to
d094822
Compare
|
This is a clean, well-documented dependency drop — every reference to @tensorflow/tfjs across package.json, the lockfile, the Dockerfile validation step, the dependency allowlist, dependabot's comment, the build/pack scripts, and all 4 language mirrors of the compression docs was updated consistently, and the reasoning in colocateOptionals.mjs about the 'instance-split bug' is spot on. I went further than the focused test suite and actually exercised the real compression path locally: installed @atjsh/llmlingua-2@2.0.5 with @tensorflow/tfjs removed entirely, and confirmed the tinybert ONNX pipeline still loads and compresses correctly through @huggingface/transformers 4.2.0 alone — so the tfjs removal does not affect compression quality. One unrelated thing I noticed while doing that (NOT something to fix in this PR — it's identical on the current release/v3.8.50 tip, so it predates this change): Looks merge-ready to me once CI actually runs (I only see semgrep/Mergify checks so far — might be waiting on workflow approval for an external contributor). |
…fjs from the LLMLingua SLM stack @atjsh/llmlingua-2@2.0.5 adds official Transformers.js v4 support (peers "@huggingface/transformers": "^3.5.2 || ^4.0.0") and 2.0.4+ no longer requires @tensorflow/tfjs, restoring compatibility with OmniRoute's Transformers.js v4 while removing the largest single contributor to the optional runtime footprint. Updates the worker gate comments, colocate/standalone/optional-pack scripts, Docker standalone validation, dependency allowlist, tests, and docs (COMPRESSION_ENGINES.md, release checklists + i18n). Closes cheaper-inference#10536.
d094822 to
2382694
Compare
|
Note on the 5 failing tests in the full compression suite — they are Windows-environment failures, pre-existing, and unrelated to this PR. I reran the full 1.
The test sets 2.
Bottom line: neither file imports anything this PR touches (deps, Dockerfile, build scripts, worker, docs, manifest), and both failures reproduce on the untouched base. They are platform artifacts of running the suite on a Windows machine — CI runs on Linux, where these 5 pass. No action needed for this PR. |
…ocal # Conflicts: # scripts/build/colocate-standalone.mjs
More work was needed — stale base fixed (merged current
|
|
@diegosouzapw code is clean let me know if more work is needed. |
…o fix/10536-llmlingua-2-2.0.5-drop-tfjs
…llmlingua-2-2.0.5-drop-tfjs
1188401
into
cheaper-inference:release/v3.8.50
…fjs (cheaper-inference#10610) Implements cheaper-inference#10536: upgrade @atjsh/llmlingua-2 2.0.3 → 2.0.5 and drop @tensorflow/tfjs from the LLMLingua SLM optional stack. Validated in an isolated worktree boarded onto origin/release/v3.8.50 (0 conflicts, 20 files): - 48/48 focused llmlingua/colocate/docker unit tests pass (author-reported, reproduced). - check-file-size, check-changelog-integrity: OK. - grep confirms no remaining source imports of @tensorflow/tfjs. - typecheck:core: clean. - check-complexity / check-cognitive-complexity: OK, both under baseline. Co-authored-by: jonlwheat2-gif <jonlwheat2-gif@users.noreply.github.com>
Summary
Implements #10536: upgrade
@atjsh/llmlingua-2from2.0.3→2.0.5and remove@tensorflow/tfjsfrom the LLMLingua SLM optional stack.@atjsh/llmlingua-2@2.0.5adds official Transformers.js v4 support (peer:"@huggingface/transformers": "^3.5.2 || ^4.0.0"), restoring compatibility with OmniRoute's current@huggingface/transformers@^4.2.0.@tensorflow/tfjs— dropping it removes the largest single contributor to the optional runtime footprint (previously dominated the ~800 MB TensorFlow.js + transformers closure).Changes
package.json/package-lock.json:@atjsh/llmlingua-22.0.3 → 2.0.5, remove@tensorflow/tfjs@4.22.0and its transitive closure.Dockerfile: drop@tensorflow/tfjsfrom the standalone package validation loop..github/dependabot.yml: refresh the stale "HARD-PINNED at 3.5.2" comment (the repo is on^4.2.0since fix(build): bump @huggingface/transformers to 4.2.0 + onnxruntime-node 1.24.3 #9962;llmlingua-2@2.0.5peers^3.5.2 || ^4.0.0).config/quality/dependency-allowlist.json: remove@tensorflow/tfjs(the stale-allowlist gate requires it once the dep is gone).scripts/build/colocateOptionals.mjs(SEED_PACKAGES),scripts/build/colocate-standalone.mjs,scripts/build/prepublish.ts,scripts/packs/optionalPackManifest.mjs(ml-runtime pack): remove tfjs from the SLM closure/seeds.open-sse/services/compression/engines/llmlingua/worker.ts: remove tfjs from the fail-open gate comments.tests/unit/colocate-optionals.test.ts,tests/unit/docker-llmlingua-optionals-9166.test.ts,tests/unit/compression/llmlingua-worker.test.ts— no longer require tfjs; fixtures updated to the 2.0.5 / Transformers.js v4 stack.docs/compression/COMPRESSION_ENGINES.md,docs/ops/RELEASE_CHECKLIST.mdplus zh-CN / zh-TW / pl translations; new changelog fragmentchangelog.d/fixes/10536-llmlingua-2-2.0.5-drop-tfjs.md.Verification
npm run typecheck:core— clean.check:deps(dependency allowlist) andcheck:changelog-integrity— clean.ml-runtimepack stages from the real installed tree with exactly 4 members (@huggingface/transformers@4.2.0,onnxruntime-node@1.24.3,@atjsh/llmlingua-2@2.0.5,js-tiktoken@1.0.21) — the index entry builds and verifies, and no@tensorflowdirectory remains anywhere undernode_modules.Closes #10536