Skip to content

Fix Studio training download readiness tracking - #7649

Closed
Imagineer99 wants to merge 1 commit into
unslothai:mainfrom
Imagineer99:fix/studio-training-download-readiness
Closed

Imagineer99 wants to merge 1 commit into
unslothai:mainfrom
Imagineer99:fix/studio-training-download-readiness

Conversation

@Imagineer99

Copy link
Copy Markdown
Member

Summary

  • report the Hugging Face repository that Unsloth actually resolves for a training model load
  • poll that resolved repository in the Studio training-start overlay instead of the already-cached configured repository
  • only render Ready / 100% after the backend's complete_on_disk signal, removing the cache-path coercion that could fabricate completion
  • make the Xet stall watchdog follow the same resolved repository

Reproduction / A-B

A — current main

Starting vision training with unsloth/gemma-4-E2B-it can resolve internally to unsloth/gemma-4-e2b-it-unsloth-bnb-4bit. The overlay continues polling the configured repository. Because that repository is already cached, coerceCachedStateReady displays 9.57 GB / 9.57 GB, Ready, and 100% while the worker is still fetching three files for the resolved repository. The focused regression test fails on unchanged main.

B — this branch

The worker includes the resolved repository in model_load_started; the parent exposes it through training status; and the frontend switches its progress polling target to that repository. Unverified byte totals are capped at 99%, and a cache path alone can no longer promote the row to Ready.

Validation

  • python -m pytest studio/backend/tests/test_training_xet_fallback.py -q — 7 passed
  • python -m ruff check on changed backend files — passed
  • npm test — 76 passed
  • npm run typecheck — passed
  • npm run build — passed
  • Python compilation of changed backend modules — passed

@Sneakr

Sneakr commented Jul 30, 2026

Copy link
Copy Markdown
Collaborator

Please add fixes where applicable to #7633 as that's WIP.

@Imagineer99

Copy link
Copy Markdown
Member Author

Please add fixes where applicable to #7633 as that's WIP.

I don’t think folding #7649 directly into #7633 is ideal. #7649 fixes a bug already on main, while #7633 is a much larger WIP with ongoing changes. Better to merge the focused fix first, then rebase/cherry-pick it into #7633 otherwise the fix and its tests get buried and become harder to review.

@danielhanchen

Copy link
Copy Markdown
Member

The resolved-repo part is the piece main still lacks, but the overlay half now conflicts with the reworked readiness path in training-start-overlay.tsx, and worker.py re-derives the mapping with unsloth internals like FLOAT_TO_INT_MAPPER and _strip_unsloth_bnb_4bit_suffix. Could you rebase and narrow it to having the loader report the repo it actually resolved, then plumb just that through status?

@danielhanchen

Copy link
Copy Markdown
Member

The resolved-repo reporting is still missing on main, but the branch has not been rebased onto the reworked readiness path in training-start-overlay.tsx and worker.py still re-derives the mapping from unsloth internals like FLOAT_TO_INT_MAPPER and _strip_unsloth_bnb_4bit_suffix. Could you rebase and cut it down to the loader reporting the repo it actually resolved plus the status plumbing for it?

@Imagineer99

Copy link
Copy Markdown
Member Author

Replaced by #11462 with the narrower loader-reported repo and status plumbing. Dropped the old overlay changes and duplicate mapping logic.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants