- Rename the app to Kaname - Hub metadata per model (base models, architecture, license, Hub tags), backfilled by the worker for existing models - Library search across repo/author/family/quant/tags and multi-select facet filters (author, family, quant, tag, status) kept in the URL - Custom tags (model page editor, on add, click-to-filter) - README rewritten around a quick install, with banner and screenshots - deploy/compose.yaml: models in a host folder (KANAME_MODELS_DIR) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
2167ea0950
commit
67191b3e16
37 files changed
+2028
-206
No files matched your search
@@ -4,9 +4,12 @@ import { Card, CardContent, CardDescription, CardHeader, CardTitle } from "@/com
|
||||
import { Table, TableBody, TableCell, TableHead, TableHeader, TableRow } from "@/components/ui/table";
|
||||
import { formatBytes } from "@/lib/format";
|
||||
import { LocalTime } from "@/components/local-time";
|
||||
import { modelFamilies } from "@/lib/hub/metadata";
|
||||
import { getModel } from "@/lib/library";
|
||||
import { modelTagList } from "@/lib/tags";
|
||||
import { ModelLive } from "./model-live";
|
||||
import { RemoveModelButton } from "./remove-model-button";
|
||||
import { TagEditor } from "./tag-editor";
|
||||
|
||||
export const dynamic = "force-dynamic";
|
||||
|
||||
@@ -15,6 +18,7 @@ export default async function ModelPage({ params }: PageProps<"/models/[id]">) {
|
||||
const data = await getModel(id);
|
||||
if (!data) notFound();
|
||||
const { model, files } = data;
|
||||
const modelTags = await modelTagList(model.id);
|
||||
const selected = files.filter((f) => f.selected);
|
||||
const totalBytes = selected.reduce((s, f) => s + f.size, 0);
|
||||
|
||||
@@ -25,6 +29,7 @@ export default async function ModelPage({ params }: PageProps<"/models/[id]">) {
|
||||
<ModelStatusBadge status={model.status} />
|
||||
<div className="ml-auto">{model.status === "pending" && <RemoveModelButton id={model.id} />}</div>
|
||||
</div>
|
||||
<TagEditor modelId={model.id} tags={modelTags} />
|
||||
|
||||
<Card>
|
||||
<CardHeader>
|
||||
@@ -43,6 +48,30 @@ export default async function ModelPage({ params }: PageProps<"/models/[id]">) {
|
||||
huggingface.co/{model.repoId}
|
||||
</a>
|
||||
</dd>
|
||||
<dt className="text-muted-foreground">Author</dt>
|
||||
<dd>{model.repoId.split("/")[0]}</dd>
|
||||
<dt className="text-muted-foreground">Family</dt>
|
||||
<dd>{modelFamilies(model.repoId, model.baseModels).join(", ")}</dd>
|
||||
<dt className="text-muted-foreground">Base model</dt>
|
||||
<dd className="flex flex-col">
|
||||
{(model.baseModels ?? []).length === 0
|
||||
? "–"
|
||||
: model.baseModels!.map((b) => (
|
||||
<a key={b} href={`https://huggingface.co/${b}`} target="_blank" rel="noreferrer" className="underline">
|
||||
{b}
|
||||
</a>
|
||||
))}
|
||||
</dd>
|
||||
<dt className="text-muted-foreground">Architecture</dt>
|
||||
<dd>{model.architecture ?? "–"}</dd>
|
||||
<dt className="text-muted-foreground">License</dt>
|
||||
<dd>{model.license ?? "–"}</dd>
|
||||
{(model.hubTags ?? []).length > 0 && (
|
||||
<>
|
||||
<dt className="text-muted-foreground">Hub tags</dt>
|
||||
<dd className="text-xs text-muted-foreground">{model.hubTags!.join(", ")}</dd>
|
||||
</>
|
||||
)}
|
||||
<dt className="text-muted-foreground">Tracked revision</dt>
|
||||
<dd className="font-mono">{model.trackedRevision}</dd>
|
||||
<dt className="text-muted-foreground">Pinned SHA</dt>
|
||||
|
||||
Reference in new issue
Block a user