Open the mirror's registry on what is current, not an empty search box
The mirror page lists Hugging Face's trending models without anything typed, with views for what is new this month and what is most downloaded, filters for task and size, and each repository's parameter count, architecture, context length and age from one registry call. "Only what these nodes can run" is on by default and leaves out architectures the nodes' llama.cpp cannot load, and adapters, saying how many it hid. Listings are remembered for ten minutes. The stylesheet is now linked by a hash of its content. It is cached for a day, so under a fixed name a deploy's new styles reached people a day after its markup. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
1 parent
5aa5675a9c
commit
02fa639657
20 files changed
+632
-52
No files matched your search
@@ -4,7 +4,7 @@
|
||||
{{/* Only while something is downloading. A reload at any other time would
|
||||
take with it whatever the operator was typing into the form below. */}}
|
||||
{{if .RefreshSec}}<meta http-equiv="refresh" content="{{.RefreshSec}}">{{end}}
|
||||
<title>Mirror · llmgw</title><link rel="stylesheet" href="/_static/base.css">
|
||||
<title>Mirror · llmgw</title><link rel="stylesheet" href="{{stylesheet}}">
|
||||
</head><body><div class="wrap">
|
||||
<header>
|
||||
<h1>Model mirror</h1>
|
||||
@@ -183,12 +183,24 @@ document.addEventListener('click', function (e) {
|
||||
{{else}}<p class="empty">The mirror is reachable and holds nothing yet.</p>{{end}}
|
||||
|
||||
{{if .HasRegistry}}
|
||||
<h2>Find a model</h2>
|
||||
<form method="get" action="/admin/mirror">
|
||||
<label>Search Hugging Face
|
||||
<input type="text" name="q" value="{{.Query}}" placeholder="qwen2.5 coder gguf"></label>
|
||||
<h2>Explore models</h2>
|
||||
{{if not .Repo}}{{with .Explore}}
|
||||
<nav class="pills" aria-label="Which models">{{range .Views}}<a href="{{.Href}}"{{if .Active}} class="on" aria-current="page"{{end}}>{{.Label}}</a>{{end}}</nav>
|
||||
<div class="explore-filters">
|
||||
<nav class="pills small" aria-label="Task">{{range .Tasks}}<a href="{{.Href}}"{{if .Active}} class="on" aria-current="true"{{end}}>{{.Label}}</a>{{end}}</nav>
|
||||
<nav class="pills small" aria-label="Size">{{range .Sizes}}<a href="{{.Href}}"{{if .Active}} class="on" aria-current="true"{{end}}>{{.Label}}</a>{{end}}</nav>
|
||||
</div>
|
||||
{{end}}
|
||||
<form method="get" action="/admin/mirror" class="explore-search">
|
||||
{{with .Explore}}<input type="hidden" name="view" value="{{.View}}">
|
||||
<input type="hidden" name="task" value="{{.Task}}">
|
||||
<input type="hidden" name="size" value="{{.Size}}">
|
||||
<input type="hidden" name="x" value="1">{{end}}
|
||||
<input type="search" name="q" value="{{.Query}}" placeholder="Search Hugging Face — qwen coder, gemma, bge…" aria-label="Search Hugging Face">
|
||||
<label class="check"><input type="checkbox" name="here" value="1" onchange="this.form.submit()"{{if .Explore}}{{if .Explore.Here}} checked{{end}}{{end}}> only what these nodes can run</label>
|
||||
<button type="submit">Search</button>
|
||||
</form>
|
||||
{{end}}
|
||||
|
||||
{{if .RegistryErr}}
|
||||
{{/* Its own line, not the page's error: the registry is somebody else's server
|
||||
@@ -197,24 +209,35 @@ document.addEventListener('click', function (e) {
|
||||
<p class="note error-row">The registry: {{.RegistryErr}}</p>
|
||||
{{end}}
|
||||
|
||||
{{if .Results}}
|
||||
<table><tr><th>Repository</th><th>Downloads</th><th>Task</th><th></th></tr>
|
||||
{{range .Results}}<tr>
|
||||
<td><code>{{.ID}}</code>{{if .Gated.Is}} <span class="opt">gated</span>{{end}}</td>
|
||||
{{if not .Repo}}{{with .Explore}}
|
||||
{{if .Rows}}
|
||||
<table class="explore">
|
||||
<tr><th>Repository</th><th class="num">Size</th><th>Architecture</th><th class="num">Context</th>
|
||||
<th class="num">Downloads</th><th class="num">Likes</th><th class="num">Updated</th></tr>
|
||||
{{range .Rows}}<tr>
|
||||
<td><a href="{{.Href}}"><code>{{.ID}}</code></a>
|
||||
{{if .New}}<span class="tag new">new</span>{{end}}{{if .Gated.Is}}<span class="tag">gated</span>{{end}}</td>
|
||||
<td class="num">{{.ParamsLabel}}</td>
|
||||
<td>{{if .Architecture}}<span{{if not .Verdict.Servable}} class="cannot"{{end}} title="{{.Verdict.Reason}}">{{.Architecture}}{{if .Verdict.Checked}}{{if .Verdict.Servable}} ✓{{else}} ✗{{end}}{{end}}</span>{{else}}—{{end}}</td>
|
||||
<td class="num">{{.ContextLabel}}</td>
|
||||
<td class="num">{{compact .Downloads}}</td>
|
||||
<td>{{or .PipelineTag "—"}}</td>
|
||||
<td><a href="/admin/mirror?q={{$.Query}}&repo={{.ID}}">files</a></td>
|
||||
<td class="num">{{compact .Likes}}</td>
|
||||
<td class="num">{{.Age}}</td>
|
||||
</tr>{{end}}
|
||||
</table>
|
||||
{{if .Hidden}}<p class="note">{{.Hidden}} more {{if eq .Hidden 1}}is{{else}}are{{end}} hidden: their architecture is one the nodes' llama.cpp cannot load.
|
||||
Untick “only what these nodes can run” to see them.</p>{{end}}
|
||||
<p class="note">A gated repository needs its terms accepted with a Hugging Face
|
||||
account, and this browses anonymously — the files will list, and fetching one
|
||||
will fail at the mirror. Download it by hand and put it in the mirror
|
||||
directory, or give the mirror a token.</p>
|
||||
{{else if .Query}}{{if not .RegistryErr}}
|
||||
<p class="empty">Nothing matched “{{.Query}}”.</p>
|
||||
{{else if not $.RegistryErr}}
|
||||
<p class="empty">{{if $.Query}}Nothing matched “{{$.Query}}”{{else}}Nothing to list{{end}}{{if .Hidden}} that these nodes can run — {{.Hidden}} {{if eq .Hidden 1}}result was{{else}}results were{{end}} hidden for an architecture llama.cpp cannot load{{end}}.</p>
|
||||
{{end}}
|
||||
{{end}}{{end}}
|
||||
|
||||
{{if .Repo}}
|
||||
<p><a href="{{.Back}}">← back to the list</a></p>
|
||||
<h3>{{.Repo.ID}} <span class="opt">at {{.Repo.ShortRevision}}</span></h3>
|
||||
{{if .RepoSets}}
|
||||
<table>
|
||||
|
||||
Reference in new issue
Block a user