Repository navigation
Studio: use one shared Hugging Face token across Settings and training - #7152
Conversation
There was a problem hiding this comment.
Code Review
This pull request centralizes the management of the Hugging Face token (hfToken) by migrating it to a shared store (useHfTokenStore). The chat runtime and training config stores have been updated to mirror this shared state, and a migration path (version 12) has been added to transition legacy persisted tokens. Additionally, local token validation has been removed from the dataset section. I have no feedback to provide as there are no review comments.
Important
The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.
|
@codex review |
|
Codex Review: Didn't find any major issues. More of your lovely PRs please. Reviewed commit: ℹ️ About Codex in GitHubCodex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback". |
|
@NilayYadav your change unifies the Settings and training Hugging Face token onto the shared store. I drove the real Studio UI to confirm it. A token set in either place now shows up in the other, a legacy Studio-only token migrates into the shared store with the persisted config bumped to v12 and the old field dropped, and the invalid-token error renders once under the token field instead of also under the dataset search. I pushed one follow-up. It folds the duplicated mirror subscription into a shared helper, makes the Settings-path setHfToken delegate to the shared store like training already does, and drops the now-dead token-changed event bridge. I rebuilt and reran the same UI flows green, including Settings now normalizing quoted and whitespace-padded tokens the way the Studio field did, plus a clean tsc. Thanks @NilayYadav. Merging. |
The token in Settings and the "Hugging Face Token (Optional)" field in Studio were stored separately and never synced. Setting a token in Settings didn't work for training gated models users had to paste it twice.
Fix