Skip to content

Studio: rank Latest Unsloth Models by trending weighed against release age - #13969

Merged
shimmyshimmer merged 9 commits into
mainfrom
studio-hub-latest-ranking
Oct 16, 2026
Merged

shimmyshimmer merged 9 commits into
mainfrom
studio-hub-latest-ranking

Conversation

@shimmyshimmer

Copy link
Copy Markdown
Member

What changed

Latest Unsloth Models in the Model hub now ranks uploads by Hugging Face trending weighed against release age, instead of by repo creation date alone.

Before, a model that was kept private until launch sorted by the date its repo was created. Muse-Spark-Open-816B-A42B-GGUF went public on 2026-10-15 but its repo was created on 2026-09-19, so it showed up 7th, below models from weeks ago, while its row said "10h ago" (the row shows last modified, the list sorted by creation date).

Ranking

score = (trendingScore + 2) / (releaseAgeDays + 2) ^ 1.6, the Hacker News gravity form:

  • The offsets stop a brand new upload with no likes from scoring zero, and stop a few hours of age from dominating.
  • Gravity 1.6 keeps a strong model from this week above a quiet upload from today, while month-old hits no longer outrank this week's releases on likes alone.
  • Release age: the Hub has no publish date. When a repo has at least 5 likes and at least 80% of them are trending (recent), it went public recently, so its last modification dates it instead of createdAt. An old repo that is only re-touched, with no likes, stays old.

The feed fetches the 100 newest and the 100 most trending Unsloth uploads, ranks that pool, then continues through the rest by creation date for scrolling. fresh is never sent to the Hub: every listing path maps it to createdAt (hubListingSort). The sort menu gains Latest for this ranking; Newest stays creation date only. ModelScope has neither sort, so both fall back to last modified, as Newest already did.

Order on 2026-10-15: Muse-Spark-Open-816B-A42B, NVIDIA-Nemotron-3.5-Bolt-74B-A9B, NVIDIA-Nemotron-3.5-Super-VL-120B-A12B, LFM2.5-24B-A2B, Qwen-Image-2.1-Turbo, embeddinggemma-2, Qwen3.8-27B.

Verification

  • npm run typecheck, npm run build, full npm test (12478 pass, 0 fail).
  • New tests/hub-fresh-ranking.test.ts covers the release age rule, the weighting on that day's real Hub numbers, and that fresh never reaches a Hub request.
  • Isolated Studio on CPU: Model hub > Latest Unsloth Models shows the order above, the sort menu reads Latest.

Not tested here

ModelScope listings were not exercised from this host.

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 16, 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-16T07:38:01.024589Z aa5f9b4 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[bot]

This comment was marked as resolved.

chatgpt-codex-connector[bot]

This comment was marked as resolved.

@shimmyshimmer

Copy link
Copy Markdown
Member Author

@codex review

1 similar comment
@shimmyshimmer

Copy link
Copy Markdown
Member Author

@codex review

shimmyshimmer pushed a commit to shimmyshimmer/unsloth-staging-4 that referenced this pull request Oct 16, 2026

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: d014c0f466

ℹ️ 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".

Comment on lines +827 to +829
if (sortBy === "fresh" && !isPublisherQuery) {
return freshChannelIterator(
{ owner: unslothOnly ? "unsloth" : undefined },

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Preserve fresh ordering for all-uploader browsing

When a user selects every uploader with an empty query and then chooses Latest, this branch correctly ranks the global candidate pool, but the existing secondary sort at lines 1035–1083 subsequently groups every unsloth/* result ahead of other publishers because there is no channel owner or query. Consequently a lower-scoring Unsloth model can precede a higher-scoring community model, so Latest does not actually retain the advertised ranking over the chosen uploaders; disable that secondary pinning when sortBy === "fresh" (or integrate the owner preference into the score).

Useful? React with 👍 / 👎.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Intended: with every uploader picked and no query, Unsloth uploads float first under every sort (pinUnslothFirst), and Latest keeps that same rule; the ranking holds within each group.

Comment on lines +513 to +521
const trending = listing("trendingScore");
const [byDate, byTrend] = await Promise.all([take(newest), take(trending)]);
void trending.return(undefined);
const pool = new Map<string, FreshRankable>();
for (const model of [...byDate, ...byTrend]) {
const name = (model as { name?: string }).name;
if (name && !pool.has(name)) pool.set(name, model as FreshRankable);
}
yield* rankFresh([...pool.values()], Date.now());

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Build the fresh pool from filtered candidates

When Latest is combined with a client-side uploader or context filter, these two 100-item pools are collected and ranked before filterModelListing applies that filter. If matching models fall outside the global top 100 newest/trending entries, an older high-scoring match is omitted from the ranked pool and only appears later in creation-date order, while sufficiently sparse filters can exhaust the initial scan on rejected rows. The candidate listings need to be filtered while filling each pool, rather than filtering only the already-ranked output.

Useful? React with 👍 / 👎.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not changing: the pool covers the 100 newest and 100 most trending, which is where Latest's top rows come from; with a sparse client-side filter on top, older matches still list, just by date after the ranked pool. Filtering inside the pool fill would mean rescanning the listing per filter for a rare combination.

chatgpt-codex-connector[bot]

This comment was marked as resolved.

chatgpt-codex-connector[bot]

This comment was marked as resolved.

@unslothai unslothai deleted a comment from chatgpt-codex-connector Bot Oct 16, 2026
@unslothai unslothai deleted a comment from chatgpt-codex-connector Bot Oct 16, 2026
@unslothai unslothai deleted a comment from chatgpt-codex-connector Bot Oct 16, 2026
@unslothai unslothai deleted a comment from chatgpt-codex-connector Bot Oct 16, 2026
@unslothai unslothai deleted a comment from chatgpt-codex-connector Bot Oct 16, 2026
@unslothai unslothai deleted a comment from chatgpt-codex-connector Bot Oct 16, 2026
@unslothai unslothai deleted a comment from chatgpt-codex-connector Bot Oct 16, 2026
@shimmyshimmer

Copy link
Copy Markdown
Member Author

@codex review

1 similar comment
@shimmyshimmer

Copy link
Copy Markdown
Member Author

@codex review

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

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Chef's kiss.

Reviewed commit: aa5f9b4df4

ℹ️ 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
shimmyshimmer merged commit 7bee02d into main Oct 16, 2026
@shimmyshimmer
shimmyshimmer deleted the studio-hub-latest-ranking branch October 16, 2026 08:48
danielhanchen added a commit that referenced this pull request Oct 16, 2026
…13991)

## Summary

`Frontend build + bundle sanity` is red on main again. #13969 merged
with it red, and its run reported `over the startup budget: transfer
1995.0 KB > 1994.7 KB, raw 6633.8 KB > 6632.7 KB`. Main at 6106de9
measures 6,796,799 B raw / 2,044,202 B transfer, against limits of
6,792,425 / 2,042,777.

Measured commit by commit (one machine and build, Node 24, 95 chunks
throughout, `rm -rf dist` before each build):

| commit | raw B | transfer B |
|---|---|---|
| 1790106 (#13983, last raise from me) | 6,791,768 | 2,042,404 |
| 7d33eff (#13965) | 6,792,034 | 2,042,515 |
| cc0cb59 (#13966) | 6,792,447 | 2,042,693 |
| 7bee02d (#13969) | 6,793,737 | 2,043,138 |
| ce83dee (#13973) | 6,796,298 | 2,044,201 |
| 6106de9 (main, after #13974, #13972, #13951, #13945) | 6,796,799 |
2,044,202 |

The two largest steps:
- Inline chat markdown tables with hover controls and the expand dialog
(#13973): +2,561 B raw / +1,063 B transfer, in the eager chat chunk.
- Latest Unsloth Models ranking (#13969): +1,290 B raw / +445 B
transfer.

#13945 already raised the budget for its own 497 B.

## Change

The budget is set to the measured build plus the margin main had at
1790106 (160 B raw, 189 B transfer), with the per-commit numbers
recorded beside the limits as in the earlier raises. If #13973's expand
dialog should be lazy-loaded instead, that is a follow-up for its owner.
This only gets main and every open PR off a red that none of them
caused.

## Testing

- `npm run build && npm run bundle:check` on main with this change:
within budget (0.2 KB transfer, 0.2 KB raw to spare). Without it: over
by 4,374 B raw / 1,425 B transfer.
- `tests/bundle-budget-cli.test.ts` and
`tests/bundle-budget-closure.test.ts`: 43 passed.
- `prettier --check scripts/check-bundle-budget.ts`: clean.
shimmyshimmer added a commit that referenced this pull request Oct 16, 2026
…ing (#13993)

## What changed

The model picker's **Recommended** list (Select model in a new chat) now
defaults to **Latest**, the same ranking as the Model hub's Latest
Unsloth Models list: Hugging Face trending weighed against release age,
with a repo kept private until launch dated by when it went public
(#13969). Before, it defaulted to the raw Hugging Face
trending score, so a two-month-old hit outranked this week's releases
and a model that just went public could sit low.

**Trending** (raw trending score) and **Recent** (last updated) stay in
the sort menu. A typed search with Latest selected keeps the search
path, newest first, as in the hub.

## Verification

- `npm run typecheck`, `npm run build`, full `npm test` (all pass). New
`tests/model-picker-latest-sort.test.ts`.
- Isolated Studio: Select model > Recommended shows Latest and lists
Muse-Spark-Open-816B-A42B-GGUF, NVIDIA-Nemotron-3.5-Bolt-74B-A9B-GGUF,
NVIDIA-Nemotron-3.5-Super-VL-120B-A12B-GGUF, LFM2.5-24B-A2B-GGUF first,
matching the hub.

## Not tested here

The task-scoped pickers (audio) use the same ranking through the
per-task pools; not exercised from this host.
shimmyshimmer added a commit that referenced this pull request Oct 20, 2026
…odified (#14329)

## What changed

**Latest** in the Model hub now ranks Unsloth uploads by Hugging Face
trending weighed against **creation date**. It no longer swaps in the
last-modified date.

#13969 dated a repo by its last change whenever at least 5 likes and 80%
of them were trending, to catch repos kept private until launch. In
practice that also matches any popular upload from the past week.
Re-uploading files to such a repo reset its age to zero and jumped it to
the top. On 2026-10-20, `LFM2.5-24B-A2B-GGUF` (created 2026-10-13,
re-uploaded that morning) sat above `DeepSeek-V4.1-Flash-1017-GGUF`
(created 2026-10-17).

The chat model picker's Hub list uses the same Latest ranking by
default, so it gets the same fix.

The score keeps the same form, `(trendingScore + 2) / (daysSinceCreated
+ 2) ^ 1.6`. Only the age input changes. The release-age heuristic and
its constants are removed.

Order on 2026-10-20 from the live unsloth listing:

1. DeepSeek-V4.1-Flash-1017-GGUF
2. NVIDIA-Nemotron-3.5-Bolt-74B-A9B-GGUF
3. LFM2.5-24B-A2B-GGUF
4. NVIDIA-Nemotron-3.5-Super-VL-120B-A12B-GGUF
5. flux-3-image-klein-GGUF

Trade-off: a repo kept private until launch is dated by when its repo
was created, so it ranks lower than its real release date suggests (for
example, Muse-Spark-Open-816B-A42B, created 2026-09-19).

## Verification

- `tests/hub-fresh-ranking.test.ts` now uses the 2026-10-20 listing. It
checks that age comes from creation only and that the re-uploaded LFM
stays below models released after it.
- `npm run typecheck`, `npm run build`, full `npm test` (12894 pass).
- Ran `rankFresh` from this branch against the live Hub listing (100
newest plus 100 most trending), which gave the order above.

Not exercised here: ModelScope listings, which do not offer Latest.
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