diff --git a/diagnostic/index.html b/diagnostic/index.html
index 7794f08..2cb4991 100644
--- a/diagnostic/index.html
+++ b/diagnostic/index.html
@@ -966,6 +966,8 @@
' +
'| ' + escapeHtml(m.id) + ''
+ + (m.tools ? ' 🔧' : '')
+ (m.uncensored ? ' unzensiert' : '')
+ (m.added_at && (Date.now() - new Date(m.added_at).getTime()) < 7 * 864e5 ? ' neu' : '')
+ (m.hfRepo ? ' ' : '')
@@ -10272,6 +10279,7 @@
Kurzbeschreibung wird vom lokalen Modell aus der Modellkarte erstellt …
${fam}
+ ${row('Werkzeuge', j.tools === true ? '🔧 ja — die Chat-Vorlage kennt Werkzeug-Aufrufe' : j.tools === false ? 'nein — eher für Übersetzen, Zusammenfassen, Erklären' : 'unbekannt (keine Chat-Vorlage)')}
${row('Größe', m.sizeGB ? '~' + m.sizeGB + ' GB · ' + escapeHtml(m.quant || '') : '')}
${row('Grundmodell', j.base ? escapeHtml(j.base) : '')}
${row('Von', escapeHtml(j.author))}
diff --git a/diagnostic/server.js b/diagnostic/server.js
index 1170690..bbe372a 100644
--- a/diagnostic/server.js
+++ b/diagnostic/server.js
@@ -573,6 +573,11 @@ async function refreshLlmCatalogFromHF() {
e.quant = q.quant; e.sizeGB = q.sizeGB; e.quants = q.quants; delete e.unusable;
}));
}
+ // Werkzeug-Faehigkeit nachtragen (alle Eintraege, die noch keine Angabe haben)
+ const noTools = [...byId.values()].filter(e => e.hfRepo && e.tools === undefined);
+ for (let i = 0; i < noTools.length; i += 6) {
+ await Promise.all(noTools.slice(i, i + 6).map(async e => { e.tools = await hfToolSupport(e.hfRepo); }));
+ }
let added = 0;
for (const e of byId.values()) { if (e._new) { added++; delete e._new; } }
// Aufraeumen: von HF uebernommen, vor > LLM_CATALOG_KEEP_DAYS Tagen, auf
@@ -821,12 +826,27 @@ async function llmModelInfo(repo) {
created: meta.createdAt || "", updated: meta.lastModified || "",
tags: tags.slice(0, 20), families,
uncensored: !!unc,
+ tools: await hfToolSupport(repo),
uncensoredWhy: unc ? `erkannt an „${unc[0]}“ in Name/Schlagworten` : "",
intro: await hfReadmeIntro(base || repo) || await hfReadmeIntro(repo),
introFrom: base || repo,
};
}
+// Kann das Modell Werkzeuge? Kennzeichen: die Chat-Vorlage im GGUF (HF liefert
+// sie unter expand[]=gguf) kennt ein Werkzeug-Format, oder Schlagworte wie
+// function-calling/tool-use. Zeigt nur, OB das Format da ist, nicht wie gut.
+const TOOLS_TEMPLATE_RE = /\btools\b|tool_call| TOOLS_TAG_RE.test(t))) return true;
+ return tpl ? false : null; // keine Vorlage = unbekannt
+}
+
async function addHfRepoToCatalog(repo, description = "") {
repo = hfRepoFromInput(repo);
if (!/^[\w.-]+\/[\w.-]+$/.test(String(repo || ""))) throw new Error("ungueltiges Repo — Link oder org/name");
@@ -842,7 +862,9 @@ async function addHfRepoToCatalog(repo, description = "") {
if (same) return { models: cat, id: same.id, existed: true };
while (cat.some(m => m.id === id)) id += "-2";
cat.push({ id, hfRepo: repo, quant: q.quant, ctx: 8192, sizeGB: q.sizeGB, quants: q.quants,
- description: description || "Aus den HuggingFace-Trends übernommen", source: "hf" });
+ description: description || "Aus den HuggingFace-Trends übernommen", source: "hf",
+ tools: await hfToolSupport(repo), uncensored: UNCENSORED_RE.test(repo),
+ added_at: new Date().toISOString().slice(0, 10) });
saveLlmCatalog(cat);
return { models: cat, id, existed: false };
}
|