Skip to content

Studio: simpler API usage examples, and no Pi / Mistral Vibe outbound links - #14914

Merged
shimmyshimmer merged 29 commits into
mainfrom
studio-remove-external-links
Oct 23, 2026
Merged

shimmyshimmer merged 29 commits into
mainfrom
studio-remove-external-links

Conversation

@shimmyshimmer

@shimmyshimmer shimmyshimmer commented Oct 23, 2026 •

Copy link
Copy Markdown
Member

Studio: simpler API usage examples, and no Pi / Mistral Vibe outbound links

Settings > API > Usage examples had three rows of pills (nine example types, two platforms, nine agents) plus a "Setup docs:" row of links. It now has a Request toggle above a code box whose one header row holds the Language pills and, at its right end, the Platform pills, plus an agent picker laid out like Settings > Agents.

What changes for users

  • Request toggle and Language toggle replace the nine example pills. Request (Basic, With tools, Advanced sampling) is a toggle above the code box; Language (curl, Python, JavaScript) and Platform keep the old pill style in the code box's header row, with Platform at its right end; the icon-only copy button stays fixed beside the code's first line, and code scrolling up fades out under the pill row. The choice is still remembered (same stored value as before).
  • Platform is a Linux / macOS / WSL vs Windows toggle that starts on the machine the user is on: on a loopback server it follows the server's own platform (which tells WSL from Windows), otherwise the browser's. An explicit pick is remembered. It drives both the curl snippet and the agent command.
  • Agent dropdown replaces the agent pills, with each agent's icon and the Agents tab's "Installed" badge. Like the Agents tab, the list shows seven rows and scrolls for the rest; the command sits full width below it, and the section has one title.
  • "Open in Agents" (with that tab's bot icon) next to the Coding agents title switches to Settings > Agents with the same agent already picked, instead of linking out. Agents is an owner-only tab, so managed accounts get the picked agent's Docs link there instead.
  • No model loaded: the example now renders with a YOUR_MODEL placeholder under the existing "load a model" note, instead of disappearing, so the pickers always visibly change it.
  • Shorter example box: examples longer than eight lines start eight lines tall and scroll (the basic curl one fits whole); drag the grip in the box's bottom corner to make it taller. The code area under the header is square, so its scrollbar is no longer cut off at the top, and its scrollbars show only while the code is hovered. The copy button is icon-only, and the code block's language label is gone (the Language toggle already says it).
  • Audio API and Image and video API sections use the same layout: the same code box header with the Language and Platform pills (icon copy, no language label, drag grip). Image and video has an Images / Video toggle above the box; Audio's tab pills and its second row of workflow pills become one Example dropdown with a Workflows group. Every section has its own platform toggle, detected the same way; the choice is shared. The shared pieces live in api-example-parts.tsx.
  • Remote & LAN card removed from the API tab. It duplicated the Remote & LAN tab directly below API in the sidebar; the unused RemoteLanSummary component and its tests go with it. The card was also what re-read a tunnel still starting and published its URL to the examples, so that moves to a headless owner-only hook (usePublishAccessUrls).
  • "Setup docs:" row removed. The Agents tab, one click away, has each agent's docs link.
  • Settings > Remote & LAN: the Remote access and LAN access Start buttons drop their 80px minimum width and use the normal small-button padding, matching the Save buttons below them, the section's row descriptions are each a clause shorter, and the Port and Addresses mode dropdowns are wide enough to show "Automatic" without clipping.
  • Settings > System > Live monitor: the divider line between the metric cards and the Detailed view row is gone; the bordered cards already close that group.
  • API page: the Load model picker gets standard padding around its chevron instead of the chat header's tucked-in one.
  • Pi and Mistral Vibe no longer link to pi.dev or github.com/mistralai; their Docs link opens unsloth.ai/docs/integrations/unsloth-start, already the fallback for agents without their own page.
  • Translations: eight new labels in all 14 locales; the nine strings the old pills and docs row used are removed.

Verification

  • npm run typecheck, npm test (13,704 pass), npm run build in studio/frontend. npm run biome:check reports the same repo-wide errors as main; the changed file formats clean.
  • tests/agent-docs-links.test.ts: Pi and Mistral Vibe docs resolve to the unsloth start page, the API tab hands its agent to the Agents tab with no hardcoded external URLs, and the platform default follows the user's machine until they pick one.
  • Fresh install.sh --local Studio on this branch, driven with Playwright in light and dark: the dropdowns switch the snippet (Python + With tools shows the tool-enabled example), picking Pi gives unsloth start pi, and "Open in Agents" lands on the Agents tab with Pi selected. The screenshot with a code sample stubs /v1/models with one loaded model, since this CPU host has none loaded.

Not tested here

Desktop builds were not run; the change is frontend-only.

Removes the Pi (pi.dev) and Mistral Vibe (github.com/mistralai) chips from the agent Setup docs row, and points both agents' Docs link in Settings > Agents at the unsloth start page.
Language, Request and Platform dropdowns replace the nine example pills and the OS pills; the coding agent pills become an Agent dropdown with icons, an Installed badge and a per-agent Docs link, which replaces the Setup docs row.
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 23, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-23T10:04:11.111231Z 4be98d1 Manual request
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. 🎉

Reviewed commit: 54ae658ddd

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

…ommand beside its picker

Platform is a two-way toggle that starts on the machine the user is on (deviceType on loopback, else the browser platform) until they pick one. The coding agents block drops its second title, puts the command to the right of the agent picker, and its link now opens the Agents tab on the picked agent.
shimmyshimmer pushed a commit to shimmyshimmer/unsloth-staging-4 that referenced this pull request Oct 23, 2026
@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Delightful!

Reviewed commit: 01187971ef

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

… agent list

The command returns to full width below the agent dropdown, the list caps at seven rows and scrolls like the Agents tab, and Open in Agents carries that tab's bot icon.
shimmyshimmer pushed a commit to shimmyshimmer/unsloth-staging-4 that referenced this pull request Oct 23, 2026
@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. 👍

Reviewed commit: 5176b7d186

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Drops the 80px minimum width that left extra space either side of Start.
shimmyshimmer pushed a commit to shimmyshimmer/unsloth-staging-4 that referenced this pull request Oct 23, 2026
chatgpt-codex-connector[bot]

This comment was marked as resolved.

shimmyshimmer pushed a commit to shimmyshimmer/unsloth-staging-4 that referenced this pull request Oct 23, 2026
@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Another round soon, please!

Reviewed commit: aefc02fa28

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

shimmyshimmer pushed a commit to shimmyshimmer/unsloth-staging-4 that referenced this pull request Oct 23, 2026
@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Breezy!

Reviewed commit: c4a74feb0a

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

…gents

Agents is an owner-only settings tab, so for other accounts the button landed on General and left no route to setup docs.
…odel is loaded

Without a model the example disappeared, so the Language, Request and Platform pickers changed nothing visible.
Remote & LAN is the next tab down, so the summary card duplicated it. Removes the now unused RemoteLanSummary component and its tests.
shimmyshimmer pushed a commit to shimmyshimmer/unsloth-staging-4 that referenced this pull request Oct 23, 2026
@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. 🎉

Reviewed commit: ce90095eaf

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

…on-only copy

Longer examples start at the height of the basic curl one, fade out, and expand to their full length. The copy button drops its Copy label.
@unslothai unslothai deleted a comment from chatgpt-codex-connector Bot Oct 23, 2026
shimmyshimmer pushed a commit to shimmyshimmer/unsloth-staging-4 that referenced this pull request Oct 23, 2026
Request (or Images / Video) and Language share the first header row beside the copy button, and Platform is the row under it, in the pill style the usage examples had before.
shimmyshimmer pushed a commit to shimmyshimmer/unsloth-staging-4 that referenced this pull request Oct 23, 2026
@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Already looking forward to the next diff.

Reviewed commit: b984e6838f

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

…o as toggles

What the example does is a toggle again; Language and Platform keep the old pills, with Platform at the right end of the same row beside the copy button.
shimmyshimmer pushed a commit to shimmyshimmer/unsloth-staging-4 that referenced this pull request Oct 23, 2026
@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. 👍

Reviewed commit: 70be9a8d60

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

The code box header keeps only the Language and Platform pills.
…l-links

# Conflicts:
#	studio/frontend/src/features/settings/components/audio-api-examples.tsx
#	studio/frontend/src/features/settings/components/media-api-examples.tsx
#	studio/frontend/src/features/settings/components/remote-lan-summary.tsx
#	studio/frontend/src/features/settings/components/usage-examples.tsx
#	studio/frontend/tests/settings-code-boxes.test.ts
shimmyshimmer pushed a commit to shimmyshimmer/unsloth-staging-4 that referenced this pull request Oct 23, 2026
@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Delightful!

Reviewed commit: 16a3045d26

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

…ollbars

The rounded scroller cut the top of its vertical scrollbar off under the header; it is square now and the box clips the scrollbar ends at its corners. The scrollbars show only while the code is hovered, and the header row drops the extra height the toggle used to need.
shimmyshimmer pushed a commit to shimmyshimmer/unsloth-staging-4 that referenced this pull request Oct 23, 2026
@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. You're on a roll.

Reviewed commit: 3cc800d45f

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

…ivider

The copy icon moves into the code area beside the first line, and the line under the Language and Platform pills goes.
shimmyshimmer pushed a commit to shimmyshimmer/unsloth-staging-4 that referenced this pull request Oct 23, 2026
@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Already looking forward to the next diff.

Reviewed commit: ea5e76c13b

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

… header

The copy icon rides in the scroller on the first code line, so it scrolls up with the code while staying at the right edge sideways, and code scrolling up fades out under the pill row instead of being cut.
@shimmyshimmer

Copy link
Copy Markdown
Member Author

@codex review

shimmyshimmer pushed a commit to shimmyshimmer/unsloth-staging-4 that referenced this pull request Oct 23, 2026
@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. More of your lovely PRs please.

Reviewed commit: 38d5d082c9

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Keeps the fade under the pill row; the copy icon goes back to a fixed spot on the first line instead of scrolling with the code.
@shimmyshimmer

Copy link
Copy Markdown
Member Author

@codex review

shimmyshimmer pushed a commit to shimmyshimmer/unsloth-staging-4 that referenced this pull request Oct 23, 2026
@shimmyshimmer
shimmyshimmer merged commit 4be98d1 into main Oct 23, 2026
3 of 38 checks passed
@shimmyshimmer
shimmyshimmer deleted the studio-remove-external-links branch October 23, 2026 09:42
@shimmyshimmer

Copy link
Copy Markdown
Member Author

@codex review

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. 🎉

Reviewed commit: 4be98d13e2

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

danielhanchen added a commit that referenced this pull request Oct 23, 2026
Four checks fail on `main` (fd924a5), so every open PR inherits them.
Each was reproduced on a clean `main` worktree and attributed. A fifth,
`test_every_resolver_probe_forwards_the_trust_decision`, was fixed on
`main` by #14990 in the meantime, so this PR takes that version.

| Check | Introduced by | Wrong side | Fix |
|---|---|---|---|
|
`studio/backend/tests/test_text_io_encoding.py::test_text_io_names_its_encoding[_xpu_triton_toolchain.py]`
| #14814 | Product | The `vswhere` call used `text=True` with no
encoding, so it decoded with the locale code page. A Visual Studio
install path with non-ASCII characters would garble. It now passes
`-utf8` to vswhere and decodes as UTF-8 (`errors="replace"`). |
|
`tests/python/test_accelerator_skip_guards.py::test_no_skip_guard_reads_a_spoofable_accelerator_probe`
| 0947723 | Test | `test_packed_fp32_cuda_parity` skipped on
`torch.cuda.is_available()`, which the CPU CI spoof answers True. It is
now gated on `has_real_cuda()`, same as the sibling attention tests. |
|
`tests/studio/test_usage_examples_model_source_contract.py::test_examples_never_print_a_hardcoded_model_id`
| #14914 | Test | #14914 deliberately renders the example with a
`YOUR_MODEL` placeholder when nothing is servable, instead of hiding it.
The test still asserted the old "no snippet" shape. |
|
`tests/test_fp8_pre_sm89_byte_dequant.py::test_kill_switch_env_is_read_at_import`
| #14936 | Test | The subprocess imports `unsloth` in a fresh
interpreter that has no conftest spoof, so on CPU CI the import raised
"cannot find any torch accelerator" before the switch was read. With no
GPU, the subprocess now applies `tests/_zoo_aggressive_cuda_spoof.py`,
the same pattern `test_qat_phone_deployment.py` uses. It now checks both
`0` and `1`. |

For the third check, the invariant is unchanged: no hardcoded
`unsloth/...` id and no `MODEL_FALLBACK`. The test now also pins the new
contract:
- the placeholder constant
- the `model ?? MODEL_PLACEHOLDER` call as the only `buildSnippets` call
site
- the no-model note rendering exactly when the placeholder is shown

## Verification

- On `main` before #14990: 4 failed in `tests/` and 1 failed in
`studio/backend/tests`.
- On this branch: `test_accelerator_skip_guards.py`,
`test_usage_examples_model_source_contract.py` and
`test_attention_packed_fp32_routing.py` give 48 passed, 1 skipped. With
the two new files and `test_audio_load_routing.py` added, the run gives
94 passed, 133 skipped. `test_text_io_encoding.py` and
`test_xpu_triton_toolchain_14807.py` give 904 passed.
- Sabotage check: hardcoding `_HIP_FP8_BYTES_DEQUANT = True` fails the
kill-switch test.
- Sabotage check: both edits below make the updated contract test fail.
  - Changing the placeholder to `"unsloth/Qwen3-4B"`.
  - Dropping the `model ? null :` gate on the note.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant