Spaces:
Sleeping
Sleeping
Upload folder using huggingface_hub (part 6)
Browse filesThis view is limited to 50 files because it contains too many changes. See raw diff
- node_modules/@huggingface/tasks/dist/commonjs/local-apps.js +526 -0
- node_modules/@huggingface/tasks/dist/commonjs/local-apps.spec.d.ts +2 -0
- node_modules/@huggingface/tasks/dist/commonjs/local-apps.spec.d.ts.map +1 -0
- node_modules/@huggingface/tasks/dist/commonjs/local-apps.spec.js +126 -0
- node_modules/@huggingface/tasks/dist/commonjs/model-data.d.ts +153 -0
- node_modules/@huggingface/tasks/dist/commonjs/model-data.d.ts.map +1 -0
- node_modules/@huggingface/tasks/dist/commonjs/model-data.js +2 -0
- node_modules/@huggingface/tasks/dist/commonjs/model-libraries-downloads.d.ts +18 -0
- node_modules/@huggingface/tasks/dist/commonjs/model-libraries-downloads.d.ts.map +1 -0
- node_modules/@huggingface/tasks/dist/commonjs/model-libraries-downloads.js +18 -0
- node_modules/@huggingface/tasks/dist/commonjs/model-libraries-snippets.d.ts +113 -0
- node_modules/@huggingface/tasks/dist/commonjs/model-libraries-snippets.d.ts.map +1 -0
- node_modules/@huggingface/tasks/dist/commonjs/model-libraries-snippets.js +2311 -0
- node_modules/@huggingface/tasks/dist/commonjs/model-libraries-snippets.spec.d.ts +2 -0
- node_modules/@huggingface/tasks/dist/commonjs/model-libraries-snippets.spec.d.ts.map +1 -0
- node_modules/@huggingface/tasks/dist/commonjs/model-libraries-snippets.spec.js +55 -0
- node_modules/@huggingface/tasks/dist/commonjs/model-libraries.d.ts +1531 -0
- node_modules/@huggingface/tasks/dist/commonjs/model-libraries.d.ts.map +1 -0
- node_modules/@huggingface/tasks/dist/commonjs/model-libraries.js +1534 -0
- node_modules/@huggingface/tasks/dist/commonjs/package.json +3 -0
- node_modules/@huggingface/tasks/dist/commonjs/pipelines.d.ts +385 -0
- node_modules/@huggingface/tasks/dist/commonjs/pipelines.d.ts.map +1 -0
- node_modules/@huggingface/tasks/dist/commonjs/pipelines.js +615 -0
- node_modules/@huggingface/tasks/dist/commonjs/snippets/common.d.ts +14 -0
- node_modules/@huggingface/tasks/dist/commonjs/snippets/common.d.ts.map +1 -0
- node_modules/@huggingface/tasks/dist/commonjs/snippets/common.js +23 -0
- node_modules/@huggingface/tasks/dist/commonjs/snippets/index.d.ts +4 -0
- node_modules/@huggingface/tasks/dist/commonjs/snippets/index.d.ts.map +1 -0
- node_modules/@huggingface/tasks/dist/commonjs/snippets/index.js +19 -0
- node_modules/@huggingface/tasks/dist/commonjs/snippets/inputs.d.ts +4 -0
- node_modules/@huggingface/tasks/dist/commonjs/snippets/inputs.d.ts.map +1 -0
- node_modules/@huggingface/tasks/dist/commonjs/snippets/inputs.js +147 -0
- node_modules/@huggingface/tasks/dist/commonjs/snippets/types.d.ts +15 -0
- node_modules/@huggingface/tasks/dist/commonjs/snippets/types.d.ts.map +1 -0
- node_modules/@huggingface/tasks/dist/commonjs/snippets/types.js +5 -0
- node_modules/@huggingface/tasks/dist/commonjs/tasks/any-to-any/data.d.ts +4 -0
- node_modules/@huggingface/tasks/dist/commonjs/tasks/any-to-any/data.d.ts.map +1 -0
- node_modules/@huggingface/tasks/dist/commonjs/tasks/any-to-any/data.js +63 -0
- node_modules/@huggingface/tasks/dist/commonjs/tasks/audio-classification/data.d.ts +4 -0
- node_modules/@huggingface/tasks/dist/commonjs/tasks/audio-classification/data.d.ts.map +1 -0
- node_modules/@huggingface/tasks/dist/commonjs/tasks/audio-classification/data.js +79 -0
- node_modules/@huggingface/tasks/dist/commonjs/tasks/audio-classification/inference.d.ts +54 -0
- node_modules/@huggingface/tasks/dist/commonjs/tasks/audio-classification/inference.d.ts.map +1 -0
- node_modules/@huggingface/tasks/dist/commonjs/tasks/audio-classification/inference.js +2 -0
- node_modules/@huggingface/tasks/dist/commonjs/tasks/audio-text-to-text/data.d.ts +4 -0
- node_modules/@huggingface/tasks/dist/commonjs/tasks/audio-text-to-text/data.d.ts.map +1 -0
- node_modules/@huggingface/tasks/dist/commonjs/tasks/audio-text-to-text/data.js +67 -0
- node_modules/@huggingface/tasks/dist/commonjs/tasks/audio-to-audio/data.d.ts +4 -0
- node_modules/@huggingface/tasks/dist/commonjs/tasks/audio-to-audio/data.d.ts.map +1 -0
- node_modules/@huggingface/tasks/dist/commonjs/tasks/audio-to-audio/data.js +62 -0
node_modules/@huggingface/tasks/dist/commonjs/local-apps.js
ADDED
|
@@ -0,0 +1,526 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|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
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
"use strict";
|
| 2 |
+
Object.defineProperty(exports, "__esModule", { value: true });
|
| 3 |
+
exports.LOCAL_APPS = void 0;
|
| 4 |
+
const gguf_js_1 = require("./gguf.js");
|
| 5 |
+
const common_js_1 = require("./snippets/common.js");
|
| 6 |
+
const inputs_js_1 = require("./snippets/inputs.js");
|
| 7 |
+
function isAwqModel(model) {
|
| 8 |
+
return model.config?.quantization_config?.quant_method === "awq";
|
| 9 |
+
}
|
| 10 |
+
function isGptqModel(model) {
|
| 11 |
+
return model.config?.quantization_config?.quant_method === "gptq";
|
| 12 |
+
}
|
| 13 |
+
function isAqlmModel(model) {
|
| 14 |
+
return model.config?.quantization_config?.quant_method === "aqlm";
|
| 15 |
+
}
|
| 16 |
+
function isMarlinModel(model) {
|
| 17 |
+
return model.config?.quantization_config?.quant_method === "marlin";
|
| 18 |
+
}
|
| 19 |
+
function isTransformersModel(model) {
|
| 20 |
+
return model.tags.includes("transformers");
|
| 21 |
+
}
|
| 22 |
+
function isTgiModel(model) {
|
| 23 |
+
return model.tags.includes("text-generation-inference");
|
| 24 |
+
}
|
| 25 |
+
function isLlamaCppGgufModel(model) {
|
| 26 |
+
return !!model.gguf?.context_length;
|
| 27 |
+
}
|
| 28 |
+
function isVllmModel(model) {
|
| 29 |
+
return ((isAwqModel(model) ||
|
| 30 |
+
isGptqModel(model) ||
|
| 31 |
+
isAqlmModel(model) ||
|
| 32 |
+
isMarlinModel(model) ||
|
| 33 |
+
isLlamaCppGgufModel(model) ||
|
| 34 |
+
isTransformersModel(model)) &&
|
| 35 |
+
(model.pipeline_tag === "text-generation" || model.pipeline_tag === "image-text-to-text"));
|
| 36 |
+
}
|
| 37 |
+
function isDockerModelRunnerModel(model) {
|
| 38 |
+
return isLlamaCppGgufModel(model) || isVllmModel(model);
|
| 39 |
+
}
|
| 40 |
+
function isAmdRyzenModel(model) {
|
| 41 |
+
return model.tags.includes("ryzenai-hybrid") || model.tags.includes("ryzenai-npu");
|
| 42 |
+
}
|
| 43 |
+
function isMlxModel(model) {
|
| 44 |
+
return model.tags.includes("mlx");
|
| 45 |
+
}
|
| 46 |
+
function getQuantTag(filepath) {
|
| 47 |
+
const defaultTag = ":{{QUANT_TAG}}";
|
| 48 |
+
if (!filepath) {
|
| 49 |
+
return defaultTag;
|
| 50 |
+
}
|
| 51 |
+
const quantLabel = (0, gguf_js_1.parseGGUFQuantLabel)(filepath);
|
| 52 |
+
return quantLabel ? `:${quantLabel}` : defaultTag;
|
| 53 |
+
}
|
| 54 |
+
const snippetLlamacpp = (model, filepath) => {
|
| 55 |
+
const serverCommand = (binary) => {
|
| 56 |
+
const snippet = [
|
| 57 |
+
"# Start a local OpenAI-compatible server with a web UI:",
|
| 58 |
+
`${binary} -hf ${model.id}${getQuantTag(filepath)}`,
|
| 59 |
+
];
|
| 60 |
+
return snippet.join("\n");
|
| 61 |
+
};
|
| 62 |
+
const cliCommand = (binary) => {
|
| 63 |
+
const snippet = ["# Run inference directly in the terminal:", `${binary} -hf ${model.id}${getQuantTag(filepath)}`];
|
| 64 |
+
return snippet.join("\n");
|
| 65 |
+
};
|
| 66 |
+
return [
|
| 67 |
+
{
|
| 68 |
+
title: "Install from brew",
|
| 69 |
+
setup: "brew install llama.cpp",
|
| 70 |
+
content: [serverCommand("llama-server"), cliCommand("llama-cli")],
|
| 71 |
+
},
|
| 72 |
+
{
|
| 73 |
+
title: "Install from WinGet (Windows)",
|
| 74 |
+
setup: "winget install llama.cpp",
|
| 75 |
+
content: [serverCommand("llama-server"), cliCommand("llama-cli")],
|
| 76 |
+
},
|
| 77 |
+
{
|
| 78 |
+
title: "Use pre-built binary",
|
| 79 |
+
setup: [
|
| 80 |
+
// prettier-ignore
|
| 81 |
+
"# Download pre-built binary from:",
|
| 82 |
+
"# https://github.com/ggerganov/llama.cpp/releases",
|
| 83 |
+
].join("\n"),
|
| 84 |
+
content: [serverCommand("./llama-server"), cliCommand("./llama-cli")],
|
| 85 |
+
},
|
| 86 |
+
{
|
| 87 |
+
title: "Build from source code",
|
| 88 |
+
setup: [
|
| 89 |
+
"git clone https://github.com/ggerganov/llama.cpp.git",
|
| 90 |
+
"cd llama.cpp",
|
| 91 |
+
"cmake -B build",
|
| 92 |
+
"cmake --build build -j --target llama-server llama-cli",
|
| 93 |
+
].join("\n"),
|
| 94 |
+
content: [serverCommand("./build/bin/llama-server"), cliCommand("./build/bin/llama-cli")],
|
| 95 |
+
},
|
| 96 |
+
{
|
| 97 |
+
title: "Use Docker",
|
| 98 |
+
content: snippetDockerModelRunner(model, filepath),
|
| 99 |
+
},
|
| 100 |
+
];
|
| 101 |
+
};
|
| 102 |
+
const snippetNodeLlamaCppCli = (model, filepath) => {
|
| 103 |
+
const tagName = getQuantTag(filepath);
|
| 104 |
+
return [
|
| 105 |
+
{
|
| 106 |
+
title: "Chat with the model",
|
| 107 |
+
content: `npx -y node-llama-cpp chat hf:${model.id}${tagName}`,
|
| 108 |
+
},
|
| 109 |
+
{
|
| 110 |
+
title: "Estimate the model compatibility with your hardware",
|
| 111 |
+
content: `npx -y node-llama-cpp inspect estimate hf:${model.id}${tagName}`,
|
| 112 |
+
},
|
| 113 |
+
];
|
| 114 |
+
};
|
| 115 |
+
const snippetOllama = (model, filepath) => {
|
| 116 |
+
return `ollama run hf.co/${model.id}${getQuantTag(filepath)}`;
|
| 117 |
+
};
|
| 118 |
+
const snippetLocalAI = (model, filepath) => {
|
| 119 |
+
const command = (binary) => ["# Load and run the model:", `${binary} huggingface://${model.id}/${filepath ?? "{{GGUF_FILE}}"}`].join("\n");
|
| 120 |
+
return [
|
| 121 |
+
{
|
| 122 |
+
title: "Install from binary",
|
| 123 |
+
setup: "curl https://localai.io/install.sh | sh",
|
| 124 |
+
content: command("local-ai run"),
|
| 125 |
+
},
|
| 126 |
+
{
|
| 127 |
+
title: "Use Docker images",
|
| 128 |
+
setup: [
|
| 129 |
+
// prettier-ignore
|
| 130 |
+
"# Pull the image:",
|
| 131 |
+
"docker pull localai/localai:latest-cpu",
|
| 132 |
+
].join("\n"),
|
| 133 |
+
content: command("docker run -p 8080:8080 --name localai -v $PWD/models:/build/models localai/localai:latest-cpu"),
|
| 134 |
+
},
|
| 135 |
+
];
|
| 136 |
+
};
|
| 137 |
+
const snippetVllm = (model) => {
|
| 138 |
+
const messages = (0, inputs_js_1.getModelInputSnippet)(model);
|
| 139 |
+
const isMistral = model.tags.includes("mistral-common");
|
| 140 |
+
const mistralFlags = isMistral
|
| 141 |
+
? " --tokenizer_mode mistral --config_format mistral --load_format mistral --tool-call-parser mistral --enable-auto-tool-choice"
|
| 142 |
+
: "";
|
| 143 |
+
const setup = isMistral
|
| 144 |
+
? [
|
| 145 |
+
"# Install vLLM from pip:",
|
| 146 |
+
"pip install vllm",
|
| 147 |
+
"# Install mistral-common:",
|
| 148 |
+
"pip install --upgrade mistral-common",
|
| 149 |
+
].join("\n")
|
| 150 |
+
: ["# Install vLLM from pip:", "pip install vllm"].join("\n");
|
| 151 |
+
const serverCommand = `# Start the vLLM server:
|
| 152 |
+
vllm serve "${model.id}"${mistralFlags}`;
|
| 153 |
+
const runCommandInstruct = `# Call the server using curl (OpenAI-compatible API):
|
| 154 |
+
curl -X POST "http://localhost:8000/v1/chat/completions" \\
|
| 155 |
+
-H "Content-Type: application/json" \\
|
| 156 |
+
--data '{
|
| 157 |
+
"model": "${model.id}",
|
| 158 |
+
"messages": ${(0, common_js_1.stringifyMessages)(messages, {
|
| 159 |
+
indent: "\t\t",
|
| 160 |
+
attributeKeyQuotes: true,
|
| 161 |
+
customContentEscaper: (str) => str.replace(/'/g, "'\\''"),
|
| 162 |
+
})}
|
| 163 |
+
}'`;
|
| 164 |
+
const runCommandNonInstruct = `# Call the server using curl (OpenAI-compatible API):
|
| 165 |
+
curl -X POST "http://localhost:8000/v1/completions" \\
|
| 166 |
+
-H "Content-Type: application/json" \\
|
| 167 |
+
--data '{
|
| 168 |
+
"model": "${model.id}",
|
| 169 |
+
"prompt": "Once upon a time,",
|
| 170 |
+
"max_tokens": 512,
|
| 171 |
+
"temperature": 0.5
|
| 172 |
+
}'`;
|
| 173 |
+
const runCommand = model.tags.includes("conversational") ? runCommandInstruct : runCommandNonInstruct;
|
| 174 |
+
return [
|
| 175 |
+
{
|
| 176 |
+
title: "Install from pip and serve model",
|
| 177 |
+
setup: setup,
|
| 178 |
+
content: [serverCommand, runCommand],
|
| 179 |
+
},
|
| 180 |
+
{
|
| 181 |
+
title: "Use Docker",
|
| 182 |
+
content: snippetDockerModelRunner(model),
|
| 183 |
+
},
|
| 184 |
+
];
|
| 185 |
+
};
|
| 186 |
+
const snippetSglang = (model) => {
|
| 187 |
+
const messages = (0, inputs_js_1.getModelInputSnippet)(model);
|
| 188 |
+
const setup = ["# Install SGLang from pip:", "pip install sglang"].join("\n");
|
| 189 |
+
const serverCommand = `# Start the SGLang server:
|
| 190 |
+
python3 -m sglang.launch_server \\
|
| 191 |
+
--model-path "${model.id}" \\
|
| 192 |
+
--host 0.0.0.0 \\
|
| 193 |
+
--port 30000`;
|
| 194 |
+
const dockerCommand = `docker run --gpus all \\
|
| 195 |
+
--shm-size 32g \\
|
| 196 |
+
-p 30000:30000 \\
|
| 197 |
+
-v ~/.cache/huggingface:/root/.cache/huggingface \\
|
| 198 |
+
--env "HF_TOKEN=<secret>" \\
|
| 199 |
+
--ipc=host \\
|
| 200 |
+
lmsysorg/sglang:latest \\
|
| 201 |
+
python3 -m sglang.launch_server \\
|
| 202 |
+
--model-path "${model.id}" \\
|
| 203 |
+
--host 0.0.0.0 \\
|
| 204 |
+
--port 30000`;
|
| 205 |
+
const runCommandInstruct = `# Call the server using curl (OpenAI-compatible API):
|
| 206 |
+
curl -X POST "http://localhost:30000/v1/chat/completions" \\
|
| 207 |
+
-H "Content-Type: application/json" \\
|
| 208 |
+
--data '{
|
| 209 |
+
"model": "${model.id}",
|
| 210 |
+
"messages": ${(0, common_js_1.stringifyMessages)(messages, {
|
| 211 |
+
indent: "\t\t",
|
| 212 |
+
attributeKeyQuotes: true,
|
| 213 |
+
customContentEscaper: (str) => str.replace(/'/g, "'\\''"),
|
| 214 |
+
})}
|
| 215 |
+
}'`;
|
| 216 |
+
const runCommandNonInstruct = `# Call the server using curl (OpenAI-compatible API):
|
| 217 |
+
curl -X POST "http://localhost:30000/v1/completions" \\
|
| 218 |
+
-H "Content-Type: application/json" \\
|
| 219 |
+
--data '{
|
| 220 |
+
"model": "${model.id}",
|
| 221 |
+
"prompt": "Once upon a time,",
|
| 222 |
+
"max_tokens": 512,
|
| 223 |
+
"temperature": 0.5
|
| 224 |
+
}'`;
|
| 225 |
+
const runCommand = model.tags.includes("conversational") ? runCommandInstruct : runCommandNonInstruct;
|
| 226 |
+
return [
|
| 227 |
+
{
|
| 228 |
+
title: "Install from pip and serve model",
|
| 229 |
+
setup: setup,
|
| 230 |
+
content: [serverCommand, runCommand],
|
| 231 |
+
},
|
| 232 |
+
{
|
| 233 |
+
title: "Use Docker images",
|
| 234 |
+
setup: dockerCommand,
|
| 235 |
+
content: [runCommand],
|
| 236 |
+
},
|
| 237 |
+
];
|
| 238 |
+
};
|
| 239 |
+
const snippetTgi = (model) => {
|
| 240 |
+
const runCommand = [
|
| 241 |
+
"# Call the server using curl:",
|
| 242 |
+
`curl -X POST "http://localhost:8000/v1/chat/completions" \\`,
|
| 243 |
+
` -H "Content-Type: application/json" \\`,
|
| 244 |
+
` --data '{`,
|
| 245 |
+
` "model": "${model.id}",`,
|
| 246 |
+
` "messages": [`,
|
| 247 |
+
` {"role": "user", "content": "What is the capital of France?"}`,
|
| 248 |
+
` ]`,
|
| 249 |
+
` }'`,
|
| 250 |
+
];
|
| 251 |
+
return [
|
| 252 |
+
{
|
| 253 |
+
title: "Use Docker images",
|
| 254 |
+
setup: [
|
| 255 |
+
"# Deploy with docker on Linux:",
|
| 256 |
+
`docker run --gpus all \\`,
|
| 257 |
+
` -v ~/.cache/huggingface:/root/.cache/huggingface \\`,
|
| 258 |
+
` -e HF_TOKEN="<secret>" \\`,
|
| 259 |
+
` -p 8000:80 \\`,
|
| 260 |
+
` ghcr.io/huggingface/text-generation-inference:latest \\`,
|
| 261 |
+
` --model-id ${model.id}`,
|
| 262 |
+
].join("\n"),
|
| 263 |
+
content: [runCommand.join("\n")],
|
| 264 |
+
},
|
| 265 |
+
];
|
| 266 |
+
};
|
| 267 |
+
const snippetMlxLm = (model) => {
|
| 268 |
+
const openaiCurl = [
|
| 269 |
+
"# Calling the OpenAI-compatible server with curl",
|
| 270 |
+
`curl -X POST "http://localhost:8000/v1/chat/completions" \\`,
|
| 271 |
+
` -H "Content-Type: application/json" \\`,
|
| 272 |
+
` --data '{`,
|
| 273 |
+
` "model": "${model.id}",`,
|
| 274 |
+
` "messages": [`,
|
| 275 |
+
` {"role": "user", "content": "Hello"}`,
|
| 276 |
+
` ]`,
|
| 277 |
+
` }'`,
|
| 278 |
+
];
|
| 279 |
+
return [
|
| 280 |
+
{
|
| 281 |
+
title: "Generate or start a chat session",
|
| 282 |
+
setup: ["# Install MLX LM", "uv tool install mlx-lm"].join("\n"),
|
| 283 |
+
content: [
|
| 284 |
+
...(model.tags.includes("conversational")
|
| 285 |
+
? ["# Interactive chat REPL", `mlx_lm.chat --model "${model.id}"`]
|
| 286 |
+
: ["# Generate some text", `mlx_lm.generate --model "${model.id}" --prompt "Once upon a time"`]),
|
| 287 |
+
].join("\n"),
|
| 288 |
+
},
|
| 289 |
+
...(model.tags.includes("conversational")
|
| 290 |
+
? [
|
| 291 |
+
{
|
| 292 |
+
title: "Run an OpenAI-compatible server",
|
| 293 |
+
setup: ["# Install MLX LM", "uv tool install mlx-lm"].join("\n"),
|
| 294 |
+
content: ["# Start the server", `mlx_lm.server --model "${model.id}"`, ...openaiCurl].join("\n"),
|
| 295 |
+
},
|
| 296 |
+
]
|
| 297 |
+
: []),
|
| 298 |
+
];
|
| 299 |
+
};
|
| 300 |
+
const snippetDockerModelRunner = (model, filepath) => {
|
| 301 |
+
// Only add quant tag for GGUF models, not safetensors
|
| 302 |
+
const quantTag = isLlamaCppGgufModel(model) ? getQuantTag(filepath) : "";
|
| 303 |
+
return `docker model run hf.co/${model.id}${quantTag}`;
|
| 304 |
+
};
|
| 305 |
+
const snippetLemonade = (model, filepath) => {
|
| 306 |
+
const tagName = getQuantTag(filepath);
|
| 307 |
+
const modelName = model.id.includes("/") ? model.id.split("/")[1] : model.id;
|
| 308 |
+
// Get recipe according to model type
|
| 309 |
+
let simplifiedModelName;
|
| 310 |
+
let recipe;
|
| 311 |
+
let checkpoint;
|
| 312 |
+
let requirements;
|
| 313 |
+
if (model.tags.some((tag) => ["ryzenai-npu", "ryzenai-hybrid"].includes(tag))) {
|
| 314 |
+
recipe = model.tags.includes("ryzenai-npu") ? "oga-npu" : "oga-hybrid";
|
| 315 |
+
checkpoint = model.id;
|
| 316 |
+
requirements = " (requires RyzenAI 300 series)";
|
| 317 |
+
simplifiedModelName = modelName.split("-awq-")[0];
|
| 318 |
+
simplifiedModelName += recipe === "oga-npu" ? "-NPU" : "-Hybrid";
|
| 319 |
+
}
|
| 320 |
+
else {
|
| 321 |
+
recipe = "llamacpp";
|
| 322 |
+
checkpoint = `${model.id}${tagName}`;
|
| 323 |
+
requirements = "";
|
| 324 |
+
simplifiedModelName = modelName;
|
| 325 |
+
}
|
| 326 |
+
return [
|
| 327 |
+
{
|
| 328 |
+
title: "Pull the model",
|
| 329 |
+
setup: "# Download Lemonade from https://lemonade-server.ai/",
|
| 330 |
+
content: [
|
| 331 |
+
`lemonade-server pull user.${simplifiedModelName} --checkpoint ${checkpoint} --recipe ${recipe}`,
|
| 332 |
+
"# Note: If you installed from source, use the lemonade-server-dev command instead.",
|
| 333 |
+
].join("\n"),
|
| 334 |
+
},
|
| 335 |
+
{
|
| 336 |
+
title: `Run and chat with the model${requirements}`,
|
| 337 |
+
content: `lemonade-server run user.${simplifiedModelName}`,
|
| 338 |
+
},
|
| 339 |
+
{
|
| 340 |
+
title: "List all available models",
|
| 341 |
+
content: "lemonade-server list",
|
| 342 |
+
},
|
| 343 |
+
];
|
| 344 |
+
};
|
| 345 |
+
/**
|
| 346 |
+
* Add your new local app here.
|
| 347 |
+
*
|
| 348 |
+
* This is open to new suggestions and awesome upcoming apps.
|
| 349 |
+
*
|
| 350 |
+
* /!\ IMPORTANT
|
| 351 |
+
*
|
| 352 |
+
* If possible, you need to support deeplinks and be as cross-platform as possible.
|
| 353 |
+
*
|
| 354 |
+
* Ping the HF team if we can help with anything!
|
| 355 |
+
*/
|
| 356 |
+
exports.LOCAL_APPS = {
|
| 357 |
+
"llama.cpp": {
|
| 358 |
+
prettyLabel: "llama.cpp",
|
| 359 |
+
docsUrl: "https://github.com/ggerganov/llama.cpp",
|
| 360 |
+
mainTask: "text-generation",
|
| 361 |
+
displayOnModelPage: isLlamaCppGgufModel,
|
| 362 |
+
snippet: snippetLlamacpp,
|
| 363 |
+
},
|
| 364 |
+
"node-llama-cpp": {
|
| 365 |
+
prettyLabel: "node-llama-cpp",
|
| 366 |
+
docsUrl: "https://node-llama-cpp.withcat.ai",
|
| 367 |
+
mainTask: "text-generation",
|
| 368 |
+
displayOnModelPage: isLlamaCppGgufModel,
|
| 369 |
+
snippet: snippetNodeLlamaCppCli,
|
| 370 |
+
},
|
| 371 |
+
vllm: {
|
| 372 |
+
prettyLabel: "vLLM",
|
| 373 |
+
docsUrl: "https://docs.vllm.ai",
|
| 374 |
+
mainTask: "text-generation",
|
| 375 |
+
displayOnModelPage: isVllmModel,
|
| 376 |
+
snippet: snippetVllm,
|
| 377 |
+
},
|
| 378 |
+
sglang: {
|
| 379 |
+
prettyLabel: "SGLang",
|
| 380 |
+
docsUrl: "https://docs.sglang.io",
|
| 381 |
+
mainTask: "text-generation",
|
| 382 |
+
displayOnModelPage: (model) => (isAwqModel(model) ||
|
| 383 |
+
isGptqModel(model) ||
|
| 384 |
+
isAqlmModel(model) ||
|
| 385 |
+
isMarlinModel(model) ||
|
| 386 |
+
isTransformersModel(model)) &&
|
| 387 |
+
(model.pipeline_tag === "text-generation" || model.pipeline_tag === "image-text-to-text"),
|
| 388 |
+
snippet: snippetSglang,
|
| 389 |
+
},
|
| 390 |
+
"mlx-lm": {
|
| 391 |
+
prettyLabel: "MLX LM",
|
| 392 |
+
docsUrl: "https://github.com/ml-explore/mlx-lm",
|
| 393 |
+
mainTask: "text-generation",
|
| 394 |
+
displayOnModelPage: (model) => model.pipeline_tag === "text-generation" && isMlxModel(model),
|
| 395 |
+
snippet: snippetMlxLm,
|
| 396 |
+
},
|
| 397 |
+
tgi: {
|
| 398 |
+
prettyLabel: "TGI",
|
| 399 |
+
docsUrl: "https://huggingface.co/docs/text-generation-inference/",
|
| 400 |
+
mainTask: "text-generation",
|
| 401 |
+
displayOnModelPage: isTgiModel,
|
| 402 |
+
snippet: snippetTgi,
|
| 403 |
+
},
|
| 404 |
+
lmstudio: {
|
| 405 |
+
prettyLabel: "LM Studio",
|
| 406 |
+
docsUrl: "https://lmstudio.ai",
|
| 407 |
+
mainTask: "text-generation",
|
| 408 |
+
displayOnModelPage: (model) => isLlamaCppGgufModel(model) || isMlxModel(model),
|
| 409 |
+
deeplink: (model, filepath) => new URL(`lmstudio://open_from_hf?model=${model.id}${filepath ? `&file=${filepath}` : ""}`),
|
| 410 |
+
},
|
| 411 |
+
localai: {
|
| 412 |
+
prettyLabel: "LocalAI",
|
| 413 |
+
docsUrl: "https://github.com/mudler/LocalAI",
|
| 414 |
+
mainTask: "text-generation",
|
| 415 |
+
displayOnModelPage: isLlamaCppGgufModel,
|
| 416 |
+
snippet: snippetLocalAI,
|
| 417 |
+
},
|
| 418 |
+
jan: {
|
| 419 |
+
prettyLabel: "Jan",
|
| 420 |
+
docsUrl: "https://jan.ai",
|
| 421 |
+
mainTask: "text-generation",
|
| 422 |
+
displayOnModelPage: isLlamaCppGgufModel,
|
| 423 |
+
deeplink: (model) => new URL(`jan://models/huggingface/${model.id}`),
|
| 424 |
+
},
|
| 425 |
+
backyard: {
|
| 426 |
+
prettyLabel: "Backyard AI",
|
| 427 |
+
docsUrl: "https://backyard.ai",
|
| 428 |
+
mainTask: "text-generation",
|
| 429 |
+
displayOnModelPage: isLlamaCppGgufModel,
|
| 430 |
+
deeplink: (model) => new URL(`https://backyard.ai/hf/model/${model.id}`),
|
| 431 |
+
},
|
| 432 |
+
sanctum: {
|
| 433 |
+
prettyLabel: "Sanctum",
|
| 434 |
+
docsUrl: "https://sanctum.ai",
|
| 435 |
+
mainTask: "text-generation",
|
| 436 |
+
displayOnModelPage: isLlamaCppGgufModel,
|
| 437 |
+
deeplink: (model) => new URL(`sanctum://open_from_hf?model=${model.id}`),
|
| 438 |
+
},
|
| 439 |
+
jellybox: {
|
| 440 |
+
prettyLabel: "Jellybox",
|
| 441 |
+
docsUrl: "https://jellybox.com",
|
| 442 |
+
mainTask: "text-generation",
|
| 443 |
+
displayOnModelPage: (model) => isLlamaCppGgufModel(model) ||
|
| 444 |
+
(model.library_name === "diffusers" &&
|
| 445 |
+
model.tags.includes("safetensors") &&
|
| 446 |
+
(model.pipeline_tag === "text-to-image" || model.tags.includes("lora"))),
|
| 447 |
+
deeplink: (model) => {
|
| 448 |
+
if (isLlamaCppGgufModel(model)) {
|
| 449 |
+
return new URL(`jellybox://llm/models/huggingface/LLM/${model.id}`);
|
| 450 |
+
}
|
| 451 |
+
else if (model.tags.includes("lora")) {
|
| 452 |
+
return new URL(`jellybox://image/models/huggingface/ImageLora/${model.id}`);
|
| 453 |
+
}
|
| 454 |
+
else {
|
| 455 |
+
return new URL(`jellybox://image/models/huggingface/Image/${model.id}`);
|
| 456 |
+
}
|
| 457 |
+
},
|
| 458 |
+
},
|
| 459 |
+
msty: {
|
| 460 |
+
prettyLabel: "Msty",
|
| 461 |
+
docsUrl: "https://msty.app",
|
| 462 |
+
mainTask: "text-generation",
|
| 463 |
+
displayOnModelPage: isLlamaCppGgufModel,
|
| 464 |
+
deeplink: (model) => new URL(`msty://models/search/hf/${model.id}`),
|
| 465 |
+
},
|
| 466 |
+
recursechat: {
|
| 467 |
+
prettyLabel: "RecurseChat",
|
| 468 |
+
docsUrl: "https://recurse.chat",
|
| 469 |
+
mainTask: "text-generation",
|
| 470 |
+
macOSOnly: true,
|
| 471 |
+
displayOnModelPage: isLlamaCppGgufModel,
|
| 472 |
+
deeplink: (model) => new URL(`recursechat://new-hf-gguf-model?hf-model-id=${model.id}`),
|
| 473 |
+
},
|
| 474 |
+
drawthings: {
|
| 475 |
+
prettyLabel: "Draw Things",
|
| 476 |
+
docsUrl: "https://drawthings.ai",
|
| 477 |
+
mainTask: "text-to-image",
|
| 478 |
+
macOSOnly: true,
|
| 479 |
+
displayOnModelPage: (model) => model.library_name === "diffusers" && (model.pipeline_tag === "text-to-image" || model.tags.includes("lora")),
|
| 480 |
+
deeplink: (model) => {
|
| 481 |
+
if (model.tags.includes("lora")) {
|
| 482 |
+
return new URL(`https://drawthings.ai/import/diffusers/pipeline.load_lora_weights?repo_id=${model.id}`);
|
| 483 |
+
}
|
| 484 |
+
else {
|
| 485 |
+
return new URL(`https://drawthings.ai/import/diffusers/pipeline.from_pretrained?repo_id=${model.id}`);
|
| 486 |
+
}
|
| 487 |
+
},
|
| 488 |
+
},
|
| 489 |
+
diffusionbee: {
|
| 490 |
+
prettyLabel: "DiffusionBee",
|
| 491 |
+
docsUrl: "https://diffusionbee.com",
|
| 492 |
+
mainTask: "text-to-image",
|
| 493 |
+
macOSOnly: true,
|
| 494 |
+
displayOnModelPage: (model) => model.library_name === "diffusers" && model.pipeline_tag === "text-to-image",
|
| 495 |
+
deeplink: (model) => new URL(`https://diffusionbee.com/huggingface_import?model_id=${model.id}`),
|
| 496 |
+
},
|
| 497 |
+
joyfusion: {
|
| 498 |
+
prettyLabel: "JoyFusion",
|
| 499 |
+
docsUrl: "https://joyfusion.app",
|
| 500 |
+
mainTask: "text-to-image",
|
| 501 |
+
macOSOnly: true,
|
| 502 |
+
displayOnModelPage: (model) => model.tags.includes("coreml") && model.tags.includes("joyfusion") && model.pipeline_tag === "text-to-image",
|
| 503 |
+
deeplink: (model) => new URL(`https://joyfusion.app/import_from_hf?repo_id=${model.id}`),
|
| 504 |
+
},
|
| 505 |
+
ollama: {
|
| 506 |
+
prettyLabel: "Ollama",
|
| 507 |
+
docsUrl: "https://ollama.com",
|
| 508 |
+
mainTask: "text-generation",
|
| 509 |
+
displayOnModelPage: isLlamaCppGgufModel,
|
| 510 |
+
snippet: snippetOllama,
|
| 511 |
+
},
|
| 512 |
+
"docker-model-runner": {
|
| 513 |
+
prettyLabel: "Docker Model Runner",
|
| 514 |
+
docsUrl: "https://docs.docker.com/ai/model-runner/",
|
| 515 |
+
mainTask: "text-generation",
|
| 516 |
+
displayOnModelPage: isDockerModelRunnerModel,
|
| 517 |
+
snippet: snippetDockerModelRunner,
|
| 518 |
+
},
|
| 519 |
+
lemonade: {
|
| 520 |
+
prettyLabel: "Lemonade",
|
| 521 |
+
docsUrl: "https://lemonade-server.ai",
|
| 522 |
+
mainTask: "text-generation",
|
| 523 |
+
displayOnModelPage: (model) => isLlamaCppGgufModel(model) || isAmdRyzenModel(model),
|
| 524 |
+
snippet: snippetLemonade,
|
| 525 |
+
},
|
| 526 |
+
};
|
node_modules/@huggingface/tasks/dist/commonjs/local-apps.spec.d.ts
ADDED
|
@@ -0,0 +1,2 @@
|
|
|
|
|
|
|
|
|
|
| 1 |
+
export {};
|
| 2 |
+
//# sourceMappingURL=local-apps.spec.d.ts.map
|
node_modules/@huggingface/tasks/dist/commonjs/local-apps.spec.d.ts.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
|
|
|
|
| 1 |
+
{"version":3,"file":"local-apps.spec.d.ts","sourceRoot":"","sources":["../../src/local-apps.spec.ts"],"names":[],"mappings":""}
|
node_modules/@huggingface/tasks/dist/commonjs/local-apps.spec.js
ADDED
|
@@ -0,0 +1,126 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
"use strict";
|
| 2 |
+
Object.defineProperty(exports, "__esModule", { value: true });
|
| 3 |
+
const vitest_1 = require("vitest");
|
| 4 |
+
const local_apps_js_1 = require("./local-apps.js");
|
| 5 |
+
(0, vitest_1.describe)("local-apps", () => {
|
| 6 |
+
(0, vitest_1.it)("llama.cpp conversational", async () => {
|
| 7 |
+
const { snippet: snippetFunc } = local_apps_js_1.LOCAL_APPS["llama.cpp"];
|
| 8 |
+
const model = {
|
| 9 |
+
id: "bartowski/Llama-3.2-3B-Instruct-GGUF",
|
| 10 |
+
tags: ["conversational"],
|
| 11 |
+
inference: "",
|
| 12 |
+
};
|
| 13 |
+
const snippet = snippetFunc(model);
|
| 14 |
+
(0, vitest_1.expect)(snippet[0].content).toEqual([
|
| 15 |
+
`# Start a local OpenAI-compatible server with a web UI:
|
| 16 |
+
llama-server -hf bartowski/Llama-3.2-3B-Instruct-GGUF:{{QUANT_TAG}}`,
|
| 17 |
+
`# Run inference directly in the terminal:
|
| 18 |
+
llama-cli -hf bartowski/Llama-3.2-3B-Instruct-GGUF:{{QUANT_TAG}}`,
|
| 19 |
+
]);
|
| 20 |
+
});
|
| 21 |
+
(0, vitest_1.it)("llama.cpp non-conversational", async () => {
|
| 22 |
+
const { snippet: snippetFunc } = local_apps_js_1.LOCAL_APPS["llama.cpp"];
|
| 23 |
+
const model = {
|
| 24 |
+
id: "mlabonne/gemma-2b-GGUF",
|
| 25 |
+
tags: [],
|
| 26 |
+
inference: "",
|
| 27 |
+
};
|
| 28 |
+
const snippet = snippetFunc(model);
|
| 29 |
+
(0, vitest_1.expect)(snippet[0].content).toEqual([
|
| 30 |
+
`# Start a local OpenAI-compatible server with a web UI:
|
| 31 |
+
llama-server -hf mlabonne/gemma-2b-GGUF:{{QUANT_TAG}}`,
|
| 32 |
+
`# Run inference directly in the terminal:
|
| 33 |
+
llama-cli -hf mlabonne/gemma-2b-GGUF:{{QUANT_TAG}}`,
|
| 34 |
+
]);
|
| 35 |
+
});
|
| 36 |
+
(0, vitest_1.it)("vLLM conversational llm", async () => {
|
| 37 |
+
const { snippet: snippetFunc } = local_apps_js_1.LOCAL_APPS["vllm"];
|
| 38 |
+
const model = {
|
| 39 |
+
id: "meta-llama/Llama-3.2-3B-Instruct",
|
| 40 |
+
pipeline_tag: "text-generation",
|
| 41 |
+
tags: ["conversational"],
|
| 42 |
+
inference: "",
|
| 43 |
+
};
|
| 44 |
+
const snippet = snippetFunc(model);
|
| 45 |
+
(0, vitest_1.expect)(snippet[0].content.join("\n")).toEqual(`# Start the vLLM server:
|
| 46 |
+
vllm serve "meta-llama/Llama-3.2-3B-Instruct"
|
| 47 |
+
# Call the server using curl (OpenAI-compatible API):
|
| 48 |
+
curl -X POST "http://localhost:8000/v1/chat/completions" \\
|
| 49 |
+
-H "Content-Type: application/json" \\
|
| 50 |
+
--data '{
|
| 51 |
+
"model": "meta-llama/Llama-3.2-3B-Instruct",
|
| 52 |
+
"messages": [
|
| 53 |
+
{
|
| 54 |
+
"role": "user",
|
| 55 |
+
"content": "What is the capital of France?"
|
| 56 |
+
}
|
| 57 |
+
]
|
| 58 |
+
}'`);
|
| 59 |
+
});
|
| 60 |
+
(0, vitest_1.it)("vLLM non-conversational llm", async () => {
|
| 61 |
+
const { snippet: snippetFunc } = local_apps_js_1.LOCAL_APPS["vllm"];
|
| 62 |
+
const model = {
|
| 63 |
+
id: "meta-llama/Llama-3.2-3B",
|
| 64 |
+
tags: [""],
|
| 65 |
+
inference: "",
|
| 66 |
+
};
|
| 67 |
+
const snippet = snippetFunc(model);
|
| 68 |
+
(0, vitest_1.expect)(snippet[0].content.join("\n")).toEqual(`# Start the vLLM server:
|
| 69 |
+
vllm serve "meta-llama/Llama-3.2-3B"
|
| 70 |
+
# Call the server using curl (OpenAI-compatible API):
|
| 71 |
+
curl -X POST "http://localhost:8000/v1/completions" \\
|
| 72 |
+
-H "Content-Type: application/json" \\
|
| 73 |
+
--data '{
|
| 74 |
+
"model": "meta-llama/Llama-3.2-3B",
|
| 75 |
+
"prompt": "Once upon a time,",
|
| 76 |
+
"max_tokens": 512,
|
| 77 |
+
"temperature": 0.5
|
| 78 |
+
}'`);
|
| 79 |
+
});
|
| 80 |
+
(0, vitest_1.it)("vLLM conversational vlm", async () => {
|
| 81 |
+
const { snippet: snippetFunc } = local_apps_js_1.LOCAL_APPS["vllm"];
|
| 82 |
+
const model = {
|
| 83 |
+
id: "meta-llama/Llama-3.2-11B-Vision-Instruct",
|
| 84 |
+
pipeline_tag: "image-text-to-text",
|
| 85 |
+
tags: ["conversational"],
|
| 86 |
+
inference: "",
|
| 87 |
+
};
|
| 88 |
+
const snippet = snippetFunc(model);
|
| 89 |
+
(0, vitest_1.expect)(snippet[0].content.join("\n")).toEqual(`# Start the vLLM server:
|
| 90 |
+
vllm serve "meta-llama/Llama-3.2-11B-Vision-Instruct"
|
| 91 |
+
# Call the server using curl (OpenAI-compatible API):
|
| 92 |
+
curl -X POST "http://localhost:8000/v1/chat/completions" \\
|
| 93 |
+
-H "Content-Type: application/json" \\
|
| 94 |
+
--data '{
|
| 95 |
+
"model": "meta-llama/Llama-3.2-11B-Vision-Instruct",
|
| 96 |
+
"messages": [
|
| 97 |
+
{
|
| 98 |
+
"role": "user",
|
| 99 |
+
"content": [
|
| 100 |
+
{
|
| 101 |
+
"type": "text",
|
| 102 |
+
"text": "Describe this image in one sentence."
|
| 103 |
+
},
|
| 104 |
+
{
|
| 105 |
+
"type": "image_url",
|
| 106 |
+
"image_url": {
|
| 107 |
+
"url": "https://cdn.britannica.com/61/93061-050-99147DCE/Statue-of-Liberty-Island-New-York-Bay.jpg"
|
| 108 |
+
}
|
| 109 |
+
}
|
| 110 |
+
]
|
| 111 |
+
}
|
| 112 |
+
]
|
| 113 |
+
}'`);
|
| 114 |
+
});
|
| 115 |
+
(0, vitest_1.it)("docker model runner", async () => {
|
| 116 |
+
const { snippet: snippetFunc } = local_apps_js_1.LOCAL_APPS["docker-model-runner"];
|
| 117 |
+
const model = {
|
| 118 |
+
id: "bartowski/Llama-3.2-3B-Instruct-GGUF",
|
| 119 |
+
tags: ["conversational"],
|
| 120 |
+
gguf: { total: 1, context_length: 4096 },
|
| 121 |
+
inference: "",
|
| 122 |
+
};
|
| 123 |
+
const snippet = snippetFunc(model);
|
| 124 |
+
(0, vitest_1.expect)(snippet).toEqual(`docker model run hf.co/bartowski/Llama-3.2-3B-Instruct-GGUF:{{QUANT_TAG}}`);
|
| 125 |
+
});
|
| 126 |
+
});
|
node_modules/@huggingface/tasks/dist/commonjs/model-data.d.ts
ADDED
|
@@ -0,0 +1,153 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
import type { PipelineType } from "./pipelines.js";
|
| 2 |
+
import type { WidgetExample } from "./widget-example.js";
|
| 3 |
+
import type { TokenizerConfig } from "./tokenizer-data.js";
|
| 4 |
+
/**
|
| 5 |
+
* Public interface for model metadata
|
| 6 |
+
*/
|
| 7 |
+
export interface ModelData {
|
| 8 |
+
/**
|
| 9 |
+
* id of model (e.g. 'user/repo_name')
|
| 10 |
+
*/
|
| 11 |
+
id: string;
|
| 12 |
+
/**
|
| 13 |
+
* Whether or not to enable inference widget for this model
|
| 14 |
+
* TODO(type it)
|
| 15 |
+
*/
|
| 16 |
+
inference: string;
|
| 17 |
+
/**
|
| 18 |
+
* is this model private?
|
| 19 |
+
*/
|
| 20 |
+
private?: boolean;
|
| 21 |
+
/**
|
| 22 |
+
* this dictionary has useful information about the model configuration
|
| 23 |
+
*/
|
| 24 |
+
config?: {
|
| 25 |
+
architectures?: string[];
|
| 26 |
+
/**
|
| 27 |
+
* Dict of AutoModel or Auto… class name to local import path in the repo
|
| 28 |
+
*/
|
| 29 |
+
auto_map?: {
|
| 30 |
+
/**
|
| 31 |
+
* String Property
|
| 32 |
+
*/
|
| 33 |
+
[x: string]: string;
|
| 34 |
+
};
|
| 35 |
+
model_type?: string;
|
| 36 |
+
quantization_config?: {
|
| 37 |
+
bits?: number;
|
| 38 |
+
load_in_4bit?: boolean;
|
| 39 |
+
load_in_8bit?: boolean;
|
| 40 |
+
/**
|
| 41 |
+
* awq, gptq, aqlm, marlin, … Used by vLLM
|
| 42 |
+
*/
|
| 43 |
+
quant_method?: string;
|
| 44 |
+
};
|
| 45 |
+
tokenizer_config?: TokenizerConfig;
|
| 46 |
+
processor_config?: {
|
| 47 |
+
chat_template?: string;
|
| 48 |
+
};
|
| 49 |
+
chat_template_jinja?: string;
|
| 50 |
+
adapter_transformers?: {
|
| 51 |
+
model_name?: string;
|
| 52 |
+
model_class?: string;
|
| 53 |
+
};
|
| 54 |
+
diffusers?: {
|
| 55 |
+
_class_name?: string;
|
| 56 |
+
};
|
| 57 |
+
sklearn?: {
|
| 58 |
+
model?: {
|
| 59 |
+
file?: string;
|
| 60 |
+
};
|
| 61 |
+
model_format?: string;
|
| 62 |
+
};
|
| 63 |
+
speechbrain?: {
|
| 64 |
+
speechbrain_interface?: string;
|
| 65 |
+
vocoder_interface?: string;
|
| 66 |
+
vocoder_model_id?: string;
|
| 67 |
+
};
|
| 68 |
+
peft?: {
|
| 69 |
+
base_model_name_or_path?: string;
|
| 70 |
+
task_type?: string;
|
| 71 |
+
};
|
| 72 |
+
keras_hub?: {
|
| 73 |
+
tasks?: string[];
|
| 74 |
+
};
|
| 75 |
+
};
|
| 76 |
+
/**
|
| 77 |
+
* all the model tags
|
| 78 |
+
*/
|
| 79 |
+
tags: string[];
|
| 80 |
+
/**
|
| 81 |
+
* transformers-specific info to display in the code sample.
|
| 82 |
+
*/
|
| 83 |
+
transformersInfo?: TransformersInfo;
|
| 84 |
+
/**
|
| 85 |
+
* Pipeline type
|
| 86 |
+
*/
|
| 87 |
+
pipeline_tag?: PipelineType | undefined;
|
| 88 |
+
/**
|
| 89 |
+
* for relevant models, get mask token
|
| 90 |
+
*/
|
| 91 |
+
mask_token?: string | undefined;
|
| 92 |
+
/**
|
| 93 |
+
* Example data that will be fed into the widget.
|
| 94 |
+
*
|
| 95 |
+
* can be set in the model card metadata (under `widget`),
|
| 96 |
+
* or by default in `DefaultWidget.ts`
|
| 97 |
+
*/
|
| 98 |
+
widgetData?: WidgetExample[] | undefined;
|
| 99 |
+
/**
|
| 100 |
+
* Parameters that will be used by the widget when calling Inference API (serverless)
|
| 101 |
+
* https://huggingface.co/docs/api-inference/detailed_parameters
|
| 102 |
+
*
|
| 103 |
+
* can be set in the model card metadata (under `inference/parameters`)
|
| 104 |
+
* Example:
|
| 105 |
+
* inference:
|
| 106 |
+
* parameters:
|
| 107 |
+
* key: val
|
| 108 |
+
*/
|
| 109 |
+
cardData?: {
|
| 110 |
+
inference?: boolean | {
|
| 111 |
+
parameters?: Record<string, unknown>;
|
| 112 |
+
};
|
| 113 |
+
base_model?: string | string[];
|
| 114 |
+
instance_prompt?: string | null;
|
| 115 |
+
};
|
| 116 |
+
/**
|
| 117 |
+
* Library name
|
| 118 |
+
* Example: transformers, SpeechBrain, Stanza, etc.
|
| 119 |
+
*/
|
| 120 |
+
library_name?: string;
|
| 121 |
+
safetensors?: {
|
| 122 |
+
parameters: Record<string, number>;
|
| 123 |
+
total: number;
|
| 124 |
+
sharded: boolean;
|
| 125 |
+
};
|
| 126 |
+
gguf?: {
|
| 127 |
+
total: number;
|
| 128 |
+
architecture?: string;
|
| 129 |
+
context_length?: number;
|
| 130 |
+
};
|
| 131 |
+
}
|
| 132 |
+
/**
|
| 133 |
+
* transformers-specific info to display in the code sample.
|
| 134 |
+
*/
|
| 135 |
+
export interface TransformersInfo {
|
| 136 |
+
/**
|
| 137 |
+
* e.g. AutoModelForSequenceClassification
|
| 138 |
+
*/
|
| 139 |
+
auto_model: string;
|
| 140 |
+
/**
|
| 141 |
+
* if set in config.json's auto_map
|
| 142 |
+
*/
|
| 143 |
+
custom_class?: string;
|
| 144 |
+
/**
|
| 145 |
+
* e.g. text-classification
|
| 146 |
+
*/
|
| 147 |
+
pipeline_tag?: PipelineType;
|
| 148 |
+
/**
|
| 149 |
+
* e.g. "AutoTokenizer" | "AutoFeatureExtractor" | "AutoProcessor"
|
| 150 |
+
*/
|
| 151 |
+
processor?: string;
|
| 152 |
+
}
|
| 153 |
+
//# sourceMappingURL=model-data.d.ts.map
|
node_modules/@huggingface/tasks/dist/commonjs/model-data.d.ts.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
|
|
|
|
| 1 |
+
{"version":3,"file":"model-data.d.ts","sourceRoot":"","sources":["../../src/model-data.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAA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,WAAW,gBAAgB;IAChC;;OAEG;IACH,UAAU,EAAE,MAAM,CAAC;IACnB;;OAEG;IACH,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB;;OAEG;IACH,YAAY,CAAC,EAAE,YAAY,CAAC;IAC5B;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;CACnB"}
|
node_modules/@huggingface/tasks/dist/commonjs/model-data.js
ADDED
|
@@ -0,0 +1,2 @@
|
|
|
|
|
|
|
|
|
|
| 1 |
+
"use strict";
|
| 2 |
+
Object.defineProperty(exports, "__esModule", { value: true });
|
node_modules/@huggingface/tasks/dist/commonjs/model-libraries-downloads.d.ts
ADDED
|
@@ -0,0 +1,18 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
/**
|
| 2 |
+
* This file contains the (simplified) types used
|
| 3 |
+
* to represent queries that are made to Elastic
|
| 4 |
+
* in order to count number of model downloads
|
| 5 |
+
*
|
| 6 |
+
* Read this doc about download stats on the Hub:
|
| 7 |
+
*
|
| 8 |
+
* https://huggingface.co/docs/hub/models-download-stats
|
| 9 |
+
* Available fields:
|
| 10 |
+
* - path: the complete file path (relative) (e.g: "prefix/file.extension")
|
| 11 |
+
* - path_prefix: the prefix of the file path (e.g: "prefix/", empty if no prefix)
|
| 12 |
+
* - path_extension: the extension of the file path (e.g: "extension")
|
| 13 |
+
* - path_filename: the name of the file path (e.g: "file")
|
| 14 |
+
* see also:
|
| 15 |
+
* https://www.elastic.co/guide/en/elasticsearch/reference/current/query-dsl-query-string-query.html
|
| 16 |
+
*/
|
| 17 |
+
export type ElasticSearchQuery = string;
|
| 18 |
+
//# sourceMappingURL=model-libraries-downloads.d.ts.map
|
node_modules/@huggingface/tasks/dist/commonjs/model-libraries-downloads.d.ts.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
|
|
|
|
| 1 |
+
{"version":3,"file":"model-libraries-downloads.d.ts","sourceRoot":"","sources":["../../src/model-libraries-downloads.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AAEH,MAAM,MAAM,kBAAkB,GAAG,MAAM,CAAC"}
|
node_modules/@huggingface/tasks/dist/commonjs/model-libraries-downloads.js
ADDED
|
@@ -0,0 +1,18 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
"use strict";
|
| 2 |
+
/**
|
| 3 |
+
* This file contains the (simplified) types used
|
| 4 |
+
* to represent queries that are made to Elastic
|
| 5 |
+
* in order to count number of model downloads
|
| 6 |
+
*
|
| 7 |
+
* Read this doc about download stats on the Hub:
|
| 8 |
+
*
|
| 9 |
+
* https://huggingface.co/docs/hub/models-download-stats
|
| 10 |
+
* Available fields:
|
| 11 |
+
* - path: the complete file path (relative) (e.g: "prefix/file.extension")
|
| 12 |
+
* - path_prefix: the prefix of the file path (e.g: "prefix/", empty if no prefix)
|
| 13 |
+
* - path_extension: the extension of the file path (e.g: "extension")
|
| 14 |
+
* - path_filename: the name of the file path (e.g: "file")
|
| 15 |
+
* see also:
|
| 16 |
+
* https://www.elastic.co/guide/en/elasticsearch/reference/current/query-dsl-query-string-query.html
|
| 17 |
+
*/
|
| 18 |
+
Object.defineProperty(exports, "__esModule", { value: true });
|
node_modules/@huggingface/tasks/dist/commonjs/model-libraries-snippets.d.ts
ADDED
|
@@ -0,0 +1,113 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
import type { ModelData } from "./model-data.js";
|
| 2 |
+
export declare const adapters: (model: ModelData) => string[];
|
| 3 |
+
export declare const allennlp: (model: ModelData) => string[];
|
| 4 |
+
export declare const araclip: (model: ModelData) => string[];
|
| 5 |
+
export declare const asteroid: (model: ModelData) => string[];
|
| 6 |
+
export declare const audioseal: (model: ModelData) => string[];
|
| 7 |
+
export declare const ben2: (model: ModelData) => string[];
|
| 8 |
+
export declare const bertopic: (model: ModelData) => string[];
|
| 9 |
+
export declare const bm25s: (model: ModelData) => string[];
|
| 10 |
+
export declare const chatterbox: () => string[];
|
| 11 |
+
export declare const chronos_forecasting: (model: ModelData) => string[];
|
| 12 |
+
export declare const colipri: (model: ModelData) => string[];
|
| 13 |
+
export declare const sap_rpt_one_oss: () => string[];
|
| 14 |
+
export declare const cxr_foundation: () => string[];
|
| 15 |
+
export declare const depth_anything_v2: (model: ModelData) => string[];
|
| 16 |
+
export declare const depth_pro: (model: ModelData) => string[];
|
| 17 |
+
export declare const derm_foundation: () => string[];
|
| 18 |
+
export declare const dia: (model: ModelData) => string[];
|
| 19 |
+
export declare const dia2: (model: ModelData) => string[];
|
| 20 |
+
export declare const describe_anything: (model: ModelData) => string[];
|
| 21 |
+
export declare const diffusers: (model: ModelData) => string[];
|
| 22 |
+
export declare const diffusionkit: (model: ModelData) => string[];
|
| 23 |
+
export declare const cartesia_pytorch: (model: ModelData) => string[];
|
| 24 |
+
export declare const cartesia_mlx: (model: ModelData) => string[];
|
| 25 |
+
export declare const edsnlp: (model: ModelData) => string[];
|
| 26 |
+
export declare const espnetTTS: (model: ModelData) => string[];
|
| 27 |
+
export declare const espnetASR: (model: ModelData) => string[];
|
| 28 |
+
export declare const espnet: (model: ModelData) => string[];
|
| 29 |
+
export declare const fairseq: (model: ModelData) => string[];
|
| 30 |
+
export declare const flair: (model: ModelData) => string[];
|
| 31 |
+
export declare const gliner: (model: ModelData) => string[];
|
| 32 |
+
export declare const gliner2: (model: ModelData) => string[];
|
| 33 |
+
export declare const indextts: (model: ModelData) => string[];
|
| 34 |
+
export declare const htrflow: (model: ModelData) => string[];
|
| 35 |
+
export declare const keras: (model: ModelData) => string[];
|
| 36 |
+
export declare const keras_hub: (model: ModelData) => string[];
|
| 37 |
+
export declare const kernels: (model: ModelData) => string[];
|
| 38 |
+
export declare const kimi_audio: (model: ModelData) => string[];
|
| 39 |
+
export declare const kittentts: (model: ModelData) => string[];
|
| 40 |
+
export declare const lightning_ir: (model: ModelData) => string[];
|
| 41 |
+
export declare const llama_cpp_python: (model: ModelData) => string[];
|
| 42 |
+
export declare const lerobot: (model: ModelData) => string[];
|
| 43 |
+
export declare const tf_keras: (model: ModelData) => string[];
|
| 44 |
+
export declare const mamba_ssm: (model: ModelData) => string[];
|
| 45 |
+
export declare const mars5_tts: (model: ModelData) => string[];
|
| 46 |
+
export declare const matanyone: (model: ModelData) => string[];
|
| 47 |
+
export declare const mesh_anything: () => string[];
|
| 48 |
+
export declare const open_clip: (model: ModelData) => string[];
|
| 49 |
+
export declare const paddlenlp: (model: ModelData) => string[];
|
| 50 |
+
export declare const paddleocr: (model: ModelData) => string[];
|
| 51 |
+
export declare const perception_encoder: (model: ModelData) => string[];
|
| 52 |
+
export declare const phantom_wan: (model: ModelData) => string[];
|
| 53 |
+
export declare const pocket_tts: (model: ModelData) => string[];
|
| 54 |
+
export declare const pyannote_audio_pipeline: (model: ModelData) => string[];
|
| 55 |
+
export declare const pyannote_audio: (model: ModelData) => string[];
|
| 56 |
+
export declare const relik: (model: ModelData) => string[];
|
| 57 |
+
export declare const renderformer: (model: ModelData) => string[];
|
| 58 |
+
export declare const tensorflowtts: (model: ModelData) => string[];
|
| 59 |
+
export declare const timm: (model: ModelData) => string[];
|
| 60 |
+
export declare const saelens: () => string[];
|
| 61 |
+
export declare const seed_story: () => string[];
|
| 62 |
+
export declare const sklearn: (model: ModelData) => string[];
|
| 63 |
+
export declare const stable_audio_tools: (model: ModelData) => string[];
|
| 64 |
+
export declare const fastai: (model: ModelData) => string[];
|
| 65 |
+
export declare const sam2: (model: ModelData) => string[];
|
| 66 |
+
export declare const sam_3d_objects: (model: ModelData) => string[];
|
| 67 |
+
export declare const sam_3d_body: (model: ModelData) => string[];
|
| 68 |
+
export declare const sampleFactory: (model: ModelData) => string[];
|
| 69 |
+
export declare const sentenceTransformers: (model: ModelData) => string[];
|
| 70 |
+
export declare const setfit: (model: ModelData) => string[];
|
| 71 |
+
export declare const spacy: (model: ModelData) => string[];
|
| 72 |
+
export declare const span_marker: (model: ModelData) => string[];
|
| 73 |
+
export declare const stanza: (model: ModelData) => string[];
|
| 74 |
+
export declare const speechbrain: (model: ModelData) => string[];
|
| 75 |
+
export declare const terratorch: (model: ModelData) => string[];
|
| 76 |
+
export declare const transformers: (model: ModelData) => string[];
|
| 77 |
+
export declare const transformersJS: (model: ModelData) => string[];
|
| 78 |
+
export declare const peft: (model: ModelData) => string[];
|
| 79 |
+
export declare const fasttext: (model: ModelData) => string[];
|
| 80 |
+
export declare const stableBaselines3: (model: ModelData) => string[];
|
| 81 |
+
export declare const mlAgents: (model: ModelData) => string[];
|
| 82 |
+
export declare const sentis: () => string[];
|
| 83 |
+
export declare const sana: (model: ModelData) => string[];
|
| 84 |
+
export declare const vibevoice: (model: ModelData) => string[];
|
| 85 |
+
export declare const videoprism: (model: ModelData) => string[];
|
| 86 |
+
export declare const vfimamba: (model: ModelData) => string[];
|
| 87 |
+
export declare const lvface: (model: ModelData) => string[];
|
| 88 |
+
export declare const voicecraft: (model: ModelData) => string[];
|
| 89 |
+
export declare const voxcpm: (model: ModelData) => string[];
|
| 90 |
+
export declare const vui: () => string[];
|
| 91 |
+
export declare const chattts: () => string[];
|
| 92 |
+
export declare const ultralytics: (model: ModelData) => string[];
|
| 93 |
+
export declare const birefnet: (model: ModelData) => string[];
|
| 94 |
+
export declare const supertonic: () => string[];
|
| 95 |
+
export declare const swarmformer: (model: ModelData) => string[];
|
| 96 |
+
export declare const univa: (model: ModelData) => string[];
|
| 97 |
+
export declare const mlxim: (model: ModelData) => string[];
|
| 98 |
+
export declare const mlx: (model: ModelData) => string[];
|
| 99 |
+
export declare const model2vec: (model: ModelData) => string[];
|
| 100 |
+
export declare const pruna: (model: ModelData) => string[];
|
| 101 |
+
export declare const nemo: (model: ModelData) => string[];
|
| 102 |
+
export declare const outetts: (model: ModelData) => string[];
|
| 103 |
+
export declare const pxia: (model: ModelData) => string[];
|
| 104 |
+
export declare const pythae: (model: ModelData) => string[];
|
| 105 |
+
export declare const qwen3_tts: (model: ModelData) => string[];
|
| 106 |
+
export declare const anemoi: (model: ModelData) => string[];
|
| 107 |
+
export declare const audiocraft: (model: ModelData) => string[];
|
| 108 |
+
export declare const whisperkit: () => string[];
|
| 109 |
+
export declare const threedtopia_xl: (model: ModelData) => string[];
|
| 110 |
+
export declare const hezar: (model: ModelData) => string[];
|
| 111 |
+
export declare const zonos: (model: ModelData) => string[];
|
| 112 |
+
export declare const moshi: (model: ModelData) => string[];
|
| 113 |
+
//# sourceMappingURL=model-libraries-snippets.d.ts.map
|
node_modules/@huggingface/tasks/dist/commonjs/model-libraries-snippets.d.ts.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
|
|
|
|
| 1 |
+
{"version":3,"file":"model-libraries-snippets.d.ts","sourceRoot":"","sources":["../../src/model-libraries-snippets.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAkBjD,eAAO,MAAM,QAAQ,GAAI,OAAO,SAAS,KAAG,MAAM,EAKjD,CAAC;AAkBF,eAAO,MAAM,QAAQ,GAAI,OAAO,SAAS,KAAG,MAAM,EAKjD,CAAC;AAEF,eAAO,MAAM,OAAO,GAAI,OAAO,SAAS,KAAG,MAAM,EAIhD,CAAC;AAEF,eAAO,MAAM,QAAQ,GAAI,OAAO,SAAS,KAAG,MAAM,EAIjD,CAAC;AAEF,eAAO,MAAM,SAAS,GAAI,OAAO,SAAS,KAAG,MAAM,EAkBlD,CAAC;AAaF,eAAO,MAAM,IAAI,GAAI,OAAO,SAAS,KAAG,MAAM,EAY7C,CAAC;AAEF,eAAO,MAAM,QAAQ,GAAI,OAAO,SAAS,KAAG,MAAM,EAIjD,CAAC;AAEF,eAAO,MAAM,KAAK,GAAI,OAAO,SAAS,KAAG,MAAM,EAI9C,CAAC;AAEF,eAAO,MAAM,UAAU,QAAO,MAAM,EAenC,CAAC;AAEF,eAAO,MAAM,mBAAmB,GAAI,OAAO,SAAS,KAAG,MAAM,EAsB5D,CAAC;AAEF,eAAO,MAAM,OAAO,GAAI,OAAO,SAAS,KAAG,MAAM,EAkBhD,CAAC;AAEF,eAAO,MAAM,eAAe,QAAO,MAAM,EAmDxC,CAAC;AAEF,eAAO,MAAM,cAAc,QAAO,MAAM,EAcvC,CAAC;AAEF,eAAO,MAAM,iBAAiB,GAAI,OAAO,SAAS,KAAG,MAAM,EA6C1D,CAAC;AAEF,eAAO,MAAM,SAAS,GAAI,OAAO,SAAS,KAAG,MAAM,EAwBlD,CA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|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
"use strict";
|
| 2 |
+
Object.defineProperty(exports, "__esModule", { value: true });
|
| 3 |
+
exports.perception_encoder = exports.paddleocr = exports.paddlenlp = exports.open_clip = exports.mesh_anything = exports.matanyone = exports.mars5_tts = exports.mamba_ssm = exports.tf_keras = exports.lerobot = exports.llama_cpp_python = exports.lightning_ir = exports.kittentts = exports.kimi_audio = exports.kernels = exports.keras_hub = exports.keras = exports.htrflow = exports.indextts = exports.gliner2 = exports.gliner = exports.flair = exports.fairseq = exports.espnet = exports.espnetASR = exports.espnetTTS = exports.edsnlp = exports.cartesia_mlx = exports.cartesia_pytorch = exports.diffusionkit = exports.diffusers = exports.describe_anything = exports.dia2 = exports.dia = exports.derm_foundation = exports.depth_pro = exports.depth_anything_v2 = exports.cxr_foundation = exports.sap_rpt_one_oss = exports.colipri = exports.chronos_forecasting = exports.chatterbox = exports.bm25s = exports.bertopic = exports.ben2 = exports.audioseal = exports.asteroid = exports.araclip = exports.allennlp = exports.adapters = void 0;
|
| 4 |
+
exports.nemo = exports.pruna = exports.model2vec = exports.mlx = exports.mlxim = exports.univa = exports.swarmformer = exports.supertonic = exports.birefnet = exports.ultralytics = exports.chattts = exports.vui = exports.voxcpm = exports.voicecraft = exports.lvface = exports.vfimamba = exports.videoprism = exports.vibevoice = exports.sana = exports.sentis = exports.mlAgents = exports.stableBaselines3 = exports.fasttext = exports.peft = exports.transformersJS = exports.transformers = exports.terratorch = exports.speechbrain = exports.stanza = exports.span_marker = exports.spacy = exports.setfit = exports.sentenceTransformers = exports.sampleFactory = exports.sam_3d_body = exports.sam_3d_objects = exports.sam2 = exports.fastai = exports.stable_audio_tools = exports.sklearn = exports.seed_story = exports.saelens = exports.timm = exports.tensorflowtts = exports.renderformer = exports.relik = exports.pyannote_audio = exports.pyannote_audio_pipeline = exports.pocket_tts = exports.phantom_wan = void 0;
|
| 5 |
+
exports.moshi = exports.zonos = exports.hezar = exports.threedtopia_xl = exports.whisperkit = exports.audiocraft = exports.anemoi = exports.qwen3_tts = exports.pythae = exports.pxia = exports.outetts = void 0;
|
| 6 |
+
const library_to_tasks_js_1 = require("./library-to-tasks.js");
|
| 7 |
+
const inputs_js_1 = require("./snippets/inputs.js");
|
| 8 |
+
const common_js_1 = require("./snippets/common.js");
|
| 9 |
+
const TAG_CUSTOM_CODE = "custom_code";
|
| 10 |
+
function nameWithoutNamespace(modelId) {
|
| 11 |
+
const splitted = modelId.split("/");
|
| 12 |
+
return splitted.length === 1 ? splitted[0] : splitted[1];
|
| 13 |
+
}
|
| 14 |
+
const escapeStringForJson = (str) => JSON.stringify(str).slice(1, -1); // slice is needed to remove surrounding quotes added by JSON.stringify
|
| 15 |
+
//#region snippets
|
| 16 |
+
const adapters = (model) => [
|
| 17 |
+
`from adapters import AutoAdapterModel
|
| 18 |
+
|
| 19 |
+
model = AutoAdapterModel.from_pretrained("${model.config?.adapter_transformers?.model_name}")
|
| 20 |
+
model.load_adapter("${model.id}", set_active=True)`,
|
| 21 |
+
];
|
| 22 |
+
exports.adapters = adapters;
|
| 23 |
+
const allennlpUnknown = (model) => [
|
| 24 |
+
`import allennlp_models
|
| 25 |
+
from allennlp.predictors.predictor import Predictor
|
| 26 |
+
|
| 27 |
+
predictor = Predictor.from_path("hf://${model.id}")`,
|
| 28 |
+
];
|
| 29 |
+
const allennlpQuestionAnswering = (model) => [
|
| 30 |
+
`import allennlp_models
|
| 31 |
+
from allennlp.predictors.predictor import Predictor
|
| 32 |
+
|
| 33 |
+
predictor = Predictor.from_path("hf://${model.id}")
|
| 34 |
+
predictor_input = {"passage": "My name is Wolfgang and I live in Berlin", "question": "Where do I live?"}
|
| 35 |
+
predictions = predictor.predict_json(predictor_input)`,
|
| 36 |
+
];
|
| 37 |
+
const allennlp = (model) => {
|
| 38 |
+
if (model.tags.includes("question-answering")) {
|
| 39 |
+
return allennlpQuestionAnswering(model);
|
| 40 |
+
}
|
| 41 |
+
return allennlpUnknown(model);
|
| 42 |
+
};
|
| 43 |
+
exports.allennlp = allennlp;
|
| 44 |
+
const araclip = (model) => [
|
| 45 |
+
`from araclip import AraClip
|
| 46 |
+
|
| 47 |
+
model = AraClip.from_pretrained("${model.id}")`,
|
| 48 |
+
];
|
| 49 |
+
exports.araclip = araclip;
|
| 50 |
+
const asteroid = (model) => [
|
| 51 |
+
`from asteroid.models import BaseModel
|
| 52 |
+
|
| 53 |
+
model = BaseModel.from_pretrained("${model.id}")`,
|
| 54 |
+
];
|
| 55 |
+
exports.asteroid = asteroid;
|
| 56 |
+
const audioseal = (model) => {
|
| 57 |
+
const watermarkSnippet = `# Watermark Generator
|
| 58 |
+
from audioseal import AudioSeal
|
| 59 |
+
|
| 60 |
+
model = AudioSeal.load_generator("${model.id}")
|
| 61 |
+
# pass a tensor (tensor_wav) of shape (batch, channels, samples) and a sample rate
|
| 62 |
+
wav, sr = tensor_wav, 16000
|
| 63 |
+
|
| 64 |
+
watermark = model.get_watermark(wav, sr)
|
| 65 |
+
watermarked_audio = wav + watermark`;
|
| 66 |
+
const detectorSnippet = `# Watermark Detector
|
| 67 |
+
from audioseal import AudioSeal
|
| 68 |
+
|
| 69 |
+
detector = AudioSeal.load_detector("${model.id}")
|
| 70 |
+
|
| 71 |
+
result, message = detector.detect_watermark(watermarked_audio, sr)`;
|
| 72 |
+
return [watermarkSnippet, detectorSnippet];
|
| 73 |
+
};
|
| 74 |
+
exports.audioseal = audioseal;
|
| 75 |
+
function get_base_diffusers_model(model) {
|
| 76 |
+
return model.cardData?.base_model?.toString() ?? "fill-in-base-model";
|
| 77 |
+
}
|
| 78 |
+
function get_prompt_from_diffusers_model(model) {
|
| 79 |
+
const prompt = model.widgetData?.[0]?.text ?? model.cardData?.instance_prompt;
|
| 80 |
+
if (prompt) {
|
| 81 |
+
return escapeStringForJson(prompt);
|
| 82 |
+
}
|
| 83 |
+
}
|
| 84 |
+
const ben2 = (model) => [
|
| 85 |
+
`import requests
|
| 86 |
+
from PIL import Image
|
| 87 |
+
from ben2 import AutoModel
|
| 88 |
+
|
| 89 |
+
url = "https://huggingface.co/datasets/mishig/sample_images/resolve/main/teapot.jpg"
|
| 90 |
+
image = Image.open(requests.get(url, stream=True).raw)
|
| 91 |
+
|
| 92 |
+
model = AutoModel.from_pretrained("${model.id}")
|
| 93 |
+
model.to("cuda").eval()
|
| 94 |
+
foreground = model.inference(image)
|
| 95 |
+
`,
|
| 96 |
+
];
|
| 97 |
+
exports.ben2 = ben2;
|
| 98 |
+
const bertopic = (model) => [
|
| 99 |
+
`from bertopic import BERTopic
|
| 100 |
+
|
| 101 |
+
model = BERTopic.load("${model.id}")`,
|
| 102 |
+
];
|
| 103 |
+
exports.bertopic = bertopic;
|
| 104 |
+
const bm25s = (model) => [
|
| 105 |
+
`from bm25s.hf import BM25HF
|
| 106 |
+
|
| 107 |
+
retriever = BM25HF.load_from_hub("${model.id}")`,
|
| 108 |
+
];
|
| 109 |
+
exports.bm25s = bm25s;
|
| 110 |
+
const chatterbox = () => [
|
| 111 |
+
`# pip install chatterbox-tts
|
| 112 |
+
import torchaudio as ta
|
| 113 |
+
from chatterbox.tts import ChatterboxTTS
|
| 114 |
+
|
| 115 |
+
model = ChatterboxTTS.from_pretrained(device="cuda")
|
| 116 |
+
|
| 117 |
+
text = "Ezreal and Jinx teamed up with Ahri, Yasuo, and Teemo to take down the enemy's Nexus in an epic late-game pentakill."
|
| 118 |
+
wav = model.generate(text)
|
| 119 |
+
ta.save("test-1.wav", wav, model.sr)
|
| 120 |
+
|
| 121 |
+
# If you want to synthesize with a different voice, specify the audio prompt
|
| 122 |
+
AUDIO_PROMPT_PATH="YOUR_FILE.wav"
|
| 123 |
+
wav = model.generate(text, audio_prompt_path=AUDIO_PROMPT_PATH)
|
| 124 |
+
ta.save("test-2.wav", wav, model.sr)`,
|
| 125 |
+
];
|
| 126 |
+
exports.chatterbox = chatterbox;
|
| 127 |
+
const chronos_forecasting = (model) => {
|
| 128 |
+
const installSnippet = `pip install chronos-forecasting`;
|
| 129 |
+
const exampleSnippet = `import pandas as pd
|
| 130 |
+
from chronos import BaseChronosPipeline
|
| 131 |
+
|
| 132 |
+
pipeline = BaseChronosPipeline.from_pretrained("${model.id}", device_map="cuda")
|
| 133 |
+
|
| 134 |
+
# Load historical data
|
| 135 |
+
context_df = pd.read_csv("https://autogluon.s3.us-west-2.amazonaws.com/datasets/timeseries/misc/AirPassengers.csv")
|
| 136 |
+
|
| 137 |
+
# Generate predictions
|
| 138 |
+
pred_df = pipeline.predict_df(
|
| 139 |
+
context_df,
|
| 140 |
+
prediction_length=36, # Number of steps to forecast
|
| 141 |
+
quantile_levels=[0.1, 0.5, 0.9], # Quantiles for probabilistic forecast
|
| 142 |
+
id_column="item_id", # Column identifying different time series
|
| 143 |
+
timestamp_column="Month", # Column with datetime information
|
| 144 |
+
target="#Passengers", # Column(s) with time series values to predict
|
| 145 |
+
)`;
|
| 146 |
+
return [installSnippet, exampleSnippet];
|
| 147 |
+
};
|
| 148 |
+
exports.chronos_forecasting = chronos_forecasting;
|
| 149 |
+
const colipri = (model) => {
|
| 150 |
+
const installSnippet = `pip install colipri`;
|
| 151 |
+
const exampleSnippet = `from colipri import get_model
|
| 152 |
+
from colipri import get_processor
|
| 153 |
+
from colipri import load_sample_ct
|
| 154 |
+
from colipri import ZeroShotImageClassificationPipeline
|
| 155 |
+
|
| 156 |
+
model = get_model().cuda()
|
| 157 |
+
processor = get_processor()
|
| 158 |
+
pipeline = ZeroShotImageClassificationPipeline("${model.id}", processor)
|
| 159 |
+
|
| 160 |
+
image = load_sample_ct()
|
| 161 |
+
|
| 162 |
+
pipeline(image, ["No lung nodules", "Lung nodules"])
|
| 163 |
+
`;
|
| 164 |
+
return [installSnippet, exampleSnippet];
|
| 165 |
+
};
|
| 166 |
+
exports.colipri = colipri;
|
| 167 |
+
const sap_rpt_one_oss = () => {
|
| 168 |
+
const installSnippet = `pip install git+https://github.com/SAP-samples/sap-rpt-1-oss`;
|
| 169 |
+
const classificationSnippet = `# Run a classification task
|
| 170 |
+
from sklearn.datasets import load_breast_cancer
|
| 171 |
+
from sklearn.metrics import accuracy_score
|
| 172 |
+
from sklearn.model_selection import train_test_split
|
| 173 |
+
|
| 174 |
+
from sap_rpt_oss import SAP_RPT_OSS_Classifier
|
| 175 |
+
|
| 176 |
+
# Load sample data
|
| 177 |
+
X, y = load_breast_cancer(return_X_y=True)
|
| 178 |
+
X_train, X_test, y_train, y_test = train_test_split(X, y, test_size=0.5, random_state=42)
|
| 179 |
+
|
| 180 |
+
# Initialize a classifier, 8k context and 8-fold bagging gives best performance, reduce if running out of memory
|
| 181 |
+
clf = SAP_RPT_OSS_Classifier(max_context_size=8192, bagging=8)
|
| 182 |
+
|
| 183 |
+
clf.fit(X_train, y_train)
|
| 184 |
+
|
| 185 |
+
# Predict probabilities
|
| 186 |
+
prediction_probabilities = clf.predict_proba(X_test)
|
| 187 |
+
# Predict labels
|
| 188 |
+
predictions = clf.predict(X_test)
|
| 189 |
+
print("Accuracy", accuracy_score(y_test, predictions))`;
|
| 190 |
+
const regressionsSnippet = `# Run a regression task
|
| 191 |
+
from sklearn.datasets import fetch_openml
|
| 192 |
+
from sklearn.metrics import r2_score
|
| 193 |
+
from sklearn.model_selection import train_test_split
|
| 194 |
+
|
| 195 |
+
from sap_rpt_oss import SAP_RPT_OSS_Regressor
|
| 196 |
+
|
| 197 |
+
# Load sample data
|
| 198 |
+
df = fetch_openml(data_id=531, as_frame=True)
|
| 199 |
+
X = df.data
|
| 200 |
+
y = df.target.astype(float)
|
| 201 |
+
|
| 202 |
+
# Train-test split
|
| 203 |
+
X_train, X_test, y_train, y_test = train_test_split(X, y, test_size=0.5, random_state=42)
|
| 204 |
+
|
| 205 |
+
# Initialize the regressor, 8k context and 8-fold bagging gives best performance, reduce if running out of memory
|
| 206 |
+
regressor = SAP_RPT_OSS_Regressor(max_context_size=8192, bagging=8)
|
| 207 |
+
|
| 208 |
+
regressor.fit(X_train, y_train)
|
| 209 |
+
|
| 210 |
+
# Predict on the test set
|
| 211 |
+
predictions = regressor.predict(X_test)
|
| 212 |
+
|
| 213 |
+
r2 = r2_score(y_test, predictions)
|
| 214 |
+
print("R² Score:", r2)`;
|
| 215 |
+
return [installSnippet, classificationSnippet, regressionsSnippet];
|
| 216 |
+
};
|
| 217 |
+
exports.sap_rpt_one_oss = sap_rpt_one_oss;
|
| 218 |
+
const cxr_foundation = () => [
|
| 219 |
+
`# pip install git+https://github.com/Google-Health/cxr-foundation.git#subdirectory=python
|
| 220 |
+
|
| 221 |
+
# Load image as grayscale (Stillwaterising, CC0, via Wikimedia Commons)
|
| 222 |
+
import requests
|
| 223 |
+
from PIL import Image
|
| 224 |
+
from io import BytesIO
|
| 225 |
+
image_url = "https://upload.wikimedia.org/wikipedia/commons/c/c8/Chest_Xray_PA_3-8-2010.png"
|
| 226 |
+
img = Image.open(requests.get(image_url, headers={'User-Agent': 'Demo'}, stream=True).raw).convert('L')
|
| 227 |
+
|
| 228 |
+
# Run inference
|
| 229 |
+
from clientside.clients import make_hugging_face_client
|
| 230 |
+
cxr_client = make_hugging_face_client('cxr_model')
|
| 231 |
+
print(cxr_client.get_image_embeddings_from_images([img]))`,
|
| 232 |
+
];
|
| 233 |
+
exports.cxr_foundation = cxr_foundation;
|
| 234 |
+
const depth_anything_v2 = (model) => {
|
| 235 |
+
let encoder;
|
| 236 |
+
let features;
|
| 237 |
+
let out_channels;
|
| 238 |
+
encoder = "<ENCODER>";
|
| 239 |
+
features = "<NUMBER_OF_FEATURES>";
|
| 240 |
+
out_channels = "<OUT_CHANNELS>";
|
| 241 |
+
if (model.id === "depth-anything/Depth-Anything-V2-Small") {
|
| 242 |
+
encoder = "vits";
|
| 243 |
+
features = "64";
|
| 244 |
+
out_channels = "[48, 96, 192, 384]";
|
| 245 |
+
}
|
| 246 |
+
else if (model.id === "depth-anything/Depth-Anything-V2-Base") {
|
| 247 |
+
encoder = "vitb";
|
| 248 |
+
features = "128";
|
| 249 |
+
out_channels = "[96, 192, 384, 768]";
|
| 250 |
+
}
|
| 251 |
+
else if (model.id === "depth-anything/Depth-Anything-V2-Large") {
|
| 252 |
+
encoder = "vitl";
|
| 253 |
+
features = "256";
|
| 254 |
+
out_channels = "[256, 512, 1024, 1024";
|
| 255 |
+
}
|
| 256 |
+
return [
|
| 257 |
+
`
|
| 258 |
+
# Install from https://github.com/DepthAnything/Depth-Anything-V2
|
| 259 |
+
|
| 260 |
+
# Load the model and infer depth from an image
|
| 261 |
+
import cv2
|
| 262 |
+
import torch
|
| 263 |
+
|
| 264 |
+
from depth_anything_v2.dpt import DepthAnythingV2
|
| 265 |
+
|
| 266 |
+
# instantiate the model
|
| 267 |
+
model = DepthAnythingV2(encoder="${encoder}", features=${features}, out_channels=${out_channels})
|
| 268 |
+
|
| 269 |
+
# load the weights
|
| 270 |
+
filepath = hf_hub_download(repo_id="${model.id}", filename="depth_anything_v2_${encoder}.pth", repo_type="model")
|
| 271 |
+
state_dict = torch.load(filepath, map_location="cpu")
|
| 272 |
+
model.load_state_dict(state_dict).eval()
|
| 273 |
+
|
| 274 |
+
raw_img = cv2.imread("your/image/path")
|
| 275 |
+
depth = model.infer_image(raw_img) # HxW raw depth map in numpy
|
| 276 |
+
`,
|
| 277 |
+
];
|
| 278 |
+
};
|
| 279 |
+
exports.depth_anything_v2 = depth_anything_v2;
|
| 280 |
+
const depth_pro = (model) => {
|
| 281 |
+
const installSnippet = `# Download checkpoint
|
| 282 |
+
pip install huggingface-hub
|
| 283 |
+
huggingface-cli download --local-dir checkpoints ${model.id}`;
|
| 284 |
+
const inferenceSnippet = `import depth_pro
|
| 285 |
+
|
| 286 |
+
# Load model and preprocessing transform
|
| 287 |
+
model, transform = depth_pro.create_model_and_transforms()
|
| 288 |
+
model.eval()
|
| 289 |
+
|
| 290 |
+
# Load and preprocess an image.
|
| 291 |
+
image, _, f_px = depth_pro.load_rgb("example.png")
|
| 292 |
+
image = transform(image)
|
| 293 |
+
|
| 294 |
+
# Run inference.
|
| 295 |
+
prediction = model.infer(image, f_px=f_px)
|
| 296 |
+
|
| 297 |
+
# Results: 1. Depth in meters
|
| 298 |
+
depth = prediction["depth"]
|
| 299 |
+
# Results: 2. Focal length in pixels
|
| 300 |
+
focallength_px = prediction["focallength_px"]`;
|
| 301 |
+
return [installSnippet, inferenceSnippet];
|
| 302 |
+
};
|
| 303 |
+
exports.depth_pro = depth_pro;
|
| 304 |
+
const derm_foundation = () => [
|
| 305 |
+
`from huggingface_hub import from_pretrained_keras
|
| 306 |
+
import tensorflow as tf, requests
|
| 307 |
+
|
| 308 |
+
# Load and format input
|
| 309 |
+
IMAGE_URL = "https://storage.googleapis.com/dx-scin-public-data/dataset/images/3445096909671059178.png"
|
| 310 |
+
input_tensor = tf.train.Example(
|
| 311 |
+
features=tf.train.Features(
|
| 312 |
+
feature={
|
| 313 |
+
"image/encoded": tf.train.Feature(
|
| 314 |
+
bytes_list=tf.train.BytesList(value=[requests.get(IMAGE_URL, stream=True).content])
|
| 315 |
+
)
|
| 316 |
+
}
|
| 317 |
+
)
|
| 318 |
+
).SerializeToString()
|
| 319 |
+
|
| 320 |
+
# Load model and run inference
|
| 321 |
+
loaded_model = from_pretrained_keras("google/derm-foundation")
|
| 322 |
+
infer = loaded_model.signatures["serving_default"]
|
| 323 |
+
print(infer(inputs=tf.constant([input_tensor])))`,
|
| 324 |
+
];
|
| 325 |
+
exports.derm_foundation = derm_foundation;
|
| 326 |
+
const dia = (model) => [
|
| 327 |
+
`import soundfile as sf
|
| 328 |
+
from dia.model import Dia
|
| 329 |
+
|
| 330 |
+
model = Dia.from_pretrained("${model.id}")
|
| 331 |
+
text = "[S1] Dia is an open weights text to dialogue model. [S2] You get full control over scripts and voices. [S1] Wow. Amazing. (laughs) [S2] Try it now on Git hub or Hugging Face."
|
| 332 |
+
output = model.generate(text)
|
| 333 |
+
|
| 334 |
+
sf.write("simple.mp3", output, 44100)`,
|
| 335 |
+
];
|
| 336 |
+
exports.dia = dia;
|
| 337 |
+
const dia2 = (model) => [
|
| 338 |
+
`from dia2 import Dia2, GenerationConfig, SamplingConfig
|
| 339 |
+
|
| 340 |
+
dia = Dia2.from_repo("${model.id}", device="cuda", dtype="bfloat16")
|
| 341 |
+
config = GenerationConfig(
|
| 342 |
+
cfg_scale=2.0,
|
| 343 |
+
audio=SamplingConfig(temperature=0.8, top_k=50),
|
| 344 |
+
use_cuda_graph=True,
|
| 345 |
+
)
|
| 346 |
+
result = dia.generate("[S1] Hello Dia2!", config=config, output_wav="hello.wav", verbose=True)
|
| 347 |
+
`,
|
| 348 |
+
];
|
| 349 |
+
exports.dia2 = dia2;
|
| 350 |
+
const describe_anything = (model) => [
|
| 351 |
+
`# pip install git+https://github.com/NVlabs/describe-anything
|
| 352 |
+
from huggingface_hub import snapshot_download
|
| 353 |
+
from dam import DescribeAnythingModel
|
| 354 |
+
|
| 355 |
+
snapshot_download(${model.id}, local_dir="checkpoints")
|
| 356 |
+
|
| 357 |
+
dam = DescribeAnythingModel(
|
| 358 |
+
model_path="checkpoints",
|
| 359 |
+
conv_mode="v1",
|
| 360 |
+
prompt_mode="focal_prompt",
|
| 361 |
+
)`,
|
| 362 |
+
];
|
| 363 |
+
exports.describe_anything = describe_anything;
|
| 364 |
+
const diffusers_install = "pip install -U diffusers transformers accelerate";
|
| 365 |
+
const diffusersDefaultPrompt = "Astronaut in a jungle, cold color palette, muted colors, detailed, 8k";
|
| 366 |
+
const diffusersImg2ImgDefaultPrompt = "Turn this cat into a dog";
|
| 367 |
+
const diffusersVideoDefaultPrompt = "A man with short gray hair plays a red electric guitar.";
|
| 368 |
+
const diffusers_default = (model) => [
|
| 369 |
+
`import torch
|
| 370 |
+
from diffusers import DiffusionPipeline
|
| 371 |
+
|
| 372 |
+
# switch to "mps" for apple devices
|
| 373 |
+
pipe = DiffusionPipeline.from_pretrained("${model.id}", dtype=torch.bfloat16, device_map="cuda")
|
| 374 |
+
|
| 375 |
+
prompt = "${get_prompt_from_diffusers_model(model) ?? diffusersDefaultPrompt}"
|
| 376 |
+
image = pipe(prompt).images[0]`,
|
| 377 |
+
];
|
| 378 |
+
const diffusers_image_to_image = (model) => [
|
| 379 |
+
`import torch
|
| 380 |
+
from diffusers import DiffusionPipeline
|
| 381 |
+
from diffusers.utils import load_image
|
| 382 |
+
|
| 383 |
+
# switch to "mps" for apple devices
|
| 384 |
+
pipe = DiffusionPipeline.from_pretrained("${model.id}", dtype=torch.bfloat16, device_map="cuda")
|
| 385 |
+
|
| 386 |
+
prompt = "${get_prompt_from_diffusers_model(model) ?? diffusersImg2ImgDefaultPrompt}"
|
| 387 |
+
input_image = load_image("https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/cat.png")
|
| 388 |
+
|
| 389 |
+
image = pipe(image=input_image, prompt=prompt).images[0]`,
|
| 390 |
+
];
|
| 391 |
+
const diffusers_image_to_video = (model) => [
|
| 392 |
+
`import torch
|
| 393 |
+
from diffusers import DiffusionPipeline
|
| 394 |
+
from diffusers.utils import load_image, export_to_video
|
| 395 |
+
|
| 396 |
+
# switch to "mps" for apple devices
|
| 397 |
+
pipe = DiffusionPipeline.from_pretrained("${model.id}", dtype=torch.bfloat16, device_map="cuda")
|
| 398 |
+
pipe.to("cuda")
|
| 399 |
+
|
| 400 |
+
prompt = "${get_prompt_from_diffusers_model(model) ?? diffusersVideoDefaultPrompt}"
|
| 401 |
+
image = load_image(
|
| 402 |
+
"https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/guitar-man.png"
|
| 403 |
+
)
|
| 404 |
+
|
| 405 |
+
output = pipe(image=image, prompt=prompt).frames[0]
|
| 406 |
+
export_to_video(output, "output.mp4")`,
|
| 407 |
+
];
|
| 408 |
+
const diffusers_controlnet = (model) => [
|
| 409 |
+
`from diffusers import ControlNetModel, StableDiffusionControlNetPipeline
|
| 410 |
+
|
| 411 |
+
controlnet = ControlNetModel.from_pretrained("${model.id}")
|
| 412 |
+
pipe = StableDiffusionControlNetPipeline.from_pretrained(
|
| 413 |
+
"${get_base_diffusers_model(model)}", controlnet=controlnet
|
| 414 |
+
)`,
|
| 415 |
+
];
|
| 416 |
+
const diffusers_lora = (model) => [
|
| 417 |
+
`import torch
|
| 418 |
+
from diffusers import DiffusionPipeline
|
| 419 |
+
|
| 420 |
+
# switch to "mps" for apple devices
|
| 421 |
+
pipe = DiffusionPipeline.from_pretrained("${get_base_diffusers_model(model)}", dtype=torch.bfloat16, device_map="cuda")
|
| 422 |
+
pipe.load_lora_weights("${model.id}")
|
| 423 |
+
|
| 424 |
+
prompt = "${get_prompt_from_diffusers_model(model) ?? diffusersDefaultPrompt}"
|
| 425 |
+
image = pipe(prompt).images[0]`,
|
| 426 |
+
];
|
| 427 |
+
const diffusers_lora_image_to_image = (model) => [
|
| 428 |
+
`import torch
|
| 429 |
+
from diffusers import DiffusionPipeline
|
| 430 |
+
from diffusers.utils import load_image
|
| 431 |
+
|
| 432 |
+
# switch to "mps" for apple devices
|
| 433 |
+
pipe = DiffusionPipeline.from_pretrained("${get_base_diffusers_model(model)}", dtype=torch.bfloat16, device_map="cuda")
|
| 434 |
+
pipe.load_lora_weights("${model.id}")
|
| 435 |
+
|
| 436 |
+
prompt = "${get_prompt_from_diffusers_model(model) ?? diffusersImg2ImgDefaultPrompt}"
|
| 437 |
+
input_image = load_image("https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/cat.png")
|
| 438 |
+
|
| 439 |
+
image = pipe(image=input_image, prompt=prompt).images[0]`,
|
| 440 |
+
];
|
| 441 |
+
const diffusers_lora_text_to_video = (model) => [
|
| 442 |
+
`import torch
|
| 443 |
+
from diffusers import DiffusionPipeline
|
| 444 |
+
from diffusers.utils import export_to_video
|
| 445 |
+
|
| 446 |
+
# switch to "mps" for apple devices
|
| 447 |
+
pipe = DiffusionPipeline.from_pretrained("${get_base_diffusers_model(model)}", dtype=torch.bfloat16, device_map="cuda")
|
| 448 |
+
pipe.load_lora_weights("${model.id}")
|
| 449 |
+
|
| 450 |
+
prompt = "${get_prompt_from_diffusers_model(model) ?? diffusersVideoDefaultPrompt}"
|
| 451 |
+
|
| 452 |
+
output = pipe(prompt=prompt).frames[0]
|
| 453 |
+
export_to_video(output, "output.mp4")`,
|
| 454 |
+
];
|
| 455 |
+
const diffusers_lora_image_to_video = (model) => [
|
| 456 |
+
`import torch
|
| 457 |
+
from diffusers import DiffusionPipeline
|
| 458 |
+
from diffusers.utils import load_image, export_to_video
|
| 459 |
+
|
| 460 |
+
# switch to "mps" for apple devices
|
| 461 |
+
pipe = DiffusionPipeline.from_pretrained("${get_base_diffusers_model(model)}", dtype=torch.bfloat16, device_map="cuda")
|
| 462 |
+
pipe.load_lora_weights("${model.id}")
|
| 463 |
+
|
| 464 |
+
prompt = "${get_prompt_from_diffusers_model(model) ?? diffusersVideoDefaultPrompt}"
|
| 465 |
+
input_image = load_image("https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/guitar-man.png")
|
| 466 |
+
|
| 467 |
+
image = pipe(image=input_image, prompt=prompt).frames[0]
|
| 468 |
+
export_to_video(output, "output.mp4")`,
|
| 469 |
+
];
|
| 470 |
+
const diffusers_textual_inversion = (model) => [
|
| 471 |
+
`import torch
|
| 472 |
+
from diffusers import DiffusionPipeline
|
| 473 |
+
|
| 474 |
+
# switch to "mps" for apple devices
|
| 475 |
+
pipe = DiffusionPipeline.from_pretrained("${get_base_diffusers_model(model)}", dtype=torch.bfloat16, device_map="cuda")
|
| 476 |
+
pipe.load_textual_inversion("${model.id}")`,
|
| 477 |
+
];
|
| 478 |
+
const diffusers_flux_fill = (model) => [
|
| 479 |
+
`import torch
|
| 480 |
+
from diffusers import FluxFillPipeline
|
| 481 |
+
from diffusers.utils import load_image
|
| 482 |
+
|
| 483 |
+
image = load_image("https://huggingface.co/datasets/diffusers/diffusers-images-docs/resolve/main/cup.png")
|
| 484 |
+
mask = load_image("https://huggingface.co/datasets/diffusers/diffusers-images-docs/resolve/main/cup_mask.png")
|
| 485 |
+
|
| 486 |
+
# switch to "mps" for apple devices
|
| 487 |
+
pipe = FluxFillPipeline.from_pretrained("${model.id}", dtype=torch.bfloat16, device_map="cuda")
|
| 488 |
+
image = pipe(
|
| 489 |
+
prompt="a white paper cup",
|
| 490 |
+
image=image,
|
| 491 |
+
mask_image=mask,
|
| 492 |
+
height=1632,
|
| 493 |
+
width=1232,
|
| 494 |
+
guidance_scale=30,
|
| 495 |
+
num_inference_steps=50,
|
| 496 |
+
max_sequence_length=512,
|
| 497 |
+
generator=torch.Generator("cpu").manual_seed(0)
|
| 498 |
+
).images[0]
|
| 499 |
+
image.save(f"flux-fill-dev.png")`,
|
| 500 |
+
];
|
| 501 |
+
const diffusers_inpainting = (model) => [
|
| 502 |
+
`import torch
|
| 503 |
+
from diffusers import AutoPipelineForInpainting
|
| 504 |
+
from diffusers.utils import load_image
|
| 505 |
+
|
| 506 |
+
# switch to "mps" for apple devices
|
| 507 |
+
pipe = AutoPipelineForInpainting.from_pretrained("${model.id}", dtype=torch.float16, variant="fp16", device_map="cuda")
|
| 508 |
+
|
| 509 |
+
img_url = "https://raw.githubusercontent.com/CompVis/latent-diffusion/main/data/inpainting_examples/overture-creations-5sI6fQgYIuo.png"
|
| 510 |
+
mask_url = "https://raw.githubusercontent.com/CompVis/latent-diffusion/main/data/inpainting_examples/overture-creations-5sI6fQgYIuo_mask.png"
|
| 511 |
+
|
| 512 |
+
image = load_image(img_url).resize((1024, 1024))
|
| 513 |
+
mask_image = load_image(mask_url).resize((1024, 1024))
|
| 514 |
+
|
| 515 |
+
prompt = "a tiger sitting on a park bench"
|
| 516 |
+
generator = torch.Generator(device="cuda").manual_seed(0)
|
| 517 |
+
|
| 518 |
+
image = pipe(
|
| 519 |
+
prompt=prompt,
|
| 520 |
+
image=image,
|
| 521 |
+
mask_image=mask_image,
|
| 522 |
+
guidance_scale=8.0,
|
| 523 |
+
num_inference_steps=20, # steps between 15 and 30 work well for us
|
| 524 |
+
strength=0.99, # make sure to use \`strength\` below 1.0
|
| 525 |
+
generator=generator,
|
| 526 |
+
).images[0]`,
|
| 527 |
+
];
|
| 528 |
+
const diffusers = (model) => {
|
| 529 |
+
let codeSnippets;
|
| 530 |
+
if (model.tags.includes("StableDiffusionInpaintPipeline") ||
|
| 531 |
+
model.tags.includes("StableDiffusionXLInpaintPipeline")) {
|
| 532 |
+
codeSnippets = diffusers_inpainting(model);
|
| 533 |
+
}
|
| 534 |
+
else if (model.tags.includes("controlnet")) {
|
| 535 |
+
codeSnippets = diffusers_controlnet(model);
|
| 536 |
+
}
|
| 537 |
+
else if (model.tags.includes("lora")) {
|
| 538 |
+
if (model.pipeline_tag === "image-to-image") {
|
| 539 |
+
codeSnippets = diffusers_lora_image_to_image(model);
|
| 540 |
+
}
|
| 541 |
+
else if (model.pipeline_tag === "image-to-video") {
|
| 542 |
+
codeSnippets = diffusers_lora_image_to_video(model);
|
| 543 |
+
}
|
| 544 |
+
else if (model.pipeline_tag === "text-to-video") {
|
| 545 |
+
codeSnippets = diffusers_lora_text_to_video(model);
|
| 546 |
+
}
|
| 547 |
+
else {
|
| 548 |
+
codeSnippets = diffusers_lora(model);
|
| 549 |
+
}
|
| 550 |
+
}
|
| 551 |
+
else if (model.tags.includes("textual_inversion")) {
|
| 552 |
+
codeSnippets = diffusers_textual_inversion(model);
|
| 553 |
+
}
|
| 554 |
+
else if (model.tags.includes("FluxFillPipeline")) {
|
| 555 |
+
codeSnippets = diffusers_flux_fill(model);
|
| 556 |
+
}
|
| 557 |
+
else if (model.pipeline_tag === "image-to-video") {
|
| 558 |
+
codeSnippets = diffusers_image_to_video(model);
|
| 559 |
+
}
|
| 560 |
+
else if (model.pipeline_tag === "image-to-image") {
|
| 561 |
+
codeSnippets = diffusers_image_to_image(model);
|
| 562 |
+
}
|
| 563 |
+
else {
|
| 564 |
+
codeSnippets = diffusers_default(model);
|
| 565 |
+
}
|
| 566 |
+
return [diffusers_install, ...codeSnippets];
|
| 567 |
+
};
|
| 568 |
+
exports.diffusers = diffusers;
|
| 569 |
+
const diffusionkit = (model) => {
|
| 570 |
+
const sd3Snippet = `# Pipeline for Stable Diffusion 3
|
| 571 |
+
from diffusionkit.mlx import DiffusionPipeline
|
| 572 |
+
|
| 573 |
+
pipeline = DiffusionPipeline(
|
| 574 |
+
shift=3.0,
|
| 575 |
+
use_t5=False,
|
| 576 |
+
model_version=${model.id},
|
| 577 |
+
low_memory_mode=True,
|
| 578 |
+
a16=True,
|
| 579 |
+
w16=True,
|
| 580 |
+
)`;
|
| 581 |
+
const fluxSnippet = `# Pipeline for Flux
|
| 582 |
+
from diffusionkit.mlx import FluxPipeline
|
| 583 |
+
|
| 584 |
+
pipeline = FluxPipeline(
|
| 585 |
+
shift=1.0,
|
| 586 |
+
model_version=${model.id},
|
| 587 |
+
low_memory_mode=True,
|
| 588 |
+
a16=True,
|
| 589 |
+
w16=True,
|
| 590 |
+
)`;
|
| 591 |
+
const generateSnippet = `# Image Generation
|
| 592 |
+
HEIGHT = 512
|
| 593 |
+
WIDTH = 512
|
| 594 |
+
NUM_STEPS = ${model.tags.includes("flux") ? 4 : 50}
|
| 595 |
+
CFG_WEIGHT = ${model.tags.includes("flux") ? 0 : 5}
|
| 596 |
+
|
| 597 |
+
image, _ = pipeline.generate_image(
|
| 598 |
+
"a photo of a cat",
|
| 599 |
+
cfg_weight=CFG_WEIGHT,
|
| 600 |
+
num_steps=NUM_STEPS,
|
| 601 |
+
latent_size=(HEIGHT // 8, WIDTH // 8),
|
| 602 |
+
)`;
|
| 603 |
+
const pipelineSnippet = model.tags.includes("flux") ? fluxSnippet : sd3Snippet;
|
| 604 |
+
return [pipelineSnippet, generateSnippet];
|
| 605 |
+
};
|
| 606 |
+
exports.diffusionkit = diffusionkit;
|
| 607 |
+
const cartesia_pytorch = (model) => [
|
| 608 |
+
`# pip install --no-binary :all: cartesia-pytorch
|
| 609 |
+
from cartesia_pytorch import ReneLMHeadModel
|
| 610 |
+
from transformers import AutoTokenizer
|
| 611 |
+
|
| 612 |
+
model = ReneLMHeadModel.from_pretrained("${model.id}")
|
| 613 |
+
tokenizer = AutoTokenizer.from_pretrained("allenai/OLMo-1B-hf")
|
| 614 |
+
|
| 615 |
+
in_message = ["Rene Descartes was"]
|
| 616 |
+
inputs = tokenizer(in_message, return_tensors="pt")
|
| 617 |
+
|
| 618 |
+
outputs = model.generate(inputs.input_ids, max_length=50, top_k=100, top_p=0.99)
|
| 619 |
+
out_message = tokenizer.batch_decode(outputs, skip_special_tokens=True)[0]
|
| 620 |
+
|
| 621 |
+
print(out_message)
|
| 622 |
+
)`,
|
| 623 |
+
];
|
| 624 |
+
exports.cartesia_pytorch = cartesia_pytorch;
|
| 625 |
+
const cartesia_mlx = (model) => [
|
| 626 |
+
`import mlx.core as mx
|
| 627 |
+
import cartesia_mlx as cmx
|
| 628 |
+
|
| 629 |
+
model = cmx.from_pretrained("${model.id}")
|
| 630 |
+
model.set_dtype(mx.float32)
|
| 631 |
+
|
| 632 |
+
prompt = "Rene Descartes was"
|
| 633 |
+
|
| 634 |
+
for text in model.generate(
|
| 635 |
+
prompt,
|
| 636 |
+
max_tokens=500,
|
| 637 |
+
eval_every_n=5,
|
| 638 |
+
verbose=True,
|
| 639 |
+
top_p=0.99,
|
| 640 |
+
temperature=0.85,
|
| 641 |
+
):
|
| 642 |
+
print(text, end="", flush=True)
|
| 643 |
+
`,
|
| 644 |
+
];
|
| 645 |
+
exports.cartesia_mlx = cartesia_mlx;
|
| 646 |
+
const edsnlp = (model) => {
|
| 647 |
+
const packageName = nameWithoutNamespace(model.id).replaceAll("-", "_");
|
| 648 |
+
return [
|
| 649 |
+
`# Load it from the Hub directly
|
| 650 |
+
import edsnlp
|
| 651 |
+
nlp = edsnlp.load("${model.id}")
|
| 652 |
+
`,
|
| 653 |
+
`# Or install it as a package
|
| 654 |
+
!pip install git+https://huggingface.co/${model.id}
|
| 655 |
+
|
| 656 |
+
# and import it as a module
|
| 657 |
+
import ${packageName}
|
| 658 |
+
|
| 659 |
+
nlp = ${packageName}.load() # or edsnlp.load("${packageName}")
|
| 660 |
+
`,
|
| 661 |
+
];
|
| 662 |
+
};
|
| 663 |
+
exports.edsnlp = edsnlp;
|
| 664 |
+
const espnetTTS = (model) => [
|
| 665 |
+
`from espnet2.bin.tts_inference import Text2Speech
|
| 666 |
+
|
| 667 |
+
model = Text2Speech.from_pretrained("${model.id}")
|
| 668 |
+
|
| 669 |
+
speech, *_ = model("text to generate speech from")`,
|
| 670 |
+
];
|
| 671 |
+
exports.espnetTTS = espnetTTS;
|
| 672 |
+
const espnetASR = (model) => [
|
| 673 |
+
`from espnet2.bin.asr_inference import Speech2Text
|
| 674 |
+
|
| 675 |
+
model = Speech2Text.from_pretrained(
|
| 676 |
+
"${model.id}"
|
| 677 |
+
)
|
| 678 |
+
|
| 679 |
+
speech, rate = soundfile.read("speech.wav")
|
| 680 |
+
text, *_ = model(speech)[0]`,
|
| 681 |
+
];
|
| 682 |
+
exports.espnetASR = espnetASR;
|
| 683 |
+
const espnetUnknown = () => [`unknown model type (must be text-to-speech or automatic-speech-recognition)`];
|
| 684 |
+
const espnet = (model) => {
|
| 685 |
+
if (model.tags.includes("text-to-speech")) {
|
| 686 |
+
return (0, exports.espnetTTS)(model);
|
| 687 |
+
}
|
| 688 |
+
else if (model.tags.includes("automatic-speech-recognition")) {
|
| 689 |
+
return (0, exports.espnetASR)(model);
|
| 690 |
+
}
|
| 691 |
+
return espnetUnknown();
|
| 692 |
+
};
|
| 693 |
+
exports.espnet = espnet;
|
| 694 |
+
const fairseq = (model) => [
|
| 695 |
+
`from fairseq.checkpoint_utils import load_model_ensemble_and_task_from_hf_hub
|
| 696 |
+
|
| 697 |
+
models, cfg, task = load_model_ensemble_and_task_from_hf_hub(
|
| 698 |
+
"${model.id}"
|
| 699 |
+
)`,
|
| 700 |
+
];
|
| 701 |
+
exports.fairseq = fairseq;
|
| 702 |
+
const flair = (model) => [
|
| 703 |
+
`from flair.models import SequenceTagger
|
| 704 |
+
|
| 705 |
+
tagger = SequenceTagger.load("${model.id}")`,
|
| 706 |
+
];
|
| 707 |
+
exports.flair = flair;
|
| 708 |
+
const gliner = (model) => [
|
| 709 |
+
`from gliner import GLiNER
|
| 710 |
+
|
| 711 |
+
model = GLiNER.from_pretrained("${model.id}")`,
|
| 712 |
+
];
|
| 713 |
+
exports.gliner = gliner;
|
| 714 |
+
const gliner2 = (model) => [
|
| 715 |
+
`from gliner2 import GLiNER2
|
| 716 |
+
|
| 717 |
+
model = GLiNER2.from_pretrained("${model.id}")
|
| 718 |
+
|
| 719 |
+
# Extract entities
|
| 720 |
+
text = "Apple CEO Tim Cook announced iPhone 15 in Cupertino yesterday."
|
| 721 |
+
result = extractor.extract_entities(text, ["company", "person", "product", "location"])
|
| 722 |
+
|
| 723 |
+
print(result)`,
|
| 724 |
+
];
|
| 725 |
+
exports.gliner2 = gliner2;
|
| 726 |
+
const indextts = (model) => [
|
| 727 |
+
`# Download model
|
| 728 |
+
from huggingface_hub import snapshot_download
|
| 729 |
+
|
| 730 |
+
snapshot_download(${model.id}, local_dir="checkpoints")
|
| 731 |
+
|
| 732 |
+
from indextts.infer import IndexTTS
|
| 733 |
+
|
| 734 |
+
# Ensure config.yaml is present in the checkpoints directory
|
| 735 |
+
tts = IndexTTS(model_dir="checkpoints", cfg_path="checkpoints/config.yaml")
|
| 736 |
+
|
| 737 |
+
voice = "path/to/your/reference_voice.wav" # Path to the voice reference audio file
|
| 738 |
+
text = "Hello, how are you?"
|
| 739 |
+
output_path = "output_index.wav"
|
| 740 |
+
|
| 741 |
+
tts.infer(voice, text, output_path)`,
|
| 742 |
+
];
|
| 743 |
+
exports.indextts = indextts;
|
| 744 |
+
const htrflow = (model) => [
|
| 745 |
+
`# CLI usage
|
| 746 |
+
# see docs: https://ai-riksarkivet.github.io/htrflow/latest/getting_started/quick_start.html
|
| 747 |
+
htrflow pipeline <path/to/pipeline.yaml> <path/to/image>`,
|
| 748 |
+
`# Python usage
|
| 749 |
+
from htrflow.pipeline.pipeline import Pipeline
|
| 750 |
+
from htrflow.pipeline.steps import Task
|
| 751 |
+
from htrflow.models.framework.model import ModelClass
|
| 752 |
+
|
| 753 |
+
pipeline = Pipeline(
|
| 754 |
+
[
|
| 755 |
+
Task(
|
| 756 |
+
ModelClass, {"model": "${model.id}"}, {}
|
| 757 |
+
),
|
| 758 |
+
])`,
|
| 759 |
+
];
|
| 760 |
+
exports.htrflow = htrflow;
|
| 761 |
+
const keras = (model) => [
|
| 762 |
+
`# Available backend options are: "jax", "torch", "tensorflow".
|
| 763 |
+
import os
|
| 764 |
+
os.environ["KERAS_BACKEND"] = "jax"
|
| 765 |
+
|
| 766 |
+
import keras
|
| 767 |
+
|
| 768 |
+
model = keras.saving.load_model("hf://${model.id}")
|
| 769 |
+
`,
|
| 770 |
+
];
|
| 771 |
+
exports.keras = keras;
|
| 772 |
+
const _keras_hub_causal_lm = (modelId) => `
|
| 773 |
+
import keras_hub
|
| 774 |
+
|
| 775 |
+
# Load CausalLM model (optional: use half precision for inference)
|
| 776 |
+
causal_lm = keras_hub.models.CausalLM.from_preset("hf://${modelId}", dtype="bfloat16")
|
| 777 |
+
causal_lm.compile(sampler="greedy") # (optional) specify a sampler
|
| 778 |
+
|
| 779 |
+
# Generate text
|
| 780 |
+
causal_lm.generate("Keras: deep learning for", max_length=64)
|
| 781 |
+
`;
|
| 782 |
+
const _keras_hub_text_to_image = (modelId) => `
|
| 783 |
+
import keras_hub
|
| 784 |
+
|
| 785 |
+
# Load TextToImage model (optional: use half precision for inference)
|
| 786 |
+
text_to_image = keras_hub.models.TextToImage.from_preset("hf://${modelId}", dtype="bfloat16")
|
| 787 |
+
|
| 788 |
+
# Generate images with a TextToImage model.
|
| 789 |
+
text_to_image.generate("Astronaut in a jungle")
|
| 790 |
+
`;
|
| 791 |
+
const _keras_hub_text_classifier = (modelId) => `
|
| 792 |
+
import keras_hub
|
| 793 |
+
|
| 794 |
+
# Load TextClassifier model
|
| 795 |
+
text_classifier = keras_hub.models.TextClassifier.from_preset(
|
| 796 |
+
"hf://${modelId}",
|
| 797 |
+
num_classes=2,
|
| 798 |
+
)
|
| 799 |
+
# Fine-tune
|
| 800 |
+
text_classifier.fit(x=["Thilling adventure!", "Total snoozefest."], y=[1, 0])
|
| 801 |
+
# Classify text
|
| 802 |
+
text_classifier.predict(["Not my cup of tea."])
|
| 803 |
+
`;
|
| 804 |
+
const _keras_hub_image_classifier = (modelId) => `
|
| 805 |
+
import keras_hub
|
| 806 |
+
import keras
|
| 807 |
+
|
| 808 |
+
# Load ImageClassifier model
|
| 809 |
+
image_classifier = keras_hub.models.ImageClassifier.from_preset(
|
| 810 |
+
"hf://${modelId}",
|
| 811 |
+
num_classes=2,
|
| 812 |
+
)
|
| 813 |
+
# Fine-tune
|
| 814 |
+
image_classifier.fit(
|
| 815 |
+
x=keras.random.randint((32, 64, 64, 3), 0, 256),
|
| 816 |
+
y=keras.random.randint((32, 1), 0, 2),
|
| 817 |
+
)
|
| 818 |
+
# Classify image
|
| 819 |
+
image_classifier.predict(keras.random.randint((1, 64, 64, 3), 0, 256))
|
| 820 |
+
`;
|
| 821 |
+
const _keras_hub_tasks_with_example = {
|
| 822 |
+
CausalLM: _keras_hub_causal_lm,
|
| 823 |
+
TextToImage: _keras_hub_text_to_image,
|
| 824 |
+
TextClassifier: _keras_hub_text_classifier,
|
| 825 |
+
ImageClassifier: _keras_hub_image_classifier,
|
| 826 |
+
};
|
| 827 |
+
const _keras_hub_task_without_example = (task, modelId) => `
|
| 828 |
+
import keras_hub
|
| 829 |
+
|
| 830 |
+
# Create a ${task} model
|
| 831 |
+
task = keras_hub.models.${task}.from_preset("hf://${modelId}")
|
| 832 |
+
`;
|
| 833 |
+
const _keras_hub_generic_backbone = (modelId) => `
|
| 834 |
+
import keras_hub
|
| 835 |
+
|
| 836 |
+
# Create a Backbone model unspecialized for any task
|
| 837 |
+
backbone = keras_hub.models.Backbone.from_preset("hf://${modelId}")
|
| 838 |
+
`;
|
| 839 |
+
const keras_hub = (model) => {
|
| 840 |
+
const modelId = model.id;
|
| 841 |
+
const tasks = model.config?.keras_hub?.tasks ?? [];
|
| 842 |
+
const snippets = [];
|
| 843 |
+
// First, generate tasks with examples
|
| 844 |
+
for (const [task, snippet] of Object.entries(_keras_hub_tasks_with_example)) {
|
| 845 |
+
if (tasks.includes(task)) {
|
| 846 |
+
snippets.push(snippet(modelId));
|
| 847 |
+
}
|
| 848 |
+
}
|
| 849 |
+
// Then, add remaining tasks
|
| 850 |
+
for (const task of tasks) {
|
| 851 |
+
if (!Object.keys(_keras_hub_tasks_with_example).includes(task)) {
|
| 852 |
+
snippets.push(_keras_hub_task_without_example(task, modelId));
|
| 853 |
+
}
|
| 854 |
+
}
|
| 855 |
+
// Finally, add generic backbone snippet
|
| 856 |
+
snippets.push(_keras_hub_generic_backbone(modelId));
|
| 857 |
+
return snippets;
|
| 858 |
+
};
|
| 859 |
+
exports.keras_hub = keras_hub;
|
| 860 |
+
const kernels = (model) => [
|
| 861 |
+
`# !pip install kernels
|
| 862 |
+
|
| 863 |
+
from kernels import get_kernel
|
| 864 |
+
|
| 865 |
+
kernel = get_kernel("${model.id}")`,
|
| 866 |
+
];
|
| 867 |
+
exports.kernels = kernels;
|
| 868 |
+
const kimi_audio = (model) => [
|
| 869 |
+
`# Example usage for KimiAudio
|
| 870 |
+
# pip install git+https://github.com/MoonshotAI/Kimi-Audio.git
|
| 871 |
+
|
| 872 |
+
from kimia_infer.api.kimia import KimiAudio
|
| 873 |
+
|
| 874 |
+
model = KimiAudio(model_path="${model.id}", load_detokenizer=True)
|
| 875 |
+
|
| 876 |
+
sampling_params = {
|
| 877 |
+
"audio_temperature": 0.8,
|
| 878 |
+
"audio_top_k": 10,
|
| 879 |
+
"text_temperature": 0.0,
|
| 880 |
+
"text_top_k": 5,
|
| 881 |
+
}
|
| 882 |
+
|
| 883 |
+
# For ASR
|
| 884 |
+
asr_audio = "asr_example.wav"
|
| 885 |
+
messages_asr = [
|
| 886 |
+
{"role": "user", "message_type": "text", "content": "Please transcribe the following audio:"},
|
| 887 |
+
{"role": "user", "message_type": "audio", "content": asr_audio}
|
| 888 |
+
]
|
| 889 |
+
_, text = model.generate(messages_asr, **sampling_params, output_type="text")
|
| 890 |
+
print(text)
|
| 891 |
+
|
| 892 |
+
# For Q&A
|
| 893 |
+
qa_audio = "qa_example.wav"
|
| 894 |
+
messages_conv = [{"role": "user", "message_type": "audio", "content": qa_audio}]
|
| 895 |
+
wav, text = model.generate(messages_conv, **sampling_params, output_type="both")
|
| 896 |
+
sf.write("output_audio.wav", wav.cpu().view(-1).numpy(), 24000)
|
| 897 |
+
print(text)
|
| 898 |
+
`,
|
| 899 |
+
];
|
| 900 |
+
exports.kimi_audio = kimi_audio;
|
| 901 |
+
const kittentts = (model) => [
|
| 902 |
+
`from kittentts import KittenTTS
|
| 903 |
+
m = KittenTTS("${model.id}")
|
| 904 |
+
|
| 905 |
+
audio = m.generate("This high quality TTS model works without a GPU")
|
| 906 |
+
|
| 907 |
+
# Save the audio
|
| 908 |
+
import soundfile as sf
|
| 909 |
+
sf.write('output.wav', audio, 24000)`,
|
| 910 |
+
];
|
| 911 |
+
exports.kittentts = kittentts;
|
| 912 |
+
const lightning_ir = (model) => {
|
| 913 |
+
if (model.tags.includes("bi-encoder")) {
|
| 914 |
+
return [
|
| 915 |
+
`#install from https://github.com/webis-de/lightning-ir
|
| 916 |
+
|
| 917 |
+
from lightning_ir import BiEncoderModule
|
| 918 |
+
model = BiEncoderModule("${model.id}")
|
| 919 |
+
|
| 920 |
+
model.score("query", ["doc1", "doc2", "doc3"])`,
|
| 921 |
+
];
|
| 922 |
+
}
|
| 923 |
+
else if (model.tags.includes("cross-encoder")) {
|
| 924 |
+
return [
|
| 925 |
+
`#install from https://github.com/webis-de/lightning-ir
|
| 926 |
+
|
| 927 |
+
from lightning_ir import CrossEncoderModule
|
| 928 |
+
model = CrossEncoderModule("${model.id}")
|
| 929 |
+
|
| 930 |
+
model.score("query", ["doc1", "doc2", "doc3"])`,
|
| 931 |
+
];
|
| 932 |
+
}
|
| 933 |
+
return [
|
| 934 |
+
`#install from https://github.com/webis-de/lightning-ir
|
| 935 |
+
|
| 936 |
+
from lightning_ir import BiEncoderModule, CrossEncoderModule
|
| 937 |
+
|
| 938 |
+
# depending on the model type, use either BiEncoderModule or CrossEncoderModule
|
| 939 |
+
model = BiEncoderModule("${model.id}")
|
| 940 |
+
# model = CrossEncoderModule("${model.id}")
|
| 941 |
+
|
| 942 |
+
model.score("query", ["doc1", "doc2", "doc3"])`,
|
| 943 |
+
];
|
| 944 |
+
};
|
| 945 |
+
exports.lightning_ir = lightning_ir;
|
| 946 |
+
const llama_cpp_python = (model) => {
|
| 947 |
+
const snippets = [
|
| 948 |
+
`# !pip install llama-cpp-python
|
| 949 |
+
|
| 950 |
+
from llama_cpp import Llama
|
| 951 |
+
|
| 952 |
+
llm = Llama.from_pretrained(
|
| 953 |
+
repo_id="${model.id}",
|
| 954 |
+
filename="{{GGUF_FILE}}",
|
| 955 |
+
)
|
| 956 |
+
`,
|
| 957 |
+
];
|
| 958 |
+
if (model.tags.includes("conversational")) {
|
| 959 |
+
const messages = (0, inputs_js_1.getModelInputSnippet)(model);
|
| 960 |
+
snippets.push(`llm.create_chat_completion(
|
| 961 |
+
messages = ${(0, common_js_1.stringifyMessages)(messages, { attributeKeyQuotes: true, indent: "\t" })}
|
| 962 |
+
)`);
|
| 963 |
+
}
|
| 964 |
+
else {
|
| 965 |
+
snippets.push(`output = llm(
|
| 966 |
+
"Once upon a time,",
|
| 967 |
+
max_tokens=512,
|
| 968 |
+
echo=True
|
| 969 |
+
)
|
| 970 |
+
print(output)`);
|
| 971 |
+
}
|
| 972 |
+
return snippets;
|
| 973 |
+
};
|
| 974 |
+
exports.llama_cpp_python = llama_cpp_python;
|
| 975 |
+
const lerobot = (model) => {
|
| 976 |
+
if (model.tags.includes("smolvla")) {
|
| 977 |
+
const smolvlaSnippets = [
|
| 978 |
+
// Installation snippet
|
| 979 |
+
`# See https://github.com/huggingface/lerobot?tab=readme-ov-file#installation for more details
|
| 980 |
+
git clone https://github.com/huggingface/lerobot.git
|
| 981 |
+
cd lerobot
|
| 982 |
+
pip install -e .[smolvla]`,
|
| 983 |
+
// Finetune snippet
|
| 984 |
+
`# Launch finetuning on your dataset
|
| 985 |
+
python lerobot/scripts/train.py \\
|
| 986 |
+
--policy.path=${model.id} \\
|
| 987 |
+
--dataset.repo_id=lerobot/svla_so101_pickplace \\
|
| 988 |
+
--batch_size=64 \\
|
| 989 |
+
--steps=20000 \\
|
| 990 |
+
--output_dir=outputs/train/my_smolvla \\
|
| 991 |
+
--job_name=my_smolvla_training \\
|
| 992 |
+
--policy.device=cuda \\
|
| 993 |
+
--wandb.enable=true`,
|
| 994 |
+
];
|
| 995 |
+
if (model.id !== "lerobot/smolvla_base") {
|
| 996 |
+
// Inference snippet (only if not base model)
|
| 997 |
+
smolvlaSnippets.push(`# Run the policy using the record function
|
| 998 |
+
python -m lerobot.record \\
|
| 999 |
+
--robot.type=so101_follower \\
|
| 1000 |
+
--robot.port=/dev/ttyACM0 \\ # <- Use your port
|
| 1001 |
+
--robot.id=my_blue_follower_arm \\ # <- Use your robot id
|
| 1002 |
+
--robot.cameras="{ front: {type: opencv, index_or_path: 8, width: 640, height: 480, fps: 30}}" \\ # <- Use your cameras
|
| 1003 |
+
--dataset.single_task="Grasp a lego block and put it in the bin." \\ # <- Use the same task description you used in your dataset recording
|
| 1004 |
+
--dataset.repo_id=HF_USER/dataset_name \\ # <- This will be the dataset name on HF Hub
|
| 1005 |
+
--dataset.episode_time_s=50 \\
|
| 1006 |
+
--dataset.num_episodes=10 \\
|
| 1007 |
+
--policy.path=${model.id}`);
|
| 1008 |
+
}
|
| 1009 |
+
return smolvlaSnippets;
|
| 1010 |
+
}
|
| 1011 |
+
return [];
|
| 1012 |
+
};
|
| 1013 |
+
exports.lerobot = lerobot;
|
| 1014 |
+
const tf_keras = (model) => [
|
| 1015 |
+
`# Note: 'keras<3.x' or 'tf_keras' must be installed (legacy)
|
| 1016 |
+
# See https://github.com/keras-team/tf-keras for more details.
|
| 1017 |
+
from huggingface_hub import from_pretrained_keras
|
| 1018 |
+
|
| 1019 |
+
model = from_pretrained_keras("${model.id}")
|
| 1020 |
+
`,
|
| 1021 |
+
];
|
| 1022 |
+
exports.tf_keras = tf_keras;
|
| 1023 |
+
const mamba_ssm = (model) => [
|
| 1024 |
+
`from mamba_ssm import MambaLMHeadModel
|
| 1025 |
+
|
| 1026 |
+
model = MambaLMHeadModel.from_pretrained("${model.id}")`,
|
| 1027 |
+
];
|
| 1028 |
+
exports.mamba_ssm = mamba_ssm;
|
| 1029 |
+
const mars5_tts = (model) => [
|
| 1030 |
+
`# Install from https://github.com/Camb-ai/MARS5-TTS
|
| 1031 |
+
|
| 1032 |
+
from inference import Mars5TTS
|
| 1033 |
+
mars5 = Mars5TTS.from_pretrained("${model.id}")`,
|
| 1034 |
+
];
|
| 1035 |
+
exports.mars5_tts = mars5_tts;
|
| 1036 |
+
const matanyone = (model) => [
|
| 1037 |
+
`# Install from https://github.com/pq-yang/MatAnyone.git
|
| 1038 |
+
|
| 1039 |
+
from matanyone.model.matanyone import MatAnyone
|
| 1040 |
+
model = MatAnyone.from_pretrained("${model.id}")`,
|
| 1041 |
+
`
|
| 1042 |
+
from matanyone import InferenceCore
|
| 1043 |
+
processor = InferenceCore("${model.id}")`,
|
| 1044 |
+
];
|
| 1045 |
+
exports.matanyone = matanyone;
|
| 1046 |
+
const mesh_anything = () => [
|
| 1047 |
+
`# Install from https://github.com/buaacyw/MeshAnything.git
|
| 1048 |
+
|
| 1049 |
+
from MeshAnything.models.meshanything import MeshAnything
|
| 1050 |
+
|
| 1051 |
+
# refer to https://github.com/buaacyw/MeshAnything/blob/main/main.py#L91 on how to define args
|
| 1052 |
+
# and https://github.com/buaacyw/MeshAnything/blob/main/app.py regarding usage
|
| 1053 |
+
model = MeshAnything(args)`,
|
| 1054 |
+
];
|
| 1055 |
+
exports.mesh_anything = mesh_anything;
|
| 1056 |
+
const open_clip = (model) => [
|
| 1057 |
+
`import open_clip
|
| 1058 |
+
|
| 1059 |
+
model, preprocess_train, preprocess_val = open_clip.create_model_and_transforms('hf-hub:${model.id}')
|
| 1060 |
+
tokenizer = open_clip.get_tokenizer('hf-hub:${model.id}')`,
|
| 1061 |
+
];
|
| 1062 |
+
exports.open_clip = open_clip;
|
| 1063 |
+
const paddlenlp = (model) => {
|
| 1064 |
+
if (model.config?.architectures?.[0]) {
|
| 1065 |
+
const architecture = model.config.architectures[0];
|
| 1066 |
+
return [
|
| 1067 |
+
[
|
| 1068 |
+
`from paddlenlp.transformers import AutoTokenizer, ${architecture}`,
|
| 1069 |
+
"",
|
| 1070 |
+
`tokenizer = AutoTokenizer.from_pretrained("${model.id}", from_hf_hub=True)`,
|
| 1071 |
+
`model = ${architecture}.from_pretrained("${model.id}", from_hf_hub=True)`,
|
| 1072 |
+
].join("\n"),
|
| 1073 |
+
];
|
| 1074 |
+
}
|
| 1075 |
+
else {
|
| 1076 |
+
return [
|
| 1077 |
+
[
|
| 1078 |
+
`# ⚠️ Type of model unknown`,
|
| 1079 |
+
`from paddlenlp.transformers import AutoTokenizer, AutoModel`,
|
| 1080 |
+
"",
|
| 1081 |
+
`tokenizer = AutoTokenizer.from_pretrained("${model.id}", from_hf_hub=True)`,
|
| 1082 |
+
`model = AutoModel.from_pretrained("${model.id}", from_hf_hub=True)`,
|
| 1083 |
+
].join("\n"),
|
| 1084 |
+
];
|
| 1085 |
+
}
|
| 1086 |
+
};
|
| 1087 |
+
exports.paddlenlp = paddlenlp;
|
| 1088 |
+
const paddleocr = (model) => {
|
| 1089 |
+
const mapping = {
|
| 1090 |
+
textline_detection: { className: "TextDetection" },
|
| 1091 |
+
textline_recognition: { className: "TextRecognition" },
|
| 1092 |
+
seal_text_detection: { className: "SealTextDetection" },
|
| 1093 |
+
doc_img_unwarping: { className: "TextImageUnwarping" },
|
| 1094 |
+
doc_img_orientation_classification: { className: "DocImgOrientationClassification" },
|
| 1095 |
+
textline_orientation_classification: { className: "TextLineOrientationClassification" },
|
| 1096 |
+
chart_parsing: { className: "ChartParsing" },
|
| 1097 |
+
formula_recognition: { className: "FormulaRecognition" },
|
| 1098 |
+
layout_detection: { className: "LayoutDetection" },
|
| 1099 |
+
table_cells_detection: { className: "TableCellsDetection" },
|
| 1100 |
+
wired_table_classification: { className: "TableClassification" },
|
| 1101 |
+
table_structure_recognition: { className: "TableStructureRecognition" },
|
| 1102 |
+
};
|
| 1103 |
+
if (model.tags.includes("doc_vlm")) {
|
| 1104 |
+
return [
|
| 1105 |
+
`# 1. See https://www.paddlepaddle.org.cn/en/install to install paddlepaddle
|
| 1106 |
+
# 2. pip install paddleocr
|
| 1107 |
+
|
| 1108 |
+
from paddleocr import DocVLM
|
| 1109 |
+
model = DocVLM(model_name="${nameWithoutNamespace(model.id)}")
|
| 1110 |
+
output = model.predict(
|
| 1111 |
+
input={"image": "path/to/image.png", "query": "Parsing this image and output the content in Markdown format."},
|
| 1112 |
+
batch_size=1
|
| 1113 |
+
)
|
| 1114 |
+
for res in output:
|
| 1115 |
+
res.print()
|
| 1116 |
+
res.save_to_json(save_path="./output/res.json")`,
|
| 1117 |
+
];
|
| 1118 |
+
}
|
| 1119 |
+
if (model.tags.includes("document-parse")) {
|
| 1120 |
+
const rawVersion = model.id.replace("PaddlePaddle/PaddleOCR-VL-", "v");
|
| 1121 |
+
const version = rawVersion === "PaddlePaddle/PaddleOCR-VL" ? "v1" : rawVersion;
|
| 1122 |
+
return [
|
| 1123 |
+
`# See https://www.paddleocr.ai/latest/version3.x/pipeline_usage/PaddleOCR-VL.html to installation
|
| 1124 |
+
|
| 1125 |
+
from paddleocr import PaddleOCRVL
|
| 1126 |
+
pipeline = PaddleOCRVL(pipeline_version="${version}")
|
| 1127 |
+
output = pipeline.predict("path/to/document_image.png")
|
| 1128 |
+
for res in output:
|
| 1129 |
+
res.print()
|
| 1130 |
+
res.save_to_json(save_path="output")
|
| 1131 |
+
res.save_to_markdown(save_path="output")`,
|
| 1132 |
+
];
|
| 1133 |
+
}
|
| 1134 |
+
for (const tag of model.tags) {
|
| 1135 |
+
if (tag in mapping) {
|
| 1136 |
+
const { className } = mapping[tag];
|
| 1137 |
+
return [
|
| 1138 |
+
`# 1. See https://www.paddlepaddle.org.cn/en/install to install paddlepaddle
|
| 1139 |
+
# 2. pip install paddleocr
|
| 1140 |
+
|
| 1141 |
+
from paddleocr import ${className}
|
| 1142 |
+
model = ${className}(model_name="${nameWithoutNamespace(model.id)}")
|
| 1143 |
+
output = model.predict(input="path/to/image.png", batch_size=1)
|
| 1144 |
+
for res in output:
|
| 1145 |
+
res.print()
|
| 1146 |
+
res.save_to_img(save_path="./output/")
|
| 1147 |
+
res.save_to_json(save_path="./output/res.json")`,
|
| 1148 |
+
];
|
| 1149 |
+
}
|
| 1150 |
+
}
|
| 1151 |
+
return [
|
| 1152 |
+
`# Please refer to the document for information on how to use the model.
|
| 1153 |
+
# https://paddlepaddle.github.io/PaddleOCR/latest/en/version3.x/module_usage/module_overview.html`,
|
| 1154 |
+
];
|
| 1155 |
+
};
|
| 1156 |
+
exports.paddleocr = paddleocr;
|
| 1157 |
+
const perception_encoder = (model) => {
|
| 1158 |
+
const clip_model = `# Use PE-Core models as CLIP models
|
| 1159 |
+
import core.vision_encoder.pe as pe
|
| 1160 |
+
|
| 1161 |
+
model = pe.CLIP.from_config("${model.id}", pretrained=True)`;
|
| 1162 |
+
const vision_encoder = `# Use any PE model as a vision encoder
|
| 1163 |
+
import core.vision_encoder.pe as pe
|
| 1164 |
+
|
| 1165 |
+
model = pe.VisionTransformer.from_config("${model.id}", pretrained=True)`;
|
| 1166 |
+
if (model.id.includes("Core")) {
|
| 1167 |
+
return [clip_model, vision_encoder];
|
| 1168 |
+
}
|
| 1169 |
+
else {
|
| 1170 |
+
return [vision_encoder];
|
| 1171 |
+
}
|
| 1172 |
+
};
|
| 1173 |
+
exports.perception_encoder = perception_encoder;
|
| 1174 |
+
const phantom_wan = (model) => [
|
| 1175 |
+
`from huggingface_hub import snapshot_download
|
| 1176 |
+
from phantom_wan import WANI2V, configs
|
| 1177 |
+
|
| 1178 |
+
checkpoint_dir = snapshot_download("${model.id}")
|
| 1179 |
+
wan_i2v = WanI2V(
|
| 1180 |
+
config=configs.WAN_CONFIGS['i2v-14B'],
|
| 1181 |
+
checkpoint_dir=checkpoint_dir,
|
| 1182 |
+
)
|
| 1183 |
+
video = wan_i2v.generate(text_prompt, image_prompt)`,
|
| 1184 |
+
];
|
| 1185 |
+
exports.phantom_wan = phantom_wan;
|
| 1186 |
+
const pocket_tts = (model) => [
|
| 1187 |
+
`from pocket_tts import TTSModel
|
| 1188 |
+
import scipy.io.wavfile
|
| 1189 |
+
|
| 1190 |
+
tts_model = TTSModel.load_model("${model.id}")
|
| 1191 |
+
voice_state = tts_model.get_state_for_audio_prompt(
|
| 1192 |
+
"hf://kyutai/tts-voices/alba-mackenna/casual.wav"
|
| 1193 |
+
)
|
| 1194 |
+
audio = tts_model.generate_audio(voice_state, "Hello world, this is a test.")
|
| 1195 |
+
# Audio is a 1D torch tensor containing PCM data.
|
| 1196 |
+
scipy.io.wavfile.write("output.wav", tts_model.sample_rate, audio.numpy())`,
|
| 1197 |
+
];
|
| 1198 |
+
exports.pocket_tts = pocket_tts;
|
| 1199 |
+
const pyannote_audio_pipeline = (model) => [
|
| 1200 |
+
`from pyannote.audio import Pipeline
|
| 1201 |
+
|
| 1202 |
+
pipeline = Pipeline.from_pretrained("${model.id}")
|
| 1203 |
+
|
| 1204 |
+
# inference on the whole file
|
| 1205 |
+
pipeline("file.wav")
|
| 1206 |
+
|
| 1207 |
+
# inference on an excerpt
|
| 1208 |
+
from pyannote.core import Segment
|
| 1209 |
+
excerpt = Segment(start=2.0, end=5.0)
|
| 1210 |
+
|
| 1211 |
+
from pyannote.audio import Audio
|
| 1212 |
+
waveform, sample_rate = Audio().crop("file.wav", excerpt)
|
| 1213 |
+
pipeline({"waveform": waveform, "sample_rate": sample_rate})`,
|
| 1214 |
+
];
|
| 1215 |
+
exports.pyannote_audio_pipeline = pyannote_audio_pipeline;
|
| 1216 |
+
const pyannote_audio_model = (model) => [
|
| 1217 |
+
`from pyannote.audio import Model, Inference
|
| 1218 |
+
|
| 1219 |
+
model = Model.from_pretrained("${model.id}")
|
| 1220 |
+
inference = Inference(model)
|
| 1221 |
+
|
| 1222 |
+
# inference on the whole file
|
| 1223 |
+
inference("file.wav")
|
| 1224 |
+
|
| 1225 |
+
# inference on an excerpt
|
| 1226 |
+
from pyannote.core import Segment
|
| 1227 |
+
excerpt = Segment(start=2.0, end=5.0)
|
| 1228 |
+
inference.crop("file.wav", excerpt)`,
|
| 1229 |
+
];
|
| 1230 |
+
const pyannote_audio = (model) => {
|
| 1231 |
+
if (model.tags.includes("pyannote-audio-pipeline")) {
|
| 1232 |
+
return (0, exports.pyannote_audio_pipeline)(model);
|
| 1233 |
+
}
|
| 1234 |
+
return pyannote_audio_model(model);
|
| 1235 |
+
};
|
| 1236 |
+
exports.pyannote_audio = pyannote_audio;
|
| 1237 |
+
const relik = (model) => [
|
| 1238 |
+
`from relik import Relik
|
| 1239 |
+
|
| 1240 |
+
relik = Relik.from_pretrained("${model.id}")`,
|
| 1241 |
+
];
|
| 1242 |
+
exports.relik = relik;
|
| 1243 |
+
const renderformer = (model) => [
|
| 1244 |
+
`# Install from https://github.com/microsoft/renderformer
|
| 1245 |
+
|
| 1246 |
+
from renderformer import RenderFormerRenderingPipeline
|
| 1247 |
+
pipeline = RenderFormerRenderingPipeline.from_pretrained("${model.id}")`,
|
| 1248 |
+
];
|
| 1249 |
+
exports.renderformer = renderformer;
|
| 1250 |
+
const tensorflowttsTextToMel = (model) => [
|
| 1251 |
+
`from tensorflow_tts.inference import AutoProcessor, TFAutoModel
|
| 1252 |
+
|
| 1253 |
+
processor = AutoProcessor.from_pretrained("${model.id}")
|
| 1254 |
+
model = TFAutoModel.from_pretrained("${model.id}")
|
| 1255 |
+
`,
|
| 1256 |
+
];
|
| 1257 |
+
const tensorflowttsMelToWav = (model) => [
|
| 1258 |
+
`from tensorflow_tts.inference import TFAutoModel
|
| 1259 |
+
|
| 1260 |
+
model = TFAutoModel.from_pretrained("${model.id}")
|
| 1261 |
+
audios = model.inference(mels)
|
| 1262 |
+
`,
|
| 1263 |
+
];
|
| 1264 |
+
const tensorflowttsUnknown = (model) => [
|
| 1265 |
+
`from tensorflow_tts.inference import TFAutoModel
|
| 1266 |
+
|
| 1267 |
+
model = TFAutoModel.from_pretrained("${model.id}")
|
| 1268 |
+
`,
|
| 1269 |
+
];
|
| 1270 |
+
const tensorflowtts = (model) => {
|
| 1271 |
+
if (model.tags.includes("text-to-mel")) {
|
| 1272 |
+
return tensorflowttsTextToMel(model);
|
| 1273 |
+
}
|
| 1274 |
+
else if (model.tags.includes("mel-to-wav")) {
|
| 1275 |
+
return tensorflowttsMelToWav(model);
|
| 1276 |
+
}
|
| 1277 |
+
return tensorflowttsUnknown(model);
|
| 1278 |
+
};
|
| 1279 |
+
exports.tensorflowtts = tensorflowtts;
|
| 1280 |
+
const timm = (model) => [
|
| 1281 |
+
`import timm
|
| 1282 |
+
|
| 1283 |
+
model = timm.create_model("hf_hub:${model.id}", pretrained=True)`,
|
| 1284 |
+
];
|
| 1285 |
+
exports.timm = timm;
|
| 1286 |
+
const saelens = ( /* model: ModelData */) => [
|
| 1287 |
+
`# pip install sae-lens
|
| 1288 |
+
from sae_lens import SAE
|
| 1289 |
+
|
| 1290 |
+
sae, cfg_dict, sparsity = SAE.from_pretrained(
|
| 1291 |
+
release = "RELEASE_ID", # e.g., "gpt2-small-res-jb". See other options in https://github.com/jbloomAus/SAELens/blob/main/sae_lens/pretrained_saes.yaml
|
| 1292 |
+
sae_id = "SAE_ID", # e.g., "blocks.8.hook_resid_pre". Won't always be a hook point
|
| 1293 |
+
)`,
|
| 1294 |
+
];
|
| 1295 |
+
exports.saelens = saelens;
|
| 1296 |
+
const seed_story = () => [
|
| 1297 |
+
`# seed_story_cfg_path refers to 'https://github.com/TencentARC/SEED-Story/blob/master/configs/clm_models/agent_7b_sft.yaml'
|
| 1298 |
+
# llm_cfg_path refers to 'https://github.com/TencentARC/SEED-Story/blob/master/configs/clm_models/llama2chat7b_lora.yaml'
|
| 1299 |
+
from omegaconf import OmegaConf
|
| 1300 |
+
import hydra
|
| 1301 |
+
|
| 1302 |
+
# load Llama2
|
| 1303 |
+
llm_cfg = OmegaConf.load(llm_cfg_path)
|
| 1304 |
+
llm = hydra.utils.instantiate(llm_cfg, torch_dtype="fp16")
|
| 1305 |
+
|
| 1306 |
+
# initialize seed_story
|
| 1307 |
+
seed_story_cfg = OmegaConf.load(seed_story_cfg_path)
|
| 1308 |
+
seed_story = hydra.utils.instantiate(seed_story_cfg, llm=llm) `,
|
| 1309 |
+
];
|
| 1310 |
+
exports.seed_story = seed_story;
|
| 1311 |
+
const skopsPickle = (model, modelFile) => {
|
| 1312 |
+
return [
|
| 1313 |
+
`import joblib
|
| 1314 |
+
from skops.hub_utils import download
|
| 1315 |
+
download("${model.id}", "path_to_folder")
|
| 1316 |
+
model = joblib.load(
|
| 1317 |
+
"${modelFile}"
|
| 1318 |
+
)
|
| 1319 |
+
# only load pickle files from sources you trust
|
| 1320 |
+
# read more about it here https://skops.readthedocs.io/en/stable/persistence.html`,
|
| 1321 |
+
];
|
| 1322 |
+
};
|
| 1323 |
+
const skopsFormat = (model, modelFile) => {
|
| 1324 |
+
return [
|
| 1325 |
+
`from skops.hub_utils import download
|
| 1326 |
+
from skops.io import load
|
| 1327 |
+
download("${model.id}", "path_to_folder")
|
| 1328 |
+
# make sure model file is in skops format
|
| 1329 |
+
# if model is a pickle file, make sure it's from a source you trust
|
| 1330 |
+
model = load("path_to_folder/${modelFile}")`,
|
| 1331 |
+
];
|
| 1332 |
+
};
|
| 1333 |
+
const skopsJobLib = (model) => {
|
| 1334 |
+
return [
|
| 1335 |
+
`from huggingface_hub import hf_hub_download
|
| 1336 |
+
import joblib
|
| 1337 |
+
model = joblib.load(
|
| 1338 |
+
hf_hub_download("${model.id}", "sklearn_model.joblib")
|
| 1339 |
+
)
|
| 1340 |
+
# only load pickle files from sources you trust
|
| 1341 |
+
# read more about it here https://skops.readthedocs.io/en/stable/persistence.html`,
|
| 1342 |
+
];
|
| 1343 |
+
};
|
| 1344 |
+
const sklearn = (model) => {
|
| 1345 |
+
if (model.tags.includes("skops")) {
|
| 1346 |
+
const skopsmodelFile = model.config?.sklearn?.model?.file;
|
| 1347 |
+
const skopssaveFormat = model.config?.sklearn?.model_format;
|
| 1348 |
+
if (!skopsmodelFile) {
|
| 1349 |
+
return [`# ⚠️ Model filename not specified in config.json`];
|
| 1350 |
+
}
|
| 1351 |
+
if (skopssaveFormat === "pickle") {
|
| 1352 |
+
return skopsPickle(model, skopsmodelFile);
|
| 1353 |
+
}
|
| 1354 |
+
else {
|
| 1355 |
+
return skopsFormat(model, skopsmodelFile);
|
| 1356 |
+
}
|
| 1357 |
+
}
|
| 1358 |
+
else {
|
| 1359 |
+
return skopsJobLib(model);
|
| 1360 |
+
}
|
| 1361 |
+
};
|
| 1362 |
+
exports.sklearn = sklearn;
|
| 1363 |
+
const stable_audio_tools = (model) => [
|
| 1364 |
+
`import torch
|
| 1365 |
+
import torchaudio
|
| 1366 |
+
from einops import rearrange
|
| 1367 |
+
from stable_audio_tools import get_pretrained_model
|
| 1368 |
+
from stable_audio_tools.inference.generation import generate_diffusion_cond
|
| 1369 |
+
|
| 1370 |
+
device = "cuda" if torch.cuda.is_available() else "cpu"
|
| 1371 |
+
|
| 1372 |
+
# Download model
|
| 1373 |
+
model, model_config = get_pretrained_model("${model.id}")
|
| 1374 |
+
sample_rate = model_config["sample_rate"]
|
| 1375 |
+
sample_size = model_config["sample_size"]
|
| 1376 |
+
|
| 1377 |
+
model = model.to(device)
|
| 1378 |
+
|
| 1379 |
+
# Set up text and timing conditioning
|
| 1380 |
+
conditioning = [{
|
| 1381 |
+
"prompt": "128 BPM tech house drum loop",
|
| 1382 |
+
}]
|
| 1383 |
+
|
| 1384 |
+
# Generate stereo audio
|
| 1385 |
+
output = generate_diffusion_cond(
|
| 1386 |
+
model,
|
| 1387 |
+
conditioning=conditioning,
|
| 1388 |
+
sample_size=sample_size,
|
| 1389 |
+
device=device
|
| 1390 |
+
)
|
| 1391 |
+
|
| 1392 |
+
# Rearrange audio batch to a single sequence
|
| 1393 |
+
output = rearrange(output, "b d n -> d (b n)")
|
| 1394 |
+
|
| 1395 |
+
# Peak normalize, clip, convert to int16, and save to file
|
| 1396 |
+
output = output.to(torch.float32).div(torch.max(torch.abs(output))).clamp(-1, 1).mul(32767).to(torch.int16).cpu()
|
| 1397 |
+
torchaudio.save("output.wav", output, sample_rate)`,
|
| 1398 |
+
];
|
| 1399 |
+
exports.stable_audio_tools = stable_audio_tools;
|
| 1400 |
+
const fastai = (model) => [
|
| 1401 |
+
`from huggingface_hub import from_pretrained_fastai
|
| 1402 |
+
|
| 1403 |
+
learn = from_pretrained_fastai("${model.id}")`,
|
| 1404 |
+
];
|
| 1405 |
+
exports.fastai = fastai;
|
| 1406 |
+
const sam2 = (model) => {
|
| 1407 |
+
const image_predictor = `# Use SAM2 with images
|
| 1408 |
+
import torch
|
| 1409 |
+
from sam2.sam2_image_predictor import SAM2ImagePredictor
|
| 1410 |
+
|
| 1411 |
+
predictor = SAM2ImagePredictor.from_pretrained(${model.id})
|
| 1412 |
+
|
| 1413 |
+
with torch.inference_mode(), torch.autocast("cuda", dtype=torch.bfloat16):
|
| 1414 |
+
predictor.set_image(<your_image>)
|
| 1415 |
+
masks, _, _ = predictor.predict(<input_prompts>)`;
|
| 1416 |
+
const video_predictor = `# Use SAM2 with videos
|
| 1417 |
+
import torch
|
| 1418 |
+
from sam2.sam2_video_predictor import SAM2VideoPredictor
|
| 1419 |
+
|
| 1420 |
+
predictor = SAM2VideoPredictor.from_pretrained(${model.id})
|
| 1421 |
+
|
| 1422 |
+
with torch.inference_mode(), torch.autocast("cuda", dtype=torch.bfloat16):
|
| 1423 |
+
state = predictor.init_state(<your_video>)
|
| 1424 |
+
|
| 1425 |
+
# add new prompts and instantly get the output on the same frame
|
| 1426 |
+
frame_idx, object_ids, masks = predictor.add_new_points(state, <your_prompts>):
|
| 1427 |
+
|
| 1428 |
+
# propagate the prompts to get masklets throughout the video
|
| 1429 |
+
for frame_idx, object_ids, masks in predictor.propagate_in_video(state):
|
| 1430 |
+
...`;
|
| 1431 |
+
return [image_predictor, video_predictor];
|
| 1432 |
+
};
|
| 1433 |
+
exports.sam2 = sam2;
|
| 1434 |
+
const sam_3d_objects = (model) => [
|
| 1435 |
+
`from inference import Inference, load_image, load_single_mask
|
| 1436 |
+
from huggingface_hub import hf_hub_download
|
| 1437 |
+
|
| 1438 |
+
path = hf_hub_download("${model.id}", "pipeline.yaml")
|
| 1439 |
+
inference = Inference(path, compile=False)
|
| 1440 |
+
|
| 1441 |
+
image = load_image("path_to_image.png")
|
| 1442 |
+
mask = load_single_mask("path_to_mask.png", index=14)
|
| 1443 |
+
|
| 1444 |
+
output = inference(image, mask)`,
|
| 1445 |
+
];
|
| 1446 |
+
exports.sam_3d_objects = sam_3d_objects;
|
| 1447 |
+
const sam_3d_body = (model) => [
|
| 1448 |
+
`from notebook.utils import setup_sam_3d_body
|
| 1449 |
+
|
| 1450 |
+
estimator = setup_sam_3d_body(${model.id})
|
| 1451 |
+
outputs = estimator.process_one_image(image)
|
| 1452 |
+
rend_img = visualize_sample_together(image, outputs, estimator.faces)`,
|
| 1453 |
+
];
|
| 1454 |
+
exports.sam_3d_body = sam_3d_body;
|
| 1455 |
+
const sampleFactory = (model) => [
|
| 1456 |
+
`python -m sample_factory.huggingface.load_from_hub -r ${model.id} -d ./train_dir`,
|
| 1457 |
+
];
|
| 1458 |
+
exports.sampleFactory = sampleFactory;
|
| 1459 |
+
function get_widget_examples_from_st_model(model) {
|
| 1460 |
+
const widgetExample = model.widgetData?.[0];
|
| 1461 |
+
if (widgetExample?.source_sentence && widgetExample?.sentences?.length) {
|
| 1462 |
+
return [widgetExample.source_sentence, ...widgetExample.sentences];
|
| 1463 |
+
}
|
| 1464 |
+
}
|
| 1465 |
+
const sentenceTransformers = (model) => {
|
| 1466 |
+
const remote_code_snippet = model.tags.includes(TAG_CUSTOM_CODE) ? ", trust_remote_code=True" : "";
|
| 1467 |
+
if (model.tags.includes("PyLate")) {
|
| 1468 |
+
return [
|
| 1469 |
+
`from pylate import models
|
| 1470 |
+
|
| 1471 |
+
queries = [
|
| 1472 |
+
"Which planet is known as the Red Planet?",
|
| 1473 |
+
"What is the largest planet in our solar system?",
|
| 1474 |
+
]
|
| 1475 |
+
|
| 1476 |
+
documents = [
|
| 1477 |
+
["Mars is the Red Planet.", "Venus is Earth's twin."],
|
| 1478 |
+
["Jupiter is the largest planet.", "Saturn has rings."],
|
| 1479 |
+
]
|
| 1480 |
+
|
| 1481 |
+
model = models.ColBERT(model_name_or_path="${model.id}")
|
| 1482 |
+
|
| 1483 |
+
queries_emb = model.encode(queries, is_query=True)
|
| 1484 |
+
docs_emb = model.encode(documents, is_query=False)`,
|
| 1485 |
+
];
|
| 1486 |
+
}
|
| 1487 |
+
if (model.tags.includes("cross-encoder") || model.pipeline_tag == "text-ranking") {
|
| 1488 |
+
return [
|
| 1489 |
+
`from sentence_transformers import CrossEncoder
|
| 1490 |
+
|
| 1491 |
+
model = CrossEncoder("${model.id}"${remote_code_snippet})
|
| 1492 |
+
|
| 1493 |
+
query = "Which planet is known as the Red Planet?"
|
| 1494 |
+
passages = [
|
| 1495 |
+
"Venus is often called Earth's twin because of its similar size and proximity.",
|
| 1496 |
+
"Mars, known for its reddish appearance, is often referred to as the Red Planet.",
|
| 1497 |
+
"Jupiter, the largest planet in our solar system, has a prominent red spot.",
|
| 1498 |
+
"Saturn, famous for its rings, is sometimes mistaken for the Red Planet."
|
| 1499 |
+
]
|
| 1500 |
+
|
| 1501 |
+
scores = model.predict([(query, passage) for passage in passages])
|
| 1502 |
+
print(scores)`,
|
| 1503 |
+
];
|
| 1504 |
+
}
|
| 1505 |
+
const exampleSentences = get_widget_examples_from_st_model(model) ?? [
|
| 1506 |
+
"The weather is lovely today.",
|
| 1507 |
+
"It's so sunny outside!",
|
| 1508 |
+
"He drove to the stadium.",
|
| 1509 |
+
];
|
| 1510 |
+
return [
|
| 1511 |
+
`from sentence_transformers import SentenceTransformer
|
| 1512 |
+
|
| 1513 |
+
model = SentenceTransformer("${model.id}"${remote_code_snippet})
|
| 1514 |
+
|
| 1515 |
+
sentences = ${JSON.stringify(exampleSentences, null, 4)}
|
| 1516 |
+
embeddings = model.encode(sentences)
|
| 1517 |
+
|
| 1518 |
+
similarities = model.similarity(embeddings, embeddings)
|
| 1519 |
+
print(similarities.shape)
|
| 1520 |
+
# [${exampleSentences.length}, ${exampleSentences.length}]`,
|
| 1521 |
+
];
|
| 1522 |
+
};
|
| 1523 |
+
exports.sentenceTransformers = sentenceTransformers;
|
| 1524 |
+
const setfit = (model) => [
|
| 1525 |
+
`from setfit import SetFitModel
|
| 1526 |
+
|
| 1527 |
+
model = SetFitModel.from_pretrained("${model.id}")`,
|
| 1528 |
+
];
|
| 1529 |
+
exports.setfit = setfit;
|
| 1530 |
+
const spacy = (model) => [
|
| 1531 |
+
`!pip install https://huggingface.co/${model.id}/resolve/main/${nameWithoutNamespace(model.id)}-any-py3-none-any.whl
|
| 1532 |
+
|
| 1533 |
+
# Using spacy.load().
|
| 1534 |
+
import spacy
|
| 1535 |
+
nlp = spacy.load("${nameWithoutNamespace(model.id)}")
|
| 1536 |
+
|
| 1537 |
+
# Importing as module.
|
| 1538 |
+
import ${nameWithoutNamespace(model.id)}
|
| 1539 |
+
nlp = ${nameWithoutNamespace(model.id)}.load()`,
|
| 1540 |
+
];
|
| 1541 |
+
exports.spacy = spacy;
|
| 1542 |
+
const span_marker = (model) => [
|
| 1543 |
+
`from span_marker import SpanMarkerModel
|
| 1544 |
+
|
| 1545 |
+
model = SpanMarkerModel.from_pretrained("${model.id}")`,
|
| 1546 |
+
];
|
| 1547 |
+
exports.span_marker = span_marker;
|
| 1548 |
+
const stanza = (model) => [
|
| 1549 |
+
`import stanza
|
| 1550 |
+
|
| 1551 |
+
stanza.download("${nameWithoutNamespace(model.id).replace("stanza-", "")}")
|
| 1552 |
+
nlp = stanza.Pipeline("${nameWithoutNamespace(model.id).replace("stanza-", "")}")`,
|
| 1553 |
+
];
|
| 1554 |
+
exports.stanza = stanza;
|
| 1555 |
+
const speechBrainMethod = (speechbrainInterface) => {
|
| 1556 |
+
switch (speechbrainInterface) {
|
| 1557 |
+
case "EncoderClassifier":
|
| 1558 |
+
return "classify_file";
|
| 1559 |
+
case "EncoderDecoderASR":
|
| 1560 |
+
case "EncoderASR":
|
| 1561 |
+
return "transcribe_file";
|
| 1562 |
+
case "SpectralMaskEnhancement":
|
| 1563 |
+
return "enhance_file";
|
| 1564 |
+
case "SepformerSeparation":
|
| 1565 |
+
return "separate_file";
|
| 1566 |
+
default:
|
| 1567 |
+
return undefined;
|
| 1568 |
+
}
|
| 1569 |
+
};
|
| 1570 |
+
const speechbrain = (model) => {
|
| 1571 |
+
const speechbrainInterface = model.config?.speechbrain?.speechbrain_interface;
|
| 1572 |
+
if (speechbrainInterface === undefined) {
|
| 1573 |
+
return [`# interface not specified in config.json`];
|
| 1574 |
+
}
|
| 1575 |
+
const speechbrainMethod = speechBrainMethod(speechbrainInterface);
|
| 1576 |
+
if (speechbrainMethod === undefined) {
|
| 1577 |
+
return [`# interface in config.json invalid`];
|
| 1578 |
+
}
|
| 1579 |
+
return [
|
| 1580 |
+
`from speechbrain.pretrained import ${speechbrainInterface}
|
| 1581 |
+
model = ${speechbrainInterface}.from_hparams(
|
| 1582 |
+
"${model.id}"
|
| 1583 |
+
)
|
| 1584 |
+
model.${speechbrainMethod}("file.wav")`,
|
| 1585 |
+
];
|
| 1586 |
+
};
|
| 1587 |
+
exports.speechbrain = speechbrain;
|
| 1588 |
+
const terratorch = (model) => [
|
| 1589 |
+
`from terratorch.registry import BACKBONE_REGISTRY
|
| 1590 |
+
|
| 1591 |
+
model = BACKBONE_REGISTRY.build("${model.id}")`,
|
| 1592 |
+
];
|
| 1593 |
+
exports.terratorch = terratorch;
|
| 1594 |
+
const hasChatTemplate = (model) => model.config?.tokenizer_config?.chat_template !== undefined ||
|
| 1595 |
+
model.config?.processor_config?.chat_template !== undefined ||
|
| 1596 |
+
model.config?.chat_template_jinja !== undefined;
|
| 1597 |
+
const transformers = (model) => {
|
| 1598 |
+
const info = model.transformersInfo;
|
| 1599 |
+
if (!info) {
|
| 1600 |
+
return [`# ⚠️ Type of model unknown`];
|
| 1601 |
+
}
|
| 1602 |
+
const remote_code_snippet = model.tags.includes(TAG_CUSTOM_CODE) ? ", trust_remote_code=True" : "";
|
| 1603 |
+
const autoSnippet = [];
|
| 1604 |
+
if (info.processor) {
|
| 1605 |
+
const processorVarName = info.processor === "AutoTokenizer"
|
| 1606 |
+
? "tokenizer"
|
| 1607 |
+
: info.processor === "AutoFeatureExtractor"
|
| 1608 |
+
? "extractor"
|
| 1609 |
+
: "processor";
|
| 1610 |
+
autoSnippet.push("# Load model directly", `from transformers import ${info.processor}, ${info.auto_model}`, "", `${processorVarName} = ${info.processor}.from_pretrained("${model.id}"` + remote_code_snippet + ")", `model = ${info.auto_model}.from_pretrained("${model.id}"` + remote_code_snippet + ")");
|
| 1611 |
+
if (model.tags.includes("conversational") && hasChatTemplate(model)) {
|
| 1612 |
+
if (model.tags.includes("image-text-to-text")) {
|
| 1613 |
+
autoSnippet.push("messages = [", [
|
| 1614 |
+
" {",
|
| 1615 |
+
' "role": "user",',
|
| 1616 |
+
' "content": [',
|
| 1617 |
+
' {"type": "image", "url": "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/p-blog/candy.JPG"},',
|
| 1618 |
+
' {"type": "text", "text": "What animal is on the candy?"}',
|
| 1619 |
+
" ]",
|
| 1620 |
+
" },",
|
| 1621 |
+
].join("\n"), "]");
|
| 1622 |
+
}
|
| 1623 |
+
else {
|
| 1624 |
+
autoSnippet.push("messages = [", ' {"role": "user", "content": "Who are you?"},', "]");
|
| 1625 |
+
}
|
| 1626 |
+
autoSnippet.push(`inputs = ${processorVarName}.apply_chat_template(`, " messages,", " add_generation_prompt=True,", " tokenize=True,", " return_dict=True,", ' return_tensors="pt",', ").to(model.device)", "", "outputs = model.generate(**inputs, max_new_tokens=40)", `print(${processorVarName}.decode(outputs[0][inputs["input_ids"].shape[-1]:]))`);
|
| 1627 |
+
}
|
| 1628 |
+
}
|
| 1629 |
+
else {
|
| 1630 |
+
autoSnippet.push("# Load model directly", `from transformers import ${info.auto_model}`, `model = ${info.auto_model}.from_pretrained("${model.id}"` + remote_code_snippet + ', dtype="auto")');
|
| 1631 |
+
}
|
| 1632 |
+
if (model.pipeline_tag && library_to_tasks_js_1.LIBRARY_TASK_MAPPING.transformers?.includes(model.pipeline_tag)) {
|
| 1633 |
+
const pipelineSnippet = ["# Use a pipeline as a high-level helper"];
|
| 1634 |
+
if (library_to_tasks_js_1.REMOVED_IN_V5_TRANSFORMERS_PIPELINES.includes(model.pipeline_tag)) {
|
| 1635 |
+
pipelineSnippet.push(`# Warning: Pipeline type "${model.pipeline_tag}" is no longer supported in transformers v5.`, `# You must load the model directly (see below) or downgrade to v4.x with:`, `# 'pip install "transformers<5.0.0'`);
|
| 1636 |
+
}
|
| 1637 |
+
pipelineSnippet.push("from transformers import pipeline", "", `pipe = pipeline("${model.pipeline_tag}", model="${model.id}"` + remote_code_snippet + ")");
|
| 1638 |
+
if (model.tags.includes("conversational")) {
|
| 1639 |
+
if (model.tags.includes("image-text-to-text")) {
|
| 1640 |
+
pipelineSnippet.push("messages = [", [
|
| 1641 |
+
" {",
|
| 1642 |
+
' "role": "user",',
|
| 1643 |
+
' "content": [',
|
| 1644 |
+
' {"type": "image", "url": "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/p-blog/candy.JPG"},',
|
| 1645 |
+
' {"type": "text", "text": "What animal is on the candy?"}',
|
| 1646 |
+
" ]",
|
| 1647 |
+
" },",
|
| 1648 |
+
].join("\n"), "]");
|
| 1649 |
+
pipelineSnippet.push("pipe(text=messages)");
|
| 1650 |
+
}
|
| 1651 |
+
else {
|
| 1652 |
+
pipelineSnippet.push("messages = [", ' {"role": "user", "content": "Who are you?"},', "]");
|
| 1653 |
+
pipelineSnippet.push("pipe(messages)");
|
| 1654 |
+
}
|
| 1655 |
+
}
|
| 1656 |
+
else if (model.pipeline_tag === "zero-shot-image-classification") {
|
| 1657 |
+
pipelineSnippet.push("pipe(", ' "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/hub/parrots.png",', ' candidate_labels=["animals", "humans", "landscape"],', ")");
|
| 1658 |
+
}
|
| 1659 |
+
else if (model.pipeline_tag === "image-classification") {
|
| 1660 |
+
pipelineSnippet.push('pipe("https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/hub/parrots.png")');
|
| 1661 |
+
}
|
| 1662 |
+
return [pipelineSnippet.join("\n"), autoSnippet.join("\n")];
|
| 1663 |
+
}
|
| 1664 |
+
return [autoSnippet.join("\n")];
|
| 1665 |
+
};
|
| 1666 |
+
exports.transformers = transformers;
|
| 1667 |
+
const transformersJS = (model) => {
|
| 1668 |
+
if (!model.pipeline_tag) {
|
| 1669 |
+
return [`// ⚠️ Unknown pipeline tag`];
|
| 1670 |
+
}
|
| 1671 |
+
const libName = "@huggingface/transformers";
|
| 1672 |
+
return [
|
| 1673 |
+
`// npm i ${libName}
|
| 1674 |
+
import { pipeline } from '${libName}';
|
| 1675 |
+
|
| 1676 |
+
// Allocate pipeline
|
| 1677 |
+
const pipe = await pipeline('${model.pipeline_tag}', '${model.id}');`,
|
| 1678 |
+
];
|
| 1679 |
+
};
|
| 1680 |
+
exports.transformersJS = transformersJS;
|
| 1681 |
+
const peftTask = (peftTaskType) => {
|
| 1682 |
+
switch (peftTaskType) {
|
| 1683 |
+
case "CAUSAL_LM":
|
| 1684 |
+
return "CausalLM";
|
| 1685 |
+
case "SEQ_2_SEQ_LM":
|
| 1686 |
+
return "Seq2SeqLM";
|
| 1687 |
+
case "TOKEN_CLS":
|
| 1688 |
+
return "TokenClassification";
|
| 1689 |
+
case "SEQ_CLS":
|
| 1690 |
+
return "SequenceClassification";
|
| 1691 |
+
default:
|
| 1692 |
+
return undefined;
|
| 1693 |
+
}
|
| 1694 |
+
};
|
| 1695 |
+
const peft = (model) => {
|
| 1696 |
+
const { base_model_name_or_path: peftBaseModel, task_type: peftTaskType } = model.config?.peft ?? {};
|
| 1697 |
+
const pefttask = peftTask(peftTaskType);
|
| 1698 |
+
if (!pefttask) {
|
| 1699 |
+
return [`Task type is invalid.`];
|
| 1700 |
+
}
|
| 1701 |
+
if (!peftBaseModel) {
|
| 1702 |
+
return [`Base model is not found.`];
|
| 1703 |
+
}
|
| 1704 |
+
return [
|
| 1705 |
+
`from peft import PeftModel
|
| 1706 |
+
from transformers import AutoModelFor${pefttask}
|
| 1707 |
+
|
| 1708 |
+
base_model = AutoModelFor${pefttask}.from_pretrained("${peftBaseModel}")
|
| 1709 |
+
model = PeftModel.from_pretrained(base_model, "${model.id}")`,
|
| 1710 |
+
];
|
| 1711 |
+
};
|
| 1712 |
+
exports.peft = peft;
|
| 1713 |
+
const fasttext = (model) => [
|
| 1714 |
+
`from huggingface_hub import hf_hub_download
|
| 1715 |
+
import fasttext
|
| 1716 |
+
|
| 1717 |
+
model = fasttext.load_model(hf_hub_download("${model.id}", "model.bin"))`,
|
| 1718 |
+
];
|
| 1719 |
+
exports.fasttext = fasttext;
|
| 1720 |
+
const stableBaselines3 = (model) => [
|
| 1721 |
+
`from huggingface_sb3 import load_from_hub
|
| 1722 |
+
checkpoint = load_from_hub(
|
| 1723 |
+
repo_id="${model.id}",
|
| 1724 |
+
filename="{MODEL FILENAME}.zip",
|
| 1725 |
+
)`,
|
| 1726 |
+
];
|
| 1727 |
+
exports.stableBaselines3 = stableBaselines3;
|
| 1728 |
+
const nemoDomainResolver = (domain, model) => {
|
| 1729 |
+
switch (domain) {
|
| 1730 |
+
case "ASR":
|
| 1731 |
+
return [
|
| 1732 |
+
`import nemo.collections.asr as nemo_asr
|
| 1733 |
+
asr_model = nemo_asr.models.ASRModel.from_pretrained("${model.id}")
|
| 1734 |
+
|
| 1735 |
+
transcriptions = asr_model.transcribe(["file.wav"])`,
|
| 1736 |
+
];
|
| 1737 |
+
default:
|
| 1738 |
+
return undefined;
|
| 1739 |
+
}
|
| 1740 |
+
};
|
| 1741 |
+
const mlAgents = (model) => [
|
| 1742 |
+
`mlagents-load-from-hf --repo-id="${model.id}" --local-dir="./download: string[]s"`,
|
| 1743 |
+
];
|
| 1744 |
+
exports.mlAgents = mlAgents;
|
| 1745 |
+
const sentis = ( /* model: ModelData */) => [
|
| 1746 |
+
`string modelName = "[Your model name here].sentis";
|
| 1747 |
+
Model model = ModelLoader.Load(Application.streamingAssetsPath + "/" + modelName);
|
| 1748 |
+
IWorker engine = WorkerFactory.CreateWorker(BackendType.GPUCompute, model);
|
| 1749 |
+
// Please see provided C# file for more details
|
| 1750 |
+
`,
|
| 1751 |
+
];
|
| 1752 |
+
exports.sentis = sentis;
|
| 1753 |
+
const sana = (model) => [
|
| 1754 |
+
`
|
| 1755 |
+
# Load the model and infer image from text
|
| 1756 |
+
import torch
|
| 1757 |
+
from app.sana_pipeline import SanaPipeline
|
| 1758 |
+
from torchvision.utils import save_image
|
| 1759 |
+
|
| 1760 |
+
sana = SanaPipeline("configs/sana_config/1024ms/Sana_1600M_img1024.yaml")
|
| 1761 |
+
sana.from_pretrained("hf://${model.id}")
|
| 1762 |
+
|
| 1763 |
+
image = sana(
|
| 1764 |
+
prompt='a cyberpunk cat with a neon sign that says "Sana"',
|
| 1765 |
+
height=1024,
|
| 1766 |
+
width=1024,
|
| 1767 |
+
guidance_scale=5.0,
|
| 1768 |
+
pag_guidance_scale=2.0,
|
| 1769 |
+
num_inference_steps=18,
|
| 1770 |
+
) `,
|
| 1771 |
+
];
|
| 1772 |
+
exports.sana = sana;
|
| 1773 |
+
const vibevoice = (model) => [
|
| 1774 |
+
`import torch, soundfile as sf, librosa, numpy as np
|
| 1775 |
+
from vibevoice.processor.vibevoice_processor import VibeVoiceProcessor
|
| 1776 |
+
from vibevoice.modular.modeling_vibevoice_inference import VibeVoiceForConditionalGenerationInference
|
| 1777 |
+
|
| 1778 |
+
# Load voice sample (should be 24kHz mono)
|
| 1779 |
+
voice, sr = sf.read("path/to/voice_sample.wav")
|
| 1780 |
+
if voice.ndim > 1: voice = voice.mean(axis=1)
|
| 1781 |
+
if sr != 24000: voice = librosa.resample(voice, sr, 24000)
|
| 1782 |
+
|
| 1783 |
+
processor = VibeVoiceProcessor.from_pretrained("${model.id}")
|
| 1784 |
+
model = VibeVoiceForConditionalGenerationInference.from_pretrained(
|
| 1785 |
+
"${model.id}", torch_dtype=torch.bfloat16
|
| 1786 |
+
).to("cuda").eval()
|
| 1787 |
+
model.set_ddpm_inference_steps(5)
|
| 1788 |
+
|
| 1789 |
+
inputs = processor(text=["Speaker 0: Hello!\\nSpeaker 1: Hi there!"],
|
| 1790 |
+
voice_samples=[[voice]], return_tensors="pt")
|
| 1791 |
+
audio = model.generate(**inputs, cfg_scale=1.3,
|
| 1792 |
+
tokenizer=processor.tokenizer).speech_outputs[0]
|
| 1793 |
+
sf.write("output.wav", audio.cpu().numpy().squeeze(), 24000)`,
|
| 1794 |
+
];
|
| 1795 |
+
exports.vibevoice = vibevoice;
|
| 1796 |
+
const videoprism = (model) => [
|
| 1797 |
+
`# Install from https://github.com/google-deepmind/videoprism
|
| 1798 |
+
import jax
|
| 1799 |
+
from videoprism import models as vp
|
| 1800 |
+
|
| 1801 |
+
flax_model = vp.get_model("${model.id}")
|
| 1802 |
+
loaded_state = vp.load_pretrained_weights("${model.id}")
|
| 1803 |
+
|
| 1804 |
+
@jax.jit
|
| 1805 |
+
def forward_fn(inputs, train=False):
|
| 1806 |
+
return flax_model.apply(loaded_state, inputs, train=train)`,
|
| 1807 |
+
];
|
| 1808 |
+
exports.videoprism = videoprism;
|
| 1809 |
+
const vfimamba = (model) => [
|
| 1810 |
+
`from Trainer_finetune import Model
|
| 1811 |
+
|
| 1812 |
+
model = Model.from_pretrained("${model.id}")`,
|
| 1813 |
+
];
|
| 1814 |
+
exports.vfimamba = vfimamba;
|
| 1815 |
+
const lvface = (model) => [
|
| 1816 |
+
`from huggingface_hub import hf_hub_download
|
| 1817 |
+
from inference_onnx import LVFaceONNXInferencer
|
| 1818 |
+
|
| 1819 |
+
model_path = hf_hub_download("${model.id}", "LVFace-L_Glint360K/LVFace-L_Glint360K.onnx")
|
| 1820 |
+
inferencer = LVFaceONNXInferencer(model_path, use_gpu=True, timeout=300)
|
| 1821 |
+
img_path = 'path/to/image1.jpg'
|
| 1822 |
+
embedding = inferencer.infer_from_image(img_path)`,
|
| 1823 |
+
];
|
| 1824 |
+
exports.lvface = lvface;
|
| 1825 |
+
const voicecraft = (model) => [
|
| 1826 |
+
`from voicecraft import VoiceCraft
|
| 1827 |
+
|
| 1828 |
+
model = VoiceCraft.from_pretrained("${model.id}")`,
|
| 1829 |
+
];
|
| 1830 |
+
exports.voicecraft = voicecraft;
|
| 1831 |
+
const voxcpm = (model) => [
|
| 1832 |
+
`import soundfile as sf
|
| 1833 |
+
from voxcpm import VoxCPM
|
| 1834 |
+
|
| 1835 |
+
model = VoxCPM.from_pretrained("${model.id}")
|
| 1836 |
+
|
| 1837 |
+
wav = model.generate(
|
| 1838 |
+
text="VoxCPM is an innovative end-to-end TTS model from ModelBest, designed to generate highly expressive speech.",
|
| 1839 |
+
prompt_wav_path=None, # optional: path to a prompt speech for voice cloning
|
| 1840 |
+
prompt_text=None, # optional: reference text
|
| 1841 |
+
cfg_value=2.0, # LM guidance on LocDiT, higher for better adherence to the prompt, but maybe worse
|
| 1842 |
+
inference_timesteps=10, # LocDiT inference timesteps, higher for better result, lower for fast speed
|
| 1843 |
+
normalize=True, # enable external TN tool
|
| 1844 |
+
denoise=True, # enable external Denoise tool
|
| 1845 |
+
retry_badcase=True, # enable retrying mode for some bad cases (unstoppable)
|
| 1846 |
+
retry_badcase_max_times=3, # maximum retrying times
|
| 1847 |
+
retry_badcase_ratio_threshold=6.0, # maximum length restriction for bad case detection (simple but effective), it could be adjusted for slow pace speech
|
| 1848 |
+
)
|
| 1849 |
+
|
| 1850 |
+
sf.write("output.wav", wav, 16000)
|
| 1851 |
+
print("saved: output.wav")`,
|
| 1852 |
+
];
|
| 1853 |
+
exports.voxcpm = voxcpm;
|
| 1854 |
+
const vui = () => [
|
| 1855 |
+
`# !pip install git+https://github.com/fluxions-ai/vui
|
| 1856 |
+
|
| 1857 |
+
import torchaudio
|
| 1858 |
+
|
| 1859 |
+
from vui.inference import render
|
| 1860 |
+
from vui.model import Vui,
|
| 1861 |
+
|
| 1862 |
+
model = Vui.from_pretrained().cuda()
|
| 1863 |
+
waveform = render(
|
| 1864 |
+
model,
|
| 1865 |
+
"Hey, here is some random stuff, usually something quite long as the shorter the text the less likely the model can cope!",
|
| 1866 |
+
)
|
| 1867 |
+
print(waveform.shape)
|
| 1868 |
+
torchaudio.save("out.opus", waveform[0], 22050)
|
| 1869 |
+
`,
|
| 1870 |
+
];
|
| 1871 |
+
exports.vui = vui;
|
| 1872 |
+
const chattts = () => [
|
| 1873 |
+
`import ChatTTS
|
| 1874 |
+
import torchaudio
|
| 1875 |
+
|
| 1876 |
+
chat = ChatTTS.Chat()
|
| 1877 |
+
chat.load_models(compile=False) # Set to True for better performance
|
| 1878 |
+
|
| 1879 |
+
texts = ["PUT YOUR TEXT HERE",]
|
| 1880 |
+
|
| 1881 |
+
wavs = chat.infer(texts, )
|
| 1882 |
+
|
| 1883 |
+
torchaudio.save("output1.wav", torch.from_numpy(wavs[0]), 24000)`,
|
| 1884 |
+
];
|
| 1885 |
+
exports.chattts = chattts;
|
| 1886 |
+
const ultralytics = (model) => {
|
| 1887 |
+
// ultralytics models must have a version tag (e.g. `yolov8`)
|
| 1888 |
+
const versionTag = model.tags.find((tag) => tag.match(/^yolov\d+$/));
|
| 1889 |
+
const className = versionTag ? `YOLOv${versionTag.slice(4)}` : "YOLOvXX";
|
| 1890 |
+
const prefix = versionTag
|
| 1891 |
+
? ""
|
| 1892 |
+
: `# Couldn't find a valid YOLO version tag.\n# Replace XX with the correct version.\n`;
|
| 1893 |
+
return [
|
| 1894 |
+
prefix +
|
| 1895 |
+
`from ultralytics import ${className}
|
| 1896 |
+
|
| 1897 |
+
model = ${className}.from_pretrained("${model.id}")
|
| 1898 |
+
source = 'http://images.cocodataset.org/val2017/000000039769.jpg'
|
| 1899 |
+
model.predict(source=source, save=True)`,
|
| 1900 |
+
];
|
| 1901 |
+
};
|
| 1902 |
+
exports.ultralytics = ultralytics;
|
| 1903 |
+
const birefnet = (model) => [
|
| 1904 |
+
`# Option 1: use with transformers
|
| 1905 |
+
|
| 1906 |
+
from transformers import AutoModelForImageSegmentation
|
| 1907 |
+
birefnet = AutoModelForImageSegmentation.from_pretrained("${model.id}", trust_remote_code=True)
|
| 1908 |
+
`,
|
| 1909 |
+
`# Option 2: use with BiRefNet
|
| 1910 |
+
|
| 1911 |
+
# Install from https://github.com/ZhengPeng7/BiRefNet
|
| 1912 |
+
|
| 1913 |
+
from models.birefnet import BiRefNet
|
| 1914 |
+
model = BiRefNet.from_pretrained("${model.id}")`,
|
| 1915 |
+
];
|
| 1916 |
+
exports.birefnet = birefnet;
|
| 1917 |
+
const supertonic = () => [
|
| 1918 |
+
`from supertonic import TTS
|
| 1919 |
+
|
| 1920 |
+
tts = TTS(auto_download=True)
|
| 1921 |
+
|
| 1922 |
+
style = tts.get_voice_style(voice_name="M1")
|
| 1923 |
+
|
| 1924 |
+
text = "The train delay was announced at 4:45 PM on Wed, Apr 3, 2024 due to track maintenance."
|
| 1925 |
+
wav, duration = tts.synthesize(text, voice_style=style)
|
| 1926 |
+
|
| 1927 |
+
tts.save_audio(wav, "output.wav")`,
|
| 1928 |
+
];
|
| 1929 |
+
exports.supertonic = supertonic;
|
| 1930 |
+
const swarmformer = (model) => [
|
| 1931 |
+
`from swarmformer import SwarmFormerModel
|
| 1932 |
+
|
| 1933 |
+
model = SwarmFormerModel.from_pretrained("${model.id}")
|
| 1934 |
+
`,
|
| 1935 |
+
];
|
| 1936 |
+
exports.swarmformer = swarmformer;
|
| 1937 |
+
const univa = (model) => [
|
| 1938 |
+
`# Follow installation instructions at https://github.com/PKU-YuanGroup/UniWorld-V1
|
| 1939 |
+
|
| 1940 |
+
from univa.models.qwen2p5vl.modeling_univa_qwen2p5vl import UnivaQwen2p5VLForConditionalGeneration
|
| 1941 |
+
model = UnivaQwen2p5VLForConditionalGeneration.from_pretrained(
|
| 1942 |
+
"${model.id}",
|
| 1943 |
+
torch_dtype=torch.bfloat16,
|
| 1944 |
+
attn_implementation="flash_attention_2",
|
| 1945 |
+
).to("cuda")
|
| 1946 |
+
processor = AutoProcessor.from_pretrained("${model.id}")
|
| 1947 |
+
`,
|
| 1948 |
+
];
|
| 1949 |
+
exports.univa = univa;
|
| 1950 |
+
const mlx_unknown = (model) => [
|
| 1951 |
+
`# Download the model from the Hub
|
| 1952 |
+
pip install huggingface_hub[hf_xet]
|
| 1953 |
+
|
| 1954 |
+
huggingface-cli download --local-dir ${nameWithoutNamespace(model.id)} ${model.id}`,
|
| 1955 |
+
];
|
| 1956 |
+
const mlxlm = (model) => [
|
| 1957 |
+
`# Make sure mlx-lm is installed
|
| 1958 |
+
# pip install --upgrade mlx-lm
|
| 1959 |
+
# if on a CUDA device, also pip install mlx[cuda]
|
| 1960 |
+
|
| 1961 |
+
# Generate text with mlx-lm
|
| 1962 |
+
from mlx_lm import load, generate
|
| 1963 |
+
|
| 1964 |
+
model, tokenizer = load("${model.id}")
|
| 1965 |
+
|
| 1966 |
+
prompt = "Once upon a time in"
|
| 1967 |
+
text = generate(model, tokenizer, prompt=prompt, verbose=True)`,
|
| 1968 |
+
];
|
| 1969 |
+
const mlxchat = (model) => [
|
| 1970 |
+
`# Make sure mlx-lm is installed
|
| 1971 |
+
# pip install --upgrade mlx-lm
|
| 1972 |
+
|
| 1973 |
+
# Generate text with mlx-lm
|
| 1974 |
+
from mlx_lm import load, generate
|
| 1975 |
+
|
| 1976 |
+
model, tokenizer = load("${model.id}")
|
| 1977 |
+
|
| 1978 |
+
prompt = "Write a story about Einstein"
|
| 1979 |
+
messages = [{"role": "user", "content": prompt}]
|
| 1980 |
+
prompt = tokenizer.apply_chat_template(
|
| 1981 |
+
messages, add_generation_prompt=True
|
| 1982 |
+
)
|
| 1983 |
+
|
| 1984 |
+
text = generate(model, tokenizer, prompt=prompt, verbose=True)`,
|
| 1985 |
+
];
|
| 1986 |
+
const mlxvlm = (model) => [
|
| 1987 |
+
`# Make sure mlx-vlm is installed
|
| 1988 |
+
# pip install --upgrade mlx-vlm
|
| 1989 |
+
|
| 1990 |
+
from mlx_vlm import load, generate
|
| 1991 |
+
from mlx_vlm.prompt_utils import apply_chat_template
|
| 1992 |
+
from mlx_vlm.utils import load_config
|
| 1993 |
+
|
| 1994 |
+
# Load the model
|
| 1995 |
+
model, processor = load("${model.id}")
|
| 1996 |
+
config = load_config("${model.id}")
|
| 1997 |
+
|
| 1998 |
+
# Prepare input
|
| 1999 |
+
image = ["http://images.cocodataset.org/val2017/000000039769.jpg"]
|
| 2000 |
+
prompt = "Describe this image."
|
| 2001 |
+
|
| 2002 |
+
# Apply chat template
|
| 2003 |
+
formatted_prompt = apply_chat_template(
|
| 2004 |
+
processor, config, prompt, num_images=1
|
| 2005 |
+
)
|
| 2006 |
+
|
| 2007 |
+
# Generate output
|
| 2008 |
+
output = generate(model, processor, formatted_prompt, image)
|
| 2009 |
+
print(output)`,
|
| 2010 |
+
];
|
| 2011 |
+
const mlxim = (model) => [
|
| 2012 |
+
`from mlxim.model import create_model
|
| 2013 |
+
|
| 2014 |
+
model = create_model(${model.id})`,
|
| 2015 |
+
];
|
| 2016 |
+
exports.mlxim = mlxim;
|
| 2017 |
+
const mlx = (model) => {
|
| 2018 |
+
if (model.pipeline_tag === "image-text-to-text") {
|
| 2019 |
+
return mlxvlm(model);
|
| 2020 |
+
}
|
| 2021 |
+
if (model.pipeline_tag === "text-generation") {
|
| 2022 |
+
if (model.tags.includes("conversational")) {
|
| 2023 |
+
return mlxchat(model);
|
| 2024 |
+
}
|
| 2025 |
+
else {
|
| 2026 |
+
return mlxlm(model);
|
| 2027 |
+
}
|
| 2028 |
+
}
|
| 2029 |
+
return mlx_unknown(model);
|
| 2030 |
+
};
|
| 2031 |
+
exports.mlx = mlx;
|
| 2032 |
+
const model2vec = (model) => [
|
| 2033 |
+
`from model2vec import StaticModel
|
| 2034 |
+
|
| 2035 |
+
model = StaticModel.from_pretrained("${model.id}")`,
|
| 2036 |
+
];
|
| 2037 |
+
exports.model2vec = model2vec;
|
| 2038 |
+
const pruna = (model) => {
|
| 2039 |
+
let snippets;
|
| 2040 |
+
if (model.tags.includes("diffusers")) {
|
| 2041 |
+
snippets = pruna_diffusers(model);
|
| 2042 |
+
}
|
| 2043 |
+
else if (model.tags.includes("transformers")) {
|
| 2044 |
+
snippets = pruna_transformers(model);
|
| 2045 |
+
}
|
| 2046 |
+
else {
|
| 2047 |
+
snippets = pruna_default(model);
|
| 2048 |
+
}
|
| 2049 |
+
const ensurePrunaModelImport = (snippet) => {
|
| 2050 |
+
if (!/^from pruna import PrunaModel/m.test(snippet)) {
|
| 2051 |
+
return `from pruna import PrunaModel\n${snippet}`;
|
| 2052 |
+
}
|
| 2053 |
+
return snippet;
|
| 2054 |
+
};
|
| 2055 |
+
snippets = snippets.map(ensurePrunaModelImport);
|
| 2056 |
+
if (model.tags.includes("pruna_pro-ai")) {
|
| 2057 |
+
return snippets.map((snippet) => snippet.replace(/\bpruna\b/g, "pruna_pro").replace(/\bPrunaModel\b/g, "PrunaProModel"));
|
| 2058 |
+
}
|
| 2059 |
+
return snippets;
|
| 2060 |
+
};
|
| 2061 |
+
exports.pruna = pruna;
|
| 2062 |
+
const pruna_diffusers = (model) => {
|
| 2063 |
+
const diffusersSnippets = (0, exports.diffusers)(model);
|
| 2064 |
+
return diffusersSnippets.map((snippet) => snippet
|
| 2065 |
+
// Replace pipeline classes with PrunaModel
|
| 2066 |
+
.replace(/\b\w*Pipeline\w*\b/g, "PrunaModel")
|
| 2067 |
+
// Clean up diffusers imports containing PrunaModel
|
| 2068 |
+
.replace(/from diffusers import ([^,\n]*PrunaModel[^,\n]*)/g, "")
|
| 2069 |
+
.replace(/from diffusers import ([^,\n]+),?\s*([^,\n]*PrunaModel[^,\n]*)/g, "from diffusers import $1")
|
| 2070 |
+
.replace(/from diffusers import\s*(\n|$)/g, "")
|
| 2071 |
+
// Fix PrunaModel imports
|
| 2072 |
+
.replace(/from diffusers import PrunaModel/g, "from pruna import PrunaModel")
|
| 2073 |
+
.replace(/from diffusers import ([^,\n]+), PrunaModel/g, "from diffusers import $1")
|
| 2074 |
+
.replace(/from diffusers import PrunaModel, ([^,\n]+)/g, "from diffusers import $1")
|
| 2075 |
+
// Clean up whitespace
|
| 2076 |
+
.replace(/\n\n+/g, "\n")
|
| 2077 |
+
.trim());
|
| 2078 |
+
};
|
| 2079 |
+
const pruna_transformers = (model) => {
|
| 2080 |
+
const info = model.transformersInfo;
|
| 2081 |
+
const transformersSnippets = (0, exports.transformers)(model);
|
| 2082 |
+
// Replace pipeline with PrunaModel
|
| 2083 |
+
let processedSnippets = transformersSnippets.map((snippet) => snippet
|
| 2084 |
+
.replace(/from transformers import pipeline/g, "from pruna import PrunaModel")
|
| 2085 |
+
.replace(/pipeline\([^)]*\)/g, `PrunaModel.from_pretrained("${model.id}")`));
|
| 2086 |
+
// Additional cleanup if auto_model info is available
|
| 2087 |
+
if (info?.auto_model) {
|
| 2088 |
+
processedSnippets = processedSnippets.map((snippet) => snippet
|
| 2089 |
+
.replace(new RegExp(`from transformers import ${info.auto_model}\n?`, "g"), "")
|
| 2090 |
+
.replace(new RegExp(`${info.auto_model}.from_pretrained`, "g"), "PrunaModel.from_pretrained")
|
| 2091 |
+
.replace(new RegExp(`^.*from.*import.*(, *${info.auto_model})+.*$`, "gm"), (line) => line.replace(new RegExp(`, *${info.auto_model}`, "g"), "")));
|
| 2092 |
+
}
|
| 2093 |
+
return processedSnippets;
|
| 2094 |
+
};
|
| 2095 |
+
const pruna_default = (model) => [
|
| 2096 |
+
`from pruna import PrunaModel
|
| 2097 |
+
model = PrunaModel.from_pretrained("${model.id}")
|
| 2098 |
+
`,
|
| 2099 |
+
];
|
| 2100 |
+
const nemo = (model) => {
|
| 2101 |
+
let command = undefined;
|
| 2102 |
+
// Resolve the tag to a nemo domain/sub-domain
|
| 2103 |
+
if (model.tags.includes("automatic-speech-recognition")) {
|
| 2104 |
+
command = nemoDomainResolver("ASR", model);
|
| 2105 |
+
}
|
| 2106 |
+
return command ?? [`# tag did not correspond to a valid NeMo domain.`];
|
| 2107 |
+
};
|
| 2108 |
+
exports.nemo = nemo;
|
| 2109 |
+
const outetts = (model) => {
|
| 2110 |
+
// Don’t show this block on GGUF / ONNX mirrors
|
| 2111 |
+
const t = model.tags ?? [];
|
| 2112 |
+
if (t.includes("gguf") || t.includes("onnx"))
|
| 2113 |
+
return [];
|
| 2114 |
+
// v1.0 HF → minimal runnable snippet
|
| 2115 |
+
return [
|
| 2116 |
+
`
|
| 2117 |
+
import outetts
|
| 2118 |
+
|
| 2119 |
+
enum = outetts.Models("${model.id}".split("/", 1)[1]) # VERSION_1_0_SIZE_1B
|
| 2120 |
+
cfg = outetts.ModelConfig.auto_config(enum, outetts.Backend.HF)
|
| 2121 |
+
tts = outetts.Interface(cfg)
|
| 2122 |
+
|
| 2123 |
+
speaker = tts.load_default_speaker("EN-FEMALE-1-NEUTRAL")
|
| 2124 |
+
tts.generate(
|
| 2125 |
+
outetts.GenerationConfig(
|
| 2126 |
+
text="Hello there, how are you doing?",
|
| 2127 |
+
speaker=speaker,
|
| 2128 |
+
)
|
| 2129 |
+
).save("output.wav")
|
| 2130 |
+
`,
|
| 2131 |
+
];
|
| 2132 |
+
};
|
| 2133 |
+
exports.outetts = outetts;
|
| 2134 |
+
const pxia = (model) => [
|
| 2135 |
+
`from pxia import AutoModel
|
| 2136 |
+
|
| 2137 |
+
model = AutoModel.from_pretrained("${model.id}")`,
|
| 2138 |
+
];
|
| 2139 |
+
exports.pxia = pxia;
|
| 2140 |
+
const pythae = (model) => [
|
| 2141 |
+
`from pythae.models import AutoModel
|
| 2142 |
+
|
| 2143 |
+
model = AutoModel.load_from_hf_hub("${model.id}")`,
|
| 2144 |
+
];
|
| 2145 |
+
exports.pythae = pythae;
|
| 2146 |
+
const qwen3_tts = (model) => [
|
| 2147 |
+
`# pip install qwen-tts
|
| 2148 |
+
import torch
|
| 2149 |
+
import soundfile as sf
|
| 2150 |
+
from qwen_tts import Qwen3TTSModel
|
| 2151 |
+
|
| 2152 |
+
model = Qwen3TTSModel.from_pretrained(
|
| 2153 |
+
"${model.id}",
|
| 2154 |
+
device_map="cuda:0",
|
| 2155 |
+
dtype=torch.bfloat16,
|
| 2156 |
+
attn_implementation="flash_attention_2",
|
| 2157 |
+
)
|
| 2158 |
+
|
| 2159 |
+
wavs, sr = model.generate_custom_voice(
|
| 2160 |
+
text="Your text here.",
|
| 2161 |
+
language="English",
|
| 2162 |
+
speaker="Ryan",
|
| 2163 |
+
instruct="Speak in a natural tone.",
|
| 2164 |
+
)
|
| 2165 |
+
|
| 2166 |
+
sf.write("output.wav", wavs[0], sr)`,
|
| 2167 |
+
];
|
| 2168 |
+
exports.qwen3_tts = qwen3_tts;
|
| 2169 |
+
const musicgen = (model) => [
|
| 2170 |
+
`from audiocraft.models import MusicGen
|
| 2171 |
+
|
| 2172 |
+
model = MusicGen.get_pretrained("${model.id}")
|
| 2173 |
+
|
| 2174 |
+
descriptions = ['happy rock', 'energetic EDM', 'sad jazz']
|
| 2175 |
+
wav = model.generate(descriptions) # generates 3 samples.`,
|
| 2176 |
+
];
|
| 2177 |
+
const magnet = (model) => [
|
| 2178 |
+
`from audiocraft.models import MAGNeT
|
| 2179 |
+
|
| 2180 |
+
model = MAGNeT.get_pretrained("${model.id}")
|
| 2181 |
+
|
| 2182 |
+
descriptions = ['disco beat', 'energetic EDM', 'funky groove']
|
| 2183 |
+
wav = model.generate(descriptions) # generates 3 samples.`,
|
| 2184 |
+
];
|
| 2185 |
+
const audiogen = (model) => [
|
| 2186 |
+
`from audiocraft.models import AudioGen
|
| 2187 |
+
|
| 2188 |
+
model = AudioGen.get_pretrained("${model.id}")
|
| 2189 |
+
model.set_generation_params(duration=5) # generate 5 seconds.
|
| 2190 |
+
descriptions = ['dog barking', 'sirene of an emergency vehicle', 'footsteps in a corridor']
|
| 2191 |
+
wav = model.generate(descriptions) # generates 3 samples.`,
|
| 2192 |
+
];
|
| 2193 |
+
const anemoi = (model) => [
|
| 2194 |
+
`from anemoi.inference.runners.default import DefaultRunner
|
| 2195 |
+
from anemoi.inference.config.run import RunConfiguration
|
| 2196 |
+
# Create Configuration
|
| 2197 |
+
config = RunConfiguration(checkpoint = {"huggingface":"${model.id}"})
|
| 2198 |
+
# Load Runner
|
| 2199 |
+
runner = DefaultRunner(config)`,
|
| 2200 |
+
];
|
| 2201 |
+
exports.anemoi = anemoi;
|
| 2202 |
+
const audiocraft = (model) => {
|
| 2203 |
+
if (model.tags.includes("musicgen")) {
|
| 2204 |
+
return musicgen(model);
|
| 2205 |
+
}
|
| 2206 |
+
else if (model.tags.includes("audiogen")) {
|
| 2207 |
+
return audiogen(model);
|
| 2208 |
+
}
|
| 2209 |
+
else if (model.tags.includes("magnet")) {
|
| 2210 |
+
return magnet(model);
|
| 2211 |
+
}
|
| 2212 |
+
else {
|
| 2213 |
+
return [`# Type of model unknown.`];
|
| 2214 |
+
}
|
| 2215 |
+
};
|
| 2216 |
+
exports.audiocraft = audiocraft;
|
| 2217 |
+
const whisperkit = () => [
|
| 2218 |
+
`# Install CLI with Homebrew on macOS device
|
| 2219 |
+
brew install whisperkit-cli
|
| 2220 |
+
|
| 2221 |
+
# View all available inference options
|
| 2222 |
+
whisperkit-cli transcribe --help
|
| 2223 |
+
|
| 2224 |
+
# Download and run inference using whisper base model
|
| 2225 |
+
whisperkit-cli transcribe --audio-path /path/to/audio.mp3
|
| 2226 |
+
|
| 2227 |
+
# Or use your preferred model variant
|
| 2228 |
+
whisperkit-cli transcribe --model "large-v3" --model-prefix "distil" --audio-path /path/to/audio.mp3 --verbose`,
|
| 2229 |
+
];
|
| 2230 |
+
exports.whisperkit = whisperkit;
|
| 2231 |
+
const threedtopia_xl = (model) => [
|
| 2232 |
+
`from threedtopia_xl.models import threedtopia_xl
|
| 2233 |
+
|
| 2234 |
+
model = threedtopia_xl.from_pretrained("${model.id}")
|
| 2235 |
+
model.generate(cond="path/to/image.png")`,
|
| 2236 |
+
];
|
| 2237 |
+
exports.threedtopia_xl = threedtopia_xl;
|
| 2238 |
+
const hezar = (model) => [
|
| 2239 |
+
`from hezar import Model
|
| 2240 |
+
|
| 2241 |
+
model = Model.load("${model.id}")`,
|
| 2242 |
+
];
|
| 2243 |
+
exports.hezar = hezar;
|
| 2244 |
+
const zonos = (model) => [
|
| 2245 |
+
`# pip install git+https://github.com/Zyphra/Zonos.git
|
| 2246 |
+
import torchaudio
|
| 2247 |
+
from zonos.model import Zonos
|
| 2248 |
+
from zonos.conditioning import make_cond_dict
|
| 2249 |
+
|
| 2250 |
+
model = Zonos.from_pretrained("${model.id}", device="cuda")
|
| 2251 |
+
|
| 2252 |
+
wav, sr = torchaudio.load("speaker.wav") # 5-10s reference clip
|
| 2253 |
+
speaker = model.make_speaker_embedding(wav, sr)
|
| 2254 |
+
|
| 2255 |
+
cond = make_cond_dict(text="Hello, world!", speaker=speaker, language="en-us")
|
| 2256 |
+
codes = model.generate(model.prepare_conditioning(cond))
|
| 2257 |
+
|
| 2258 |
+
audio = model.autoencoder.decode(codes)[0].cpu()
|
| 2259 |
+
torchaudio.save("sample.wav", audio, model.autoencoder.sampling_rate)
|
| 2260 |
+
`,
|
| 2261 |
+
];
|
| 2262 |
+
exports.zonos = zonos;
|
| 2263 |
+
const moshi = (model) => {
|
| 2264 |
+
// Detect backend from model name (no distinguishing tags available)
|
| 2265 |
+
if (model.id.includes("-mlx")) {
|
| 2266 |
+
// MLX backend (macOS Apple Silicon)
|
| 2267 |
+
// -q flag only accepts 4 or 8, bf16 models don't use it
|
| 2268 |
+
const quantFlag = model.id.includes("-q4") ? " -q 4" : model.id.includes("-q8") ? " -q 8" : "";
|
| 2269 |
+
return [
|
| 2270 |
+
`# pip install moshi_mlx
|
| 2271 |
+
# Run local inference (macOS Apple Silicon)
|
| 2272 |
+
python -m moshi_mlx.local${quantFlag} --hf-repo "${model.id}"
|
| 2273 |
+
|
| 2274 |
+
# Or run with web UI
|
| 2275 |
+
python -m moshi_mlx.local_web${quantFlag} --hf-repo "${model.id}"`,
|
| 2276 |
+
];
|
| 2277 |
+
}
|
| 2278 |
+
if (model.id.includes("-candle")) {
|
| 2279 |
+
// Rust/Candle backend
|
| 2280 |
+
return [
|
| 2281 |
+
`# pip install rustymimi
|
| 2282 |
+
# Candle backend - see https://github.com/kyutai-labs/moshi
|
| 2283 |
+
# for Rust installation instructions`,
|
| 2284 |
+
];
|
| 2285 |
+
}
|
| 2286 |
+
// PyTorch backend (default)
|
| 2287 |
+
return [
|
| 2288 |
+
`# pip install moshi
|
| 2289 |
+
# Run the interactive web server
|
| 2290 |
+
python -m moshi.server --hf-repo "${model.id}"
|
| 2291 |
+
# Then open https://localhost:8998 in your browser`,
|
| 2292 |
+
`# pip install moshi
|
| 2293 |
+
import torch
|
| 2294 |
+
from moshi.models import loaders
|
| 2295 |
+
|
| 2296 |
+
# Load checkpoint info from HuggingFace
|
| 2297 |
+
checkpoint = loaders.CheckpointInfo.from_hf_repo("${model.id}")
|
| 2298 |
+
|
| 2299 |
+
# Load the Mimi audio codec
|
| 2300 |
+
mimi = checkpoint.get_mimi(device="cuda")
|
| 2301 |
+
mimi.set_num_codebooks(8)
|
| 2302 |
+
|
| 2303 |
+
# Encode audio (24kHz, mono)
|
| 2304 |
+
wav = torch.randn(1, 1, 24000 * 10) # [batch, channels, samples]
|
| 2305 |
+
with torch.no_grad():
|
| 2306 |
+
codes = mimi.encode(wav.cuda())
|
| 2307 |
+
decoded = mimi.decode(codes)`,
|
| 2308 |
+
];
|
| 2309 |
+
};
|
| 2310 |
+
exports.moshi = moshi;
|
| 2311 |
+
//#endregion
|
node_modules/@huggingface/tasks/dist/commonjs/model-libraries-snippets.spec.d.ts
ADDED
|
@@ -0,0 +1,2 @@
|
|
|
|
|
|
|
|
|
|
| 1 |
+
export {};
|
| 2 |
+
//# sourceMappingURL=model-libraries-snippets.spec.d.ts.map
|
node_modules/@huggingface/tasks/dist/commonjs/model-libraries-snippets.spec.d.ts.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
|
|
|
|
| 1 |
+
{"version":3,"file":"model-libraries-snippets.spec.d.ts","sourceRoot":"","sources":["../../src/model-libraries-snippets.spec.ts"],"names":[],"mappings":""}
|
node_modules/@huggingface/tasks/dist/commonjs/model-libraries-snippets.spec.js
ADDED
|
@@ -0,0 +1,55 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
"use strict";
|
| 2 |
+
Object.defineProperty(exports, "__esModule", { value: true });
|
| 3 |
+
const vitest_1 = require("vitest");
|
| 4 |
+
const model_libraries_snippets_js_1 = require("./model-libraries-snippets.js");
|
| 5 |
+
(0, vitest_1.describe)("model-libraries-snippets", () => {
|
| 6 |
+
(0, vitest_1.it)("llama_cpp_python conversational", async () => {
|
| 7 |
+
const model = {
|
| 8 |
+
id: "bartowski/Llama-3.2-3B-Instruct-GGUF",
|
| 9 |
+
pipeline_tag: "text-generation",
|
| 10 |
+
tags: ["conversational"],
|
| 11 |
+
inference: "",
|
| 12 |
+
};
|
| 13 |
+
const snippet = (0, model_libraries_snippets_js_1.llama_cpp_python)(model);
|
| 14 |
+
(0, vitest_1.expect)(snippet.join("\n")).toEqual(`# !pip install llama-cpp-python
|
| 15 |
+
|
| 16 |
+
from llama_cpp import Llama
|
| 17 |
+
|
| 18 |
+
llm = Llama.from_pretrained(
|
| 19 |
+
repo_id="bartowski/Llama-3.2-3B-Instruct-GGUF",
|
| 20 |
+
filename="{{GGUF_FILE}}",
|
| 21 |
+
)
|
| 22 |
+
|
| 23 |
+
llm.create_chat_completion(
|
| 24 |
+
messages = [
|
| 25 |
+
{
|
| 26 |
+
"role": "user",
|
| 27 |
+
"content": "What is the capital of France?"
|
| 28 |
+
}
|
| 29 |
+
]
|
| 30 |
+
)`);
|
| 31 |
+
});
|
| 32 |
+
(0, vitest_1.it)("llama_cpp_python non-conversational", async () => {
|
| 33 |
+
const model = {
|
| 34 |
+
id: "mlabonne/gemma-2b-GGUF",
|
| 35 |
+
tags: [""],
|
| 36 |
+
inference: "",
|
| 37 |
+
};
|
| 38 |
+
const snippet = (0, model_libraries_snippets_js_1.llama_cpp_python)(model);
|
| 39 |
+
(0, vitest_1.expect)(snippet.join("\n")).toEqual(`# !pip install llama-cpp-python
|
| 40 |
+
|
| 41 |
+
from llama_cpp import Llama
|
| 42 |
+
|
| 43 |
+
llm = Llama.from_pretrained(
|
| 44 |
+
repo_id="mlabonne/gemma-2b-GGUF",
|
| 45 |
+
filename="{{GGUF_FILE}}",
|
| 46 |
+
)
|
| 47 |
+
|
| 48 |
+
output = llm(
|
| 49 |
+
"Once upon a time,",
|
| 50 |
+
max_tokens=512,
|
| 51 |
+
echo=True
|
| 52 |
+
)
|
| 53 |
+
print(output)`);
|
| 54 |
+
});
|
| 55 |
+
});
|
node_modules/@huggingface/tasks/dist/commonjs/model-libraries.d.ts
ADDED
|
@@ -0,0 +1,1531 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|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
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
import type { ModelData } from "./model-data.js";
|
| 2 |
+
import type { ElasticSearchQuery } from "./model-libraries-downloads.js";
|
| 3 |
+
/**
|
| 4 |
+
* Elements configurable by a model library.
|
| 5 |
+
*/
|
| 6 |
+
export interface LibraryUiElement {
|
| 7 |
+
/**
|
| 8 |
+
* Pretty name of the library.
|
| 9 |
+
* displayed in tags, and on the main
|
| 10 |
+
* call-to-action button on the model page.
|
| 11 |
+
*/
|
| 12 |
+
prettyLabel: string;
|
| 13 |
+
/**
|
| 14 |
+
* Repo name of the library's (usually on GitHub) code repo
|
| 15 |
+
*/
|
| 16 |
+
repoName: string;
|
| 17 |
+
/**
|
| 18 |
+
* URL to library's (usually on GitHub) code repo
|
| 19 |
+
*/
|
| 20 |
+
repoUrl: string;
|
| 21 |
+
/**
|
| 22 |
+
* URL to library's docs
|
| 23 |
+
*/
|
| 24 |
+
docsUrl?: string;
|
| 25 |
+
/**
|
| 26 |
+
* Code snippet(s) displayed on model page
|
| 27 |
+
*/
|
| 28 |
+
snippets?: (model: ModelData) => string[];
|
| 29 |
+
/**
|
| 30 |
+
* Elastic query used to count this library's model downloads
|
| 31 |
+
*
|
| 32 |
+
* By default, those files are counted:
|
| 33 |
+
* "config.json", "config.yaml", "hyperparams.yaml", "params.json", "meta.yaml"
|
| 34 |
+
*/
|
| 35 |
+
countDownloads?: ElasticSearchQuery;
|
| 36 |
+
/**
|
| 37 |
+
* should we display this library in hf.co/models filter
|
| 38 |
+
* (only for popular libraries with > 100 models)
|
| 39 |
+
*/
|
| 40 |
+
filter?: boolean;
|
| 41 |
+
}
|
| 42 |
+
/**
|
| 43 |
+
* Add your new library here.
|
| 44 |
+
*
|
| 45 |
+
* This is for modeling (= architectures) libraries, not for file formats (like ONNX, etc).
|
| 46 |
+
* (unlike libraries, file formats live in an enum inside the internal codebase.)
|
| 47 |
+
*
|
| 48 |
+
* Doc on how to add a library to the Hub:
|
| 49 |
+
*
|
| 50 |
+
* https://huggingface.co/docs/hub/models-adding-libraries
|
| 51 |
+
*
|
| 52 |
+
* /!\ IMPORTANT
|
| 53 |
+
*
|
| 54 |
+
* The key you choose is the tag your models have in their library_name on the Hub.
|
| 55 |
+
*/
|
| 56 |
+
export declare const MODEL_LIBRARIES_UI_ELEMENTS: {
|
| 57 |
+
acestep: {
|
| 58 |
+
prettyLabel: string;
|
| 59 |
+
repoName: string;
|
| 60 |
+
repoUrl: string;
|
| 61 |
+
filter: false;
|
| 62 |
+
countDownloads: string;
|
| 63 |
+
};
|
| 64 |
+
"adapter-transformers": {
|
| 65 |
+
prettyLabel: string;
|
| 66 |
+
repoName: string;
|
| 67 |
+
repoUrl: string;
|
| 68 |
+
docsUrl: string;
|
| 69 |
+
snippets: (model: ModelData) => string[];
|
| 70 |
+
filter: true;
|
| 71 |
+
countDownloads: string;
|
| 72 |
+
};
|
| 73 |
+
allennlp: {
|
| 74 |
+
prettyLabel: string;
|
| 75 |
+
repoName: string;
|
| 76 |
+
repoUrl: string;
|
| 77 |
+
docsUrl: string;
|
| 78 |
+
snippets: (model: ModelData) => string[];
|
| 79 |
+
filter: true;
|
| 80 |
+
};
|
| 81 |
+
anemoi: {
|
| 82 |
+
prettyLabel: string;
|
| 83 |
+
repoName: string;
|
| 84 |
+
repoUrl: string;
|
| 85 |
+
docsUrl: string;
|
| 86 |
+
filter: false;
|
| 87 |
+
countDownloads: string;
|
| 88 |
+
snippets: (model: ModelData) => string[];
|
| 89 |
+
};
|
| 90 |
+
araclip: {
|
| 91 |
+
prettyLabel: string;
|
| 92 |
+
repoName: string;
|
| 93 |
+
repoUrl: string;
|
| 94 |
+
filter: false;
|
| 95 |
+
snippets: (model: ModelData) => string[];
|
| 96 |
+
};
|
| 97 |
+
"aviation-ner": {
|
| 98 |
+
prettyLabel: string;
|
| 99 |
+
repoName: string;
|
| 100 |
+
repoUrl: string;
|
| 101 |
+
docsUrl: string;
|
| 102 |
+
countDownloads: string;
|
| 103 |
+
filter: false;
|
| 104 |
+
};
|
| 105 |
+
asteroid: {
|
| 106 |
+
prettyLabel: string;
|
| 107 |
+
repoName: string;
|
| 108 |
+
repoUrl: string;
|
| 109 |
+
docsUrl: string;
|
| 110 |
+
snippets: (model: ModelData) => string[];
|
| 111 |
+
filter: true;
|
| 112 |
+
countDownloads: string;
|
| 113 |
+
};
|
| 114 |
+
audiocraft: {
|
| 115 |
+
prettyLabel: string;
|
| 116 |
+
repoName: string;
|
| 117 |
+
repoUrl: string;
|
| 118 |
+
snippets: (model: ModelData) => string[];
|
| 119 |
+
filter: false;
|
| 120 |
+
countDownloads: string;
|
| 121 |
+
};
|
| 122 |
+
audioseal: {
|
| 123 |
+
prettyLabel: string;
|
| 124 |
+
repoName: string;
|
| 125 |
+
repoUrl: string;
|
| 126 |
+
filter: false;
|
| 127 |
+
countDownloads: string;
|
| 128 |
+
snippets: (model: ModelData) => string[];
|
| 129 |
+
};
|
| 130 |
+
"bagel-mot": {
|
| 131 |
+
prettyLabel: string;
|
| 132 |
+
repoName: string;
|
| 133 |
+
repoUrl: string;
|
| 134 |
+
filter: false;
|
| 135 |
+
countDownloads: string;
|
| 136 |
+
};
|
| 137 |
+
bboxmaskpose: {
|
| 138 |
+
prettyLabel: string;
|
| 139 |
+
repoName: string;
|
| 140 |
+
repoUrl: string;
|
| 141 |
+
filter: false;
|
| 142 |
+
countDownloads: string;
|
| 143 |
+
};
|
| 144 |
+
ben2: {
|
| 145 |
+
prettyLabel: string;
|
| 146 |
+
repoName: string;
|
| 147 |
+
repoUrl: string;
|
| 148 |
+
snippets: (model: ModelData) => string[];
|
| 149 |
+
filter: false;
|
| 150 |
+
};
|
| 151 |
+
bertopic: {
|
| 152 |
+
prettyLabel: string;
|
| 153 |
+
repoName: string;
|
| 154 |
+
repoUrl: string;
|
| 155 |
+
snippets: (model: ModelData) => string[];
|
| 156 |
+
filter: true;
|
| 157 |
+
};
|
| 158 |
+
big_vision: {
|
| 159 |
+
prettyLabel: string;
|
| 160 |
+
repoName: string;
|
| 161 |
+
repoUrl: string;
|
| 162 |
+
filter: false;
|
| 163 |
+
countDownloads: string;
|
| 164 |
+
};
|
| 165 |
+
birder: {
|
| 166 |
+
prettyLabel: string;
|
| 167 |
+
repoName: string;
|
| 168 |
+
repoUrl: string;
|
| 169 |
+
filter: false;
|
| 170 |
+
countDownloads: string;
|
| 171 |
+
};
|
| 172 |
+
birefnet: {
|
| 173 |
+
prettyLabel: string;
|
| 174 |
+
repoName: string;
|
| 175 |
+
repoUrl: string;
|
| 176 |
+
snippets: (model: ModelData) => string[];
|
| 177 |
+
filter: false;
|
| 178 |
+
};
|
| 179 |
+
bm25s: {
|
| 180 |
+
prettyLabel: string;
|
| 181 |
+
repoName: string;
|
| 182 |
+
repoUrl: string;
|
| 183 |
+
snippets: (model: ModelData) => string[];
|
| 184 |
+
filter: false;
|
| 185 |
+
countDownloads: string;
|
| 186 |
+
};
|
| 187 |
+
boltzgen: {
|
| 188 |
+
prettyLabel: string;
|
| 189 |
+
repoName: string;
|
| 190 |
+
repoUrl: string;
|
| 191 |
+
filter: false;
|
| 192 |
+
countDownloads: string;
|
| 193 |
+
};
|
| 194 |
+
cancertathomev2: {
|
| 195 |
+
prettyLabel: string;
|
| 196 |
+
repoName: string;
|
| 197 |
+
repoUrl: string;
|
| 198 |
+
filter: false;
|
| 199 |
+
countDownloads: string;
|
| 200 |
+
};
|
| 201 |
+
cartesia_pytorch: {
|
| 202 |
+
prettyLabel: string;
|
| 203 |
+
repoName: string;
|
| 204 |
+
repoUrl: string;
|
| 205 |
+
snippets: (model: ModelData) => string[];
|
| 206 |
+
};
|
| 207 |
+
cartesia_mlx: {
|
| 208 |
+
prettyLabel: string;
|
| 209 |
+
repoName: string;
|
| 210 |
+
repoUrl: string;
|
| 211 |
+
snippets: (model: ModelData) => string[];
|
| 212 |
+
};
|
| 213 |
+
champ: {
|
| 214 |
+
prettyLabel: string;
|
| 215 |
+
repoName: string;
|
| 216 |
+
repoUrl: string;
|
| 217 |
+
countDownloads: string;
|
| 218 |
+
};
|
| 219 |
+
chatterbox: {
|
| 220 |
+
prettyLabel: string;
|
| 221 |
+
repoName: string;
|
| 222 |
+
repoUrl: string;
|
| 223 |
+
snippets: () => string[];
|
| 224 |
+
countDownloads: string;
|
| 225 |
+
filter: false;
|
| 226 |
+
};
|
| 227 |
+
chaossim: {
|
| 228 |
+
prettyLabel: string;
|
| 229 |
+
repoName: string;
|
| 230 |
+
repoUrl: string;
|
| 231 |
+
countDownloads: string;
|
| 232 |
+
filter: false;
|
| 233 |
+
};
|
| 234 |
+
chat_tts: {
|
| 235 |
+
prettyLabel: string;
|
| 236 |
+
repoName: string;
|
| 237 |
+
repoUrl: string;
|
| 238 |
+
snippets: () => string[];
|
| 239 |
+
filter: false;
|
| 240 |
+
countDownloads: string;
|
| 241 |
+
};
|
| 242 |
+
"chronos-forecasting": {
|
| 243 |
+
prettyLabel: string;
|
| 244 |
+
repoName: string;
|
| 245 |
+
repoUrl: string;
|
| 246 |
+
snippets: (model: ModelData) => string[];
|
| 247 |
+
};
|
| 248 |
+
clara: {
|
| 249 |
+
prettyLabel: string;
|
| 250 |
+
repoName: string;
|
| 251 |
+
filter: false;
|
| 252 |
+
repoUrl: string;
|
| 253 |
+
countDownloads: string;
|
| 254 |
+
};
|
| 255 |
+
clipscope: {
|
| 256 |
+
prettyLabel: string;
|
| 257 |
+
repoName: string;
|
| 258 |
+
repoUrl: string;
|
| 259 |
+
filter: false;
|
| 260 |
+
countDownloads: string;
|
| 261 |
+
};
|
| 262 |
+
"cloud-agents": {
|
| 263 |
+
prettyLabel: string;
|
| 264 |
+
repoName: string;
|
| 265 |
+
repoUrl: string;
|
| 266 |
+
filter: false;
|
| 267 |
+
countDownloads: string;
|
| 268 |
+
};
|
| 269 |
+
colipri: {
|
| 270 |
+
prettyLabel: string;
|
| 271 |
+
repoName: string;
|
| 272 |
+
repoUrl: string;
|
| 273 |
+
snippets: (model: ModelData) => string[];
|
| 274 |
+
filter: false;
|
| 275 |
+
countDownloads: string;
|
| 276 |
+
};
|
| 277 |
+
cosyvoice: {
|
| 278 |
+
prettyLabel: string;
|
| 279 |
+
repoName: string;
|
| 280 |
+
repoUrl: string;
|
| 281 |
+
filter: false;
|
| 282 |
+
countDownloads: string;
|
| 283 |
+
};
|
| 284 |
+
cotracker: {
|
| 285 |
+
prettyLabel: string;
|
| 286 |
+
repoName: string;
|
| 287 |
+
repoUrl: string;
|
| 288 |
+
filter: false;
|
| 289 |
+
countDownloads: string;
|
| 290 |
+
};
|
| 291 |
+
colpali: {
|
| 292 |
+
prettyLabel: string;
|
| 293 |
+
repoName: string;
|
| 294 |
+
repoUrl: string;
|
| 295 |
+
filter: false;
|
| 296 |
+
countDownloads: string;
|
| 297 |
+
};
|
| 298 |
+
comet: {
|
| 299 |
+
prettyLabel: string;
|
| 300 |
+
repoName: string;
|
| 301 |
+
repoUrl: string;
|
| 302 |
+
countDownloads: string;
|
| 303 |
+
};
|
| 304 |
+
cosmos: {
|
| 305 |
+
prettyLabel: string;
|
| 306 |
+
repoName: string;
|
| 307 |
+
repoUrl: string;
|
| 308 |
+
countDownloads: string;
|
| 309 |
+
};
|
| 310 |
+
"cxr-foundation": {
|
| 311 |
+
prettyLabel: string;
|
| 312 |
+
repoName: string;
|
| 313 |
+
repoUrl: string;
|
| 314 |
+
snippets: () => string[];
|
| 315 |
+
filter: false;
|
| 316 |
+
countDownloads: string;
|
| 317 |
+
};
|
| 318 |
+
deepforest: {
|
| 319 |
+
prettyLabel: string;
|
| 320 |
+
repoName: string;
|
| 321 |
+
docsUrl: string;
|
| 322 |
+
repoUrl: string;
|
| 323 |
+
};
|
| 324 |
+
"depth-anything-v2": {
|
| 325 |
+
prettyLabel: string;
|
| 326 |
+
repoName: string;
|
| 327 |
+
repoUrl: string;
|
| 328 |
+
snippets: (model: ModelData) => string[];
|
| 329 |
+
filter: false;
|
| 330 |
+
countDownloads: string;
|
| 331 |
+
};
|
| 332 |
+
"depth-pro": {
|
| 333 |
+
prettyLabel: string;
|
| 334 |
+
repoName: string;
|
| 335 |
+
repoUrl: string;
|
| 336 |
+
countDownloads: string;
|
| 337 |
+
snippets: (model: ModelData) => string[];
|
| 338 |
+
filter: false;
|
| 339 |
+
};
|
| 340 |
+
"derm-foundation": {
|
| 341 |
+
prettyLabel: string;
|
| 342 |
+
repoName: string;
|
| 343 |
+
repoUrl: string;
|
| 344 |
+
snippets: () => string[];
|
| 345 |
+
filter: false;
|
| 346 |
+
countDownloads: string;
|
| 347 |
+
};
|
| 348 |
+
"describe-anything": {
|
| 349 |
+
prettyLabel: string;
|
| 350 |
+
repoName: string;
|
| 351 |
+
repoUrl: string;
|
| 352 |
+
snippets: (model: ModelData) => string[];
|
| 353 |
+
filter: false;
|
| 354 |
+
};
|
| 355 |
+
"dia-tts": {
|
| 356 |
+
prettyLabel: string;
|
| 357 |
+
repoName: string;
|
| 358 |
+
repoUrl: string;
|
| 359 |
+
snippets: (model: ModelData) => string[];
|
| 360 |
+
filter: false;
|
| 361 |
+
};
|
| 362 |
+
dia2: {
|
| 363 |
+
prettyLabel: string;
|
| 364 |
+
repoName: string;
|
| 365 |
+
repoUrl: string;
|
| 366 |
+
snippets: (model: ModelData) => string[];
|
| 367 |
+
filter: false;
|
| 368 |
+
};
|
| 369 |
+
"diff-interpretation-tuning": {
|
| 370 |
+
prettyLabel: string;
|
| 371 |
+
repoName: string;
|
| 372 |
+
repoUrl: string;
|
| 373 |
+
filter: false;
|
| 374 |
+
countDownloads: string;
|
| 375 |
+
};
|
| 376 |
+
diffree: {
|
| 377 |
+
prettyLabel: string;
|
| 378 |
+
repoName: string;
|
| 379 |
+
repoUrl: string;
|
| 380 |
+
filter: false;
|
| 381 |
+
countDownloads: string;
|
| 382 |
+
};
|
| 383 |
+
diffusers: {
|
| 384 |
+
prettyLabel: string;
|
| 385 |
+
repoName: string;
|
| 386 |
+
repoUrl: string;
|
| 387 |
+
docsUrl: string;
|
| 388 |
+
snippets: (model: ModelData) => string[];
|
| 389 |
+
filter: true;
|
| 390 |
+
};
|
| 391 |
+
diffusionkit: {
|
| 392 |
+
prettyLabel: string;
|
| 393 |
+
repoName: string;
|
| 394 |
+
repoUrl: string;
|
| 395 |
+
snippets: (model: ModelData) => string[];
|
| 396 |
+
};
|
| 397 |
+
"docking-at-home": {
|
| 398 |
+
prettyLabel: string;
|
| 399 |
+
repoName: string;
|
| 400 |
+
repoUrl: string;
|
| 401 |
+
filter: false;
|
| 402 |
+
countDownloads: string;
|
| 403 |
+
};
|
| 404 |
+
doctr: {
|
| 405 |
+
prettyLabel: string;
|
| 406 |
+
repoName: string;
|
| 407 |
+
repoUrl: string;
|
| 408 |
+
};
|
| 409 |
+
edsnlp: {
|
| 410 |
+
prettyLabel: string;
|
| 411 |
+
repoName: string;
|
| 412 |
+
repoUrl: string;
|
| 413 |
+
docsUrl: string;
|
| 414 |
+
filter: false;
|
| 415 |
+
snippets: (model: ModelData) => string[];
|
| 416 |
+
countDownloads: string;
|
| 417 |
+
};
|
| 418 |
+
elm: {
|
| 419 |
+
prettyLabel: string;
|
| 420 |
+
repoName: string;
|
| 421 |
+
repoUrl: string;
|
| 422 |
+
filter: false;
|
| 423 |
+
countDownloads: string;
|
| 424 |
+
};
|
| 425 |
+
espnet: {
|
| 426 |
+
prettyLabel: string;
|
| 427 |
+
repoName: string;
|
| 428 |
+
repoUrl: string;
|
| 429 |
+
docsUrl: string;
|
| 430 |
+
snippets: (model: ModelData) => string[];
|
| 431 |
+
filter: true;
|
| 432 |
+
};
|
| 433 |
+
fairseq: {
|
| 434 |
+
prettyLabel: string;
|
| 435 |
+
repoName: string;
|
| 436 |
+
repoUrl: string;
|
| 437 |
+
snippets: (model: ModelData) => string[];
|
| 438 |
+
filter: true;
|
| 439 |
+
};
|
| 440 |
+
fastai: {
|
| 441 |
+
prettyLabel: string;
|
| 442 |
+
repoName: string;
|
| 443 |
+
repoUrl: string;
|
| 444 |
+
docsUrl: string;
|
| 445 |
+
snippets: (model: ModelData) => string[];
|
| 446 |
+
filter: true;
|
| 447 |
+
};
|
| 448 |
+
fastprint: {
|
| 449 |
+
prettyLabel: string;
|
| 450 |
+
repoName: string;
|
| 451 |
+
repoUrl: string;
|
| 452 |
+
countDownloads: string;
|
| 453 |
+
};
|
| 454 |
+
fasttext: {
|
| 455 |
+
prettyLabel: string;
|
| 456 |
+
repoName: string;
|
| 457 |
+
repoUrl: string;
|
| 458 |
+
snippets: (model: ModelData) => string[];
|
| 459 |
+
filter: true;
|
| 460 |
+
countDownloads: string;
|
| 461 |
+
};
|
| 462 |
+
fixer: {
|
| 463 |
+
prettyLabel: string;
|
| 464 |
+
repoName: string;
|
| 465 |
+
repoUrl: string;
|
| 466 |
+
filter: false;
|
| 467 |
+
countDownloads: string;
|
| 468 |
+
};
|
| 469 |
+
flair: {
|
| 470 |
+
prettyLabel: string;
|
| 471 |
+
repoName: string;
|
| 472 |
+
repoUrl: string;
|
| 473 |
+
docsUrl: string;
|
| 474 |
+
snippets: (model: ModelData) => string[];
|
| 475 |
+
filter: true;
|
| 476 |
+
countDownloads: string;
|
| 477 |
+
};
|
| 478 |
+
fme: {
|
| 479 |
+
prettyLabel: string;
|
| 480 |
+
repoName: string;
|
| 481 |
+
repoUrl: string;
|
| 482 |
+
docsUrl: string;
|
| 483 |
+
filter: false;
|
| 484 |
+
countDownloads: string;
|
| 485 |
+
};
|
| 486 |
+
"gemma.cpp": {
|
| 487 |
+
prettyLabel: string;
|
| 488 |
+
repoName: string;
|
| 489 |
+
repoUrl: string;
|
| 490 |
+
filter: false;
|
| 491 |
+
countDownloads: string;
|
| 492 |
+
};
|
| 493 |
+
"geometry-crafter": {
|
| 494 |
+
prettyLabel: string;
|
| 495 |
+
repoName: string;
|
| 496 |
+
repoUrl: string;
|
| 497 |
+
countDownloads: string;
|
| 498 |
+
};
|
| 499 |
+
gliner: {
|
| 500 |
+
prettyLabel: string;
|
| 501 |
+
repoName: string;
|
| 502 |
+
repoUrl: string;
|
| 503 |
+
snippets: (model: ModelData) => string[];
|
| 504 |
+
filter: false;
|
| 505 |
+
countDownloads: string;
|
| 506 |
+
};
|
| 507 |
+
gliner2: {
|
| 508 |
+
prettyLabel: string;
|
| 509 |
+
repoName: string;
|
| 510 |
+
repoUrl: string;
|
| 511 |
+
snippets: (model: ModelData) => string[];
|
| 512 |
+
filter: false;
|
| 513 |
+
};
|
| 514 |
+
"glm-tts": {
|
| 515 |
+
prettyLabel: string;
|
| 516 |
+
repoName: string;
|
| 517 |
+
repoUrl: string;
|
| 518 |
+
filter: false;
|
| 519 |
+
countDownloads: string;
|
| 520 |
+
};
|
| 521 |
+
"glyph-byt5": {
|
| 522 |
+
prettyLabel: string;
|
| 523 |
+
repoName: string;
|
| 524 |
+
repoUrl: string;
|
| 525 |
+
filter: false;
|
| 526 |
+
countDownloads: string;
|
| 527 |
+
};
|
| 528 |
+
grok: {
|
| 529 |
+
prettyLabel: string;
|
| 530 |
+
repoName: string;
|
| 531 |
+
repoUrl: string;
|
| 532 |
+
filter: false;
|
| 533 |
+
countDownloads: string;
|
| 534 |
+
};
|
| 535 |
+
"habibi-tts": {
|
| 536 |
+
prettyLabel: string;
|
| 537 |
+
repoName: string;
|
| 538 |
+
repoUrl: string;
|
| 539 |
+
filter: false;
|
| 540 |
+
countDownloads: string;
|
| 541 |
+
};
|
| 542 |
+
hallo: {
|
| 543 |
+
prettyLabel: string;
|
| 544 |
+
repoName: string;
|
| 545 |
+
repoUrl: string;
|
| 546 |
+
countDownloads: string;
|
| 547 |
+
};
|
| 548 |
+
hermes: {
|
| 549 |
+
prettyLabel: string;
|
| 550 |
+
repoName: string;
|
| 551 |
+
repoUrl: string;
|
| 552 |
+
filter: false;
|
| 553 |
+
countDownloads: string;
|
| 554 |
+
};
|
| 555 |
+
hezar: {
|
| 556 |
+
prettyLabel: string;
|
| 557 |
+
repoName: string;
|
| 558 |
+
repoUrl: string;
|
| 559 |
+
docsUrl: string;
|
| 560 |
+
countDownloads: string;
|
| 561 |
+
};
|
| 562 |
+
htrflow: {
|
| 563 |
+
prettyLabel: string;
|
| 564 |
+
repoName: string;
|
| 565 |
+
repoUrl: string;
|
| 566 |
+
docsUrl: string;
|
| 567 |
+
snippets: (model: ModelData) => string[];
|
| 568 |
+
};
|
| 569 |
+
"hunyuan-dit": {
|
| 570 |
+
prettyLabel: string;
|
| 571 |
+
repoName: string;
|
| 572 |
+
repoUrl: string;
|
| 573 |
+
countDownloads: string;
|
| 574 |
+
};
|
| 575 |
+
"hunyuan3d-2": {
|
| 576 |
+
prettyLabel: string;
|
| 577 |
+
repoName: string;
|
| 578 |
+
repoUrl: string;
|
| 579 |
+
countDownloads: string;
|
| 580 |
+
};
|
| 581 |
+
"hunyuanworld-voyager": {
|
| 582 |
+
prettyLabel: string;
|
| 583 |
+
repoName: string;
|
| 584 |
+
repoUrl: string;
|
| 585 |
+
};
|
| 586 |
+
"hy-worldplay": {
|
| 587 |
+
prettyLabel: string;
|
| 588 |
+
repoName: string;
|
| 589 |
+
repoUrl: string;
|
| 590 |
+
filter: false;
|
| 591 |
+
countDownloads: string;
|
| 592 |
+
};
|
| 593 |
+
"image-matching-models": {
|
| 594 |
+
prettyLabel: string;
|
| 595 |
+
repoName: string;
|
| 596 |
+
repoUrl: string;
|
| 597 |
+
filter: false;
|
| 598 |
+
countDownloads: string;
|
| 599 |
+
};
|
| 600 |
+
imstoucan: {
|
| 601 |
+
prettyLabel: string;
|
| 602 |
+
repoName: string;
|
| 603 |
+
repoUrl: string;
|
| 604 |
+
countDownloads: string;
|
| 605 |
+
};
|
| 606 |
+
"index-tts": {
|
| 607 |
+
prettyLabel: string;
|
| 608 |
+
repoName: string;
|
| 609 |
+
repoUrl: string;
|
| 610 |
+
snippets: (model: ModelData) => string[];
|
| 611 |
+
filter: false;
|
| 612 |
+
};
|
| 613 |
+
infinitetalk: {
|
| 614 |
+
prettyLabel: string;
|
| 615 |
+
repoName: string;
|
| 616 |
+
repoUrl: string;
|
| 617 |
+
filter: false;
|
| 618 |
+
countDownloads: string;
|
| 619 |
+
};
|
| 620 |
+
"infinite-you": {
|
| 621 |
+
prettyLabel: string;
|
| 622 |
+
repoName: string;
|
| 623 |
+
repoUrl: string;
|
| 624 |
+
filter: false;
|
| 625 |
+
countDownloads: string;
|
| 626 |
+
};
|
| 627 |
+
intellifold: {
|
| 628 |
+
prettyLabel: string;
|
| 629 |
+
repoName: string;
|
| 630 |
+
repoUrl: string;
|
| 631 |
+
filter: false;
|
| 632 |
+
countDownloads: string;
|
| 633 |
+
};
|
| 634 |
+
keras: {
|
| 635 |
+
prettyLabel: string;
|
| 636 |
+
repoName: string;
|
| 637 |
+
repoUrl: string;
|
| 638 |
+
docsUrl: string;
|
| 639 |
+
snippets: (model: ModelData) => string[];
|
| 640 |
+
filter: true;
|
| 641 |
+
countDownloads: string;
|
| 642 |
+
};
|
| 643 |
+
"tf-keras": {
|
| 644 |
+
prettyLabel: string;
|
| 645 |
+
repoName: string;
|
| 646 |
+
repoUrl: string;
|
| 647 |
+
docsUrl: string;
|
| 648 |
+
snippets: (model: ModelData) => string[];
|
| 649 |
+
countDownloads: string;
|
| 650 |
+
};
|
| 651 |
+
"keras-hub": {
|
| 652 |
+
prettyLabel: string;
|
| 653 |
+
repoName: string;
|
| 654 |
+
repoUrl: string;
|
| 655 |
+
docsUrl: string;
|
| 656 |
+
snippets: (model: ModelData) => string[];
|
| 657 |
+
filter: true;
|
| 658 |
+
};
|
| 659 |
+
kernels: {
|
| 660 |
+
prettyLabel: string;
|
| 661 |
+
repoName: string;
|
| 662 |
+
repoUrl: string;
|
| 663 |
+
docsUrl: string;
|
| 664 |
+
snippets: (model: ModelData) => string[];
|
| 665 |
+
countDownloads: string;
|
| 666 |
+
};
|
| 667 |
+
"kimi-audio": {
|
| 668 |
+
prettyLabel: string;
|
| 669 |
+
repoName: string;
|
| 670 |
+
repoUrl: string;
|
| 671 |
+
snippets: (model: ModelData) => string[];
|
| 672 |
+
filter: false;
|
| 673 |
+
};
|
| 674 |
+
kittentts: {
|
| 675 |
+
prettyLabel: string;
|
| 676 |
+
repoName: string;
|
| 677 |
+
repoUrl: string;
|
| 678 |
+
snippets: (model: ModelData) => string[];
|
| 679 |
+
};
|
| 680 |
+
kronos: {
|
| 681 |
+
prettyLabel: string;
|
| 682 |
+
repoName: string;
|
| 683 |
+
repoUrl: string;
|
| 684 |
+
filter: false;
|
| 685 |
+
countDownloads: string;
|
| 686 |
+
};
|
| 687 |
+
k2: {
|
| 688 |
+
prettyLabel: string;
|
| 689 |
+
repoName: string;
|
| 690 |
+
repoUrl: string;
|
| 691 |
+
};
|
| 692 |
+
"lightning-ir": {
|
| 693 |
+
prettyLabel: string;
|
| 694 |
+
repoName: string;
|
| 695 |
+
repoUrl: string;
|
| 696 |
+
snippets: (model: ModelData) => string[];
|
| 697 |
+
};
|
| 698 |
+
litert: {
|
| 699 |
+
prettyLabel: string;
|
| 700 |
+
repoName: string;
|
| 701 |
+
repoUrl: string;
|
| 702 |
+
filter: false;
|
| 703 |
+
countDownloads: string;
|
| 704 |
+
};
|
| 705 |
+
"litert-lm": {
|
| 706 |
+
prettyLabel: string;
|
| 707 |
+
repoName: string;
|
| 708 |
+
repoUrl: string;
|
| 709 |
+
filter: false;
|
| 710 |
+
countDownloads: string;
|
| 711 |
+
};
|
| 712 |
+
lerobot: {
|
| 713 |
+
prettyLabel: string;
|
| 714 |
+
repoName: string;
|
| 715 |
+
repoUrl: string;
|
| 716 |
+
docsUrl: string;
|
| 717 |
+
filter: false;
|
| 718 |
+
snippets: (model: ModelData) => string[];
|
| 719 |
+
};
|
| 720 |
+
lightglue: {
|
| 721 |
+
prettyLabel: string;
|
| 722 |
+
repoName: string;
|
| 723 |
+
repoUrl: string;
|
| 724 |
+
filter: false;
|
| 725 |
+
countDownloads: string;
|
| 726 |
+
};
|
| 727 |
+
liveportrait: {
|
| 728 |
+
prettyLabel: string;
|
| 729 |
+
repoName: string;
|
| 730 |
+
repoUrl: string;
|
| 731 |
+
filter: false;
|
| 732 |
+
countDownloads: string;
|
| 733 |
+
};
|
| 734 |
+
"llama-cpp-python": {
|
| 735 |
+
prettyLabel: string;
|
| 736 |
+
repoName: string;
|
| 737 |
+
repoUrl: string;
|
| 738 |
+
snippets: (model: ModelData) => string[];
|
| 739 |
+
};
|
| 740 |
+
"mini-omni2": {
|
| 741 |
+
prettyLabel: string;
|
| 742 |
+
repoName: string;
|
| 743 |
+
repoUrl: string;
|
| 744 |
+
countDownloads: string;
|
| 745 |
+
};
|
| 746 |
+
mindspore: {
|
| 747 |
+
prettyLabel: string;
|
| 748 |
+
repoName: string;
|
| 749 |
+
repoUrl: string;
|
| 750 |
+
};
|
| 751 |
+
"magi-1": {
|
| 752 |
+
prettyLabel: string;
|
| 753 |
+
repoName: string;
|
| 754 |
+
repoUrl: string;
|
| 755 |
+
countDownloads: string;
|
| 756 |
+
};
|
| 757 |
+
"magenta-realtime": {
|
| 758 |
+
prettyLabel: string;
|
| 759 |
+
repoName: string;
|
| 760 |
+
repoUrl: string;
|
| 761 |
+
countDownloads: string;
|
| 762 |
+
};
|
| 763 |
+
"mamba-ssm": {
|
| 764 |
+
prettyLabel: string;
|
| 765 |
+
repoName: string;
|
| 766 |
+
repoUrl: string;
|
| 767 |
+
filter: false;
|
| 768 |
+
snippets: (model: ModelData) => string[];
|
| 769 |
+
};
|
| 770 |
+
"mars5-tts": {
|
| 771 |
+
prettyLabel: string;
|
| 772 |
+
repoName: string;
|
| 773 |
+
repoUrl: string;
|
| 774 |
+
filter: false;
|
| 775 |
+
countDownloads: string;
|
| 776 |
+
snippets: (model: ModelData) => string[];
|
| 777 |
+
};
|
| 778 |
+
matanyone: {
|
| 779 |
+
prettyLabel: string;
|
| 780 |
+
repoName: string;
|
| 781 |
+
repoUrl: string;
|
| 782 |
+
snippets: (model: ModelData) => string[];
|
| 783 |
+
filter: false;
|
| 784 |
+
};
|
| 785 |
+
"mesh-anything": {
|
| 786 |
+
prettyLabel: string;
|
| 787 |
+
repoName: string;
|
| 788 |
+
repoUrl: string;
|
| 789 |
+
filter: false;
|
| 790 |
+
countDownloads: string;
|
| 791 |
+
snippets: () => string[];
|
| 792 |
+
};
|
| 793 |
+
merlin: {
|
| 794 |
+
prettyLabel: string;
|
| 795 |
+
repoName: string;
|
| 796 |
+
repoUrl: string;
|
| 797 |
+
filter: false;
|
| 798 |
+
countDownloads: string;
|
| 799 |
+
};
|
| 800 |
+
medvae: {
|
| 801 |
+
prettyLabel: string;
|
| 802 |
+
repoName: string;
|
| 803 |
+
repoUrl: string;
|
| 804 |
+
filter: false;
|
| 805 |
+
countDownloads: string;
|
| 806 |
+
};
|
| 807 |
+
mitie: {
|
| 808 |
+
prettyLabel: string;
|
| 809 |
+
repoName: string;
|
| 810 |
+
repoUrl: string;
|
| 811 |
+
countDownloads: string;
|
| 812 |
+
};
|
| 813 |
+
"ml-agents": {
|
| 814 |
+
prettyLabel: string;
|
| 815 |
+
repoName: string;
|
| 816 |
+
repoUrl: string;
|
| 817 |
+
docsUrl: string;
|
| 818 |
+
snippets: (model: ModelData) => string[];
|
| 819 |
+
filter: true;
|
| 820 |
+
countDownloads: string;
|
| 821 |
+
};
|
| 822 |
+
"ml-sharp": {
|
| 823 |
+
prettyLabel: string;
|
| 824 |
+
repoName: string;
|
| 825 |
+
repoUrl: string;
|
| 826 |
+
filter: false;
|
| 827 |
+
countDownloads: string;
|
| 828 |
+
};
|
| 829 |
+
mlx: {
|
| 830 |
+
prettyLabel: string;
|
| 831 |
+
repoName: string;
|
| 832 |
+
repoUrl: string;
|
| 833 |
+
snippets: (model: ModelData) => string[];
|
| 834 |
+
filter: true;
|
| 835 |
+
};
|
| 836 |
+
"mlx-image": {
|
| 837 |
+
prettyLabel: string;
|
| 838 |
+
repoName: string;
|
| 839 |
+
repoUrl: string;
|
| 840 |
+
docsUrl: string;
|
| 841 |
+
snippets: (model: ModelData) => string[];
|
| 842 |
+
filter: false;
|
| 843 |
+
countDownloads: string;
|
| 844 |
+
};
|
| 845 |
+
"mlc-llm": {
|
| 846 |
+
prettyLabel: string;
|
| 847 |
+
repoName: string;
|
| 848 |
+
repoUrl: string;
|
| 849 |
+
docsUrl: string;
|
| 850 |
+
filter: false;
|
| 851 |
+
countDownloads: string;
|
| 852 |
+
};
|
| 853 |
+
model2vec: {
|
| 854 |
+
prettyLabel: string;
|
| 855 |
+
repoName: string;
|
| 856 |
+
repoUrl: string;
|
| 857 |
+
snippets: (model: ModelData) => string[];
|
| 858 |
+
filter: false;
|
| 859 |
+
};
|
| 860 |
+
moshi: {
|
| 861 |
+
prettyLabel: string;
|
| 862 |
+
repoName: string;
|
| 863 |
+
repoUrl: string;
|
| 864 |
+
snippets: (model: ModelData) => string[];
|
| 865 |
+
filter: false;
|
| 866 |
+
countDownloads: string;
|
| 867 |
+
};
|
| 868 |
+
mtvcraft: {
|
| 869 |
+
prettyLabel: string;
|
| 870 |
+
repoName: string;
|
| 871 |
+
repoUrl: string;
|
| 872 |
+
filter: false;
|
| 873 |
+
countDownloads: string;
|
| 874 |
+
};
|
| 875 |
+
nemo: {
|
| 876 |
+
prettyLabel: string;
|
| 877 |
+
repoName: string;
|
| 878 |
+
repoUrl: string;
|
| 879 |
+
snippets: (model: ModelData) => string[];
|
| 880 |
+
filter: true;
|
| 881 |
+
countDownloads: string;
|
| 882 |
+
};
|
| 883 |
+
"open-oasis": {
|
| 884 |
+
prettyLabel: string;
|
| 885 |
+
repoName: string;
|
| 886 |
+
repoUrl: string;
|
| 887 |
+
countDownloads: string;
|
| 888 |
+
};
|
| 889 |
+
open_clip: {
|
| 890 |
+
prettyLabel: string;
|
| 891 |
+
repoName: string;
|
| 892 |
+
repoUrl: string;
|
| 893 |
+
snippets: (model: ModelData) => string[];
|
| 894 |
+
filter: true;
|
| 895 |
+
countDownloads: string;
|
| 896 |
+
};
|
| 897 |
+
openpeerllm: {
|
| 898 |
+
prettyLabel: string;
|
| 899 |
+
repoName: string;
|
| 900 |
+
repoUrl: string;
|
| 901 |
+
docsUrl: string;
|
| 902 |
+
countDownloads: string;
|
| 903 |
+
filter: false;
|
| 904 |
+
};
|
| 905 |
+
"open-sora": {
|
| 906 |
+
prettyLabel: string;
|
| 907 |
+
repoName: string;
|
| 908 |
+
repoUrl: string;
|
| 909 |
+
filter: false;
|
| 910 |
+
countDownloads: string;
|
| 911 |
+
};
|
| 912 |
+
outetts: {
|
| 913 |
+
prettyLabel: string;
|
| 914 |
+
repoName: string;
|
| 915 |
+
repoUrl: string;
|
| 916 |
+
snippets: (model: ModelData) => string[];
|
| 917 |
+
filter: false;
|
| 918 |
+
};
|
| 919 |
+
paddlenlp: {
|
| 920 |
+
prettyLabel: string;
|
| 921 |
+
repoName: string;
|
| 922 |
+
repoUrl: string;
|
| 923 |
+
docsUrl: string;
|
| 924 |
+
snippets: (model: ModelData) => string[];
|
| 925 |
+
filter: true;
|
| 926 |
+
countDownloads: string;
|
| 927 |
+
};
|
| 928 |
+
PaddleOCR: {
|
| 929 |
+
prettyLabel: string;
|
| 930 |
+
repoName: string;
|
| 931 |
+
repoUrl: string;
|
| 932 |
+
docsUrl: string;
|
| 933 |
+
snippets: (model: ModelData) => string[];
|
| 934 |
+
filter: true;
|
| 935 |
+
countDownloads: string;
|
| 936 |
+
};
|
| 937 |
+
peft: {
|
| 938 |
+
prettyLabel: string;
|
| 939 |
+
repoName: string;
|
| 940 |
+
repoUrl: string;
|
| 941 |
+
snippets: (model: ModelData) => string[];
|
| 942 |
+
filter: true;
|
| 943 |
+
countDownloads: string;
|
| 944 |
+
};
|
| 945 |
+
"perception-encoder": {
|
| 946 |
+
prettyLabel: string;
|
| 947 |
+
repoName: string;
|
| 948 |
+
repoUrl: string;
|
| 949 |
+
filter: false;
|
| 950 |
+
snippets: (model: ModelData) => string[];
|
| 951 |
+
countDownloads: string;
|
| 952 |
+
};
|
| 953 |
+
"phantom-wan": {
|
| 954 |
+
prettyLabel: string;
|
| 955 |
+
repoName: string;
|
| 956 |
+
repoUrl: string;
|
| 957 |
+
snippets: (model: ModelData) => string[];
|
| 958 |
+
filter: false;
|
| 959 |
+
countDownloads: string;
|
| 960 |
+
};
|
| 961 |
+
"pocket-tts": {
|
| 962 |
+
prettyLabel: string;
|
| 963 |
+
repoName: string;
|
| 964 |
+
repoUrl: string;
|
| 965 |
+
snippets: (model: ModelData) => string[];
|
| 966 |
+
filter: false;
|
| 967 |
+
countDownloads: string;
|
| 968 |
+
};
|
| 969 |
+
"pruna-ai": {
|
| 970 |
+
prettyLabel: string;
|
| 971 |
+
repoName: string;
|
| 972 |
+
repoUrl: string;
|
| 973 |
+
snippets: (model: ModelData) => string[];
|
| 974 |
+
docsUrl: string;
|
| 975 |
+
};
|
| 976 |
+
pxia: {
|
| 977 |
+
prettyLabel: string;
|
| 978 |
+
repoName: string;
|
| 979 |
+
repoUrl: string;
|
| 980 |
+
snippets: (model: ModelData) => string[];
|
| 981 |
+
filter: false;
|
| 982 |
+
};
|
| 983 |
+
"pyannote-audio": {
|
| 984 |
+
prettyLabel: string;
|
| 985 |
+
repoName: string;
|
| 986 |
+
repoUrl: string;
|
| 987 |
+
snippets: (model: ModelData) => string[];
|
| 988 |
+
filter: true;
|
| 989 |
+
};
|
| 990 |
+
"py-feat": {
|
| 991 |
+
prettyLabel: string;
|
| 992 |
+
repoName: string;
|
| 993 |
+
repoUrl: string;
|
| 994 |
+
docsUrl: string;
|
| 995 |
+
filter: false;
|
| 996 |
+
};
|
| 997 |
+
pythae: {
|
| 998 |
+
prettyLabel: string;
|
| 999 |
+
repoName: string;
|
| 1000 |
+
repoUrl: string;
|
| 1001 |
+
snippets: (model: ModelData) => string[];
|
| 1002 |
+
filter: false;
|
| 1003 |
+
};
|
| 1004 |
+
quantumpeer: {
|
| 1005 |
+
prettyLabel: string;
|
| 1006 |
+
repoName: string;
|
| 1007 |
+
repoUrl: string;
|
| 1008 |
+
filter: false;
|
| 1009 |
+
countDownloads: string;
|
| 1010 |
+
};
|
| 1011 |
+
qwen3_tts: {
|
| 1012 |
+
prettyLabel: string;
|
| 1013 |
+
repoName: string;
|
| 1014 |
+
repoUrl: string;
|
| 1015 |
+
snippets: (model: ModelData) => string[];
|
| 1016 |
+
filter: false;
|
| 1017 |
+
};
|
| 1018 |
+
recurrentgemma: {
|
| 1019 |
+
prettyLabel: string;
|
| 1020 |
+
repoName: string;
|
| 1021 |
+
repoUrl: string;
|
| 1022 |
+
filter: false;
|
| 1023 |
+
countDownloads: string;
|
| 1024 |
+
};
|
| 1025 |
+
relik: {
|
| 1026 |
+
prettyLabel: string;
|
| 1027 |
+
repoName: string;
|
| 1028 |
+
repoUrl: string;
|
| 1029 |
+
snippets: (model: ModelData) => string[];
|
| 1030 |
+
filter: false;
|
| 1031 |
+
};
|
| 1032 |
+
refiners: {
|
| 1033 |
+
prettyLabel: string;
|
| 1034 |
+
repoName: string;
|
| 1035 |
+
repoUrl: string;
|
| 1036 |
+
docsUrl: string;
|
| 1037 |
+
filter: false;
|
| 1038 |
+
countDownloads: string;
|
| 1039 |
+
};
|
| 1040 |
+
renderformer: {
|
| 1041 |
+
prettyLabel: string;
|
| 1042 |
+
repoName: string;
|
| 1043 |
+
repoUrl: string;
|
| 1044 |
+
snippets: (model: ModelData) => string[];
|
| 1045 |
+
filter: false;
|
| 1046 |
+
};
|
| 1047 |
+
reverb: {
|
| 1048 |
+
prettyLabel: string;
|
| 1049 |
+
repoName: string;
|
| 1050 |
+
repoUrl: string;
|
| 1051 |
+
filter: false;
|
| 1052 |
+
};
|
| 1053 |
+
rkllm: {
|
| 1054 |
+
prettyLabel: string;
|
| 1055 |
+
repoName: string;
|
| 1056 |
+
repoUrl: string;
|
| 1057 |
+
countDownloads: string;
|
| 1058 |
+
};
|
| 1059 |
+
saelens: {
|
| 1060 |
+
prettyLabel: string;
|
| 1061 |
+
repoName: string;
|
| 1062 |
+
repoUrl: string;
|
| 1063 |
+
snippets: () => string[];
|
| 1064 |
+
filter: false;
|
| 1065 |
+
};
|
| 1066 |
+
sam2: {
|
| 1067 |
+
prettyLabel: string;
|
| 1068 |
+
repoName: string;
|
| 1069 |
+
repoUrl: string;
|
| 1070 |
+
filter: false;
|
| 1071 |
+
snippets: (model: ModelData) => string[];
|
| 1072 |
+
countDownloads: string;
|
| 1073 |
+
};
|
| 1074 |
+
"sam-3d-body": {
|
| 1075 |
+
prettyLabel: string;
|
| 1076 |
+
repoName: string;
|
| 1077 |
+
repoUrl: string;
|
| 1078 |
+
filter: false;
|
| 1079 |
+
snippets: (model: ModelData) => string[];
|
| 1080 |
+
countDownloads: string;
|
| 1081 |
+
};
|
| 1082 |
+
"sam-3d-objects": {
|
| 1083 |
+
prettyLabel: string;
|
| 1084 |
+
repoName: string;
|
| 1085 |
+
repoUrl: string;
|
| 1086 |
+
filter: false;
|
| 1087 |
+
snippets: (model: ModelData) => string[];
|
| 1088 |
+
countDownloads: string;
|
| 1089 |
+
};
|
| 1090 |
+
same: {
|
| 1091 |
+
prettyLabel: string;
|
| 1092 |
+
repoName: string;
|
| 1093 |
+
repoUrl: string;
|
| 1094 |
+
filter: false;
|
| 1095 |
+
countDownloads: string;
|
| 1096 |
+
};
|
| 1097 |
+
"sample-factory": {
|
| 1098 |
+
prettyLabel: string;
|
| 1099 |
+
repoName: string;
|
| 1100 |
+
repoUrl: string;
|
| 1101 |
+
docsUrl: string;
|
| 1102 |
+
snippets: (model: ModelData) => string[];
|
| 1103 |
+
filter: true;
|
| 1104 |
+
countDownloads: string;
|
| 1105 |
+
};
|
| 1106 |
+
"sap-rpt-1-oss": {
|
| 1107 |
+
prettyLabel: string;
|
| 1108 |
+
repoName: string;
|
| 1109 |
+
repoUrl: string;
|
| 1110 |
+
countDownloads: string;
|
| 1111 |
+
snippets: () => string[];
|
| 1112 |
+
};
|
| 1113 |
+
sapiens: {
|
| 1114 |
+
prettyLabel: string;
|
| 1115 |
+
repoName: string;
|
| 1116 |
+
repoUrl: string;
|
| 1117 |
+
filter: false;
|
| 1118 |
+
countDownloads: string;
|
| 1119 |
+
};
|
| 1120 |
+
seedvr: {
|
| 1121 |
+
prettyLabel: string;
|
| 1122 |
+
repoName: string;
|
| 1123 |
+
repoUrl: string;
|
| 1124 |
+
filter: false;
|
| 1125 |
+
countDownloads: string;
|
| 1126 |
+
};
|
| 1127 |
+
"self-forcing": {
|
| 1128 |
+
prettyLabel: string;
|
| 1129 |
+
repoName: string;
|
| 1130 |
+
repoUrl: string;
|
| 1131 |
+
filter: false;
|
| 1132 |
+
countDownloads: string;
|
| 1133 |
+
};
|
| 1134 |
+
"sentence-transformers": {
|
| 1135 |
+
prettyLabel: string;
|
| 1136 |
+
repoName: string;
|
| 1137 |
+
repoUrl: string;
|
| 1138 |
+
docsUrl: string;
|
| 1139 |
+
snippets: (model: ModelData) => string[];
|
| 1140 |
+
filter: true;
|
| 1141 |
+
};
|
| 1142 |
+
setfit: {
|
| 1143 |
+
prettyLabel: string;
|
| 1144 |
+
repoName: string;
|
| 1145 |
+
repoUrl: string;
|
| 1146 |
+
docsUrl: string;
|
| 1147 |
+
snippets: (model: ModelData) => string[];
|
| 1148 |
+
filter: true;
|
| 1149 |
+
};
|
| 1150 |
+
sklearn: {
|
| 1151 |
+
prettyLabel: string;
|
| 1152 |
+
repoName: string;
|
| 1153 |
+
repoUrl: string;
|
| 1154 |
+
snippets: (model: ModelData) => string[];
|
| 1155 |
+
filter: true;
|
| 1156 |
+
countDownloads: string;
|
| 1157 |
+
};
|
| 1158 |
+
spacy: {
|
| 1159 |
+
prettyLabel: string;
|
| 1160 |
+
repoName: string;
|
| 1161 |
+
repoUrl: string;
|
| 1162 |
+
docsUrl: string;
|
| 1163 |
+
snippets: (model: ModelData) => string[];
|
| 1164 |
+
filter: true;
|
| 1165 |
+
countDownloads: string;
|
| 1166 |
+
};
|
| 1167 |
+
"span-marker": {
|
| 1168 |
+
prettyLabel: string;
|
| 1169 |
+
repoName: string;
|
| 1170 |
+
repoUrl: string;
|
| 1171 |
+
docsUrl: string;
|
| 1172 |
+
snippets: (model: ModelData) => string[];
|
| 1173 |
+
filter: true;
|
| 1174 |
+
};
|
| 1175 |
+
speechbrain: {
|
| 1176 |
+
prettyLabel: string;
|
| 1177 |
+
repoName: string;
|
| 1178 |
+
repoUrl: string;
|
| 1179 |
+
docsUrl: string;
|
| 1180 |
+
snippets: (model: ModelData) => string[];
|
| 1181 |
+
filter: true;
|
| 1182 |
+
countDownloads: string;
|
| 1183 |
+
};
|
| 1184 |
+
"ssr-speech": {
|
| 1185 |
+
prettyLabel: string;
|
| 1186 |
+
repoName: string;
|
| 1187 |
+
repoUrl: string;
|
| 1188 |
+
filter: false;
|
| 1189 |
+
countDownloads: string;
|
| 1190 |
+
};
|
| 1191 |
+
"stable-audio-tools": {
|
| 1192 |
+
prettyLabel: string;
|
| 1193 |
+
repoName: string;
|
| 1194 |
+
repoUrl: string;
|
| 1195 |
+
filter: false;
|
| 1196 |
+
countDownloads: string;
|
| 1197 |
+
snippets: (model: ModelData) => string[];
|
| 1198 |
+
};
|
| 1199 |
+
monkeyocr: {
|
| 1200 |
+
prettyLabel: string;
|
| 1201 |
+
repoName: string;
|
| 1202 |
+
repoUrl: string;
|
| 1203 |
+
filter: false;
|
| 1204 |
+
countDownloads: string;
|
| 1205 |
+
};
|
| 1206 |
+
"diffusion-single-file": {
|
| 1207 |
+
prettyLabel: string;
|
| 1208 |
+
repoName: string;
|
| 1209 |
+
repoUrl: string;
|
| 1210 |
+
filter: false;
|
| 1211 |
+
countDownloads: string;
|
| 1212 |
+
};
|
| 1213 |
+
"seed-story": {
|
| 1214 |
+
prettyLabel: string;
|
| 1215 |
+
repoName: string;
|
| 1216 |
+
repoUrl: string;
|
| 1217 |
+
filter: false;
|
| 1218 |
+
countDownloads: string;
|
| 1219 |
+
snippets: () => string[];
|
| 1220 |
+
};
|
| 1221 |
+
soloaudio: {
|
| 1222 |
+
prettyLabel: string;
|
| 1223 |
+
repoName: string;
|
| 1224 |
+
repoUrl: string;
|
| 1225 |
+
filter: false;
|
| 1226 |
+
countDownloads: string;
|
| 1227 |
+
};
|
| 1228 |
+
songbloom: {
|
| 1229 |
+
prettyLabel: string;
|
| 1230 |
+
repoName: string;
|
| 1231 |
+
repoUrl: string;
|
| 1232 |
+
filter: false;
|
| 1233 |
+
countDownloads: string;
|
| 1234 |
+
};
|
| 1235 |
+
"stable-baselines3": {
|
| 1236 |
+
prettyLabel: string;
|
| 1237 |
+
repoName: string;
|
| 1238 |
+
repoUrl: string;
|
| 1239 |
+
docsUrl: string;
|
| 1240 |
+
snippets: (model: ModelData) => string[];
|
| 1241 |
+
filter: true;
|
| 1242 |
+
countDownloads: string;
|
| 1243 |
+
};
|
| 1244 |
+
stanza: {
|
| 1245 |
+
prettyLabel: string;
|
| 1246 |
+
repoName: string;
|
| 1247 |
+
repoUrl: string;
|
| 1248 |
+
docsUrl: string;
|
| 1249 |
+
snippets: (model: ModelData) => string[];
|
| 1250 |
+
filter: true;
|
| 1251 |
+
countDownloads: string;
|
| 1252 |
+
};
|
| 1253 |
+
supertonic: {
|
| 1254 |
+
prettyLabel: string;
|
| 1255 |
+
repoName: string;
|
| 1256 |
+
repoUrl: string;
|
| 1257 |
+
snippets: () => string[];
|
| 1258 |
+
filter: false;
|
| 1259 |
+
};
|
| 1260 |
+
swarmformer: {
|
| 1261 |
+
prettyLabel: string;
|
| 1262 |
+
repoName: string;
|
| 1263 |
+
repoUrl: string;
|
| 1264 |
+
snippets: (model: ModelData) => string[];
|
| 1265 |
+
filter: false;
|
| 1266 |
+
};
|
| 1267 |
+
"f5-tts": {
|
| 1268 |
+
prettyLabel: string;
|
| 1269 |
+
repoName: string;
|
| 1270 |
+
repoUrl: string;
|
| 1271 |
+
filter: false;
|
| 1272 |
+
countDownloads: string;
|
| 1273 |
+
};
|
| 1274 |
+
genmo: {
|
| 1275 |
+
prettyLabel: string;
|
| 1276 |
+
repoName: string;
|
| 1277 |
+
repoUrl: string;
|
| 1278 |
+
filter: false;
|
| 1279 |
+
countDownloads: string;
|
| 1280 |
+
};
|
| 1281 |
+
"tencent-song-generation": {
|
| 1282 |
+
prettyLabel: string;
|
| 1283 |
+
repoName: string;
|
| 1284 |
+
repoUrl: string;
|
| 1285 |
+
filter: false;
|
| 1286 |
+
countDownloads: string;
|
| 1287 |
+
};
|
| 1288 |
+
tensorflowtts: {
|
| 1289 |
+
prettyLabel: string;
|
| 1290 |
+
repoName: string;
|
| 1291 |
+
repoUrl: string;
|
| 1292 |
+
snippets: (model: ModelData) => string[];
|
| 1293 |
+
};
|
| 1294 |
+
tensorrt: {
|
| 1295 |
+
prettyLabel: string;
|
| 1296 |
+
repoName: string;
|
| 1297 |
+
repoUrl: string;
|
| 1298 |
+
countDownloads: string;
|
| 1299 |
+
};
|
| 1300 |
+
tabpfn: {
|
| 1301 |
+
prettyLabel: string;
|
| 1302 |
+
repoName: string;
|
| 1303 |
+
repoUrl: string;
|
| 1304 |
+
};
|
| 1305 |
+
terratorch: {
|
| 1306 |
+
prettyLabel: string;
|
| 1307 |
+
repoName: string;
|
| 1308 |
+
repoUrl: string;
|
| 1309 |
+
docsUrl: string;
|
| 1310 |
+
filter: false;
|
| 1311 |
+
countDownloads: string;
|
| 1312 |
+
snippets: (model: ModelData) => string[];
|
| 1313 |
+
};
|
| 1314 |
+
"tic-clip": {
|
| 1315 |
+
prettyLabel: string;
|
| 1316 |
+
repoName: string;
|
| 1317 |
+
repoUrl: string;
|
| 1318 |
+
filter: false;
|
| 1319 |
+
countDownloads: string;
|
| 1320 |
+
};
|
| 1321 |
+
timesfm: {
|
| 1322 |
+
prettyLabel: string;
|
| 1323 |
+
repoName: string;
|
| 1324 |
+
repoUrl: string;
|
| 1325 |
+
filter: false;
|
| 1326 |
+
countDownloads: string;
|
| 1327 |
+
};
|
| 1328 |
+
timm: {
|
| 1329 |
+
prettyLabel: string;
|
| 1330 |
+
repoName: string;
|
| 1331 |
+
repoUrl: string;
|
| 1332 |
+
docsUrl: string;
|
| 1333 |
+
snippets: (model: ModelData) => string[];
|
| 1334 |
+
filter: true;
|
| 1335 |
+
countDownloads: string;
|
| 1336 |
+
};
|
| 1337 |
+
tirex: {
|
| 1338 |
+
prettyLabel: string;
|
| 1339 |
+
repoName: string;
|
| 1340 |
+
repoUrl: string;
|
| 1341 |
+
countDownloads: string;
|
| 1342 |
+
};
|
| 1343 |
+
torchgeo: {
|
| 1344 |
+
prettyLabel: string;
|
| 1345 |
+
repoName: string;
|
| 1346 |
+
repoUrl: string;
|
| 1347 |
+
docsUrl: string;
|
| 1348 |
+
filter: false;
|
| 1349 |
+
countDownloads: string;
|
| 1350 |
+
};
|
| 1351 |
+
transformers: {
|
| 1352 |
+
prettyLabel: string;
|
| 1353 |
+
repoName: string;
|
| 1354 |
+
repoUrl: string;
|
| 1355 |
+
docsUrl: string;
|
| 1356 |
+
snippets: (model: ModelData) => string[];
|
| 1357 |
+
filter: true;
|
| 1358 |
+
};
|
| 1359 |
+
"transformers.js": {
|
| 1360 |
+
prettyLabel: string;
|
| 1361 |
+
repoName: string;
|
| 1362 |
+
repoUrl: string;
|
| 1363 |
+
docsUrl: string;
|
| 1364 |
+
snippets: (model: ModelData) => string[];
|
| 1365 |
+
filter: true;
|
| 1366 |
+
};
|
| 1367 |
+
trellis: {
|
| 1368 |
+
prettyLabel: string;
|
| 1369 |
+
repoName: string;
|
| 1370 |
+
repoUrl: string;
|
| 1371 |
+
countDownloads: string;
|
| 1372 |
+
};
|
| 1373 |
+
ultralytics: {
|
| 1374 |
+
prettyLabel: string;
|
| 1375 |
+
repoName: string;
|
| 1376 |
+
repoUrl: string;
|
| 1377 |
+
docsUrl: string;
|
| 1378 |
+
filter: false;
|
| 1379 |
+
countDownloads: string;
|
| 1380 |
+
snippets: (model: ModelData) => string[];
|
| 1381 |
+
};
|
| 1382 |
+
univa: {
|
| 1383 |
+
prettyLabel: string;
|
| 1384 |
+
repoName: string;
|
| 1385 |
+
repoUrl: string;
|
| 1386 |
+
snippets: (model: ModelData) => string[];
|
| 1387 |
+
filter: true;
|
| 1388 |
+
countDownloads: string;
|
| 1389 |
+
};
|
| 1390 |
+
"uni-3dar": {
|
| 1391 |
+
prettyLabel: string;
|
| 1392 |
+
repoName: string;
|
| 1393 |
+
repoUrl: string;
|
| 1394 |
+
docsUrl: string;
|
| 1395 |
+
countDownloads: string;
|
| 1396 |
+
};
|
| 1397 |
+
"unity-sentis": {
|
| 1398 |
+
prettyLabel: string;
|
| 1399 |
+
repoName: string;
|
| 1400 |
+
repoUrl: string;
|
| 1401 |
+
snippets: () => string[];
|
| 1402 |
+
filter: true;
|
| 1403 |
+
countDownloads: string;
|
| 1404 |
+
};
|
| 1405 |
+
sana: {
|
| 1406 |
+
prettyLabel: string;
|
| 1407 |
+
repoName: string;
|
| 1408 |
+
repoUrl: string;
|
| 1409 |
+
countDownloads: string;
|
| 1410 |
+
snippets: (model: ModelData) => string[];
|
| 1411 |
+
};
|
| 1412 |
+
videoprism: {
|
| 1413 |
+
prettyLabel: string;
|
| 1414 |
+
repoName: string;
|
| 1415 |
+
repoUrl: string;
|
| 1416 |
+
countDownloads: string;
|
| 1417 |
+
snippets: (model: ModelData) => string[];
|
| 1418 |
+
};
|
| 1419 |
+
"vfi-mamba": {
|
| 1420 |
+
prettyLabel: string;
|
| 1421 |
+
repoName: string;
|
| 1422 |
+
repoUrl: string;
|
| 1423 |
+
countDownloads: string;
|
| 1424 |
+
snippets: (model: ModelData) => string[];
|
| 1425 |
+
};
|
| 1426 |
+
vismatch: {
|
| 1427 |
+
prettyLabel: string;
|
| 1428 |
+
repoName: string;
|
| 1429 |
+
repoUrl: string;
|
| 1430 |
+
filter: false;
|
| 1431 |
+
countDownloads: string;
|
| 1432 |
+
};
|
| 1433 |
+
lvface: {
|
| 1434 |
+
prettyLabel: string;
|
| 1435 |
+
repoName: string;
|
| 1436 |
+
repoUrl: string;
|
| 1437 |
+
countDownloads: string;
|
| 1438 |
+
snippets: (model: ModelData) => string[];
|
| 1439 |
+
};
|
| 1440 |
+
voicecraft: {
|
| 1441 |
+
prettyLabel: string;
|
| 1442 |
+
repoName: string;
|
| 1443 |
+
repoUrl: string;
|
| 1444 |
+
docsUrl: string;
|
| 1445 |
+
snippets: (model: ModelData) => string[];
|
| 1446 |
+
};
|
| 1447 |
+
voxcpm: {
|
| 1448 |
+
prettyLabel: string;
|
| 1449 |
+
repoName: string;
|
| 1450 |
+
repoUrl: string;
|
| 1451 |
+
snippets: (model: ModelData) => string[];
|
| 1452 |
+
filter: false;
|
| 1453 |
+
};
|
| 1454 |
+
vui: {
|
| 1455 |
+
prettyLabel: string;
|
| 1456 |
+
repoName: string;
|
| 1457 |
+
repoUrl: string;
|
| 1458 |
+
countDownloads: string;
|
| 1459 |
+
snippets: () => string[];
|
| 1460 |
+
};
|
| 1461 |
+
vibevoice: {
|
| 1462 |
+
prettyLabel: string;
|
| 1463 |
+
repoName: string;
|
| 1464 |
+
repoUrl: string;
|
| 1465 |
+
snippets: (model: ModelData) => string[];
|
| 1466 |
+
filter: false;
|
| 1467 |
+
};
|
| 1468 |
+
videox_fun: {
|
| 1469 |
+
prettyLabel: string;
|
| 1470 |
+
repoName: string;
|
| 1471 |
+
repoUrl: string;
|
| 1472 |
+
filter: false;
|
| 1473 |
+
countDownloads: string;
|
| 1474 |
+
};
|
| 1475 |
+
"wan2.2": {
|
| 1476 |
+
prettyLabel: string;
|
| 1477 |
+
repoName: string;
|
| 1478 |
+
repoUrl: string;
|
| 1479 |
+
countDownloads: string;
|
| 1480 |
+
};
|
| 1481 |
+
wham: {
|
| 1482 |
+
prettyLabel: string;
|
| 1483 |
+
repoName: string;
|
| 1484 |
+
repoUrl: string;
|
| 1485 |
+
docsUrl: string;
|
| 1486 |
+
countDownloads: string;
|
| 1487 |
+
};
|
| 1488 |
+
whisperkit: {
|
| 1489 |
+
prettyLabel: string;
|
| 1490 |
+
repoName: string;
|
| 1491 |
+
repoUrl: string;
|
| 1492 |
+
docsUrl: string;
|
| 1493 |
+
snippets: () => string[];
|
| 1494 |
+
countDownloads: string;
|
| 1495 |
+
};
|
| 1496 |
+
yolov10: {
|
| 1497 |
+
prettyLabel: string;
|
| 1498 |
+
repoName: string;
|
| 1499 |
+
repoUrl: string;
|
| 1500 |
+
docsUrl: string;
|
| 1501 |
+
countDownloads: string;
|
| 1502 |
+
snippets: (model: ModelData) => string[];
|
| 1503 |
+
};
|
| 1504 |
+
yolov26: {
|
| 1505 |
+
prettyLabel: string;
|
| 1506 |
+
repoName: string;
|
| 1507 |
+
repoUrl: string;
|
| 1508 |
+
docsUrl: string;
|
| 1509 |
+
countDownloads: string;
|
| 1510 |
+
};
|
| 1511 |
+
zonos: {
|
| 1512 |
+
prettyLabel: string;
|
| 1513 |
+
repoName: string;
|
| 1514 |
+
repoUrl: string;
|
| 1515 |
+
docsUrl: string;
|
| 1516 |
+
snippets: (model: ModelData) => string[];
|
| 1517 |
+
filter: false;
|
| 1518 |
+
};
|
| 1519 |
+
"3dtopia-xl": {
|
| 1520 |
+
prettyLabel: string;
|
| 1521 |
+
repoName: string;
|
| 1522 |
+
repoUrl: string;
|
| 1523 |
+
filter: false;
|
| 1524 |
+
countDownloads: string;
|
| 1525 |
+
snippets: (model: ModelData) => string[];
|
| 1526 |
+
};
|
| 1527 |
+
};
|
| 1528 |
+
export type ModelLibraryKey = keyof typeof MODEL_LIBRARIES_UI_ELEMENTS;
|
| 1529 |
+
export declare const ALL_MODEL_LIBRARY_KEYS: ModelLibraryKey[];
|
| 1530 |
+
export declare const ALL_DISPLAY_MODEL_LIBRARY_KEYS: ("acestep" | "adapter-transformers" | "allennlp" | "anemoi" | "araclip" | "aviation-ner" | "asteroid" | "audiocraft" | "audioseal" | "bagel-mot" | "bboxmaskpose" | "ben2" | "bertopic" | "big_vision" | "birder" | "birefnet" | "bm25s" | "boltzgen" | "cancertathomev2" | "cartesia_pytorch" | "cartesia_mlx" | "champ" | "chatterbox" | "chaossim" | "chat_tts" | "chronos-forecasting" | "clara" | "clipscope" | "cloud-agents" | "colipri" | "cosyvoice" | "cotracker" | "colpali" | "comet" | "cosmos" | "cxr-foundation" | "deepforest" | "depth-anything-v2" | "depth-pro" | "derm-foundation" | "describe-anything" | "dia-tts" | "dia2" | "diff-interpretation-tuning" | "diffree" | "diffusers" | "diffusionkit" | "docking-at-home" | "doctr" | "edsnlp" | "elm" | "espnet" | "fairseq" | "fastai" | "fastprint" | "fasttext" | "fixer" | "flair" | "fme" | "gemma.cpp" | "geometry-crafter" | "gliner" | "gliner2" | "glm-tts" | "glyph-byt5" | "grok" | "habibi-tts" | "hallo" | "hermes" | "hezar" | "htrflow" | "hunyuan-dit" | "hunyuan3d-2" | "hunyuanworld-voyager" | "hy-worldplay" | "image-matching-models" | "imstoucan" | "index-tts" | "infinitetalk" | "infinite-you" | "intellifold" | "keras" | "tf-keras" | "keras-hub" | "kernels" | "kimi-audio" | "kittentts" | "kronos" | "k2" | "lightning-ir" | "litert" | "litert-lm" | "lerobot" | "lightglue" | "liveportrait" | "llama-cpp-python" | "mini-omni2" | "mindspore" | "magi-1" | "magenta-realtime" | "mamba-ssm" | "mars5-tts" | "matanyone" | "mesh-anything" | "merlin" | "medvae" | "mitie" | "ml-agents" | "ml-sharp" | "mlx" | "mlx-image" | "mlc-llm" | "model2vec" | "moshi" | "mtvcraft" | "nemo" | "open-oasis" | "open_clip" | "openpeerllm" | "open-sora" | "outetts" | "paddlenlp" | "PaddleOCR" | "peft" | "perception-encoder" | "phantom-wan" | "pocket-tts" | "pruna-ai" | "pxia" | "pyannote-audio" | "py-feat" | "pythae" | "quantumpeer" | "qwen3_tts" | "recurrentgemma" | "relik" | "refiners" | "renderformer" | "reverb" | "rkllm" | "saelens" | "sam2" | "sam-3d-body" | "sam-3d-objects" | "same" | "sample-factory" | "sap-rpt-1-oss" | "sapiens" | "seedvr" | "self-forcing" | "sentence-transformers" | "setfit" | "sklearn" | "spacy" | "span-marker" | "speechbrain" | "ssr-speech" | "stable-audio-tools" | "monkeyocr" | "diffusion-single-file" | "seed-story" | "soloaudio" | "songbloom" | "stable-baselines3" | "stanza" | "supertonic" | "swarmformer" | "f5-tts" | "genmo" | "tencent-song-generation" | "tensorflowtts" | "tensorrt" | "tabpfn" | "terratorch" | "tic-clip" | "timesfm" | "timm" | "tirex" | "torchgeo" | "transformers" | "transformers.js" | "trellis" | "ultralytics" | "univa" | "uni-3dar" | "unity-sentis" | "sana" | "videoprism" | "vfi-mamba" | "vismatch" | "lvface" | "voicecraft" | "voxcpm" | "vui" | "vibevoice" | "videox_fun" | "wan2.2" | "wham" | "whisperkit" | "yolov10" | "yolov26" | "zonos" | "3dtopia-xl")[];
|
| 1531 |
+
//# sourceMappingURL=model-libraries.d.ts.map
|
node_modules/@huggingface/tasks/dist/commonjs/model-libraries.d.ts.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
|
|
|
|
| 1 |
+
{"version":3,"file":"model-libraries.d.ts","sourceRoot":"","sources":["../../src/model-lib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
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
"use strict";
|
| 2 |
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
| 3 |
+
if (k2 === undefined) k2 = k;
|
| 4 |
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
| 5 |
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
| 6 |
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
| 7 |
+
}
|
| 8 |
+
Object.defineProperty(o, k2, desc);
|
| 9 |
+
}) : (function(o, m, k, k2) {
|
| 10 |
+
if (k2 === undefined) k2 = k;
|
| 11 |
+
o[k2] = m[k];
|
| 12 |
+
}));
|
| 13 |
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
| 14 |
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
| 15 |
+
}) : function(o, v) {
|
| 16 |
+
o["default"] = v;
|
| 17 |
+
});
|
| 18 |
+
var __importStar = (this && this.__importStar) || (function () {
|
| 19 |
+
var ownKeys = function(o) {
|
| 20 |
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
| 21 |
+
var ar = [];
|
| 22 |
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
| 23 |
+
return ar;
|
| 24 |
+
};
|
| 25 |
+
return ownKeys(o);
|
| 26 |
+
};
|
| 27 |
+
return function (mod) {
|
| 28 |
+
if (mod && mod.__esModule) return mod;
|
| 29 |
+
var result = {};
|
| 30 |
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
| 31 |
+
__setModuleDefault(result, mod);
|
| 32 |
+
return result;
|
| 33 |
+
};
|
| 34 |
+
})();
|
| 35 |
+
Object.defineProperty(exports, "__esModule", { value: true });
|
| 36 |
+
exports.ALL_DISPLAY_MODEL_LIBRARY_KEYS = exports.ALL_MODEL_LIBRARY_KEYS = exports.MODEL_LIBRARIES_UI_ELEMENTS = void 0;
|
| 37 |
+
const snippets = __importStar(require("./model-libraries-snippets.js"));
|
| 38 |
+
/**
|
| 39 |
+
* Add your new library here.
|
| 40 |
+
*
|
| 41 |
+
* This is for modeling (= architectures) libraries, not for file formats (like ONNX, etc).
|
| 42 |
+
* (unlike libraries, file formats live in an enum inside the internal codebase.)
|
| 43 |
+
*
|
| 44 |
+
* Doc on how to add a library to the Hub:
|
| 45 |
+
*
|
| 46 |
+
* https://huggingface.co/docs/hub/models-adding-libraries
|
| 47 |
+
*
|
| 48 |
+
* /!\ IMPORTANT
|
| 49 |
+
*
|
| 50 |
+
* The key you choose is the tag your models have in their library_name on the Hub.
|
| 51 |
+
*/
|
| 52 |
+
exports.MODEL_LIBRARIES_UI_ELEMENTS = {
|
| 53 |
+
acestep: {
|
| 54 |
+
prettyLabel: "ACE-Step",
|
| 55 |
+
repoName: "ACE-Step",
|
| 56 |
+
repoUrl: "https://github.com/ace-step/ACE-Step",
|
| 57 |
+
filter: false,
|
| 58 |
+
countDownloads: `path:"ace_step_transformer/config.json"`,
|
| 59 |
+
},
|
| 60 |
+
"adapter-transformers": {
|
| 61 |
+
prettyLabel: "Adapters",
|
| 62 |
+
repoName: "adapters",
|
| 63 |
+
repoUrl: "https://github.com/Adapter-Hub/adapters",
|
| 64 |
+
docsUrl: "https://huggingface.co/docs/hub/adapters",
|
| 65 |
+
snippets: snippets.adapters,
|
| 66 |
+
filter: true,
|
| 67 |
+
countDownloads: `path:"adapter_config.json"`,
|
| 68 |
+
},
|
| 69 |
+
allennlp: {
|
| 70 |
+
prettyLabel: "AllenNLP",
|
| 71 |
+
repoName: "AllenNLP",
|
| 72 |
+
repoUrl: "https://github.com/allenai/allennlp",
|
| 73 |
+
docsUrl: "https://huggingface.co/docs/hub/allennlp",
|
| 74 |
+
snippets: snippets.allennlp,
|
| 75 |
+
filter: true,
|
| 76 |
+
},
|
| 77 |
+
anemoi: {
|
| 78 |
+
prettyLabel: "AnemoI",
|
| 79 |
+
repoName: "AnemoI",
|
| 80 |
+
repoUrl: "https://github.com/ecmwf/anemoi-inference",
|
| 81 |
+
docsUrl: "https://anemoi.readthedocs.io/en/latest/",
|
| 82 |
+
filter: false,
|
| 83 |
+
countDownloads: `path_extension:"ckpt"`,
|
| 84 |
+
snippets: snippets.anemoi,
|
| 85 |
+
},
|
| 86 |
+
araclip: {
|
| 87 |
+
prettyLabel: "AraClip",
|
| 88 |
+
repoName: "AraClip",
|
| 89 |
+
repoUrl: "https://huggingface.co/Arabic-Clip/araclip",
|
| 90 |
+
filter: false,
|
| 91 |
+
snippets: snippets.araclip,
|
| 92 |
+
},
|
| 93 |
+
"aviation-ner": {
|
| 94 |
+
prettyLabel: "Aviation NER",
|
| 95 |
+
repoName: "Aviation NER",
|
| 96 |
+
repoUrl: "https://github.com/Boeing/aviation_ner_sdr",
|
| 97 |
+
docsUrl: "https://github.com/Boeing/aviation_ner_sdr",
|
| 98 |
+
countDownloads: `path:"gliner_config.json"`,
|
| 99 |
+
filter: false,
|
| 100 |
+
},
|
| 101 |
+
asteroid: {
|
| 102 |
+
prettyLabel: "Asteroid",
|
| 103 |
+
repoName: "Asteroid",
|
| 104 |
+
repoUrl: "https://github.com/asteroid-team/asteroid",
|
| 105 |
+
docsUrl: "https://huggingface.co/docs/hub/asteroid",
|
| 106 |
+
snippets: snippets.asteroid,
|
| 107 |
+
filter: true,
|
| 108 |
+
countDownloads: `path:"pytorch_model.bin"`,
|
| 109 |
+
},
|
| 110 |
+
audiocraft: {
|
| 111 |
+
prettyLabel: "Audiocraft",
|
| 112 |
+
repoName: "audiocraft",
|
| 113 |
+
repoUrl: "https://github.com/facebookresearch/audiocraft",
|
| 114 |
+
snippets: snippets.audiocraft,
|
| 115 |
+
filter: false,
|
| 116 |
+
countDownloads: `path:"state_dict.bin"`,
|
| 117 |
+
},
|
| 118 |
+
audioseal: {
|
| 119 |
+
prettyLabel: "AudioSeal",
|
| 120 |
+
repoName: "audioseal",
|
| 121 |
+
repoUrl: "https://github.com/facebookresearch/audioseal",
|
| 122 |
+
filter: false,
|
| 123 |
+
countDownloads: `path_extension:"pth"`,
|
| 124 |
+
snippets: snippets.audioseal,
|
| 125 |
+
},
|
| 126 |
+
"bagel-mot": {
|
| 127 |
+
prettyLabel: "Bagel",
|
| 128 |
+
repoName: "Bagel",
|
| 129 |
+
repoUrl: "https://github.com/ByteDance-Seed/Bagel/",
|
| 130 |
+
filter: false,
|
| 131 |
+
countDownloads: `path:"llm_config.json"`,
|
| 132 |
+
},
|
| 133 |
+
bboxmaskpose: {
|
| 134 |
+
prettyLabel: "BBoxMaskPose",
|
| 135 |
+
repoName: "BBoxMaskPose",
|
| 136 |
+
repoUrl: "https://github.com/MiraPurkrabek/BBoxMaskPose",
|
| 137 |
+
filter: false,
|
| 138 |
+
countDownloads: `path_extension:"pth"`,
|
| 139 |
+
},
|
| 140 |
+
ben2: {
|
| 141 |
+
prettyLabel: "BEN2",
|
| 142 |
+
repoName: "BEN2",
|
| 143 |
+
repoUrl: "https://github.com/PramaLLC/BEN2",
|
| 144 |
+
snippets: snippets.ben2,
|
| 145 |
+
filter: false,
|
| 146 |
+
},
|
| 147 |
+
bertopic: {
|
| 148 |
+
prettyLabel: "BERTopic",
|
| 149 |
+
repoName: "BERTopic",
|
| 150 |
+
repoUrl: "https://github.com/MaartenGr/BERTopic",
|
| 151 |
+
snippets: snippets.bertopic,
|
| 152 |
+
filter: true,
|
| 153 |
+
},
|
| 154 |
+
big_vision: {
|
| 155 |
+
prettyLabel: "Big Vision",
|
| 156 |
+
repoName: "big_vision",
|
| 157 |
+
repoUrl: "https://github.com/google-research/big_vision",
|
| 158 |
+
filter: false,
|
| 159 |
+
countDownloads: `path_extension:"npz"`,
|
| 160 |
+
},
|
| 161 |
+
birder: {
|
| 162 |
+
prettyLabel: "Birder",
|
| 163 |
+
repoName: "Birder",
|
| 164 |
+
repoUrl: "https://gitlab.com/birder/birder",
|
| 165 |
+
filter: false,
|
| 166 |
+
countDownloads: `path_extension:"pt"`,
|
| 167 |
+
},
|
| 168 |
+
birefnet: {
|
| 169 |
+
prettyLabel: "BiRefNet",
|
| 170 |
+
repoName: "BiRefNet",
|
| 171 |
+
repoUrl: "https://github.com/ZhengPeng7/BiRefNet",
|
| 172 |
+
snippets: snippets.birefnet,
|
| 173 |
+
filter: false,
|
| 174 |
+
},
|
| 175 |
+
bm25s: {
|
| 176 |
+
prettyLabel: "BM25S",
|
| 177 |
+
repoName: "bm25s",
|
| 178 |
+
repoUrl: "https://github.com/xhluca/bm25s",
|
| 179 |
+
snippets: snippets.bm25s,
|
| 180 |
+
filter: false,
|
| 181 |
+
countDownloads: `path:"params.index.json"`,
|
| 182 |
+
},
|
| 183 |
+
boltzgen: {
|
| 184 |
+
prettyLabel: "BoltzGen",
|
| 185 |
+
repoName: "BoltzGen",
|
| 186 |
+
repoUrl: "https://github.com/HannesStark/boltzgen",
|
| 187 |
+
filter: false,
|
| 188 |
+
countDownloads: `path:"boltzgen1_diverse.ckpt"`,
|
| 189 |
+
},
|
| 190 |
+
cancertathomev2: {
|
| 191 |
+
prettyLabel: "Cancer@HomeV2",
|
| 192 |
+
repoName: "Cancer@HomeV2",
|
| 193 |
+
repoUrl: "https://huggingface.co/OpenPeerAI/CancerAtHomeV2",
|
| 194 |
+
filter: false,
|
| 195 |
+
countDownloads: `path:"run.py"`,
|
| 196 |
+
},
|
| 197 |
+
cartesia_pytorch: {
|
| 198 |
+
prettyLabel: "Cartesia Pytorch",
|
| 199 |
+
repoName: "Cartesia Pytorch",
|
| 200 |
+
repoUrl: "https://github.com/cartesia-ai/cartesia_pytorch",
|
| 201 |
+
snippets: snippets.cartesia_pytorch,
|
| 202 |
+
},
|
| 203 |
+
cartesia_mlx: {
|
| 204 |
+
prettyLabel: "Cartesia MLX",
|
| 205 |
+
repoName: "Cartesia MLX",
|
| 206 |
+
repoUrl: "https://github.com/cartesia-ai/cartesia_mlx",
|
| 207 |
+
snippets: snippets.cartesia_mlx,
|
| 208 |
+
},
|
| 209 |
+
champ: {
|
| 210 |
+
prettyLabel: "Champ",
|
| 211 |
+
repoName: "Champ",
|
| 212 |
+
repoUrl: "https://github.com/fudan-generative-vision/champ",
|
| 213 |
+
countDownloads: `path:"champ/motion_module.pth"`,
|
| 214 |
+
},
|
| 215 |
+
chatterbox: {
|
| 216 |
+
prettyLabel: "Chatterbox",
|
| 217 |
+
repoName: "Chatterbox",
|
| 218 |
+
repoUrl: "https://github.com/resemble-ai/chatterbox",
|
| 219 |
+
snippets: snippets.chatterbox,
|
| 220 |
+
countDownloads: `path:"tokenizer.json"`,
|
| 221 |
+
filter: false,
|
| 222 |
+
},
|
| 223 |
+
chaossim: {
|
| 224 |
+
prettyLabel: "ChaosSIM",
|
| 225 |
+
repoName: "ChaosSIM",
|
| 226 |
+
repoUrl: "https://huggingface.co/OpenPeerAI/ChaosSIM/",
|
| 227 |
+
countDownloads: `path:"ChaosSim.nb"`,
|
| 228 |
+
filter: false,
|
| 229 |
+
},
|
| 230 |
+
chat_tts: {
|
| 231 |
+
prettyLabel: "ChatTTS",
|
| 232 |
+
repoName: "ChatTTS",
|
| 233 |
+
repoUrl: "https://github.com/2noise/ChatTTS.git",
|
| 234 |
+
snippets: snippets.chattts,
|
| 235 |
+
filter: false,
|
| 236 |
+
countDownloads: `path:"asset/GPT.pt"`,
|
| 237 |
+
},
|
| 238 |
+
"chronos-forecasting": {
|
| 239 |
+
prettyLabel: "Chronos",
|
| 240 |
+
repoName: "Chronos",
|
| 241 |
+
repoUrl: "https://github.com/amazon-science/chronos-forecasting",
|
| 242 |
+
snippets: snippets.chronos_forecasting,
|
| 243 |
+
},
|
| 244 |
+
clara: {
|
| 245 |
+
prettyLabel: "Clara",
|
| 246 |
+
repoName: "Clara",
|
| 247 |
+
filter: false,
|
| 248 |
+
repoUrl: "https://github.com/nvidia/clara",
|
| 249 |
+
countDownloads: `path_extension:"ckpt" OR path:"config.json"`,
|
| 250 |
+
},
|
| 251 |
+
clipscope: {
|
| 252 |
+
prettyLabel: "clipscope",
|
| 253 |
+
repoName: "clipscope",
|
| 254 |
+
repoUrl: "https://github.com/Lewington-pitsos/clipscope",
|
| 255 |
+
filter: false,
|
| 256 |
+
countDownloads: `path_extension:"pt"`,
|
| 257 |
+
},
|
| 258 |
+
"cloud-agents": {
|
| 259 |
+
prettyLabel: "Cloud Agents",
|
| 260 |
+
repoName: "Cloud Agents",
|
| 261 |
+
repoUrl: "https://huggingface.co/OpenPeerAI/Cloud-Agents",
|
| 262 |
+
filter: false,
|
| 263 |
+
countDownloads: `path:"setup.py"`,
|
| 264 |
+
},
|
| 265 |
+
colipri: {
|
| 266 |
+
prettyLabel: "COLIPRI",
|
| 267 |
+
repoName: "COLIPRI",
|
| 268 |
+
repoUrl: "https://huggingface.co/microsoft/colipri",
|
| 269 |
+
snippets: snippets.colipri,
|
| 270 |
+
filter: false,
|
| 271 |
+
countDownloads: `path_extension:"safetensors"`,
|
| 272 |
+
},
|
| 273 |
+
cosyvoice: {
|
| 274 |
+
prettyLabel: "CosyVoice",
|
| 275 |
+
repoName: "CosyVoice",
|
| 276 |
+
repoUrl: "https://github.com/FunAudioLLM/CosyVoice",
|
| 277 |
+
filter: false,
|
| 278 |
+
countDownloads: `path_extension:"onnx" OR path_extension:"pt"`,
|
| 279 |
+
},
|
| 280 |
+
cotracker: {
|
| 281 |
+
prettyLabel: "CoTracker",
|
| 282 |
+
repoName: "CoTracker",
|
| 283 |
+
repoUrl: "https://github.com/facebookresearch/co-tracker",
|
| 284 |
+
filter: false,
|
| 285 |
+
countDownloads: `path_extension:"pth"`,
|
| 286 |
+
},
|
| 287 |
+
colpali: {
|
| 288 |
+
prettyLabel: "ColPali",
|
| 289 |
+
repoName: "ColPali",
|
| 290 |
+
repoUrl: "https://github.com/ManuelFay/colpali",
|
| 291 |
+
filter: false,
|
| 292 |
+
countDownloads: `path:"adapter_config.json"`,
|
| 293 |
+
},
|
| 294 |
+
comet: {
|
| 295 |
+
prettyLabel: "COMET",
|
| 296 |
+
repoName: "COMET",
|
| 297 |
+
repoUrl: "https://github.com/Unbabel/COMET/",
|
| 298 |
+
countDownloads: `path:"hparams.yaml"`,
|
| 299 |
+
},
|
| 300 |
+
cosmos: {
|
| 301 |
+
prettyLabel: "Cosmos",
|
| 302 |
+
repoName: "Cosmos",
|
| 303 |
+
repoUrl: "https://github.com/NVIDIA/Cosmos",
|
| 304 |
+
countDownloads: `path:"config.json" OR path_extension:"pt"`,
|
| 305 |
+
},
|
| 306 |
+
"cxr-foundation": {
|
| 307 |
+
prettyLabel: "CXR Foundation",
|
| 308 |
+
repoName: "cxr-foundation",
|
| 309 |
+
repoUrl: "https://github.com/google-health/cxr-foundation",
|
| 310 |
+
snippets: snippets.cxr_foundation,
|
| 311 |
+
filter: false,
|
| 312 |
+
countDownloads: `path:"precomputed_embeddings/embeddings.npz" OR path:"pax-elixr-b-text/saved_model.pb"`,
|
| 313 |
+
},
|
| 314 |
+
deepforest: {
|
| 315 |
+
prettyLabel: "DeepForest",
|
| 316 |
+
repoName: "deepforest",
|
| 317 |
+
docsUrl: "https://deepforest.readthedocs.io/en/latest/",
|
| 318 |
+
repoUrl: "https://github.com/weecology/DeepForest",
|
| 319 |
+
},
|
| 320 |
+
"depth-anything-v2": {
|
| 321 |
+
prettyLabel: "DepthAnythingV2",
|
| 322 |
+
repoName: "Depth Anything V2",
|
| 323 |
+
repoUrl: "https://github.com/DepthAnything/Depth-Anything-V2",
|
| 324 |
+
snippets: snippets.depth_anything_v2,
|
| 325 |
+
filter: false,
|
| 326 |
+
countDownloads: `path_extension:"pth"`,
|
| 327 |
+
},
|
| 328 |
+
"depth-pro": {
|
| 329 |
+
prettyLabel: "Depth Pro",
|
| 330 |
+
repoName: "Depth Pro",
|
| 331 |
+
repoUrl: "https://github.com/apple/ml-depth-pro",
|
| 332 |
+
countDownloads: `path_extension:"pt"`,
|
| 333 |
+
snippets: snippets.depth_pro,
|
| 334 |
+
filter: false,
|
| 335 |
+
},
|
| 336 |
+
"derm-foundation": {
|
| 337 |
+
prettyLabel: "Derm Foundation",
|
| 338 |
+
repoName: "derm-foundation",
|
| 339 |
+
repoUrl: "https://github.com/google-health/derm-foundation",
|
| 340 |
+
snippets: snippets.derm_foundation,
|
| 341 |
+
filter: false,
|
| 342 |
+
countDownloads: `path:"scin_dataset_precomputed_embeddings.npz" OR path:"saved_model.pb"`,
|
| 343 |
+
},
|
| 344 |
+
"describe-anything": {
|
| 345 |
+
prettyLabel: "Describe Anything",
|
| 346 |
+
repoName: "Describe Anything",
|
| 347 |
+
repoUrl: "https://github.com/NVlabs/describe-anything",
|
| 348 |
+
snippets: snippets.describe_anything,
|
| 349 |
+
filter: false,
|
| 350 |
+
},
|
| 351 |
+
"dia-tts": {
|
| 352 |
+
prettyLabel: "Dia",
|
| 353 |
+
repoName: "Dia",
|
| 354 |
+
repoUrl: "https://github.com/nari-labs/dia",
|
| 355 |
+
snippets: snippets.dia,
|
| 356 |
+
filter: false,
|
| 357 |
+
},
|
| 358 |
+
dia2: {
|
| 359 |
+
prettyLabel: "Dia2",
|
| 360 |
+
repoName: "Dia2",
|
| 361 |
+
repoUrl: "https://github.com/nari-labs/dia2",
|
| 362 |
+
snippets: snippets.dia2,
|
| 363 |
+
filter: false,
|
| 364 |
+
},
|
| 365 |
+
"diff-interpretation-tuning": {
|
| 366 |
+
prettyLabel: "Diff Interpretation Tuning",
|
| 367 |
+
repoName: "Diff Interpretation Tuning",
|
| 368 |
+
repoUrl: "https://github.com/Aviously/diff-interpretation-tuning",
|
| 369 |
+
filter: false,
|
| 370 |
+
countDownloads: `path_extension:"pt"`,
|
| 371 |
+
},
|
| 372 |
+
diffree: {
|
| 373 |
+
prettyLabel: "Diffree",
|
| 374 |
+
repoName: "Diffree",
|
| 375 |
+
repoUrl: "https://github.com/OpenGVLab/Diffree",
|
| 376 |
+
filter: false,
|
| 377 |
+
countDownloads: `path:"diffree-step=000010999.ckpt"`,
|
| 378 |
+
},
|
| 379 |
+
diffusers: {
|
| 380 |
+
prettyLabel: "Diffusers",
|
| 381 |
+
repoName: "🤗/diffusers",
|
| 382 |
+
repoUrl: "https://github.com/huggingface/diffusers",
|
| 383 |
+
docsUrl: "https://huggingface.co/docs/hub/diffusers",
|
| 384 |
+
snippets: snippets.diffusers,
|
| 385 |
+
filter: true,
|
| 386 |
+
/// diffusers has its own more complex "countDownloads" query
|
| 387 |
+
},
|
| 388 |
+
diffusionkit: {
|
| 389 |
+
prettyLabel: "DiffusionKit",
|
| 390 |
+
repoName: "DiffusionKit",
|
| 391 |
+
repoUrl: "https://github.com/argmaxinc/DiffusionKit",
|
| 392 |
+
snippets: snippets.diffusionkit,
|
| 393 |
+
},
|
| 394 |
+
"docking-at-home": {
|
| 395 |
+
prettyLabel: "Docking@Home",
|
| 396 |
+
repoName: "Docking@Home",
|
| 397 |
+
repoUrl: "https://huggingface.co/OpenPeerAI/DockingAtHOME",
|
| 398 |
+
filter: false,
|
| 399 |
+
countDownloads: `path:"setup.py"`,
|
| 400 |
+
},
|
| 401 |
+
doctr: {
|
| 402 |
+
prettyLabel: "docTR",
|
| 403 |
+
repoName: "doctr",
|
| 404 |
+
repoUrl: "https://github.com/mindee/doctr",
|
| 405 |
+
},
|
| 406 |
+
edsnlp: {
|
| 407 |
+
prettyLabel: "EDS-NLP",
|
| 408 |
+
repoName: "edsnlp",
|
| 409 |
+
repoUrl: "https://github.com/aphp/edsnlp",
|
| 410 |
+
docsUrl: "https://aphp.github.io/edsnlp/latest/",
|
| 411 |
+
filter: false,
|
| 412 |
+
snippets: snippets.edsnlp,
|
| 413 |
+
countDownloads: `path_filename:"config" AND path_extension:"cfg"`,
|
| 414 |
+
},
|
| 415 |
+
elm: {
|
| 416 |
+
prettyLabel: "ELM",
|
| 417 |
+
repoName: "elm",
|
| 418 |
+
repoUrl: "https://github.com/slicex-ai/elm",
|
| 419 |
+
filter: false,
|
| 420 |
+
countDownloads: `path_filename:"slicex_elm_config" AND path_extension:"json"`,
|
| 421 |
+
},
|
| 422 |
+
espnet: {
|
| 423 |
+
prettyLabel: "ESPnet",
|
| 424 |
+
repoName: "ESPnet",
|
| 425 |
+
repoUrl: "https://github.com/espnet/espnet",
|
| 426 |
+
docsUrl: "https://huggingface.co/docs/hub/espnet",
|
| 427 |
+
snippets: snippets.espnet,
|
| 428 |
+
filter: true,
|
| 429 |
+
},
|
| 430 |
+
fairseq: {
|
| 431 |
+
prettyLabel: "Fairseq",
|
| 432 |
+
repoName: "fairseq",
|
| 433 |
+
repoUrl: "https://github.com/pytorch/fairseq",
|
| 434 |
+
snippets: snippets.fairseq,
|
| 435 |
+
filter: true,
|
| 436 |
+
},
|
| 437 |
+
fastai: {
|
| 438 |
+
prettyLabel: "fastai",
|
| 439 |
+
repoName: "fastai",
|
| 440 |
+
repoUrl: "https://github.com/fastai/fastai",
|
| 441 |
+
docsUrl: "https://huggingface.co/docs/hub/fastai",
|
| 442 |
+
snippets: snippets.fastai,
|
| 443 |
+
filter: true,
|
| 444 |
+
},
|
| 445 |
+
fastprint: {
|
| 446 |
+
prettyLabel: "Fast Print",
|
| 447 |
+
repoName: "Fast Print",
|
| 448 |
+
repoUrl: "https://huggingface.co/OpenPeerAI/FastPrint",
|
| 449 |
+
countDownloads: `path_extension:"cs"`,
|
| 450 |
+
},
|
| 451 |
+
fasttext: {
|
| 452 |
+
prettyLabel: "fastText",
|
| 453 |
+
repoName: "fastText",
|
| 454 |
+
repoUrl: "https://fasttext.cc/",
|
| 455 |
+
snippets: snippets.fasttext,
|
| 456 |
+
filter: true,
|
| 457 |
+
countDownloads: `path_extension:"bin"`,
|
| 458 |
+
},
|
| 459 |
+
fixer: {
|
| 460 |
+
prettyLabel: "Fixer",
|
| 461 |
+
repoName: "Fixer",
|
| 462 |
+
repoUrl: "https://github.com/nv-tlabs/Fixer",
|
| 463 |
+
filter: false,
|
| 464 |
+
countDownloads: `path:"pretrained/pretrained_fixer.pkl"`,
|
| 465 |
+
},
|
| 466 |
+
flair: {
|
| 467 |
+
prettyLabel: "Flair",
|
| 468 |
+
repoName: "Flair",
|
| 469 |
+
repoUrl: "https://github.com/flairNLP/flair",
|
| 470 |
+
docsUrl: "https://huggingface.co/docs/hub/flair",
|
| 471 |
+
snippets: snippets.flair,
|
| 472 |
+
filter: true,
|
| 473 |
+
countDownloads: `path:"pytorch_model.bin"`,
|
| 474 |
+
},
|
| 475 |
+
fme: {
|
| 476 |
+
prettyLabel: "Full Model Emulation",
|
| 477 |
+
repoName: "Full Model Emulation",
|
| 478 |
+
repoUrl: "https://github.com/ai2cm/ace",
|
| 479 |
+
docsUrl: "https://ai2-climate-emulator.readthedocs.io/en/latest/",
|
| 480 |
+
filter: false,
|
| 481 |
+
countDownloads: `path_extension:"tar"`,
|
| 482 |
+
},
|
| 483 |
+
"gemma.cpp": {
|
| 484 |
+
prettyLabel: "gemma.cpp",
|
| 485 |
+
repoName: "gemma.cpp",
|
| 486 |
+
repoUrl: "https://github.com/google/gemma.cpp",
|
| 487 |
+
filter: false,
|
| 488 |
+
countDownloads: `path_extension:"sbs"`,
|
| 489 |
+
},
|
| 490 |
+
"geometry-crafter": {
|
| 491 |
+
prettyLabel: "GeometryCrafter",
|
| 492 |
+
repoName: "GeometryCrafter",
|
| 493 |
+
repoUrl: "https://github.com/TencentARC/GeometryCrafter",
|
| 494 |
+
countDownloads: `path:"point_map_vae/diffusion_pytorch_model.safetensors"`,
|
| 495 |
+
},
|
| 496 |
+
gliner: {
|
| 497 |
+
prettyLabel: "GLiNER",
|
| 498 |
+
repoName: "GLiNER",
|
| 499 |
+
repoUrl: "https://github.com/urchade/GLiNER",
|
| 500 |
+
snippets: snippets.gliner,
|
| 501 |
+
filter: false,
|
| 502 |
+
countDownloads: `path:"gliner_config.json"`,
|
| 503 |
+
},
|
| 504 |
+
gliner2: {
|
| 505 |
+
prettyLabel: "GLiNER2",
|
| 506 |
+
repoName: "GLiNER2",
|
| 507 |
+
repoUrl: "https://github.com/fastino-ai/GLiNER2",
|
| 508 |
+
snippets: snippets.gliner2,
|
| 509 |
+
filter: false,
|
| 510 |
+
},
|
| 511 |
+
"glm-tts": {
|
| 512 |
+
prettyLabel: "GLM-TTS",
|
| 513 |
+
repoName: "GLM-TTS",
|
| 514 |
+
repoUrl: "https://github.com/zai-org/GLM-TTS",
|
| 515 |
+
filter: false,
|
| 516 |
+
countDownloads: `path:"flow/flow.pt"`,
|
| 517 |
+
},
|
| 518 |
+
"glyph-byt5": {
|
| 519 |
+
prettyLabel: "Glyph-ByT5",
|
| 520 |
+
repoName: "Glyph-ByT5",
|
| 521 |
+
repoUrl: "https://github.com/AIGText/Glyph-ByT5",
|
| 522 |
+
filter: false,
|
| 523 |
+
countDownloads: `path:"checkpoints/byt5_model.pt"`,
|
| 524 |
+
},
|
| 525 |
+
grok: {
|
| 526 |
+
prettyLabel: "Grok",
|
| 527 |
+
repoName: "Grok",
|
| 528 |
+
repoUrl: "https://github.com/xai-org/grok-1",
|
| 529 |
+
filter: false,
|
| 530 |
+
countDownloads: `path:"ckpt/tensor00000_000" OR path:"ckpt-0/tensor00000_000"`,
|
| 531 |
+
},
|
| 532 |
+
"habibi-tts": {
|
| 533 |
+
prettyLabel: "Habibi-TTS",
|
| 534 |
+
repoName: "Habibi-TTS",
|
| 535 |
+
repoUrl: "https://github.com/SWivid/Habibi-TTS",
|
| 536 |
+
filter: false,
|
| 537 |
+
countDownloads: `path_extension:"safetensors"`,
|
| 538 |
+
},
|
| 539 |
+
hallo: {
|
| 540 |
+
prettyLabel: "Hallo",
|
| 541 |
+
repoName: "Hallo",
|
| 542 |
+
repoUrl: "https://github.com/fudan-generative-vision/hallo",
|
| 543 |
+
countDownloads: `path:"hallo/net.pth"`,
|
| 544 |
+
},
|
| 545 |
+
hermes: {
|
| 546 |
+
prettyLabel: "HERMES",
|
| 547 |
+
repoName: "HERMES",
|
| 548 |
+
repoUrl: "https://github.com/LMD0311/HERMES",
|
| 549 |
+
filter: false,
|
| 550 |
+
countDownloads: `path:"ckpt/hermes_final.pth"`,
|
| 551 |
+
},
|
| 552 |
+
hezar: {
|
| 553 |
+
prettyLabel: "Hezar",
|
| 554 |
+
repoName: "Hezar",
|
| 555 |
+
repoUrl: "https://github.com/hezarai/hezar",
|
| 556 |
+
docsUrl: "https://hezarai.github.io/hezar",
|
| 557 |
+
countDownloads: `path:"model_config.yaml" OR path:"embedding/embedding_config.yaml"`,
|
| 558 |
+
},
|
| 559 |
+
htrflow: {
|
| 560 |
+
prettyLabel: "HTRflow",
|
| 561 |
+
repoName: "HTRflow",
|
| 562 |
+
repoUrl: "https://github.com/AI-Riksarkivet/htrflow",
|
| 563 |
+
docsUrl: "https://ai-riksarkivet.github.io/htrflow",
|
| 564 |
+
snippets: snippets.htrflow,
|
| 565 |
+
},
|
| 566 |
+
"hunyuan-dit": {
|
| 567 |
+
prettyLabel: "HunyuanDiT",
|
| 568 |
+
repoName: "HunyuanDiT",
|
| 569 |
+
repoUrl: "https://github.com/Tencent/HunyuanDiT",
|
| 570 |
+
countDownloads: `path:"pytorch_model_ema.pt" OR path:"pytorch_model_distill.pt"`,
|
| 571 |
+
},
|
| 572 |
+
"hunyuan3d-2": {
|
| 573 |
+
prettyLabel: "Hunyuan3D-2",
|
| 574 |
+
repoName: "Hunyuan3D-2",
|
| 575 |
+
repoUrl: "https://github.com/Tencent/Hunyuan3D-2",
|
| 576 |
+
countDownloads: `path_filename:"model_index" OR path_filename:"config"`,
|
| 577 |
+
},
|
| 578 |
+
"hunyuanworld-voyager": {
|
| 579 |
+
prettyLabel: "HunyuanWorld-voyager",
|
| 580 |
+
repoName: "HunyuanWorld-voyager",
|
| 581 |
+
repoUrl: "https://github.com/Tencent-Hunyuan/HunyuanWorld-Voyager",
|
| 582 |
+
},
|
| 583 |
+
"hy-worldplay": {
|
| 584 |
+
prettyLabel: "HY-WorldPlay",
|
| 585 |
+
repoName: "HY-WorldPlay",
|
| 586 |
+
repoUrl: "https://github.com/Tencent-Hunyuan/HY-WorldPlay",
|
| 587 |
+
filter: false,
|
| 588 |
+
countDownloads: `path_extension:"json"`,
|
| 589 |
+
},
|
| 590 |
+
"image-matching-models": {
|
| 591 |
+
prettyLabel: "Image Matching Models",
|
| 592 |
+
repoName: "Image Matching Models",
|
| 593 |
+
repoUrl: "https://github.com/alexstoken/image-matching-models",
|
| 594 |
+
filter: false,
|
| 595 |
+
countDownloads: `path_extension:"safetensors"`,
|
| 596 |
+
},
|
| 597 |
+
imstoucan: {
|
| 598 |
+
prettyLabel: "IMS Toucan",
|
| 599 |
+
repoName: "IMS-Toucan",
|
| 600 |
+
repoUrl: "https://github.com/DigitalPhonetics/IMS-Toucan",
|
| 601 |
+
countDownloads: `path:"embedding_gan.pt" OR path:"Vocoder.pt" OR path:"ToucanTTS.pt"`,
|
| 602 |
+
},
|
| 603 |
+
"index-tts": {
|
| 604 |
+
prettyLabel: "IndexTTS",
|
| 605 |
+
repoName: "IndexTTS",
|
| 606 |
+
repoUrl: "https://github.com/index-tts/index-tts",
|
| 607 |
+
snippets: snippets.indextts,
|
| 608 |
+
filter: false,
|
| 609 |
+
},
|
| 610 |
+
infinitetalk: {
|
| 611 |
+
prettyLabel: "InfiniteTalk",
|
| 612 |
+
repoName: "InfiniteTalk",
|
| 613 |
+
repoUrl: "https://github.com/MeiGen-AI/InfiniteTalk",
|
| 614 |
+
filter: false,
|
| 615 |
+
countDownloads: `path_extension:"safetensors"`,
|
| 616 |
+
},
|
| 617 |
+
"infinite-you": {
|
| 618 |
+
prettyLabel: "InfiniteYou",
|
| 619 |
+
repoName: "InfiniteYou",
|
| 620 |
+
repoUrl: "https://github.com/bytedance/InfiniteYou",
|
| 621 |
+
filter: false,
|
| 622 |
+
countDownloads: `path:"infu_flux_v1.0/sim_stage1/image_proj_model.bin" OR path:"infu_flux_v1.0/aes_stage2/image_proj_model.bin"`,
|
| 623 |
+
},
|
| 624 |
+
intellifold: {
|
| 625 |
+
prettyLabel: "IntelliFold",
|
| 626 |
+
repoName: "IntelliFold",
|
| 627 |
+
repoUrl: "https://github.com/IntelliGen-AI/IntelliFold",
|
| 628 |
+
filter: false,
|
| 629 |
+
countDownloads: `path_extension:"pt"`,
|
| 630 |
+
},
|
| 631 |
+
keras: {
|
| 632 |
+
prettyLabel: "Keras",
|
| 633 |
+
repoName: "Keras",
|
| 634 |
+
repoUrl: "https://github.com/keras-team/keras",
|
| 635 |
+
docsUrl: "https://huggingface.co/docs/hub/keras",
|
| 636 |
+
snippets: snippets.keras,
|
| 637 |
+
filter: true,
|
| 638 |
+
countDownloads: `path:"config.json" OR path_extension:"keras"`,
|
| 639 |
+
},
|
| 640 |
+
"tf-keras": {
|
| 641 |
+
// Legacy "Keras 2" library (tensorflow-only)
|
| 642 |
+
prettyLabel: "TF-Keras",
|
| 643 |
+
repoName: "TF-Keras",
|
| 644 |
+
repoUrl: "https://github.com/keras-team/tf-keras",
|
| 645 |
+
docsUrl: "https://huggingface.co/docs/hub/tf-keras",
|
| 646 |
+
snippets: snippets.tf_keras,
|
| 647 |
+
countDownloads: `path:"saved_model.pb"`,
|
| 648 |
+
},
|
| 649 |
+
"keras-hub": {
|
| 650 |
+
prettyLabel: "KerasHub",
|
| 651 |
+
repoName: "KerasHub",
|
| 652 |
+
repoUrl: "https://github.com/keras-team/keras-hub",
|
| 653 |
+
docsUrl: "https://keras.io/keras_hub/",
|
| 654 |
+
snippets: snippets.keras_hub,
|
| 655 |
+
filter: true,
|
| 656 |
+
},
|
| 657 |
+
kernels: {
|
| 658 |
+
prettyLabel: "Kernels",
|
| 659 |
+
repoName: "Kernels",
|
| 660 |
+
repoUrl: "https://github.com/huggingface/kernels",
|
| 661 |
+
docsUrl: "https://huggingface.co/docs/kernels",
|
| 662 |
+
snippets: snippets.kernels,
|
| 663 |
+
countDownloads: `path_filename:"_ops" AND path_extension:"py"`,
|
| 664 |
+
},
|
| 665 |
+
"kimi-audio": {
|
| 666 |
+
prettyLabel: "KimiAudio",
|
| 667 |
+
repoName: "KimiAudio",
|
| 668 |
+
repoUrl: "https://github.com/MoonshotAI/Kimi-Audio",
|
| 669 |
+
snippets: snippets.kimi_audio,
|
| 670 |
+
filter: false,
|
| 671 |
+
},
|
| 672 |
+
kittentts: {
|
| 673 |
+
prettyLabel: "KittenTTS",
|
| 674 |
+
repoName: "KittenTTS",
|
| 675 |
+
repoUrl: "https://github.com/KittenML/KittenTTS",
|
| 676 |
+
snippets: snippets.kittentts,
|
| 677 |
+
},
|
| 678 |
+
kronos: {
|
| 679 |
+
prettyLabel: "KRONOS",
|
| 680 |
+
repoName: "KRONOS",
|
| 681 |
+
repoUrl: "https://github.com/mahmoodlab/KRONOS",
|
| 682 |
+
filter: false,
|
| 683 |
+
countDownloads: `path_extension:"pt"`,
|
| 684 |
+
},
|
| 685 |
+
k2: {
|
| 686 |
+
prettyLabel: "K2",
|
| 687 |
+
repoName: "k2",
|
| 688 |
+
repoUrl: "https://github.com/k2-fsa/k2",
|
| 689 |
+
},
|
| 690 |
+
"lightning-ir": {
|
| 691 |
+
prettyLabel: "Lightning IR",
|
| 692 |
+
repoName: "Lightning IR",
|
| 693 |
+
repoUrl: "https://github.com/webis-de/lightning-ir",
|
| 694 |
+
snippets: snippets.lightning_ir,
|
| 695 |
+
},
|
| 696 |
+
litert: {
|
| 697 |
+
prettyLabel: "LiteRT",
|
| 698 |
+
repoName: "LiteRT",
|
| 699 |
+
repoUrl: "https://github.com/google-ai-edge/LiteRT",
|
| 700 |
+
filter: false,
|
| 701 |
+
countDownloads: `path_extension:"tflite"`,
|
| 702 |
+
},
|
| 703 |
+
"litert-lm": {
|
| 704 |
+
prettyLabel: "LiteRT-LM",
|
| 705 |
+
repoName: "LiteRT-LM",
|
| 706 |
+
repoUrl: "https://github.com/google-ai-edge/LiteRT-LM",
|
| 707 |
+
filter: false,
|
| 708 |
+
countDownloads: `path_extension:"litertlm" OR path_extension:"task"`,
|
| 709 |
+
},
|
| 710 |
+
lerobot: {
|
| 711 |
+
prettyLabel: "LeRobot",
|
| 712 |
+
repoName: "LeRobot",
|
| 713 |
+
repoUrl: "https://github.com/huggingface/lerobot",
|
| 714 |
+
docsUrl: "https://huggingface.co/docs/lerobot",
|
| 715 |
+
filter: false,
|
| 716 |
+
snippets: snippets.lerobot,
|
| 717 |
+
},
|
| 718 |
+
lightglue: {
|
| 719 |
+
prettyLabel: "LightGlue",
|
| 720 |
+
repoName: "LightGlue",
|
| 721 |
+
repoUrl: "https://github.com/cvg/LightGlue",
|
| 722 |
+
filter: false,
|
| 723 |
+
countDownloads: `path_extension:"pth" OR path:"config.json"`,
|
| 724 |
+
},
|
| 725 |
+
liveportrait: {
|
| 726 |
+
prettyLabel: "LivePortrait",
|
| 727 |
+
repoName: "LivePortrait",
|
| 728 |
+
repoUrl: "https://github.com/KwaiVGI/LivePortrait",
|
| 729 |
+
filter: false,
|
| 730 |
+
countDownloads: `path:"liveportrait/landmark.onnx"`,
|
| 731 |
+
},
|
| 732 |
+
"llama-cpp-python": {
|
| 733 |
+
prettyLabel: "llama-cpp-python",
|
| 734 |
+
repoName: "llama-cpp-python",
|
| 735 |
+
repoUrl: "https://github.com/abetlen/llama-cpp-python",
|
| 736 |
+
snippets: snippets.llama_cpp_python,
|
| 737 |
+
},
|
| 738 |
+
"mini-omni2": {
|
| 739 |
+
prettyLabel: "Mini-Omni2",
|
| 740 |
+
repoName: "Mini-Omni2",
|
| 741 |
+
repoUrl: "https://github.com/gpt-omni/mini-omni2",
|
| 742 |
+
countDownloads: `path:"model_config.yaml"`,
|
| 743 |
+
},
|
| 744 |
+
mindspore: {
|
| 745 |
+
prettyLabel: "MindSpore",
|
| 746 |
+
repoName: "mindspore",
|
| 747 |
+
repoUrl: "https://github.com/mindspore-ai/mindspore",
|
| 748 |
+
},
|
| 749 |
+
"magi-1": {
|
| 750 |
+
prettyLabel: "MAGI-1",
|
| 751 |
+
repoName: "MAGI-1",
|
| 752 |
+
repoUrl: "https://github.com/SandAI-org/MAGI-1",
|
| 753 |
+
countDownloads: `path:"ckpt/vae/config.json"`,
|
| 754 |
+
},
|
| 755 |
+
"magenta-realtime": {
|
| 756 |
+
prettyLabel: "Magenta RT",
|
| 757 |
+
repoName: "Magenta RT",
|
| 758 |
+
repoUrl: "https://github.com/magenta/magenta-realtime",
|
| 759 |
+
countDownloads: `path:"checkpoints/llm_base_x4286_c1860k.tar" OR path:"checkpoints/llm_large_x3047_c1860k.tar" OR path:"checkpoints/llm_large_x3047_c1860k/checkpoint"`,
|
| 760 |
+
},
|
| 761 |
+
"mamba-ssm": {
|
| 762 |
+
prettyLabel: "MambaSSM",
|
| 763 |
+
repoName: "MambaSSM",
|
| 764 |
+
repoUrl: "https://github.com/state-spaces/mamba",
|
| 765 |
+
filter: false,
|
| 766 |
+
snippets: snippets.mamba_ssm,
|
| 767 |
+
},
|
| 768 |
+
"mars5-tts": {
|
| 769 |
+
prettyLabel: "MARS5-TTS",
|
| 770 |
+
repoName: "MARS5-TTS",
|
| 771 |
+
repoUrl: "https://github.com/Camb-ai/MARS5-TTS",
|
| 772 |
+
filter: false,
|
| 773 |
+
countDownloads: `path:"mars5_ar.safetensors"`,
|
| 774 |
+
snippets: snippets.mars5_tts,
|
| 775 |
+
},
|
| 776 |
+
matanyone: {
|
| 777 |
+
prettyLabel: "MatAnyone",
|
| 778 |
+
repoName: "MatAnyone",
|
| 779 |
+
repoUrl: "https://github.com/pq-yang/MatAnyone",
|
| 780 |
+
snippets: snippets.matanyone,
|
| 781 |
+
filter: false,
|
| 782 |
+
},
|
| 783 |
+
"mesh-anything": {
|
| 784 |
+
prettyLabel: "MeshAnything",
|
| 785 |
+
repoName: "MeshAnything",
|
| 786 |
+
repoUrl: "https://github.com/buaacyw/MeshAnything",
|
| 787 |
+
filter: false,
|
| 788 |
+
countDownloads: `path:"MeshAnything_350m.pth"`,
|
| 789 |
+
snippets: snippets.mesh_anything,
|
| 790 |
+
},
|
| 791 |
+
merlin: {
|
| 792 |
+
prettyLabel: "Merlin",
|
| 793 |
+
repoName: "Merlin",
|
| 794 |
+
repoUrl: "https://github.com/StanfordMIMI/Merlin",
|
| 795 |
+
filter: false,
|
| 796 |
+
countDownloads: `path_extension:"pt"`,
|
| 797 |
+
},
|
| 798 |
+
medvae: {
|
| 799 |
+
prettyLabel: "MedVAE",
|
| 800 |
+
repoName: "MedVAE",
|
| 801 |
+
repoUrl: "https://github.com/StanfordMIMI/MedVAE",
|
| 802 |
+
filter: false,
|
| 803 |
+
countDownloads: `path_extension:"ckpt"`,
|
| 804 |
+
},
|
| 805 |
+
mitie: {
|
| 806 |
+
prettyLabel: "MITIE",
|
| 807 |
+
repoName: "MITIE",
|
| 808 |
+
repoUrl: "https://github.com/mit-nlp/MITIE",
|
| 809 |
+
countDownloads: `path_filename:"total_word_feature_extractor"`,
|
| 810 |
+
},
|
| 811 |
+
"ml-agents": {
|
| 812 |
+
prettyLabel: "ml-agents",
|
| 813 |
+
repoName: "ml-agents",
|
| 814 |
+
repoUrl: "https://github.com/Unity-Technologies/ml-agents",
|
| 815 |
+
docsUrl: "https://huggingface.co/docs/hub/ml-agents",
|
| 816 |
+
snippets: snippets.mlAgents,
|
| 817 |
+
filter: true,
|
| 818 |
+
countDownloads: `path_extension:"onnx"`,
|
| 819 |
+
},
|
| 820 |
+
"ml-sharp": {
|
| 821 |
+
prettyLabel: "Sharp",
|
| 822 |
+
repoName: "Sharp",
|
| 823 |
+
repoUrl: "https://github.com/apple/ml-sharp",
|
| 824 |
+
filter: false,
|
| 825 |
+
countDownloads: `path_extension:"pt"`,
|
| 826 |
+
},
|
| 827 |
+
mlx: {
|
| 828 |
+
prettyLabel: "MLX",
|
| 829 |
+
repoName: "MLX",
|
| 830 |
+
repoUrl: "https://github.com/ml-explore/mlx-examples/tree/main",
|
| 831 |
+
snippets: snippets.mlx,
|
| 832 |
+
filter: true,
|
| 833 |
+
},
|
| 834 |
+
"mlx-image": {
|
| 835 |
+
prettyLabel: "mlx-image",
|
| 836 |
+
repoName: "mlx-image",
|
| 837 |
+
repoUrl: "https://github.com/riccardomusmeci/mlx-image",
|
| 838 |
+
docsUrl: "https://huggingface.co/docs/hub/mlx-image",
|
| 839 |
+
snippets: snippets.mlxim,
|
| 840 |
+
filter: false,
|
| 841 |
+
countDownloads: `path:"model.safetensors"`,
|
| 842 |
+
},
|
| 843 |
+
"mlc-llm": {
|
| 844 |
+
prettyLabel: "MLC-LLM",
|
| 845 |
+
repoName: "MLC-LLM",
|
| 846 |
+
repoUrl: "https://github.com/mlc-ai/mlc-llm",
|
| 847 |
+
docsUrl: "https://llm.mlc.ai/docs/",
|
| 848 |
+
filter: false,
|
| 849 |
+
countDownloads: `path:"mlc-chat-config.json"`,
|
| 850 |
+
},
|
| 851 |
+
model2vec: {
|
| 852 |
+
prettyLabel: "Model2Vec",
|
| 853 |
+
repoName: "model2vec",
|
| 854 |
+
repoUrl: "https://github.com/MinishLab/model2vec",
|
| 855 |
+
snippets: snippets.model2vec,
|
| 856 |
+
filter: false,
|
| 857 |
+
},
|
| 858 |
+
moshi: {
|
| 859 |
+
prettyLabel: "Moshi",
|
| 860 |
+
repoName: "Moshi",
|
| 861 |
+
repoUrl: "https://github.com/kyutai-labs/moshi",
|
| 862 |
+
snippets: snippets.moshi,
|
| 863 |
+
filter: false,
|
| 864 |
+
countDownloads: `path:"tokenizer-e351c8d8-checkpoint125.safetensors"`,
|
| 865 |
+
},
|
| 866 |
+
mtvcraft: {
|
| 867 |
+
prettyLabel: "MTVCraft",
|
| 868 |
+
repoName: "MTVCraft",
|
| 869 |
+
repoUrl: "https://github.com/baaivision/MTVCraft",
|
| 870 |
+
filter: false,
|
| 871 |
+
countDownloads: `path:"vae/3d-vae.pt"`,
|
| 872 |
+
},
|
| 873 |
+
nemo: {
|
| 874 |
+
prettyLabel: "NeMo",
|
| 875 |
+
repoName: "NeMo",
|
| 876 |
+
repoUrl: "https://github.com/NVIDIA/NeMo",
|
| 877 |
+
snippets: snippets.nemo,
|
| 878 |
+
filter: true,
|
| 879 |
+
countDownloads: `path_extension:"nemo" OR path:"model_config.yaml" OR path_extension:"json"`,
|
| 880 |
+
},
|
| 881 |
+
"open-oasis": {
|
| 882 |
+
prettyLabel: "open-oasis",
|
| 883 |
+
repoName: "open-oasis",
|
| 884 |
+
repoUrl: "https://github.com/etched-ai/open-oasis",
|
| 885 |
+
countDownloads: `path:"oasis500m.safetensors"`,
|
| 886 |
+
},
|
| 887 |
+
open_clip: {
|
| 888 |
+
prettyLabel: "OpenCLIP",
|
| 889 |
+
repoName: "OpenCLIP",
|
| 890 |
+
repoUrl: "https://github.com/mlfoundations/open_clip",
|
| 891 |
+
snippets: snippets.open_clip,
|
| 892 |
+
filter: true,
|
| 893 |
+
countDownloads: `path:"open_clip_model.safetensors"
|
| 894 |
+
OR path:"model.safetensors"
|
| 895 |
+
OR path:"open_clip_pytorch_model.bin"
|
| 896 |
+
OR path:"pytorch_model.bin"`,
|
| 897 |
+
},
|
| 898 |
+
openpeerllm: {
|
| 899 |
+
prettyLabel: "OpenPeerLLM",
|
| 900 |
+
repoName: "OpenPeerLLM",
|
| 901 |
+
repoUrl: "https://huggingface.co/openpeerai/openpeerllm",
|
| 902 |
+
docsUrl: "https://huggingface.co/OpenPeerAI/OpenPeerLLM/blob/main/README.md",
|
| 903 |
+
countDownloads: `path:".meta-huggingface.json"`,
|
| 904 |
+
filter: false,
|
| 905 |
+
},
|
| 906 |
+
"open-sora": {
|
| 907 |
+
prettyLabel: "Open-Sora",
|
| 908 |
+
repoName: "Open-Sora",
|
| 909 |
+
repoUrl: "https://github.com/hpcaitech/Open-Sora",
|
| 910 |
+
filter: false,
|
| 911 |
+
countDownloads: `path:"Open_Sora_v2.safetensors"`,
|
| 912 |
+
},
|
| 913 |
+
outetts: {
|
| 914 |
+
prettyLabel: "OuteTTS",
|
| 915 |
+
repoName: "OuteTTS",
|
| 916 |
+
repoUrl: "https://github.com/edwko/OuteTTS",
|
| 917 |
+
snippets: snippets.outetts,
|
| 918 |
+
filter: false,
|
| 919 |
+
},
|
| 920 |
+
paddlenlp: {
|
| 921 |
+
prettyLabel: "paddlenlp",
|
| 922 |
+
repoName: "PaddleNLP",
|
| 923 |
+
repoUrl: "https://github.com/PaddlePaddle/PaddleNLP",
|
| 924 |
+
docsUrl: "https://huggingface.co/docs/hub/paddlenlp",
|
| 925 |
+
snippets: snippets.paddlenlp,
|
| 926 |
+
filter: true,
|
| 927 |
+
countDownloads: `path:"model_config.json"`,
|
| 928 |
+
},
|
| 929 |
+
PaddleOCR: {
|
| 930 |
+
prettyLabel: "PaddleOCR",
|
| 931 |
+
repoName: "PaddleOCR",
|
| 932 |
+
repoUrl: "https://github.com/PaddlePaddle/PaddleOCR",
|
| 933 |
+
docsUrl: "https://www.paddleocr.ai/",
|
| 934 |
+
snippets: snippets.paddleocr,
|
| 935 |
+
filter: true,
|
| 936 |
+
countDownloads: `path_extension:"safetensors" OR path:"inference.pdiparams"`,
|
| 937 |
+
},
|
| 938 |
+
peft: {
|
| 939 |
+
prettyLabel: "PEFT",
|
| 940 |
+
repoName: "PEFT",
|
| 941 |
+
repoUrl: "https://github.com/huggingface/peft",
|
| 942 |
+
snippets: snippets.peft,
|
| 943 |
+
filter: true,
|
| 944 |
+
countDownloads: `path:"adapter_config.json"`,
|
| 945 |
+
},
|
| 946 |
+
"perception-encoder": {
|
| 947 |
+
prettyLabel: "PerceptionEncoder",
|
| 948 |
+
repoName: "PerceptionModels",
|
| 949 |
+
repoUrl: "https://github.com/facebookresearch/perception_models",
|
| 950 |
+
filter: false,
|
| 951 |
+
snippets: snippets.perception_encoder,
|
| 952 |
+
countDownloads: `path_extension:"pt"`,
|
| 953 |
+
},
|
| 954 |
+
"phantom-wan": {
|
| 955 |
+
prettyLabel: "Phantom",
|
| 956 |
+
repoName: "Phantom",
|
| 957 |
+
repoUrl: "https://github.com/Phantom-video/Phantom",
|
| 958 |
+
snippets: snippets.phantom_wan,
|
| 959 |
+
filter: false,
|
| 960 |
+
countDownloads: `path_extension:"pth"`,
|
| 961 |
+
},
|
| 962 |
+
"pocket-tts": {
|
| 963 |
+
prettyLabel: "Pocket-TTS",
|
| 964 |
+
repoName: "PocketTTS",
|
| 965 |
+
repoUrl: "https://github.com/kyutai-labs/pocket-tts",
|
| 966 |
+
snippets: snippets.pocket_tts,
|
| 967 |
+
filter: false,
|
| 968 |
+
countDownloads: `path:"tts_b6369a24.safetensors"`,
|
| 969 |
+
},
|
| 970 |
+
"pruna-ai": {
|
| 971 |
+
prettyLabel: "Pruna AI",
|
| 972 |
+
repoName: "Pruna AI",
|
| 973 |
+
repoUrl: "https://github.com/PrunaAI/pruna",
|
| 974 |
+
snippets: snippets.pruna,
|
| 975 |
+
docsUrl: "https://docs.pruna.ai",
|
| 976 |
+
},
|
| 977 |
+
pxia: {
|
| 978 |
+
prettyLabel: "pxia",
|
| 979 |
+
repoName: "pxia",
|
| 980 |
+
repoUrl: "https://github.com/not-lain/pxia",
|
| 981 |
+
snippets: snippets.pxia,
|
| 982 |
+
filter: false,
|
| 983 |
+
},
|
| 984 |
+
"pyannote-audio": {
|
| 985 |
+
prettyLabel: "pyannote.audio",
|
| 986 |
+
repoName: "pyannote-audio",
|
| 987 |
+
repoUrl: "https://github.com/pyannote/pyannote-audio",
|
| 988 |
+
snippets: snippets.pyannote_audio,
|
| 989 |
+
filter: true,
|
| 990 |
+
},
|
| 991 |
+
"py-feat": {
|
| 992 |
+
prettyLabel: "Py-Feat",
|
| 993 |
+
repoName: "Py-Feat",
|
| 994 |
+
repoUrl: "https://github.com/cosanlab/py-feat",
|
| 995 |
+
docsUrl: "https://py-feat.org/",
|
| 996 |
+
filter: false,
|
| 997 |
+
},
|
| 998 |
+
pythae: {
|
| 999 |
+
prettyLabel: "pythae",
|
| 1000 |
+
repoName: "pythae",
|
| 1001 |
+
repoUrl: "https://github.com/clementchadebec/benchmark_VAE",
|
| 1002 |
+
snippets: snippets.pythae,
|
| 1003 |
+
filter: false,
|
| 1004 |
+
},
|
| 1005 |
+
quantumpeer: {
|
| 1006 |
+
prettyLabel: "QuantumPeer",
|
| 1007 |
+
repoName: "QuantumPeer",
|
| 1008 |
+
repoUrl: "https://github.com/OpenPeer-AI/QuantumPeer",
|
| 1009 |
+
filter: false,
|
| 1010 |
+
countDownloads: `path_extension:"setup.py"`,
|
| 1011 |
+
},
|
| 1012 |
+
qwen3_tts: {
|
| 1013 |
+
prettyLabel: "Qwen3-TTS",
|
| 1014 |
+
repoName: "Qwen3-TTS",
|
| 1015 |
+
repoUrl: "https://github.com/QwenLM/Qwen3-TTS",
|
| 1016 |
+
snippets: snippets.qwen3_tts,
|
| 1017 |
+
filter: false,
|
| 1018 |
+
},
|
| 1019 |
+
recurrentgemma: {
|
| 1020 |
+
prettyLabel: "RecurrentGemma",
|
| 1021 |
+
repoName: "recurrentgemma",
|
| 1022 |
+
repoUrl: "https://github.com/google-deepmind/recurrentgemma",
|
| 1023 |
+
filter: false,
|
| 1024 |
+
countDownloads: `path:"tokenizer.model"`,
|
| 1025 |
+
},
|
| 1026 |
+
relik: {
|
| 1027 |
+
prettyLabel: "Relik",
|
| 1028 |
+
repoName: "Relik",
|
| 1029 |
+
repoUrl: "https://github.com/SapienzaNLP/relik",
|
| 1030 |
+
snippets: snippets.relik,
|
| 1031 |
+
filter: false,
|
| 1032 |
+
},
|
| 1033 |
+
refiners: {
|
| 1034 |
+
prettyLabel: "Refiners",
|
| 1035 |
+
repoName: "Refiners",
|
| 1036 |
+
repoUrl: "https://github.com/finegrain-ai/refiners",
|
| 1037 |
+
docsUrl: "https://refine.rs/",
|
| 1038 |
+
filter: false,
|
| 1039 |
+
countDownloads: `path:"model.safetensors"`,
|
| 1040 |
+
},
|
| 1041 |
+
renderformer: {
|
| 1042 |
+
prettyLabel: "RenderFormer",
|
| 1043 |
+
repoName: "RenderFormer",
|
| 1044 |
+
repoUrl: "https://github.com/microsoft/renderformer",
|
| 1045 |
+
snippets: snippets.renderformer,
|
| 1046 |
+
filter: false,
|
| 1047 |
+
},
|
| 1048 |
+
reverb: {
|
| 1049 |
+
prettyLabel: "Reverb",
|
| 1050 |
+
repoName: "Reverb",
|
| 1051 |
+
repoUrl: "https://github.com/revdotcom/reverb",
|
| 1052 |
+
filter: false,
|
| 1053 |
+
},
|
| 1054 |
+
rkllm: {
|
| 1055 |
+
prettyLabel: "RKLLM",
|
| 1056 |
+
repoName: "RKLLM",
|
| 1057 |
+
repoUrl: "https://github.com/airockchip/rknn-llm",
|
| 1058 |
+
countDownloads: `path_extension:"rkllm"`,
|
| 1059 |
+
},
|
| 1060 |
+
saelens: {
|
| 1061 |
+
prettyLabel: "SAELens",
|
| 1062 |
+
repoName: "SAELens",
|
| 1063 |
+
repoUrl: "https://github.com/jbloomAus/SAELens",
|
| 1064 |
+
snippets: snippets.saelens,
|
| 1065 |
+
filter: false,
|
| 1066 |
+
},
|
| 1067 |
+
sam2: {
|
| 1068 |
+
prettyLabel: "sam2",
|
| 1069 |
+
repoName: "sam2",
|
| 1070 |
+
repoUrl: "https://github.com/facebookresearch/segment-anything-2",
|
| 1071 |
+
filter: false,
|
| 1072 |
+
snippets: snippets.sam2,
|
| 1073 |
+
countDownloads: `path_extension:"pt"`,
|
| 1074 |
+
},
|
| 1075 |
+
"sam-3d-body": {
|
| 1076 |
+
prettyLabel: "SAM 3D Body",
|
| 1077 |
+
repoName: "SAM 3D Body",
|
| 1078 |
+
repoUrl: "https://github.com/facebookresearch/sam-3d-body",
|
| 1079 |
+
filter: false,
|
| 1080 |
+
snippets: snippets.sam_3d_body,
|
| 1081 |
+
countDownloads: `path:"model_config.yaml"`,
|
| 1082 |
+
},
|
| 1083 |
+
"sam-3d-objects": {
|
| 1084 |
+
prettyLabel: "SAM 3D Objects",
|
| 1085 |
+
repoName: "SAM 3D Objects",
|
| 1086 |
+
repoUrl: "https://github.com/facebookresearch/sam-3d-objects",
|
| 1087 |
+
filter: false,
|
| 1088 |
+
snippets: snippets.sam_3d_objects,
|
| 1089 |
+
countDownloads: `path:"checkpoints/pipeline.yaml"`,
|
| 1090 |
+
},
|
| 1091 |
+
same: {
|
| 1092 |
+
prettyLabel: "SAME",
|
| 1093 |
+
repoName: "SAME",
|
| 1094 |
+
repoUrl: "https://github.com/GengzeZhou/SAME",
|
| 1095 |
+
filter: false,
|
| 1096 |
+
countDownloads: `path:"ckpt/SAME.pt" OR path:"pretrain/Attnq_pretrained_ckpt.pt"`,
|
| 1097 |
+
},
|
| 1098 |
+
"sample-factory": {
|
| 1099 |
+
prettyLabel: "sample-factory",
|
| 1100 |
+
repoName: "sample-factory",
|
| 1101 |
+
repoUrl: "https://github.com/alex-petrenko/sample-factory",
|
| 1102 |
+
docsUrl: "https://huggingface.co/docs/hub/sample-factory",
|
| 1103 |
+
snippets: snippets.sampleFactory,
|
| 1104 |
+
filter: true,
|
| 1105 |
+
countDownloads: `path:"cfg.json"`,
|
| 1106 |
+
},
|
| 1107 |
+
"sap-rpt-1-oss": {
|
| 1108 |
+
prettyLabel: "sap-rpt-1-oss",
|
| 1109 |
+
repoName: "sap-rpt-1-oss",
|
| 1110 |
+
repoUrl: "https://github.com/SAP-samples/sap-rpt-1-oss",
|
| 1111 |
+
countDownloads: `path_extension:"pt"`,
|
| 1112 |
+
snippets: snippets.sap_rpt_one_oss,
|
| 1113 |
+
},
|
| 1114 |
+
sapiens: {
|
| 1115 |
+
prettyLabel: "sapiens",
|
| 1116 |
+
repoName: "sapiens",
|
| 1117 |
+
repoUrl: "https://github.com/facebookresearch/sapiens",
|
| 1118 |
+
filter: false,
|
| 1119 |
+
countDownloads: `path_extension:"pt2" OR path_extension:"pth" OR path_extension:"onnx"`,
|
| 1120 |
+
},
|
| 1121 |
+
seedvr: {
|
| 1122 |
+
prettyLabel: "SeedVR",
|
| 1123 |
+
repoName: "SeedVR",
|
| 1124 |
+
repoUrl: "https://github.com/ByteDance-Seed/SeedVR",
|
| 1125 |
+
filter: false,
|
| 1126 |
+
countDownloads: `path_extension:"pth"`,
|
| 1127 |
+
},
|
| 1128 |
+
"self-forcing": {
|
| 1129 |
+
prettyLabel: "SelfForcing",
|
| 1130 |
+
repoName: "SelfForcing",
|
| 1131 |
+
repoUrl: "https://github.com/guandeh17/Self-Forcing",
|
| 1132 |
+
filter: false,
|
| 1133 |
+
countDownloads: `path_extension:"pt"`,
|
| 1134 |
+
},
|
| 1135 |
+
"sentence-transformers": {
|
| 1136 |
+
prettyLabel: "sentence-transformers",
|
| 1137 |
+
repoName: "sentence-transformers",
|
| 1138 |
+
repoUrl: "https://github.com/UKPLab/sentence-transformers",
|
| 1139 |
+
docsUrl: "https://huggingface.co/docs/hub/sentence-transformers",
|
| 1140 |
+
snippets: snippets.sentenceTransformers,
|
| 1141 |
+
filter: true,
|
| 1142 |
+
},
|
| 1143 |
+
setfit: {
|
| 1144 |
+
prettyLabel: "setfit",
|
| 1145 |
+
repoName: "setfit",
|
| 1146 |
+
repoUrl: "https://github.com/huggingface/setfit",
|
| 1147 |
+
docsUrl: "https://huggingface.co/docs/hub/setfit",
|
| 1148 |
+
snippets: snippets.setfit,
|
| 1149 |
+
filter: true,
|
| 1150 |
+
},
|
| 1151 |
+
sklearn: {
|
| 1152 |
+
prettyLabel: "Scikit-learn",
|
| 1153 |
+
repoName: "Scikit-learn",
|
| 1154 |
+
repoUrl: "https://github.com/scikit-learn/scikit-learn",
|
| 1155 |
+
snippets: snippets.sklearn,
|
| 1156 |
+
filter: true,
|
| 1157 |
+
countDownloads: `path:"sklearn_model.joblib"`,
|
| 1158 |
+
},
|
| 1159 |
+
spacy: {
|
| 1160 |
+
prettyLabel: "spaCy",
|
| 1161 |
+
repoName: "spaCy",
|
| 1162 |
+
repoUrl: "https://github.com/explosion/spaCy",
|
| 1163 |
+
docsUrl: "https://huggingface.co/docs/hub/spacy",
|
| 1164 |
+
snippets: snippets.spacy,
|
| 1165 |
+
filter: true,
|
| 1166 |
+
countDownloads: `path_extension:"whl"`,
|
| 1167 |
+
},
|
| 1168 |
+
"span-marker": {
|
| 1169 |
+
prettyLabel: "SpanMarker",
|
| 1170 |
+
repoName: "SpanMarkerNER",
|
| 1171 |
+
repoUrl: "https://github.com/tomaarsen/SpanMarkerNER",
|
| 1172 |
+
docsUrl: "https://huggingface.co/docs/hub/span_marker",
|
| 1173 |
+
snippets: snippets.span_marker,
|
| 1174 |
+
filter: true,
|
| 1175 |
+
},
|
| 1176 |
+
speechbrain: {
|
| 1177 |
+
prettyLabel: "speechbrain",
|
| 1178 |
+
repoName: "speechbrain",
|
| 1179 |
+
repoUrl: "https://github.com/speechbrain/speechbrain",
|
| 1180 |
+
docsUrl: "https://huggingface.co/docs/hub/speechbrain",
|
| 1181 |
+
snippets: snippets.speechbrain,
|
| 1182 |
+
filter: true,
|
| 1183 |
+
countDownloads: `path:"hyperparams.yaml"`,
|
| 1184 |
+
},
|
| 1185 |
+
"ssr-speech": {
|
| 1186 |
+
prettyLabel: "SSR-Speech",
|
| 1187 |
+
repoName: "SSR-Speech",
|
| 1188 |
+
repoUrl: "https://github.com/WangHelin1997/SSR-Speech",
|
| 1189 |
+
filter: false,
|
| 1190 |
+
countDownloads: `path_extension:".pth"`,
|
| 1191 |
+
},
|
| 1192 |
+
"stable-audio-tools": {
|
| 1193 |
+
prettyLabel: "Stable Audio Tools",
|
| 1194 |
+
repoName: "stable-audio-tools",
|
| 1195 |
+
repoUrl: "https://github.com/Stability-AI/stable-audio-tools.git",
|
| 1196 |
+
filter: false,
|
| 1197 |
+
countDownloads: `path:"model.safetensors"`,
|
| 1198 |
+
snippets: snippets.stable_audio_tools,
|
| 1199 |
+
},
|
| 1200 |
+
monkeyocr: {
|
| 1201 |
+
prettyLabel: "MonkeyOCR",
|
| 1202 |
+
repoName: "monkeyocr",
|
| 1203 |
+
repoUrl: "https://github.com/Yuliang-Liu/MonkeyOCR",
|
| 1204 |
+
filter: false,
|
| 1205 |
+
countDownloads: `path:"Recognition/config.json"`,
|
| 1206 |
+
},
|
| 1207 |
+
"diffusion-single-file": {
|
| 1208 |
+
prettyLabel: "Diffusion Single File",
|
| 1209 |
+
repoName: "diffusion-single-file",
|
| 1210 |
+
repoUrl: "https://github.com/comfyanonymous/ComfyUI",
|
| 1211 |
+
filter: false,
|
| 1212 |
+
countDownloads: `path_extension:"safetensors"`,
|
| 1213 |
+
},
|
| 1214 |
+
"seed-story": {
|
| 1215 |
+
prettyLabel: "SEED-Story",
|
| 1216 |
+
repoName: "SEED-Story",
|
| 1217 |
+
repoUrl: "https://github.com/TencentARC/SEED-Story",
|
| 1218 |
+
filter: false,
|
| 1219 |
+
countDownloads: `path:"cvlm_llama2_tokenizer/tokenizer.model"`,
|
| 1220 |
+
snippets: snippets.seed_story,
|
| 1221 |
+
},
|
| 1222 |
+
soloaudio: {
|
| 1223 |
+
prettyLabel: "SoloAudio",
|
| 1224 |
+
repoName: "SoloAudio",
|
| 1225 |
+
repoUrl: "https://github.com/WangHelin1997/SoloAudio",
|
| 1226 |
+
filter: false,
|
| 1227 |
+
countDownloads: `path:"soloaudio_v2.pt"`,
|
| 1228 |
+
},
|
| 1229 |
+
songbloom: {
|
| 1230 |
+
prettyLabel: "SongBloom",
|
| 1231 |
+
repoName: "SongBloom",
|
| 1232 |
+
repoUrl: "https://github.com/Cypress-Yang/SongBloom",
|
| 1233 |
+
filter: false,
|
| 1234 |
+
countDownloads: `path_extension:"pt"`,
|
| 1235 |
+
},
|
| 1236 |
+
"stable-baselines3": {
|
| 1237 |
+
prettyLabel: "stable-baselines3",
|
| 1238 |
+
repoName: "stable-baselines3",
|
| 1239 |
+
repoUrl: "https://github.com/huggingface/huggingface_sb3",
|
| 1240 |
+
docsUrl: "https://huggingface.co/docs/hub/stable-baselines3",
|
| 1241 |
+
snippets: snippets.stableBaselines3,
|
| 1242 |
+
filter: true,
|
| 1243 |
+
countDownloads: `path_extension:"zip"`,
|
| 1244 |
+
},
|
| 1245 |
+
stanza: {
|
| 1246 |
+
prettyLabel: "Stanza",
|
| 1247 |
+
repoName: "stanza",
|
| 1248 |
+
repoUrl: "https://github.com/stanfordnlp/stanza",
|
| 1249 |
+
docsUrl: "https://huggingface.co/docs/hub/stanza",
|
| 1250 |
+
snippets: snippets.stanza,
|
| 1251 |
+
filter: true,
|
| 1252 |
+
countDownloads: `path:"models/default.zip"`,
|
| 1253 |
+
},
|
| 1254 |
+
supertonic: {
|
| 1255 |
+
prettyLabel: "Supertonic",
|
| 1256 |
+
repoName: "Supertonic",
|
| 1257 |
+
repoUrl: "https://github.com/supertone-inc/supertonic",
|
| 1258 |
+
snippets: snippets.supertonic,
|
| 1259 |
+
filter: false,
|
| 1260 |
+
},
|
| 1261 |
+
swarmformer: {
|
| 1262 |
+
prettyLabel: "SwarmFormer",
|
| 1263 |
+
repoName: "SwarmFormer",
|
| 1264 |
+
repoUrl: "https://github.com/takara-ai/SwarmFormer",
|
| 1265 |
+
snippets: snippets.swarmformer,
|
| 1266 |
+
filter: false,
|
| 1267 |
+
},
|
| 1268 |
+
"f5-tts": {
|
| 1269 |
+
prettyLabel: "F5-TTS",
|
| 1270 |
+
repoName: "F5-TTS",
|
| 1271 |
+
repoUrl: "https://github.com/SWivid/F5-TTS",
|
| 1272 |
+
filter: false,
|
| 1273 |
+
countDownloads: `path_extension:"safetensors" OR path_extension:"pt"`,
|
| 1274 |
+
},
|
| 1275 |
+
genmo: {
|
| 1276 |
+
prettyLabel: "Genmo",
|
| 1277 |
+
repoName: "Genmo",
|
| 1278 |
+
repoUrl: "https://github.com/genmoai/models",
|
| 1279 |
+
filter: false,
|
| 1280 |
+
countDownloads: `path:"vae_stats.json"`,
|
| 1281 |
+
},
|
| 1282 |
+
"tencent-song-generation": {
|
| 1283 |
+
prettyLabel: "SongGeneration",
|
| 1284 |
+
repoName: "SongGeneration",
|
| 1285 |
+
repoUrl: "https://github.com/tencent-ailab/songgeneration",
|
| 1286 |
+
filter: false,
|
| 1287 |
+
countDownloads: `path:"ckpt/songgeneration_base/model.pt"`,
|
| 1288 |
+
},
|
| 1289 |
+
tensorflowtts: {
|
| 1290 |
+
prettyLabel: "TensorFlowTTS",
|
| 1291 |
+
repoName: "TensorFlowTTS",
|
| 1292 |
+
repoUrl: "https://github.com/TensorSpeech/TensorFlowTTS",
|
| 1293 |
+
snippets: snippets.tensorflowtts,
|
| 1294 |
+
},
|
| 1295 |
+
tensorrt: {
|
| 1296 |
+
prettyLabel: "TensorRT",
|
| 1297 |
+
repoName: "TensorRT",
|
| 1298 |
+
repoUrl: "https://github.com/NVIDIA/TensorRT",
|
| 1299 |
+
countDownloads: `path_extension:"onnx"`,
|
| 1300 |
+
},
|
| 1301 |
+
tabpfn: {
|
| 1302 |
+
prettyLabel: "TabPFN",
|
| 1303 |
+
repoName: "TabPFN",
|
| 1304 |
+
repoUrl: "https://github.com/PriorLabs/TabPFN",
|
| 1305 |
+
},
|
| 1306 |
+
terratorch: {
|
| 1307 |
+
prettyLabel: "TerraTorch",
|
| 1308 |
+
repoName: "TerraTorch",
|
| 1309 |
+
repoUrl: "https://github.com/IBM/terratorch",
|
| 1310 |
+
docsUrl: "https://ibm.github.io/terratorch/",
|
| 1311 |
+
filter: false,
|
| 1312 |
+
countDownloads: `path_extension:"pt" OR path_extension:"ckpt"`,
|
| 1313 |
+
snippets: snippets.terratorch,
|
| 1314 |
+
},
|
| 1315 |
+
"tic-clip": {
|
| 1316 |
+
prettyLabel: "TiC-CLIP",
|
| 1317 |
+
repoName: "TiC-CLIP",
|
| 1318 |
+
repoUrl: "https://github.com/apple/ml-tic-clip",
|
| 1319 |
+
filter: false,
|
| 1320 |
+
countDownloads: `path_extension:"pt" AND path_prefix:"checkpoints/"`,
|
| 1321 |
+
},
|
| 1322 |
+
timesfm: {
|
| 1323 |
+
prettyLabel: "TimesFM",
|
| 1324 |
+
repoName: "timesfm",
|
| 1325 |
+
repoUrl: "https://github.com/google-research/timesfm",
|
| 1326 |
+
filter: false,
|
| 1327 |
+
countDownloads: `path:"checkpoints/checkpoint_1100000/state/checkpoint" OR path:"checkpoints/checkpoint_2150000/state/checkpoint" OR path_extension:"ckpt"`,
|
| 1328 |
+
},
|
| 1329 |
+
timm: {
|
| 1330 |
+
prettyLabel: "timm",
|
| 1331 |
+
repoName: "pytorch-image-models",
|
| 1332 |
+
repoUrl: "https://github.com/rwightman/pytorch-image-models",
|
| 1333 |
+
docsUrl: "https://huggingface.co/docs/hub/timm",
|
| 1334 |
+
snippets: snippets.timm,
|
| 1335 |
+
filter: true,
|
| 1336 |
+
countDownloads: `path:"pytorch_model.bin" OR path:"model.safetensors"`,
|
| 1337 |
+
},
|
| 1338 |
+
tirex: {
|
| 1339 |
+
prettyLabel: "TiRex",
|
| 1340 |
+
repoName: "TiRex",
|
| 1341 |
+
repoUrl: "https://github.com/NX-AI/tirex",
|
| 1342 |
+
countDownloads: `path_extension:"ckpt"`,
|
| 1343 |
+
},
|
| 1344 |
+
torchgeo: {
|
| 1345 |
+
prettyLabel: "TorchGeo",
|
| 1346 |
+
repoName: "TorchGeo",
|
| 1347 |
+
repoUrl: "https://github.com/microsoft/torchgeo",
|
| 1348 |
+
docsUrl: "https://torchgeo.readthedocs.io/",
|
| 1349 |
+
filter: false,
|
| 1350 |
+
countDownloads: `path_extension:"pt" OR path_extension:"pth"`,
|
| 1351 |
+
},
|
| 1352 |
+
transformers: {
|
| 1353 |
+
prettyLabel: "Transformers",
|
| 1354 |
+
repoName: "🤗/transformers",
|
| 1355 |
+
repoUrl: "https://github.com/huggingface/transformers",
|
| 1356 |
+
docsUrl: "https://huggingface.co/docs/hub/transformers",
|
| 1357 |
+
snippets: snippets.transformers,
|
| 1358 |
+
filter: true,
|
| 1359 |
+
},
|
| 1360 |
+
"transformers.js": {
|
| 1361 |
+
prettyLabel: "Transformers.js",
|
| 1362 |
+
repoName: "transformers.js",
|
| 1363 |
+
repoUrl: "https://github.com/huggingface/transformers.js",
|
| 1364 |
+
docsUrl: "https://huggingface.co/docs/hub/transformers-js",
|
| 1365 |
+
snippets: snippets.transformersJS,
|
| 1366 |
+
filter: true,
|
| 1367 |
+
},
|
| 1368 |
+
trellis: {
|
| 1369 |
+
prettyLabel: "Trellis",
|
| 1370 |
+
repoName: "Trellis",
|
| 1371 |
+
repoUrl: "https://github.com/microsoft/TRELLIS",
|
| 1372 |
+
countDownloads: `path_extension:"safetensors"`,
|
| 1373 |
+
},
|
| 1374 |
+
ultralytics: {
|
| 1375 |
+
prettyLabel: "ultralytics",
|
| 1376 |
+
repoName: "ultralytics",
|
| 1377 |
+
repoUrl: "https://github.com/ultralytics/ultralytics",
|
| 1378 |
+
docsUrl: "https://github.com/ultralytics/ultralytics",
|
| 1379 |
+
filter: false,
|
| 1380 |
+
countDownloads: `path_extension:"pt"`,
|
| 1381 |
+
snippets: snippets.ultralytics,
|
| 1382 |
+
},
|
| 1383 |
+
univa: {
|
| 1384 |
+
prettyLabel: "univa",
|
| 1385 |
+
repoName: "univa",
|
| 1386 |
+
repoUrl: "https://github.com/PKU-YuanGroup/UniWorld-V1",
|
| 1387 |
+
snippets: snippets.univa,
|
| 1388 |
+
filter: true,
|
| 1389 |
+
countDownloads: `path:"config.json"`,
|
| 1390 |
+
},
|
| 1391 |
+
"uni-3dar": {
|
| 1392 |
+
prettyLabel: "Uni-3DAR",
|
| 1393 |
+
repoName: "Uni-3DAR",
|
| 1394 |
+
repoUrl: "https://github.com/dptech-corp/Uni-3DAR",
|
| 1395 |
+
docsUrl: "https://github.com/dptech-corp/Uni-3DAR",
|
| 1396 |
+
countDownloads: `path_extension:"pt"`,
|
| 1397 |
+
},
|
| 1398 |
+
"unity-sentis": {
|
| 1399 |
+
prettyLabel: "unity-sentis",
|
| 1400 |
+
repoName: "unity-sentis",
|
| 1401 |
+
repoUrl: "https://github.com/Unity-Technologies/sentis-samples",
|
| 1402 |
+
snippets: snippets.sentis,
|
| 1403 |
+
filter: true,
|
| 1404 |
+
countDownloads: `path_extension:"sentis"`,
|
| 1405 |
+
},
|
| 1406 |
+
sana: {
|
| 1407 |
+
prettyLabel: "Sana",
|
| 1408 |
+
repoName: "Sana",
|
| 1409 |
+
repoUrl: "https://github.com/NVlabs/Sana",
|
| 1410 |
+
countDownloads: `path_extension:"pth"`,
|
| 1411 |
+
snippets: snippets.sana,
|
| 1412 |
+
},
|
| 1413 |
+
videoprism: {
|
| 1414 |
+
prettyLabel: "VideoPrism",
|
| 1415 |
+
repoName: "VideoPrism",
|
| 1416 |
+
repoUrl: "https://github.com/google-deepmind/videoprism",
|
| 1417 |
+
countDownloads: `path_extension:"npz"`,
|
| 1418 |
+
snippets: snippets.videoprism,
|
| 1419 |
+
},
|
| 1420 |
+
"vfi-mamba": {
|
| 1421 |
+
prettyLabel: "VFIMamba",
|
| 1422 |
+
repoName: "VFIMamba",
|
| 1423 |
+
repoUrl: "https://github.com/MCG-NJU/VFIMamba",
|
| 1424 |
+
countDownloads: `path_extension:"pkl"`,
|
| 1425 |
+
snippets: snippets.vfimamba,
|
| 1426 |
+
},
|
| 1427 |
+
vismatch: {
|
| 1428 |
+
prettyLabel: "VisMatch",
|
| 1429 |
+
repoName: "VisMatch",
|
| 1430 |
+
repoUrl: "https://github.com/gmberton/vismatch",
|
| 1431 |
+
filter: false,
|
| 1432 |
+
countDownloads: `path:"vismatch.yaml"`,
|
| 1433 |
+
},
|
| 1434 |
+
lvface: {
|
| 1435 |
+
prettyLabel: "LVFace",
|
| 1436 |
+
repoName: "LVFace",
|
| 1437 |
+
repoUrl: "https://github.com/bytedance/LVFace",
|
| 1438 |
+
countDownloads: `path_extension:"pt" OR path_extension:"onnx"`,
|
| 1439 |
+
snippets: snippets.lvface,
|
| 1440 |
+
},
|
| 1441 |
+
voicecraft: {
|
| 1442 |
+
prettyLabel: "VoiceCraft",
|
| 1443 |
+
repoName: "VoiceCraft",
|
| 1444 |
+
repoUrl: "https://github.com/jasonppy/VoiceCraft",
|
| 1445 |
+
docsUrl: "https://github.com/jasonppy/VoiceCraft",
|
| 1446 |
+
snippets: snippets.voicecraft,
|
| 1447 |
+
},
|
| 1448 |
+
voxcpm: {
|
| 1449 |
+
prettyLabel: "VoxCPM",
|
| 1450 |
+
repoName: "VoxCPM",
|
| 1451 |
+
repoUrl: "https://github.com/OpenBMB/VoxCPM",
|
| 1452 |
+
snippets: snippets.voxcpm,
|
| 1453 |
+
filter: false,
|
| 1454 |
+
},
|
| 1455 |
+
vui: {
|
| 1456 |
+
prettyLabel: "Vui",
|
| 1457 |
+
repoName: "Vui",
|
| 1458 |
+
repoUrl: "https://github.com/vui-ai/vui",
|
| 1459 |
+
countDownloads: `path_extension:"pt"`,
|
| 1460 |
+
snippets: snippets.vui,
|
| 1461 |
+
},
|
| 1462 |
+
vibevoice: {
|
| 1463 |
+
prettyLabel: "VibeVoice",
|
| 1464 |
+
repoName: "VibeVoice",
|
| 1465 |
+
repoUrl: "https://github.com/microsoft/VibeVoice",
|
| 1466 |
+
snippets: snippets.vibevoice,
|
| 1467 |
+
filter: false,
|
| 1468 |
+
},
|
| 1469 |
+
videox_fun: {
|
| 1470 |
+
prettyLabel: "VideoX Fun",
|
| 1471 |
+
repoName: "VideoX Fun",
|
| 1472 |
+
repoUrl: "https://github.com/aigc-apps/VideoX-Fun",
|
| 1473 |
+
filter: false,
|
| 1474 |
+
countDownloads: `path_extension:"safetensors"`,
|
| 1475 |
+
},
|
| 1476 |
+
"wan2.2": {
|
| 1477 |
+
prettyLabel: "Wan2.2",
|
| 1478 |
+
repoName: "Wan2.2",
|
| 1479 |
+
repoUrl: "https://github.com/Wan-Video/Wan2.2",
|
| 1480 |
+
countDownloads: `path_filename:"config" AND path_extension:"json"`,
|
| 1481 |
+
},
|
| 1482 |
+
wham: {
|
| 1483 |
+
prettyLabel: "WHAM",
|
| 1484 |
+
repoName: "wham",
|
| 1485 |
+
repoUrl: "https://huggingface.co/microsoft/wham",
|
| 1486 |
+
docsUrl: "https://huggingface.co/microsoft/wham/blob/main/README.md",
|
| 1487 |
+
countDownloads: `path_extension:"ckpt"`,
|
| 1488 |
+
},
|
| 1489 |
+
whisperkit: {
|
| 1490 |
+
prettyLabel: "WhisperKit",
|
| 1491 |
+
repoName: "WhisperKit",
|
| 1492 |
+
repoUrl: "https://github.com/argmaxinc/WhisperKit",
|
| 1493 |
+
docsUrl: "https://github.com/argmaxinc/WhisperKit?tab=readme-ov-file#homebrew",
|
| 1494 |
+
snippets: snippets.whisperkit,
|
| 1495 |
+
countDownloads: `path_filename:"model" AND path_extension:"mil" AND _exists_:"path_prefix"`,
|
| 1496 |
+
},
|
| 1497 |
+
yolov10: {
|
| 1498 |
+
// YOLOv10 is a fork of ultraLytics. Code snippets and download count are the same but the repo is different.
|
| 1499 |
+
prettyLabel: "YOLOv10",
|
| 1500 |
+
repoName: "YOLOv10",
|
| 1501 |
+
repoUrl: "https://github.com/THU-MIG/yolov10",
|
| 1502 |
+
docsUrl: "https://github.com/THU-MIG/yolov10",
|
| 1503 |
+
countDownloads: `path_extension:"pt" OR path_extension:"safetensors"`,
|
| 1504 |
+
snippets: snippets.ultralytics,
|
| 1505 |
+
},
|
| 1506 |
+
yolov26: {
|
| 1507 |
+
prettyLabel: "YOLOv26",
|
| 1508 |
+
repoName: "YOLOv26",
|
| 1509 |
+
repoUrl: "https://github.com/ultralytics/ultralytics",
|
| 1510 |
+
docsUrl: "https://docs.ultralytics.com/models/yolo26/",
|
| 1511 |
+
countDownloads: `path_extension:"pt" OR path_extension:"safetensors"`,
|
| 1512 |
+
},
|
| 1513 |
+
zonos: {
|
| 1514 |
+
prettyLabel: "Zonos",
|
| 1515 |
+
repoName: "Zonos",
|
| 1516 |
+
repoUrl: "https://github.com/Zyphra/Zonos",
|
| 1517 |
+
docsUrl: "https://github.com/Zyphra/Zonos",
|
| 1518 |
+
snippets: snippets.zonos,
|
| 1519 |
+
filter: false,
|
| 1520 |
+
},
|
| 1521 |
+
"3dtopia-xl": {
|
| 1522 |
+
prettyLabel: "3DTopia-XL",
|
| 1523 |
+
repoName: "3DTopia-XL",
|
| 1524 |
+
repoUrl: "https://github.com/3DTopia/3DTopia-XL",
|
| 1525 |
+
filter: false,
|
| 1526 |
+
countDownloads: `path:"model_vae_fp16.pt"`,
|
| 1527 |
+
snippets: snippets.threedtopia_xl,
|
| 1528 |
+
},
|
| 1529 |
+
};
|
| 1530 |
+
exports.ALL_MODEL_LIBRARY_KEYS = Object.keys(exports.MODEL_LIBRARIES_UI_ELEMENTS);
|
| 1531 |
+
exports.ALL_DISPLAY_MODEL_LIBRARY_KEYS = Object.entries(exports.MODEL_LIBRARIES_UI_ELEMENTS)
|
| 1532 |
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
| 1533 |
+
.filter(([_, v]) => v.filter)
|
| 1534 |
+
.map(([k]) => k);
|
node_modules/@huggingface/tasks/dist/commonjs/package.json
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"type": "commonjs"
|
| 3 |
+
}
|
node_modules/@huggingface/tasks/dist/commonjs/pipelines.d.ts
ADDED
|
@@ -0,0 +1,385 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
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|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
export declare const MODALITIES: readonly ["multimodal", "nlp", "cv", "audio", "tabular", "rl", "other"];
|
| 2 |
+
export type Modality = (typeof MODALITIES)[number];
|
| 3 |
+
export declare const MODALITY_LABELS: {
|
| 4 |
+
multimodal: string;
|
| 5 |
+
nlp: string;
|
| 6 |
+
audio: string;
|
| 7 |
+
cv: string;
|
| 8 |
+
rl: string;
|
| 9 |
+
tabular: string;
|
| 10 |
+
other: string;
|
| 11 |
+
};
|
| 12 |
+
/**
|
| 13 |
+
* Public interface for a sub task.
|
| 14 |
+
*
|
| 15 |
+
* This can be used in a model card's `model-index` metadata.
|
| 16 |
+
* and is more granular classification that can grow significantly
|
| 17 |
+
* over time as new tasks are added.
|
| 18 |
+
*/
|
| 19 |
+
export interface SubTask {
|
| 20 |
+
/**
|
| 21 |
+
* type of the task (e.g. audio-source-separation)
|
| 22 |
+
*/
|
| 23 |
+
type: string;
|
| 24 |
+
/**
|
| 25 |
+
* displayed name of the task (e.g. Audio Source Separation)
|
| 26 |
+
*/
|
| 27 |
+
name: string;
|
| 28 |
+
}
|
| 29 |
+
/**
|
| 30 |
+
* Public interface for a PipelineData.
|
| 31 |
+
*
|
| 32 |
+
* This information corresponds to a pipeline type (aka task)
|
| 33 |
+
* in the Hub.
|
| 34 |
+
*/
|
| 35 |
+
export interface PipelineData {
|
| 36 |
+
/**
|
| 37 |
+
* displayed name of the task (e.g. Text Classification)
|
| 38 |
+
*/
|
| 39 |
+
name: string;
|
| 40 |
+
subtasks?: SubTask[];
|
| 41 |
+
modality: Modality;
|
| 42 |
+
/**
|
| 43 |
+
* whether to hide in /models filters
|
| 44 |
+
*/
|
| 45 |
+
hideInModels?: boolean;
|
| 46 |
+
/**
|
| 47 |
+
* whether to hide in /datasets filters
|
| 48 |
+
*/
|
| 49 |
+
hideInDatasets?: boolean;
|
| 50 |
+
}
|
| 51 |
+
export declare const PIPELINE_DATA: {
|
| 52 |
+
"text-classification": {
|
| 53 |
+
name: string;
|
| 54 |
+
subtasks: {
|
| 55 |
+
type: string;
|
| 56 |
+
name: string;
|
| 57 |
+
}[];
|
| 58 |
+
modality: "nlp";
|
| 59 |
+
};
|
| 60 |
+
"token-classification": {
|
| 61 |
+
name: string;
|
| 62 |
+
subtasks: {
|
| 63 |
+
type: string;
|
| 64 |
+
name: string;
|
| 65 |
+
}[];
|
| 66 |
+
modality: "nlp";
|
| 67 |
+
};
|
| 68 |
+
"table-question-answering": {
|
| 69 |
+
name: string;
|
| 70 |
+
modality: "nlp";
|
| 71 |
+
};
|
| 72 |
+
"question-answering": {
|
| 73 |
+
name: string;
|
| 74 |
+
subtasks: {
|
| 75 |
+
type: string;
|
| 76 |
+
name: string;
|
| 77 |
+
}[];
|
| 78 |
+
modality: "nlp";
|
| 79 |
+
};
|
| 80 |
+
"zero-shot-classification": {
|
| 81 |
+
name: string;
|
| 82 |
+
modality: "nlp";
|
| 83 |
+
};
|
| 84 |
+
translation: {
|
| 85 |
+
name: string;
|
| 86 |
+
modality: "nlp";
|
| 87 |
+
};
|
| 88 |
+
summarization: {
|
| 89 |
+
name: string;
|
| 90 |
+
subtasks: {
|
| 91 |
+
type: string;
|
| 92 |
+
name: string;
|
| 93 |
+
}[];
|
| 94 |
+
modality: "nlp";
|
| 95 |
+
};
|
| 96 |
+
"feature-extraction": {
|
| 97 |
+
name: string;
|
| 98 |
+
modality: "nlp";
|
| 99 |
+
};
|
| 100 |
+
"text-generation": {
|
| 101 |
+
name: string;
|
| 102 |
+
subtasks: {
|
| 103 |
+
type: string;
|
| 104 |
+
name: string;
|
| 105 |
+
}[];
|
| 106 |
+
modality: "nlp";
|
| 107 |
+
};
|
| 108 |
+
"fill-mask": {
|
| 109 |
+
name: string;
|
| 110 |
+
subtasks: {
|
| 111 |
+
type: string;
|
| 112 |
+
name: string;
|
| 113 |
+
}[];
|
| 114 |
+
modality: "nlp";
|
| 115 |
+
};
|
| 116 |
+
"sentence-similarity": {
|
| 117 |
+
name: string;
|
| 118 |
+
modality: "nlp";
|
| 119 |
+
};
|
| 120 |
+
"text-to-speech": {
|
| 121 |
+
name: string;
|
| 122 |
+
modality: "audio";
|
| 123 |
+
};
|
| 124 |
+
"text-to-audio": {
|
| 125 |
+
name: string;
|
| 126 |
+
modality: "audio";
|
| 127 |
+
};
|
| 128 |
+
"automatic-speech-recognition": {
|
| 129 |
+
name: string;
|
| 130 |
+
modality: "audio";
|
| 131 |
+
};
|
| 132 |
+
"audio-to-audio": {
|
| 133 |
+
name: string;
|
| 134 |
+
modality: "audio";
|
| 135 |
+
};
|
| 136 |
+
"audio-classification": {
|
| 137 |
+
name: string;
|
| 138 |
+
subtasks: {
|
| 139 |
+
type: string;
|
| 140 |
+
name: string;
|
| 141 |
+
}[];
|
| 142 |
+
modality: "audio";
|
| 143 |
+
};
|
| 144 |
+
"audio-text-to-text": {
|
| 145 |
+
name: string;
|
| 146 |
+
modality: "multimodal";
|
| 147 |
+
hideInDatasets: true;
|
| 148 |
+
};
|
| 149 |
+
"voice-activity-detection": {
|
| 150 |
+
name: string;
|
| 151 |
+
modality: "audio";
|
| 152 |
+
};
|
| 153 |
+
"depth-estimation": {
|
| 154 |
+
name: string;
|
| 155 |
+
modality: "cv";
|
| 156 |
+
};
|
| 157 |
+
"image-classification": {
|
| 158 |
+
name: string;
|
| 159 |
+
subtasks: {
|
| 160 |
+
type: string;
|
| 161 |
+
name: string;
|
| 162 |
+
}[];
|
| 163 |
+
modality: "cv";
|
| 164 |
+
};
|
| 165 |
+
"object-detection": {
|
| 166 |
+
name: string;
|
| 167 |
+
subtasks: {
|
| 168 |
+
type: string;
|
| 169 |
+
name: string;
|
| 170 |
+
}[];
|
| 171 |
+
modality: "cv";
|
| 172 |
+
};
|
| 173 |
+
"image-segmentation": {
|
| 174 |
+
name: string;
|
| 175 |
+
subtasks: {
|
| 176 |
+
type: string;
|
| 177 |
+
name: string;
|
| 178 |
+
}[];
|
| 179 |
+
modality: "cv";
|
| 180 |
+
};
|
| 181 |
+
"text-to-image": {
|
| 182 |
+
name: string;
|
| 183 |
+
modality: "cv";
|
| 184 |
+
};
|
| 185 |
+
"image-to-text": {
|
| 186 |
+
name: string;
|
| 187 |
+
subtasks: {
|
| 188 |
+
type: string;
|
| 189 |
+
name: string;
|
| 190 |
+
}[];
|
| 191 |
+
modality: "cv";
|
| 192 |
+
};
|
| 193 |
+
"image-to-image": {
|
| 194 |
+
name: string;
|
| 195 |
+
subtasks: {
|
| 196 |
+
type: string;
|
| 197 |
+
name: string;
|
| 198 |
+
}[];
|
| 199 |
+
modality: "cv";
|
| 200 |
+
};
|
| 201 |
+
"image-to-video": {
|
| 202 |
+
name: string;
|
| 203 |
+
modality: "cv";
|
| 204 |
+
};
|
| 205 |
+
"unconditional-image-generation": {
|
| 206 |
+
name: string;
|
| 207 |
+
modality: "cv";
|
| 208 |
+
};
|
| 209 |
+
"video-classification": {
|
| 210 |
+
name: string;
|
| 211 |
+
modality: "cv";
|
| 212 |
+
};
|
| 213 |
+
"reinforcement-learning": {
|
| 214 |
+
name: string;
|
| 215 |
+
modality: "rl";
|
| 216 |
+
};
|
| 217 |
+
robotics: {
|
| 218 |
+
name: string;
|
| 219 |
+
modality: "rl";
|
| 220 |
+
subtasks: {
|
| 221 |
+
type: string;
|
| 222 |
+
name: string;
|
| 223 |
+
}[];
|
| 224 |
+
};
|
| 225 |
+
"tabular-classification": {
|
| 226 |
+
name: string;
|
| 227 |
+
modality: "tabular";
|
| 228 |
+
subtasks: {
|
| 229 |
+
type: string;
|
| 230 |
+
name: string;
|
| 231 |
+
}[];
|
| 232 |
+
};
|
| 233 |
+
"tabular-regression": {
|
| 234 |
+
name: string;
|
| 235 |
+
modality: "tabular";
|
| 236 |
+
subtasks: {
|
| 237 |
+
type: string;
|
| 238 |
+
name: string;
|
| 239 |
+
}[];
|
| 240 |
+
};
|
| 241 |
+
"tabular-to-text": {
|
| 242 |
+
name: string;
|
| 243 |
+
modality: "tabular";
|
| 244 |
+
subtasks: {
|
| 245 |
+
type: string;
|
| 246 |
+
name: string;
|
| 247 |
+
}[];
|
| 248 |
+
hideInModels: true;
|
| 249 |
+
};
|
| 250 |
+
"table-to-text": {
|
| 251 |
+
name: string;
|
| 252 |
+
modality: "nlp";
|
| 253 |
+
hideInModels: true;
|
| 254 |
+
};
|
| 255 |
+
"multiple-choice": {
|
| 256 |
+
name: string;
|
| 257 |
+
subtasks: {
|
| 258 |
+
type: string;
|
| 259 |
+
name: string;
|
| 260 |
+
}[];
|
| 261 |
+
modality: "nlp";
|
| 262 |
+
hideInModels: true;
|
| 263 |
+
};
|
| 264 |
+
"text-ranking": {
|
| 265 |
+
name: string;
|
| 266 |
+
modality: "nlp";
|
| 267 |
+
};
|
| 268 |
+
"text-retrieval": {
|
| 269 |
+
name: string;
|
| 270 |
+
subtasks: {
|
| 271 |
+
type: string;
|
| 272 |
+
name: string;
|
| 273 |
+
}[];
|
| 274 |
+
modality: "nlp";
|
| 275 |
+
hideInModels: true;
|
| 276 |
+
};
|
| 277 |
+
"time-series-forecasting": {
|
| 278 |
+
name: string;
|
| 279 |
+
modality: "tabular";
|
| 280 |
+
subtasks: {
|
| 281 |
+
type: string;
|
| 282 |
+
name: string;
|
| 283 |
+
}[];
|
| 284 |
+
};
|
| 285 |
+
"text-to-video": {
|
| 286 |
+
name: string;
|
| 287 |
+
modality: "cv";
|
| 288 |
+
};
|
| 289 |
+
"image-text-to-text": {
|
| 290 |
+
name: string;
|
| 291 |
+
modality: "multimodal";
|
| 292 |
+
};
|
| 293 |
+
"image-text-to-image": {
|
| 294 |
+
name: string;
|
| 295 |
+
modality: "multimodal";
|
| 296 |
+
};
|
| 297 |
+
"image-text-to-video": {
|
| 298 |
+
name: string;
|
| 299 |
+
modality: "multimodal";
|
| 300 |
+
};
|
| 301 |
+
"visual-question-answering": {
|
| 302 |
+
name: string;
|
| 303 |
+
subtasks: {
|
| 304 |
+
type: string;
|
| 305 |
+
name: string;
|
| 306 |
+
}[];
|
| 307 |
+
modality: "multimodal";
|
| 308 |
+
};
|
| 309 |
+
"document-question-answering": {
|
| 310 |
+
name: string;
|
| 311 |
+
subtasks: {
|
| 312 |
+
type: string;
|
| 313 |
+
name: string;
|
| 314 |
+
}[];
|
| 315 |
+
modality: "multimodal";
|
| 316 |
+
hideInDatasets: true;
|
| 317 |
+
};
|
| 318 |
+
"zero-shot-image-classification": {
|
| 319 |
+
name: string;
|
| 320 |
+
modality: "cv";
|
| 321 |
+
};
|
| 322 |
+
"graph-ml": {
|
| 323 |
+
name: string;
|
| 324 |
+
modality: "other";
|
| 325 |
+
};
|
| 326 |
+
"mask-generation": {
|
| 327 |
+
name: string;
|
| 328 |
+
modality: "cv";
|
| 329 |
+
};
|
| 330 |
+
"zero-shot-object-detection": {
|
| 331 |
+
name: string;
|
| 332 |
+
modality: "cv";
|
| 333 |
+
};
|
| 334 |
+
"text-to-3d": {
|
| 335 |
+
name: string;
|
| 336 |
+
modality: "cv";
|
| 337 |
+
};
|
| 338 |
+
"image-to-3d": {
|
| 339 |
+
name: string;
|
| 340 |
+
modality: "cv";
|
| 341 |
+
};
|
| 342 |
+
"image-feature-extraction": {
|
| 343 |
+
name: string;
|
| 344 |
+
modality: "cv";
|
| 345 |
+
};
|
| 346 |
+
"video-text-to-text": {
|
| 347 |
+
name: string;
|
| 348 |
+
modality: "multimodal";
|
| 349 |
+
hideInDatasets: false;
|
| 350 |
+
};
|
| 351 |
+
"keypoint-detection": {
|
| 352 |
+
name: string;
|
| 353 |
+
subtasks: {
|
| 354 |
+
type: string;
|
| 355 |
+
name: string;
|
| 356 |
+
}[];
|
| 357 |
+
modality: "cv";
|
| 358 |
+
hideInDatasets: true;
|
| 359 |
+
};
|
| 360 |
+
"visual-document-retrieval": {
|
| 361 |
+
name: string;
|
| 362 |
+
modality: "multimodal";
|
| 363 |
+
};
|
| 364 |
+
"any-to-any": {
|
| 365 |
+
name: string;
|
| 366 |
+
modality: "multimodal";
|
| 367 |
+
};
|
| 368 |
+
"video-to-video": {
|
| 369 |
+
name: string;
|
| 370 |
+
modality: "cv";
|
| 371 |
+
hideInDatasets: true;
|
| 372 |
+
};
|
| 373 |
+
other: {
|
| 374 |
+
name: string;
|
| 375 |
+
modality: "other";
|
| 376 |
+
hideInModels: true;
|
| 377 |
+
hideInDatasets: true;
|
| 378 |
+
};
|
| 379 |
+
};
|
| 380 |
+
export type PipelineType = keyof typeof PIPELINE_DATA;
|
| 381 |
+
export type WidgetType = PipelineType | "conversational";
|
| 382 |
+
export declare const PIPELINE_TYPES: PipelineType[];
|
| 383 |
+
export declare const SUBTASK_TYPES: string[];
|
| 384 |
+
export declare const PIPELINE_TYPES_SET: Set<"other" | "text-classification" | "token-classification" | "table-question-answering" | "question-answering" | "zero-shot-classification" | "translation" | "summarization" | "feature-extraction" | "text-generation" | "fill-mask" | "sentence-similarity" | "text-to-speech" | "text-to-audio" | "automatic-speech-recognition" | "audio-to-audio" | "audio-classification" | "audio-text-to-text" | "voice-activity-detection" | "depth-estimation" | "image-classification" | "object-detection" | "image-segmentation" | "text-to-image" | "image-to-text" | "image-to-image" | "image-to-video" | "unconditional-image-generation" | "video-classification" | "reinforcement-learning" | "robotics" | "tabular-classification" | "tabular-regression" | "tabular-to-text" | "table-to-text" | "multiple-choice" | "text-ranking" | "text-retrieval" | "time-series-forecasting" | "text-to-video" | "image-text-to-text" | "image-text-to-image" | "image-text-to-video" | "visual-question-answering" | "document-question-answering" | "zero-shot-image-classification" | "graph-ml" | "mask-generation" | "zero-shot-object-detection" | "text-to-3d" | "image-to-3d" | "image-feature-extraction" | "video-text-to-text" | "keypoint-detection" | "visual-document-retrieval" | "any-to-any" | "video-to-video">;
|
| 385 |
+
//# sourceMappingURL=pipelines.d.ts.map
|
node_modules/@huggingface/tasks/dist/commonjs/pipelines.d.ts.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
|
|
|
|
| 1 |
+
{"version":3,"file":"pipelines.d.ts","sourceRoot":"","sources":["../../src/pipelines.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,UAAU,yEAA0E,CAAC;AAElG,MAAM,MAAM,QAAQ,GAAG,CAAC,OAAO,UAAU,CAAC,CAAC,MAAM,CAAC,CAAC;AAEnD,eAAO,MAAM,eAAe;;;;;;;;CAQQ,CAAC;AAErC;;;;;;GAMG;AACH,MAAM,WAAW,OAAO;IACvB;;OAEG;IACH,IAAI,EAAE,MAAM,CAAC;IACb;;OAEG;IACH,IAAI,EAAE,MAAM,CAAC;CACb;AAED;;;;;GAKG;AACH,MAAM,WAAW,YAAY;IAC5B;;OAEG;IACH,IAAI,EAAE,MAAM,CAAC;IACb,QAAQ,CAAC,EAAE,OAAO,EAAE,CAAC;IACrB,QAAQ,EA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
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
"use strict";
|
| 2 |
+
Object.defineProperty(exports, "__esModule", { value: true });
|
| 3 |
+
exports.PIPELINE_TYPES_SET = exports.SUBTASK_TYPES = exports.PIPELINE_TYPES = exports.PIPELINE_DATA = exports.MODALITY_LABELS = exports.MODALITIES = void 0;
|
| 4 |
+
exports.MODALITIES = ["multimodal", "nlp", "cv", "audio", "tabular", "rl", "other"];
|
| 5 |
+
exports.MODALITY_LABELS = {
|
| 6 |
+
multimodal: "Multimodal",
|
| 7 |
+
nlp: "Natural Language Processing",
|
| 8 |
+
audio: "Audio",
|
| 9 |
+
cv: "Computer Vision",
|
| 10 |
+
rl: "Reinforcement Learning",
|
| 11 |
+
tabular: "Tabular",
|
| 12 |
+
other: "Other",
|
| 13 |
+
};
|
| 14 |
+
/// Coarse-grained taxonomy of tasks
|
| 15 |
+
///
|
| 16 |
+
/// This type is used in multiple places in the Hugging Face
|
| 17 |
+
/// ecosystem:
|
| 18 |
+
/// - To determine which widget to show.
|
| 19 |
+
/// - To determine which endpoint of Inference Endpoints to use.
|
| 20 |
+
/// - As filters at the left of models and datasets page.
|
| 21 |
+
///
|
| 22 |
+
/// Note that this is sensitive to order.
|
| 23 |
+
/// For each domain, the order should be of decreasing specificity.
|
| 24 |
+
/// This will impact the default pipeline tag of a model when not
|
| 25 |
+
/// specified.
|
| 26 |
+
exports.PIPELINE_DATA = {
|
| 27 |
+
"text-classification": {
|
| 28 |
+
name: "Text Classification",
|
| 29 |
+
subtasks: [
|
| 30 |
+
{
|
| 31 |
+
type: "acceptability-classification",
|
| 32 |
+
name: "Acceptability Classification",
|
| 33 |
+
},
|
| 34 |
+
{
|
| 35 |
+
type: "entity-linking-classification",
|
| 36 |
+
name: "Entity Linking Classification",
|
| 37 |
+
},
|
| 38 |
+
{
|
| 39 |
+
type: "fact-checking",
|
| 40 |
+
name: "Fact Checking",
|
| 41 |
+
},
|
| 42 |
+
{
|
| 43 |
+
type: "intent-classification",
|
| 44 |
+
name: "Intent Classification",
|
| 45 |
+
},
|
| 46 |
+
{
|
| 47 |
+
type: "language-identification",
|
| 48 |
+
name: "Language Identification",
|
| 49 |
+
},
|
| 50 |
+
{
|
| 51 |
+
type: "multi-class-classification",
|
| 52 |
+
name: "Multi Class Classification",
|
| 53 |
+
},
|
| 54 |
+
{
|
| 55 |
+
type: "multi-label-classification",
|
| 56 |
+
name: "Multi Label Classification",
|
| 57 |
+
},
|
| 58 |
+
{
|
| 59 |
+
type: "multi-input-text-classification",
|
| 60 |
+
name: "Multi-input Text Classification",
|
| 61 |
+
},
|
| 62 |
+
{
|
| 63 |
+
type: "natural-language-inference",
|
| 64 |
+
name: "Natural Language Inference",
|
| 65 |
+
},
|
| 66 |
+
{
|
| 67 |
+
type: "semantic-similarity-classification",
|
| 68 |
+
name: "Semantic Similarity Classification",
|
| 69 |
+
},
|
| 70 |
+
{
|
| 71 |
+
type: "sentiment-classification",
|
| 72 |
+
name: "Sentiment Classification",
|
| 73 |
+
},
|
| 74 |
+
{
|
| 75 |
+
type: "topic-classification",
|
| 76 |
+
name: "Topic Classification",
|
| 77 |
+
},
|
| 78 |
+
{
|
| 79 |
+
type: "semantic-similarity-scoring",
|
| 80 |
+
name: "Semantic Similarity Scoring",
|
| 81 |
+
},
|
| 82 |
+
{
|
| 83 |
+
type: "sentiment-scoring",
|
| 84 |
+
name: "Sentiment Scoring",
|
| 85 |
+
},
|
| 86 |
+
{
|
| 87 |
+
type: "sentiment-analysis",
|
| 88 |
+
name: "Sentiment Analysis",
|
| 89 |
+
},
|
| 90 |
+
{
|
| 91 |
+
type: "hate-speech-detection",
|
| 92 |
+
name: "Hate Speech Detection",
|
| 93 |
+
},
|
| 94 |
+
{
|
| 95 |
+
type: "text-scoring",
|
| 96 |
+
name: "Text Scoring",
|
| 97 |
+
},
|
| 98 |
+
],
|
| 99 |
+
modality: "nlp",
|
| 100 |
+
},
|
| 101 |
+
"token-classification": {
|
| 102 |
+
name: "Token Classification",
|
| 103 |
+
subtasks: [
|
| 104 |
+
{
|
| 105 |
+
type: "named-entity-recognition",
|
| 106 |
+
name: "Named Entity Recognition",
|
| 107 |
+
},
|
| 108 |
+
{
|
| 109 |
+
type: "part-of-speech",
|
| 110 |
+
name: "Part of Speech",
|
| 111 |
+
},
|
| 112 |
+
{
|
| 113 |
+
type: "parsing",
|
| 114 |
+
name: "Parsing",
|
| 115 |
+
},
|
| 116 |
+
{
|
| 117 |
+
type: "lemmatization",
|
| 118 |
+
name: "Lemmatization",
|
| 119 |
+
},
|
| 120 |
+
{
|
| 121 |
+
type: "word-sense-disambiguation",
|
| 122 |
+
name: "Word Sense Disambiguation",
|
| 123 |
+
},
|
| 124 |
+
{
|
| 125 |
+
type: "coreference-resolution",
|
| 126 |
+
name: "Coreference-resolution",
|
| 127 |
+
},
|
| 128 |
+
],
|
| 129 |
+
modality: "nlp",
|
| 130 |
+
},
|
| 131 |
+
"table-question-answering": {
|
| 132 |
+
name: "Table Question Answering",
|
| 133 |
+
modality: "nlp",
|
| 134 |
+
},
|
| 135 |
+
"question-answering": {
|
| 136 |
+
name: "Question Answering",
|
| 137 |
+
subtasks: [
|
| 138 |
+
{
|
| 139 |
+
type: "extractive-qa",
|
| 140 |
+
name: "Extractive QA",
|
| 141 |
+
},
|
| 142 |
+
{
|
| 143 |
+
type: "open-domain-qa",
|
| 144 |
+
name: "Open Domain QA",
|
| 145 |
+
},
|
| 146 |
+
{
|
| 147 |
+
type: "closed-domain-qa",
|
| 148 |
+
name: "Closed Domain QA",
|
| 149 |
+
},
|
| 150 |
+
],
|
| 151 |
+
modality: "nlp",
|
| 152 |
+
},
|
| 153 |
+
"zero-shot-classification": {
|
| 154 |
+
name: "Zero-Shot Classification",
|
| 155 |
+
modality: "nlp",
|
| 156 |
+
},
|
| 157 |
+
translation: {
|
| 158 |
+
name: "Translation",
|
| 159 |
+
modality: "nlp",
|
| 160 |
+
},
|
| 161 |
+
summarization: {
|
| 162 |
+
name: "Summarization",
|
| 163 |
+
subtasks: [
|
| 164 |
+
{
|
| 165 |
+
type: "news-articles-summarization",
|
| 166 |
+
name: "News Articles Summarization",
|
| 167 |
+
},
|
| 168 |
+
{
|
| 169 |
+
type: "news-articles-headline-generation",
|
| 170 |
+
name: "News Articles Headline Generation",
|
| 171 |
+
},
|
| 172 |
+
],
|
| 173 |
+
modality: "nlp",
|
| 174 |
+
},
|
| 175 |
+
"feature-extraction": {
|
| 176 |
+
name: "Feature Extraction",
|
| 177 |
+
modality: "nlp",
|
| 178 |
+
},
|
| 179 |
+
"text-generation": {
|
| 180 |
+
name: "Text Generation",
|
| 181 |
+
subtasks: [
|
| 182 |
+
{
|
| 183 |
+
type: "dialogue-modeling",
|
| 184 |
+
name: "Dialogue Modeling",
|
| 185 |
+
},
|
| 186 |
+
{
|
| 187 |
+
type: "dialogue-generation",
|
| 188 |
+
name: "Dialogue Generation",
|
| 189 |
+
},
|
| 190 |
+
{
|
| 191 |
+
type: "conversational",
|
| 192 |
+
name: "Conversational",
|
| 193 |
+
},
|
| 194 |
+
{
|
| 195 |
+
type: "language-modeling",
|
| 196 |
+
name: "Language Modeling",
|
| 197 |
+
},
|
| 198 |
+
{
|
| 199 |
+
type: "text-simplification",
|
| 200 |
+
name: "Text simplification",
|
| 201 |
+
},
|
| 202 |
+
{
|
| 203 |
+
type: "explanation-generation",
|
| 204 |
+
name: "Explanation Generation",
|
| 205 |
+
},
|
| 206 |
+
{
|
| 207 |
+
type: "abstractive-qa",
|
| 208 |
+
name: "Abstractive QA",
|
| 209 |
+
},
|
| 210 |
+
{
|
| 211 |
+
type: "open-domain-abstractive-qa",
|
| 212 |
+
name: "Open Domain Abstractive QA",
|
| 213 |
+
},
|
| 214 |
+
{
|
| 215 |
+
type: "closed-domain-qa",
|
| 216 |
+
name: "Closed Domain QA",
|
| 217 |
+
},
|
| 218 |
+
{
|
| 219 |
+
type: "open-book-qa",
|
| 220 |
+
name: "Open Book QA",
|
| 221 |
+
},
|
| 222 |
+
{
|
| 223 |
+
type: "closed-book-qa",
|
| 224 |
+
name: "Closed Book QA",
|
| 225 |
+
},
|
| 226 |
+
{
|
| 227 |
+
type: "text2text-generation",
|
| 228 |
+
name: "Text2Text Generation",
|
| 229 |
+
},
|
| 230 |
+
],
|
| 231 |
+
modality: "nlp",
|
| 232 |
+
},
|
| 233 |
+
"fill-mask": {
|
| 234 |
+
name: "Fill-Mask",
|
| 235 |
+
subtasks: [
|
| 236 |
+
{
|
| 237 |
+
type: "slot-filling",
|
| 238 |
+
name: "Slot Filling",
|
| 239 |
+
},
|
| 240 |
+
{
|
| 241 |
+
type: "masked-language-modeling",
|
| 242 |
+
name: "Masked Language Modeling",
|
| 243 |
+
},
|
| 244 |
+
],
|
| 245 |
+
modality: "nlp",
|
| 246 |
+
},
|
| 247 |
+
"sentence-similarity": {
|
| 248 |
+
name: "Sentence Similarity",
|
| 249 |
+
modality: "nlp",
|
| 250 |
+
},
|
| 251 |
+
"text-to-speech": {
|
| 252 |
+
name: "Text-to-Speech",
|
| 253 |
+
modality: "audio",
|
| 254 |
+
},
|
| 255 |
+
"text-to-audio": {
|
| 256 |
+
name: "Text-to-Audio",
|
| 257 |
+
modality: "audio",
|
| 258 |
+
},
|
| 259 |
+
"automatic-speech-recognition": {
|
| 260 |
+
name: "Automatic Speech Recognition",
|
| 261 |
+
modality: "audio",
|
| 262 |
+
},
|
| 263 |
+
"audio-to-audio": {
|
| 264 |
+
name: "Audio-to-Audio",
|
| 265 |
+
modality: "audio",
|
| 266 |
+
},
|
| 267 |
+
"audio-classification": {
|
| 268 |
+
name: "Audio Classification",
|
| 269 |
+
subtasks: [
|
| 270 |
+
{
|
| 271 |
+
type: "keyword-spotting",
|
| 272 |
+
name: "Keyword Spotting",
|
| 273 |
+
},
|
| 274 |
+
{
|
| 275 |
+
type: "speaker-identification",
|
| 276 |
+
name: "Speaker Identification",
|
| 277 |
+
},
|
| 278 |
+
{
|
| 279 |
+
type: "audio-intent-classification",
|
| 280 |
+
name: "Audio Intent Classification",
|
| 281 |
+
},
|
| 282 |
+
{
|
| 283 |
+
type: "audio-emotion-recognition",
|
| 284 |
+
name: "Audio Emotion Recognition",
|
| 285 |
+
},
|
| 286 |
+
{
|
| 287 |
+
type: "audio-language-identification",
|
| 288 |
+
name: "Audio Language Identification",
|
| 289 |
+
},
|
| 290 |
+
],
|
| 291 |
+
modality: "audio",
|
| 292 |
+
},
|
| 293 |
+
"audio-text-to-text": {
|
| 294 |
+
name: "Audio-Text-to-Text",
|
| 295 |
+
modality: "multimodal",
|
| 296 |
+
hideInDatasets: true,
|
| 297 |
+
},
|
| 298 |
+
"voice-activity-detection": {
|
| 299 |
+
name: "Voice Activity Detection",
|
| 300 |
+
modality: "audio",
|
| 301 |
+
},
|
| 302 |
+
"depth-estimation": {
|
| 303 |
+
name: "Depth Estimation",
|
| 304 |
+
modality: "cv",
|
| 305 |
+
},
|
| 306 |
+
"image-classification": {
|
| 307 |
+
name: "Image Classification",
|
| 308 |
+
subtasks: [
|
| 309 |
+
{
|
| 310 |
+
type: "multi-label-image-classification",
|
| 311 |
+
name: "Multi Label Image Classification",
|
| 312 |
+
},
|
| 313 |
+
{
|
| 314 |
+
type: "multi-class-image-classification",
|
| 315 |
+
name: "Multi Class Image Classification",
|
| 316 |
+
},
|
| 317 |
+
],
|
| 318 |
+
modality: "cv",
|
| 319 |
+
},
|
| 320 |
+
"object-detection": {
|
| 321 |
+
name: "Object Detection",
|
| 322 |
+
subtasks: [
|
| 323 |
+
{
|
| 324 |
+
type: "face-detection",
|
| 325 |
+
name: "Face Detection",
|
| 326 |
+
},
|
| 327 |
+
{
|
| 328 |
+
type: "vehicle-detection",
|
| 329 |
+
name: "Vehicle Detection",
|
| 330 |
+
},
|
| 331 |
+
],
|
| 332 |
+
modality: "cv",
|
| 333 |
+
},
|
| 334 |
+
"image-segmentation": {
|
| 335 |
+
name: "Image Segmentation",
|
| 336 |
+
subtasks: [
|
| 337 |
+
{
|
| 338 |
+
type: "instance-segmentation",
|
| 339 |
+
name: "Instance Segmentation",
|
| 340 |
+
},
|
| 341 |
+
{
|
| 342 |
+
type: "semantic-segmentation",
|
| 343 |
+
name: "Semantic Segmentation",
|
| 344 |
+
},
|
| 345 |
+
{
|
| 346 |
+
type: "panoptic-segmentation",
|
| 347 |
+
name: "Panoptic Segmentation",
|
| 348 |
+
},
|
| 349 |
+
],
|
| 350 |
+
modality: "cv",
|
| 351 |
+
},
|
| 352 |
+
"text-to-image": {
|
| 353 |
+
name: "Text-to-Image",
|
| 354 |
+
modality: "cv",
|
| 355 |
+
},
|
| 356 |
+
"image-to-text": {
|
| 357 |
+
name: "Image-to-Text",
|
| 358 |
+
subtasks: [
|
| 359 |
+
{
|
| 360 |
+
type: "image-captioning",
|
| 361 |
+
name: "Image Captioning",
|
| 362 |
+
},
|
| 363 |
+
],
|
| 364 |
+
modality: "cv",
|
| 365 |
+
},
|
| 366 |
+
"image-to-image": {
|
| 367 |
+
name: "Image-to-Image",
|
| 368 |
+
subtasks: [
|
| 369 |
+
{
|
| 370 |
+
type: "image-inpainting",
|
| 371 |
+
name: "Image Inpainting",
|
| 372 |
+
},
|
| 373 |
+
{
|
| 374 |
+
type: "image-colorization",
|
| 375 |
+
name: "Image Colorization",
|
| 376 |
+
},
|
| 377 |
+
{
|
| 378 |
+
type: "super-resolution",
|
| 379 |
+
name: "Super Resolution",
|
| 380 |
+
},
|
| 381 |
+
],
|
| 382 |
+
modality: "cv",
|
| 383 |
+
},
|
| 384 |
+
"image-to-video": {
|
| 385 |
+
name: "Image-to-Video",
|
| 386 |
+
modality: "cv",
|
| 387 |
+
},
|
| 388 |
+
"unconditional-image-generation": {
|
| 389 |
+
name: "Unconditional Image Generation",
|
| 390 |
+
modality: "cv",
|
| 391 |
+
},
|
| 392 |
+
"video-classification": {
|
| 393 |
+
name: "Video Classification",
|
| 394 |
+
modality: "cv",
|
| 395 |
+
},
|
| 396 |
+
"reinforcement-learning": {
|
| 397 |
+
name: "Reinforcement Learning",
|
| 398 |
+
modality: "rl",
|
| 399 |
+
},
|
| 400 |
+
robotics: {
|
| 401 |
+
name: "Robotics",
|
| 402 |
+
modality: "rl",
|
| 403 |
+
subtasks: [
|
| 404 |
+
{
|
| 405 |
+
type: "grasping",
|
| 406 |
+
name: "Grasping",
|
| 407 |
+
},
|
| 408 |
+
{
|
| 409 |
+
type: "task-planning",
|
| 410 |
+
name: "Task Planning",
|
| 411 |
+
},
|
| 412 |
+
],
|
| 413 |
+
},
|
| 414 |
+
"tabular-classification": {
|
| 415 |
+
name: "Tabular Classification",
|
| 416 |
+
modality: "tabular",
|
| 417 |
+
subtasks: [
|
| 418 |
+
{
|
| 419 |
+
type: "tabular-multi-class-classification",
|
| 420 |
+
name: "Tabular Multi Class Classification",
|
| 421 |
+
},
|
| 422 |
+
{
|
| 423 |
+
type: "tabular-multi-label-classification",
|
| 424 |
+
name: "Tabular Multi Label Classification",
|
| 425 |
+
},
|
| 426 |
+
],
|
| 427 |
+
},
|
| 428 |
+
"tabular-regression": {
|
| 429 |
+
name: "Tabular Regression",
|
| 430 |
+
modality: "tabular",
|
| 431 |
+
subtasks: [
|
| 432 |
+
{
|
| 433 |
+
type: "tabular-single-column-regression",
|
| 434 |
+
name: "Tabular Single Column Regression",
|
| 435 |
+
},
|
| 436 |
+
],
|
| 437 |
+
},
|
| 438 |
+
"tabular-to-text": {
|
| 439 |
+
name: "Tabular to Text",
|
| 440 |
+
modality: "tabular",
|
| 441 |
+
subtasks: [
|
| 442 |
+
{
|
| 443 |
+
type: "rdf-to-text",
|
| 444 |
+
name: "RDF to text",
|
| 445 |
+
},
|
| 446 |
+
],
|
| 447 |
+
hideInModels: true,
|
| 448 |
+
},
|
| 449 |
+
"table-to-text": {
|
| 450 |
+
name: "Table to Text",
|
| 451 |
+
modality: "nlp",
|
| 452 |
+
hideInModels: true,
|
| 453 |
+
},
|
| 454 |
+
"multiple-choice": {
|
| 455 |
+
name: "Multiple Choice",
|
| 456 |
+
subtasks: [
|
| 457 |
+
{
|
| 458 |
+
type: "multiple-choice-qa",
|
| 459 |
+
name: "Multiple Choice QA",
|
| 460 |
+
},
|
| 461 |
+
{
|
| 462 |
+
type: "multiple-choice-coreference-resolution",
|
| 463 |
+
name: "Multiple Choice Coreference Resolution",
|
| 464 |
+
},
|
| 465 |
+
],
|
| 466 |
+
modality: "nlp",
|
| 467 |
+
hideInModels: true,
|
| 468 |
+
},
|
| 469 |
+
"text-ranking": {
|
| 470 |
+
name: "Text Ranking",
|
| 471 |
+
modality: "nlp",
|
| 472 |
+
},
|
| 473 |
+
"text-retrieval": {
|
| 474 |
+
name: "Text Retrieval",
|
| 475 |
+
subtasks: [
|
| 476 |
+
{
|
| 477 |
+
type: "document-retrieval",
|
| 478 |
+
name: "Document Retrieval",
|
| 479 |
+
},
|
| 480 |
+
{
|
| 481 |
+
type: "utterance-retrieval",
|
| 482 |
+
name: "Utterance Retrieval",
|
| 483 |
+
},
|
| 484 |
+
{
|
| 485 |
+
type: "entity-linking-retrieval",
|
| 486 |
+
name: "Entity Linking Retrieval",
|
| 487 |
+
},
|
| 488 |
+
{
|
| 489 |
+
type: "fact-checking-retrieval",
|
| 490 |
+
name: "Fact Checking Retrieval",
|
| 491 |
+
},
|
| 492 |
+
],
|
| 493 |
+
modality: "nlp",
|
| 494 |
+
hideInModels: true,
|
| 495 |
+
},
|
| 496 |
+
"time-series-forecasting": {
|
| 497 |
+
name: "Time Series Forecasting",
|
| 498 |
+
modality: "tabular",
|
| 499 |
+
subtasks: [
|
| 500 |
+
{
|
| 501 |
+
type: "univariate-time-series-forecasting",
|
| 502 |
+
name: "Univariate Time Series Forecasting",
|
| 503 |
+
},
|
| 504 |
+
{
|
| 505 |
+
type: "multivariate-time-series-forecasting",
|
| 506 |
+
name: "Multivariate Time Series Forecasting",
|
| 507 |
+
},
|
| 508 |
+
],
|
| 509 |
+
},
|
| 510 |
+
"text-to-video": {
|
| 511 |
+
name: "Text-to-Video",
|
| 512 |
+
modality: "cv",
|
| 513 |
+
},
|
| 514 |
+
"image-text-to-text": {
|
| 515 |
+
name: "Image-Text-to-Text",
|
| 516 |
+
modality: "multimodal",
|
| 517 |
+
},
|
| 518 |
+
"image-text-to-image": {
|
| 519 |
+
name: "Image-Text-to-Image",
|
| 520 |
+
modality: "multimodal",
|
| 521 |
+
},
|
| 522 |
+
"image-text-to-video": {
|
| 523 |
+
name: "Image-Text-to-Video",
|
| 524 |
+
modality: "multimodal",
|
| 525 |
+
},
|
| 526 |
+
"visual-question-answering": {
|
| 527 |
+
name: "Visual Question Answering",
|
| 528 |
+
subtasks: [
|
| 529 |
+
{
|
| 530 |
+
type: "visual-question-answering",
|
| 531 |
+
name: "Visual Question Answering",
|
| 532 |
+
},
|
| 533 |
+
],
|
| 534 |
+
modality: "multimodal",
|
| 535 |
+
},
|
| 536 |
+
"document-question-answering": {
|
| 537 |
+
name: "Document Question Answering",
|
| 538 |
+
subtasks: [
|
| 539 |
+
{
|
| 540 |
+
type: "document-question-answering",
|
| 541 |
+
name: "Document Question Answering",
|
| 542 |
+
},
|
| 543 |
+
],
|
| 544 |
+
modality: "multimodal",
|
| 545 |
+
hideInDatasets: true,
|
| 546 |
+
},
|
| 547 |
+
"zero-shot-image-classification": {
|
| 548 |
+
name: "Zero-Shot Image Classification",
|
| 549 |
+
modality: "cv",
|
| 550 |
+
},
|
| 551 |
+
"graph-ml": {
|
| 552 |
+
name: "Graph Machine Learning",
|
| 553 |
+
modality: "other",
|
| 554 |
+
},
|
| 555 |
+
"mask-generation": {
|
| 556 |
+
name: "Mask Generation",
|
| 557 |
+
modality: "cv",
|
| 558 |
+
},
|
| 559 |
+
"zero-shot-object-detection": {
|
| 560 |
+
name: "Zero-Shot Object Detection",
|
| 561 |
+
modality: "cv",
|
| 562 |
+
},
|
| 563 |
+
"text-to-3d": {
|
| 564 |
+
name: "Text-to-3D",
|
| 565 |
+
modality: "cv",
|
| 566 |
+
},
|
| 567 |
+
"image-to-3d": {
|
| 568 |
+
name: "Image-to-3D",
|
| 569 |
+
modality: "cv",
|
| 570 |
+
},
|
| 571 |
+
"image-feature-extraction": {
|
| 572 |
+
name: "Image Feature Extraction",
|
| 573 |
+
modality: "cv",
|
| 574 |
+
},
|
| 575 |
+
"video-text-to-text": {
|
| 576 |
+
name: "Video-Text-to-Text",
|
| 577 |
+
modality: "multimodal",
|
| 578 |
+
hideInDatasets: false,
|
| 579 |
+
},
|
| 580 |
+
"keypoint-detection": {
|
| 581 |
+
name: "Keypoint Detection",
|
| 582 |
+
subtasks: [
|
| 583 |
+
{
|
| 584 |
+
type: "pose-estimation",
|
| 585 |
+
name: "Pose Estimation",
|
| 586 |
+
},
|
| 587 |
+
],
|
| 588 |
+
modality: "cv",
|
| 589 |
+
hideInDatasets: true,
|
| 590 |
+
},
|
| 591 |
+
"visual-document-retrieval": {
|
| 592 |
+
name: "Visual Document Retrieval",
|
| 593 |
+
modality: "multimodal",
|
| 594 |
+
},
|
| 595 |
+
"any-to-any": {
|
| 596 |
+
name: "Any-to-Any",
|
| 597 |
+
modality: "multimodal",
|
| 598 |
+
},
|
| 599 |
+
"video-to-video": {
|
| 600 |
+
name: "Video-to-Video",
|
| 601 |
+
modality: "cv",
|
| 602 |
+
hideInDatasets: true,
|
| 603 |
+
},
|
| 604 |
+
other: {
|
| 605 |
+
name: "Other",
|
| 606 |
+
modality: "other",
|
| 607 |
+
hideInModels: true,
|
| 608 |
+
hideInDatasets: true,
|
| 609 |
+
},
|
| 610 |
+
};
|
| 611 |
+
exports.PIPELINE_TYPES = Object.keys(exports.PIPELINE_DATA);
|
| 612 |
+
exports.SUBTASK_TYPES = Object.values(exports.PIPELINE_DATA)
|
| 613 |
+
.flatMap((data) => ("subtasks" in data ? data.subtasks : []))
|
| 614 |
+
.map((s) => s.type);
|
| 615 |
+
exports.PIPELINE_TYPES_SET = new Set(exports.PIPELINE_TYPES);
|
node_modules/@huggingface/tasks/dist/commonjs/snippets/common.d.ts
ADDED
|
@@ -0,0 +1,14 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
import type { ChatCompletionInputMessage, GenerationParameters } from "../tasks/index.js";
|
| 2 |
+
export declare function stringifyMessages(messages: ChatCompletionInputMessage[], opts?: {
|
| 3 |
+
indent?: string;
|
| 4 |
+
attributeKeyQuotes?: boolean;
|
| 5 |
+
customContentEscaper?: (str: string) => string;
|
| 6 |
+
}): string;
|
| 7 |
+
type PartialGenerationParameters = Partial<Pick<GenerationParameters, "temperature" | "max_tokens" | "top_p">>;
|
| 8 |
+
export declare function stringifyGenerationConfig(config: PartialGenerationParameters, opts: {
|
| 9 |
+
indent: string;
|
| 10 |
+
attributeValueConnector: string;
|
| 11 |
+
attributeKeyQuotes?: boolean;
|
| 12 |
+
}): string;
|
| 13 |
+
export {};
|
| 14 |
+
//# sourceMappingURL=common.d.ts.map
|
node_modules/@huggingface/tasks/dist/commonjs/snippets/common.d.ts.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
|
|
|
|
| 1 |
+
{"version":3,"file":"common.d.ts","sourceRoot":"","sources":["../../../src/snippets/common.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,0BAA0B,EAAE,oBAAoB,EAAE,MAAM,mBAAmB,CAAC;AAE1F,wBAAgB,iBAAiB,CAChC,QAAQ,EAAE,0BAA0B,EAAE,EACtC,IAAI,CAAC,EAAE;IACN,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,kBAAkB,CAAC,EAAE,OAAO,CAAC;IAC7B,oBAAoB,CAAC,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,MAAM,CAAC;CAC/C,GACC,MAAM,CAYR;AAED,KAAK,2BAA2B,GAAG,OAAO,CAAC,IAAI,CAAC,oBAAoB,EAAE,aAAa,GAAG,YAAY,GAAG,OAAO,CAAC,CAAC,CAAC;AAE/G,wBAAgB,yBAAyB,CACxC,MAAM,EAAE,2BAA2B,EACnC,IAAI,EAAE;IACL,MAAM,EAAE,MAAM,CAAC;IACf,uBAAuB,EAAE,MAAM,CAAC;IAChC,kBAAkB,CAAC,EAAE,OAAO,CAAC;CAC7B,GACC,MAAM,CAMR"}
|
node_modules/@huggingface/tasks/dist/commonjs/snippets/common.js
ADDED
|
@@ -0,0 +1,23 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
"use strict";
|
| 2 |
+
Object.defineProperty(exports, "__esModule", { value: true });
|
| 3 |
+
exports.stringifyMessages = stringifyMessages;
|
| 4 |
+
exports.stringifyGenerationConfig = stringifyGenerationConfig;
|
| 5 |
+
function stringifyMessages(messages, opts) {
|
| 6 |
+
let messagesStr = JSON.stringify(messages, null, "\t");
|
| 7 |
+
if (opts?.indent) {
|
| 8 |
+
messagesStr = messagesStr.replaceAll("\n", `\n${opts.indent}`);
|
| 9 |
+
}
|
| 10 |
+
if (!opts?.attributeKeyQuotes) {
|
| 11 |
+
messagesStr = messagesStr.replace(/"([^"]+)":/g, "$1:");
|
| 12 |
+
}
|
| 13 |
+
if (opts?.customContentEscaper) {
|
| 14 |
+
messagesStr = opts.customContentEscaper(messagesStr);
|
| 15 |
+
}
|
| 16 |
+
return messagesStr;
|
| 17 |
+
}
|
| 18 |
+
function stringifyGenerationConfig(config, opts) {
|
| 19 |
+
const quote = opts.attributeKeyQuotes ? `"` : "";
|
| 20 |
+
return Object.entries(config)
|
| 21 |
+
.map(([key, val]) => `${quote}${key}${quote}${opts.attributeValueConnector}${val},`)
|
| 22 |
+
.join(`${opts.indent}`);
|
| 23 |
+
}
|
node_modules/@huggingface/tasks/dist/commonjs/snippets/index.d.ts
ADDED
|
@@ -0,0 +1,4 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
export * from "./common.js";
|
| 2 |
+
export * from "./inputs.js";
|
| 3 |
+
export * from "./types.js";
|
| 4 |
+
//# sourceMappingURL=index.d.ts.map
|
node_modules/@huggingface/tasks/dist/commonjs/snippets/index.d.ts.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
|
|
|
|
| 1 |
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/snippets/index.ts"],"names":[],"mappings":"AAAA,cAAc,aAAa,CAAC;AAC5B,cAAc,aAAa,CAAC;AAC5B,cAAc,YAAY,CAAC"}
|
node_modules/@huggingface/tasks/dist/commonjs/snippets/index.js
ADDED
|
@@ -0,0 +1,19 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
"use strict";
|
| 2 |
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
| 3 |
+
if (k2 === undefined) k2 = k;
|
| 4 |
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
| 5 |
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
| 6 |
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
| 7 |
+
}
|
| 8 |
+
Object.defineProperty(o, k2, desc);
|
| 9 |
+
}) : (function(o, m, k, k2) {
|
| 10 |
+
if (k2 === undefined) k2 = k;
|
| 11 |
+
o[k2] = m[k];
|
| 12 |
+
}));
|
| 13 |
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
| 14 |
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
| 15 |
+
};
|
| 16 |
+
Object.defineProperty(exports, "__esModule", { value: true });
|
| 17 |
+
__exportStar(require("./common.js"), exports);
|
| 18 |
+
__exportStar(require("./inputs.js"), exports);
|
| 19 |
+
__exportStar(require("./types.js"), exports);
|
node_modules/@huggingface/tasks/dist/commonjs/snippets/inputs.d.ts
ADDED
|
@@ -0,0 +1,4 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
import type { ChatCompletionInputMessage } from "../tasks/index.js";
|
| 2 |
+
import type { ModelDataMinimal } from "./types.js";
|
| 3 |
+
export declare function getModelInputSnippet(model: ModelDataMinimal, noWrap?: boolean, noQuotes?: boolean): string | ChatCompletionInputMessage[];
|
| 4 |
+
//# sourceMappingURL=inputs.d.ts.map
|
node_modules/@huggingface/tasks/dist/commonjs/snippets/inputs.d.ts.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
|
|
|
|
| 1 |
+
{"version":3,"file":"inputs.d.ts","sourceRoot":"","sources":["../../../src/snippets/inputs.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,0BAA0B,EAAE,MAAM,mBAAmB,CAAC;AACpE,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,YAAY,CAAC;AAqKnD,wBAAgB,oBAAoB,CACnC,KAAK,EAAE,gBAAgB,EACvB,MAAM,UAAQ,EACd,QAAQ,UAAQ,GACd,MAAM,GAAG,0BAA0B,EAAE,CAmBvC"}
|
node_modules/@huggingface/tasks/dist/commonjs/snippets/inputs.js
ADDED
|
@@ -0,0 +1,147 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
"use strict";
|
| 2 |
+
Object.defineProperty(exports, "__esModule", { value: true });
|
| 3 |
+
exports.getModelInputSnippet = getModelInputSnippet;
|
| 4 |
+
const inputsZeroShotClassification = () => `"Hi, I recently bought a device from your company but it is not working as advertised and I would like to get reimbursed!"`;
|
| 5 |
+
const inputsTranslation = () => `"Меня зовут Вольфганг и я живу в Берлине"`;
|
| 6 |
+
const inputsSummarization = () => `"The tower is 324 metres (1,063 ft) tall, about the same height as an 81-storey building, and the tallest structure in Paris. Its base is square, measuring 125 metres (410 ft) on each side. During its construction, the Eiffel Tower surpassed the Washington Monument to become the tallest man-made structure in the world, a title it held for 41 years until the Chrysler Building in New York City was finished in 1930. It was the first structure to reach a height of 300 metres. Due to the addition of a broadcasting aerial at the top of the tower in 1957, it is now taller than the Chrysler Building by 5.2 metres (17 ft). Excluding transmitters, the Eiffel Tower is the second tallest free-standing structure in France after the Millau Viaduct."`;
|
| 7 |
+
const inputsTableQuestionAnswering = () => `{
|
| 8 |
+
"query": "How many stars does the transformers repository have?",
|
| 9 |
+
"table": {
|
| 10 |
+
"Repository": ["Transformers", "Datasets", "Tokenizers"],
|
| 11 |
+
"Stars": ["36542", "4512", "3934"],
|
| 12 |
+
"Contributors": ["651", "77", "34"],
|
| 13 |
+
"Programming language": [
|
| 14 |
+
"Python",
|
| 15 |
+
"Python",
|
| 16 |
+
"Rust, Python and NodeJS"
|
| 17 |
+
]
|
| 18 |
+
}
|
| 19 |
+
}`;
|
| 20 |
+
const inputsVisualQuestionAnswering = () => `{
|
| 21 |
+
"image": "cat.png",
|
| 22 |
+
"question": "What is in this image?"
|
| 23 |
+
}`;
|
| 24 |
+
const inputsQuestionAnswering = () => `{
|
| 25 |
+
"question": "What is my name?",
|
| 26 |
+
"context": "My name is Clara and I live in Berkeley."
|
| 27 |
+
}`;
|
| 28 |
+
const inputsTextClassification = () => `"I like you. I love you"`;
|
| 29 |
+
const inputsTokenClassification = () => `"My name is Sarah Jessica Parker but you can call me Jessica"`;
|
| 30 |
+
const inputsTextGeneration = (model) => {
|
| 31 |
+
if (model.tags.includes("conversational")) {
|
| 32 |
+
return model.pipeline_tag === "text-generation"
|
| 33 |
+
? [{ role: "user", content: "What is the capital of France?" }]
|
| 34 |
+
: [
|
| 35 |
+
{
|
| 36 |
+
role: "user",
|
| 37 |
+
content: [
|
| 38 |
+
{
|
| 39 |
+
type: "text",
|
| 40 |
+
text: "Describe this image in one sentence.",
|
| 41 |
+
},
|
| 42 |
+
{
|
| 43 |
+
type: "image_url",
|
| 44 |
+
image_url: {
|
| 45 |
+
url: "https://cdn.britannica.com/61/93061-050-99147DCE/Statue-of-Liberty-Island-New-York-Bay.jpg",
|
| 46 |
+
},
|
| 47 |
+
},
|
| 48 |
+
],
|
| 49 |
+
},
|
| 50 |
+
];
|
| 51 |
+
}
|
| 52 |
+
return `"Can you please let us know more details about your "`;
|
| 53 |
+
};
|
| 54 |
+
const inputsFillMask = (model) => `"The answer to the universe is ${model.mask_token}."`;
|
| 55 |
+
const inputsSentenceSimilarity = () => `{
|
| 56 |
+
"source_sentence": "That is a happy person",
|
| 57 |
+
"sentences": [
|
| 58 |
+
"That is a happy dog",
|
| 59 |
+
"That is a very happy person",
|
| 60 |
+
"Today is a sunny day"
|
| 61 |
+
]
|
| 62 |
+
}`;
|
| 63 |
+
const inputsFeatureExtraction = () => `"Today is a sunny day and I will get some ice cream."`;
|
| 64 |
+
const inputsImageClassification = () => `"cats.jpg"`;
|
| 65 |
+
const inputsImageToText = () => `"cats.jpg"`;
|
| 66 |
+
const inputsImageToImage = () => `{
|
| 67 |
+
"image": "cat.png",
|
| 68 |
+
"prompt": "Turn the cat into a tiger."
|
| 69 |
+
}`;
|
| 70 |
+
const inputsImageToVideo = () => `{
|
| 71 |
+
"image": "cat.png",
|
| 72 |
+
"prompt": "The cat starts to dance"
|
| 73 |
+
}`;
|
| 74 |
+
const inputsImageTextToImage = () => `{
|
| 75 |
+
"image": "cat.png",
|
| 76 |
+
"prompt": "Turn the cat into a tiger."
|
| 77 |
+
}`;
|
| 78 |
+
const inputsImageTextToVideo = () => `{
|
| 79 |
+
"image": "cat.png",
|
| 80 |
+
"prompt": "The cat starts to dance"
|
| 81 |
+
}`;
|
| 82 |
+
const inputsImageSegmentation = () => `"cats.jpg"`;
|
| 83 |
+
const inputsObjectDetection = () => `"cats.jpg"`;
|
| 84 |
+
const inputsAudioToAudio = () => `"sample1.flac"`;
|
| 85 |
+
const inputsAudioClassification = () => `"sample1.flac"`;
|
| 86 |
+
const inputsTextToImage = () => `"Astronaut riding a horse"`;
|
| 87 |
+
const inputsTextToVideo = () => `"A young man walking on the street"`;
|
| 88 |
+
const inputsTextToSpeech = () => `"The answer to the universe is 42"`;
|
| 89 |
+
const inputsTextToAudio = () => `"liquid drum and bass, atmospheric synths, airy sounds"`;
|
| 90 |
+
const inputsAutomaticSpeechRecognition = () => `"sample1.flac"`;
|
| 91 |
+
const inputsTabularPrediction = () => `'{"Height":[11.52,12.48],"Length1":[23.2,24.0],"Length2":[25.4,26.3],"Species": ["Bream","Bream"]}'`;
|
| 92 |
+
const inputsZeroShotImageClassification = () => `"cats.jpg"`;
|
| 93 |
+
const modelInputSnippets = {
|
| 94 |
+
"audio-to-audio": inputsAudioToAudio,
|
| 95 |
+
"audio-classification": inputsAudioClassification,
|
| 96 |
+
"automatic-speech-recognition": inputsAutomaticSpeechRecognition,
|
| 97 |
+
"document-question-answering": inputsVisualQuestionAnswering,
|
| 98 |
+
"feature-extraction": inputsFeatureExtraction,
|
| 99 |
+
"fill-mask": inputsFillMask,
|
| 100 |
+
"image-classification": inputsImageClassification,
|
| 101 |
+
"image-to-text": inputsImageToText,
|
| 102 |
+
"image-to-image": inputsImageToImage,
|
| 103 |
+
"image-to-video": inputsImageToVideo,
|
| 104 |
+
"image-text-to-image": inputsImageTextToImage,
|
| 105 |
+
"image-text-to-video": inputsImageTextToVideo,
|
| 106 |
+
"image-segmentation": inputsImageSegmentation,
|
| 107 |
+
"object-detection": inputsObjectDetection,
|
| 108 |
+
"question-answering": inputsQuestionAnswering,
|
| 109 |
+
"sentence-similarity": inputsSentenceSimilarity,
|
| 110 |
+
summarization: inputsSummarization,
|
| 111 |
+
"table-question-answering": inputsTableQuestionAnswering,
|
| 112 |
+
"tabular-regression": inputsTabularPrediction,
|
| 113 |
+
"tabular-classification": inputsTabularPrediction,
|
| 114 |
+
"text-classification": inputsTextClassification,
|
| 115 |
+
"text-generation": inputsTextGeneration,
|
| 116 |
+
"image-text-to-text": inputsTextGeneration,
|
| 117 |
+
"text-to-image": inputsTextToImage,
|
| 118 |
+
"text-to-video": inputsTextToVideo,
|
| 119 |
+
"text-to-speech": inputsTextToSpeech,
|
| 120 |
+
"text-to-audio": inputsTextToAudio,
|
| 121 |
+
"token-classification": inputsTokenClassification,
|
| 122 |
+
translation: inputsTranslation,
|
| 123 |
+
"zero-shot-classification": inputsZeroShotClassification,
|
| 124 |
+
"zero-shot-image-classification": inputsZeroShotImageClassification,
|
| 125 |
+
};
|
| 126 |
+
// Use noWrap to put the whole snippet on a single line (removing new lines and tabulations)
|
| 127 |
+
// Use noQuotes to strip quotes from start & end (example: "abc" -> abc)
|
| 128 |
+
function getModelInputSnippet(model, noWrap = false, noQuotes = false) {
|
| 129 |
+
if (model.pipeline_tag) {
|
| 130 |
+
const inputs = modelInputSnippets[model.pipeline_tag];
|
| 131 |
+
if (inputs) {
|
| 132 |
+
let result = inputs(model);
|
| 133 |
+
if (typeof result === "string") {
|
| 134 |
+
if (noWrap) {
|
| 135 |
+
result = result.replace(/(?:(?:\r?\n|\r)\t*)|\t+/g, " ");
|
| 136 |
+
}
|
| 137 |
+
if (noQuotes) {
|
| 138 |
+
const REGEX_QUOTES = /^"(.+)"$/s;
|
| 139 |
+
const match = result.match(REGEX_QUOTES);
|
| 140 |
+
result = match ? match[1] : result;
|
| 141 |
+
}
|
| 142 |
+
}
|
| 143 |
+
return result;
|
| 144 |
+
}
|
| 145 |
+
}
|
| 146 |
+
return "No input example has been defined for this model task.";
|
| 147 |
+
}
|
node_modules/@huggingface/tasks/dist/commonjs/snippets/types.d.ts
ADDED
|
@@ -0,0 +1,15 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
import type { ModelData } from "../model-data.js";
|
| 2 |
+
/**
|
| 3 |
+
* Minimal model data required for snippets.
|
| 4 |
+
*
|
| 5 |
+
* Add more fields as needed.
|
| 6 |
+
*/
|
| 7 |
+
export type ModelDataMinimal = Pick<ModelData, "id" | "pipeline_tag" | "mask_token" | "library_name" | "config" | "tags" | "inference">;
|
| 8 |
+
export declare const inferenceSnippetLanguages: readonly ["python", "js", "sh"];
|
| 9 |
+
export type InferenceSnippetLanguage = (typeof inferenceSnippetLanguages)[number];
|
| 10 |
+
export interface InferenceSnippet {
|
| 11 |
+
language: InferenceSnippetLanguage;
|
| 12 |
+
client: string;
|
| 13 |
+
content: string;
|
| 14 |
+
}
|
| 15 |
+
//# sourceMappingURL=types.d.ts.map
|
node_modules/@huggingface/tasks/dist/commonjs/snippets/types.d.ts.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
|
|
|
|
| 1 |
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/snippets/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAC;AAElD;;;;GAIG;AACH,MAAM,MAAM,gBAAgB,GAAG,IAAI,CAClC,SAAS,EACT,IAAI,GAAG,cAAc,GAAG,YAAY,GAAG,cAAc,GAAG,QAAQ,GAAG,MAAM,GAAG,WAAW,CACvF,CAAC;AAGF,eAAO,MAAM,yBAAyB,iCAAkC,CAAC;AACzE,MAAM,MAAM,wBAAwB,GAAG,CAAC,OAAO,yBAAyB,CAAC,CAAC,MAAM,CAAC,CAAC;AAElF,MAAM,WAAW,gBAAgB;IAChC,QAAQ,EAAE,wBAAwB,CAAC;IACnC,MAAM,EAAE,MAAM,CAAC;IACf,OAAO,EAAE,MAAM,CAAC;CAChB"}
|
node_modules/@huggingface/tasks/dist/commonjs/snippets/types.js
ADDED
|
@@ -0,0 +1,5 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
"use strict";
|
| 2 |
+
Object.defineProperty(exports, "__esModule", { value: true });
|
| 3 |
+
exports.inferenceSnippetLanguages = void 0;
|
| 4 |
+
// Order of the elements in InferenceModal.svelte is determined by this const
|
| 5 |
+
exports.inferenceSnippetLanguages = ["python", "js", "sh"];
|
node_modules/@huggingface/tasks/dist/commonjs/tasks/any-to-any/data.d.ts
ADDED
|
@@ -0,0 +1,4 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
import type { TaskDataCustom } from "../index.js";
|
| 2 |
+
declare const taskData: TaskDataCustom;
|
| 3 |
+
export default taskData;
|
| 4 |
+
//# sourceMappingURL=data.d.ts.map
|
node_modules/@huggingface/tasks/dist/commonjs/tasks/any-to-any/data.d.ts.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
|
|
|
|
| 1 |
+
{"version":3,"file":"data.d.ts","sourceRoot":"","sources":["../../../../src/tasks/any-to-any/data.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAElD,QAAA,MAAM,QAAQ,EAAE,cA4Df,CAAC;AAEF,eAAe,QAAQ,CAAC"}
|
node_modules/@huggingface/tasks/dist/commonjs/tasks/any-to-any/data.js
ADDED
|
@@ -0,0 +1,63 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
"use strict";
|
| 2 |
+
Object.defineProperty(exports, "__esModule", { value: true });
|
| 3 |
+
const taskData = {
|
| 4 |
+
datasets: [
|
| 5 |
+
{
|
| 6 |
+
description: "A dataset with multiple modality input and output pairs.",
|
| 7 |
+
id: "PKU-Alignment/align-anything",
|
| 8 |
+
},
|
| 9 |
+
],
|
| 10 |
+
demo: {
|
| 11 |
+
inputs: [
|
| 12 |
+
{
|
| 13 |
+
filename: "any-to-any-input.jpg",
|
| 14 |
+
type: "img",
|
| 15 |
+
},
|
| 16 |
+
{
|
| 17 |
+
label: "Text Prompt",
|
| 18 |
+
content: "What is the significance of this place?",
|
| 19 |
+
type: "text",
|
| 20 |
+
},
|
| 21 |
+
],
|
| 22 |
+
outputs: [
|
| 23 |
+
{
|
| 24 |
+
label: "Generated Text",
|
| 25 |
+
content: "The place in the picture is Osaka Castle, located in Osaka, Japan. Osaka Castle is a historic castle that was originally built in the 16th century by Toyotomi Hideyoshi, a powerful warlord of the time. It is one of the most famous landmarks in Osaka and is known for its distinctive white walls and black roof tiles. The castle has been rebuilt several times over the centuries and is now a popular tourist attraction, offering visitors a glimpse into Japan's rich history and culture.",
|
| 26 |
+
type: "text",
|
| 27 |
+
},
|
| 28 |
+
{
|
| 29 |
+
filename: "any-to-any-output.wav",
|
| 30 |
+
type: "audio",
|
| 31 |
+
},
|
| 32 |
+
],
|
| 33 |
+
},
|
| 34 |
+
metrics: [],
|
| 35 |
+
models: [
|
| 36 |
+
{
|
| 37 |
+
description: "Strong model that can take in video, audio, image, text and output text and natural speech.",
|
| 38 |
+
id: "Qwen/Qwen2.5-Omni-7B",
|
| 39 |
+
},
|
| 40 |
+
{
|
| 41 |
+
description: "Robust model that can take in image and text and generate image and text.",
|
| 42 |
+
id: "OmniGen2/OmniGen2",
|
| 43 |
+
},
|
| 44 |
+
{
|
| 45 |
+
description: "Any-to-any model with speech, video, audio, image and text understanding capabilities.",
|
| 46 |
+
id: "openbmb/MiniCPM-o-2_6",
|
| 47 |
+
},
|
| 48 |
+
{
|
| 49 |
+
description: "A model that can understand image and text and generate image and text.",
|
| 50 |
+
id: "ByteDance-Seed/BAGEL-7B-MoT",
|
| 51 |
+
},
|
| 52 |
+
],
|
| 53 |
+
spaces: [
|
| 54 |
+
{
|
| 55 |
+
description: "An application to chat with an any-to-any (image & text) model.",
|
| 56 |
+
id: "OmniGen2/OmniGen2",
|
| 57 |
+
},
|
| 58 |
+
],
|
| 59 |
+
summary: "Any-to-any models can understand two or more modalities and output two or more modalities.",
|
| 60 |
+
widgetModels: [],
|
| 61 |
+
youtubeId: "",
|
| 62 |
+
};
|
| 63 |
+
exports.default = taskData;
|
node_modules/@huggingface/tasks/dist/commonjs/tasks/audio-classification/data.d.ts
ADDED
|
@@ -0,0 +1,4 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
import type { TaskDataCustom } from "../index.js";
|
| 2 |
+
declare const taskData: TaskDataCustom;
|
| 3 |
+
export default taskData;
|
| 4 |
+
//# sourceMappingURL=data.d.ts.map
|
node_modules/@huggingface/tasks/dist/commonjs/tasks/audio-classification/data.d.ts.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
|
|
|
|
| 1 |
+
{"version":3,"file":"data.d.ts","sourceRoot":"","sources":["../../../../src/tasks/audio-classification/data.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAElD,QAAA,MAAM,QAAQ,EAAE,cA4Ef,CAAC;AAEF,eAAe,QAAQ,CAAC"}
|
node_modules/@huggingface/tasks/dist/commonjs/tasks/audio-classification/data.js
ADDED
|
@@ -0,0 +1,79 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
"use strict";
|
| 2 |
+
Object.defineProperty(exports, "__esModule", { value: true });
|
| 3 |
+
const taskData = {
|
| 4 |
+
datasets: [
|
| 5 |
+
{
|
| 6 |
+
description: "A benchmark of 10 different audio tasks.",
|
| 7 |
+
id: "s3prl/superb",
|
| 8 |
+
},
|
| 9 |
+
{
|
| 10 |
+
description: "A dataset of YouTube clips and their sound categories.",
|
| 11 |
+
id: "agkphysics/AudioSet",
|
| 12 |
+
},
|
| 13 |
+
],
|
| 14 |
+
demo: {
|
| 15 |
+
inputs: [
|
| 16 |
+
{
|
| 17 |
+
filename: "audio.wav",
|
| 18 |
+
type: "audio",
|
| 19 |
+
},
|
| 20 |
+
],
|
| 21 |
+
outputs: [
|
| 22 |
+
{
|
| 23 |
+
data: [
|
| 24 |
+
{
|
| 25 |
+
label: "Up",
|
| 26 |
+
score: 0.2,
|
| 27 |
+
},
|
| 28 |
+
{
|
| 29 |
+
label: "Down",
|
| 30 |
+
score: 0.8,
|
| 31 |
+
},
|
| 32 |
+
],
|
| 33 |
+
type: "chart",
|
| 34 |
+
},
|
| 35 |
+
],
|
| 36 |
+
},
|
| 37 |
+
metrics: [
|
| 38 |
+
{
|
| 39 |
+
description: "",
|
| 40 |
+
id: "accuracy",
|
| 41 |
+
},
|
| 42 |
+
{
|
| 43 |
+
description: "",
|
| 44 |
+
id: "recall",
|
| 45 |
+
},
|
| 46 |
+
{
|
| 47 |
+
description: "",
|
| 48 |
+
id: "precision",
|
| 49 |
+
},
|
| 50 |
+
{
|
| 51 |
+
description: "",
|
| 52 |
+
id: "f1",
|
| 53 |
+
},
|
| 54 |
+
],
|
| 55 |
+
models: [
|
| 56 |
+
{
|
| 57 |
+
description: "An easy-to-use model for command recognition.",
|
| 58 |
+
id: "speechbrain/google_speech_command_xvector",
|
| 59 |
+
},
|
| 60 |
+
{
|
| 61 |
+
description: "An emotion recognition model.",
|
| 62 |
+
id: "ehcalabres/wav2vec2-lg-xlsr-en-speech-emotion-recognition",
|
| 63 |
+
},
|
| 64 |
+
{
|
| 65 |
+
description: "A language identification model.",
|
| 66 |
+
id: "facebook/mms-lid-126",
|
| 67 |
+
},
|
| 68 |
+
],
|
| 69 |
+
spaces: [
|
| 70 |
+
{
|
| 71 |
+
description: "An application that can classify music into different genre.",
|
| 72 |
+
id: "kurianbenoy/audioclassification",
|
| 73 |
+
},
|
| 74 |
+
],
|
| 75 |
+
summary: "Audio classification is the task of assigning a label or class to a given audio. It can be used for recognizing which command a user is giving or the emotion of a statement, as well as identifying a speaker.",
|
| 76 |
+
widgetModels: ["MIT/ast-finetuned-audioset-10-10-0.4593"],
|
| 77 |
+
youtubeId: "KWwzcmG98Ds",
|
| 78 |
+
};
|
| 79 |
+
exports.default = taskData;
|
node_modules/@huggingface/tasks/dist/commonjs/tasks/audio-classification/inference.d.ts
ADDED
|
@@ -0,0 +1,54 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
/**
|
| 2 |
+
* Inference code generated from the JSON schema spec in ./spec
|
| 3 |
+
*
|
| 4 |
+
* Using src/scripts/inference-codegen
|
| 5 |
+
*/
|
| 6 |
+
/**
|
| 7 |
+
* Inputs for Audio Classification inference
|
| 8 |
+
*/
|
| 9 |
+
export interface AudioClassificationInput {
|
| 10 |
+
/**
|
| 11 |
+
* The input audio data as a base64-encoded string. If no `parameters` are provided, you can
|
| 12 |
+
* also provide the audio data as a raw bytes payload.
|
| 13 |
+
*/
|
| 14 |
+
inputs: Blob;
|
| 15 |
+
/**
|
| 16 |
+
* Additional inference parameters for Audio Classification
|
| 17 |
+
*/
|
| 18 |
+
parameters?: AudioClassificationParameters;
|
| 19 |
+
[property: string]: unknown;
|
| 20 |
+
}
|
| 21 |
+
/**
|
| 22 |
+
* Additional inference parameters for Audio Classification
|
| 23 |
+
*/
|
| 24 |
+
export interface AudioClassificationParameters {
|
| 25 |
+
/**
|
| 26 |
+
* The function to apply to the model outputs in order to retrieve the scores.
|
| 27 |
+
*/
|
| 28 |
+
function_to_apply?: ClassificationOutputTransform;
|
| 29 |
+
/**
|
| 30 |
+
* When specified, limits the output to the top K most probable classes.
|
| 31 |
+
*/
|
| 32 |
+
top_k?: number;
|
| 33 |
+
[property: string]: unknown;
|
| 34 |
+
}
|
| 35 |
+
/**
|
| 36 |
+
* The function to apply to the model outputs in order to retrieve the scores.
|
| 37 |
+
*/
|
| 38 |
+
export type ClassificationOutputTransform = "sigmoid" | "softmax" | "none";
|
| 39 |
+
export type AudioClassificationOutput = AudioClassificationOutputElement[];
|
| 40 |
+
/**
|
| 41 |
+
* Outputs for Audio Classification inference
|
| 42 |
+
*/
|
| 43 |
+
export interface AudioClassificationOutputElement {
|
| 44 |
+
/**
|
| 45 |
+
* The predicted class label.
|
| 46 |
+
*/
|
| 47 |
+
label: string;
|
| 48 |
+
/**
|
| 49 |
+
* The corresponding probability.
|
| 50 |
+
*/
|
| 51 |
+
score: number;
|
| 52 |
+
[property: string]: unknown;
|
| 53 |
+
}
|
| 54 |
+
//# sourceMappingURL=inference.d.ts.map
|
node_modules/@huggingface/tasks/dist/commonjs/tasks/audio-classification/inference.d.ts.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
|
|
|
|
| 1 |
+
{"version":3,"file":"inference.d.ts","sourceRoot":"","sources":["../../../../src/tasks/audio-classification/inference.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH;;GAEG;AACH,MAAM,WAAW,wBAAwB;IACxC;;;OAGG;IACH,MAAM,EAAE,IAAI,CAAC;IACb;;OAEG;IACH,UAAU,CAAC,EAAE,6BAA6B,CAAC;IAC3C,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAAC;CAC5B;AACD;;GAEG;AACH,MAAM,WAAW,6BAA6B;IAC7C;;OAEG;IACH,iBAAiB,CAAC,EAAE,6BAA6B,CAAC;IAClD;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAAC;CAC5B;AACD;;GAEG;AACH,MAAM,MAAM,6BAA6B,GAAG,SAAS,GAAG,SAAS,GAAG,MAAM,CAAC;AAC3E,MAAM,MAAM,yBAAyB,GAAG,gCAAgC,EAAE,CAAC;AAC3E;;GAEG;AACH,MAAM,WAAW,gCAAgC;IAChD;;OAEG;IACH,KAAK,EAAE,MAAM,CAAC;IACd;;OAEG;IACH,KAAK,EAAE,MAAM,CAAC;IACd,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAAC;CAC5B"}
|
node_modules/@huggingface/tasks/dist/commonjs/tasks/audio-classification/inference.js
ADDED
|
@@ -0,0 +1,2 @@
|
|
|
|
|
|
|
|
|
|
| 1 |
+
"use strict";
|
| 2 |
+
Object.defineProperty(exports, "__esModule", { value: true });
|
node_modules/@huggingface/tasks/dist/commonjs/tasks/audio-text-to-text/data.d.ts
ADDED
|
@@ -0,0 +1,4 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
import type { TaskDataCustom } from "../index.js";
|
| 2 |
+
declare const taskData: TaskDataCustom;
|
| 3 |
+
export default taskData;
|
| 4 |
+
//# sourceMappingURL=data.d.ts.map
|
node_modules/@huggingface/tasks/dist/commonjs/tasks/audio-text-to-text/data.d.ts.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
|
|
|
|
| 1 |
+
{"version":3,"file":"data.d.ts","sourceRoot":"","sources":["../../../../src/tasks/audio-text-to-text/data.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAElD,QAAA,MAAM,QAAQ,EAAE,cAiEf,CAAC;AAEF,eAAe,QAAQ,CAAC"}
|
node_modules/@huggingface/tasks/dist/commonjs/tasks/audio-text-to-text/data.js
ADDED
|
@@ -0,0 +1,67 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
"use strict";
|
| 2 |
+
Object.defineProperty(exports, "__esModule", { value: true });
|
| 3 |
+
const taskData = {
|
| 4 |
+
datasets: [
|
| 5 |
+
{
|
| 6 |
+
description: "A dataset containing audio conversations with question–answer pairs.",
|
| 7 |
+
id: "nvidia/AF-Think",
|
| 8 |
+
},
|
| 9 |
+
{
|
| 10 |
+
description: "A more advanced and comprehensive dataset that contains characteristics of the audio as well",
|
| 11 |
+
id: "tsinghua-ee/QualiSpeech",
|
| 12 |
+
},
|
| 13 |
+
],
|
| 14 |
+
demo: {
|
| 15 |
+
inputs: [
|
| 16 |
+
{
|
| 17 |
+
filename: "audio.wav",
|
| 18 |
+
type: "audio",
|
| 19 |
+
},
|
| 20 |
+
{
|
| 21 |
+
label: "Text Prompt",
|
| 22 |
+
content: "What is the gender of the speaker?",
|
| 23 |
+
type: "text",
|
| 24 |
+
},
|
| 25 |
+
],
|
| 26 |
+
outputs: [
|
| 27 |
+
{
|
| 28 |
+
label: "Generated Text",
|
| 29 |
+
content: "The gender of the speaker is female.",
|
| 30 |
+
type: "text",
|
| 31 |
+
},
|
| 32 |
+
],
|
| 33 |
+
},
|
| 34 |
+
metrics: [],
|
| 35 |
+
models: [
|
| 36 |
+
{
|
| 37 |
+
description: "A lightweight model that has capabilities of taking both audio and text as inputs and generating responses.",
|
| 38 |
+
id: "fixie-ai/ultravox-v0_5-llama-3_2-1b",
|
| 39 |
+
},
|
| 40 |
+
{
|
| 41 |
+
description: "A multimodal model that supports voice chat and audio analysis.",
|
| 42 |
+
id: "Qwen/Qwen2-Audio-7B-Instruct",
|
| 43 |
+
},
|
| 44 |
+
{
|
| 45 |
+
description: "A model for audio understanding, speech translation, and transcription.",
|
| 46 |
+
id: "mistralai/Voxtral-Small-24B-2507",
|
| 47 |
+
},
|
| 48 |
+
{
|
| 49 |
+
description: "A new model capable of audio question answering and reasoning.",
|
| 50 |
+
id: "nvidia/audio-flamingo-3",
|
| 51 |
+
},
|
| 52 |
+
],
|
| 53 |
+
spaces: [
|
| 54 |
+
{
|
| 55 |
+
description: "A space that takes input as both audio and text and generates answers.",
|
| 56 |
+
id: "iamomtiwari/ATTT",
|
| 57 |
+
},
|
| 58 |
+
{
|
| 59 |
+
description: "A web application that demonstrates chatting with the Qwen2Audio Model.",
|
| 60 |
+
id: "freddyaboulton/talk-to-qwen-webrtc",
|
| 61 |
+
},
|
| 62 |
+
],
|
| 63 |
+
summary: "Audio-text-to-text models take both an audio clip and a text prompt as input, and generate natural language text as output. These models can answer questions about spoken content, summarize meetings, analyze music, or interpret speech beyond simple transcription. They are useful for applications that combine speech understanding with reasoning or conversation.",
|
| 64 |
+
widgetModels: [],
|
| 65 |
+
youtubeId: "",
|
| 66 |
+
};
|
| 67 |
+
exports.default = taskData;
|
node_modules/@huggingface/tasks/dist/commonjs/tasks/audio-to-audio/data.d.ts
ADDED
|
@@ -0,0 +1,4 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
import type { TaskDataCustom } from "../index.js";
|
| 2 |
+
declare const taskData: TaskDataCustom;
|
| 3 |
+
export default taskData;
|
| 4 |
+
//# sourceMappingURL=data.d.ts.map
|
node_modules/@huggingface/tasks/dist/commonjs/tasks/audio-to-audio/data.d.ts.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
|
|
|
|
| 1 |
+
{"version":3,"file":"data.d.ts","sourceRoot":"","sources":["../../../../src/tasks/audio-to-audio/data.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAElD,QAAA,MAAM,QAAQ,EAAE,cA6Df,CAAC;AAEF,eAAe,QAAQ,CAAC"}
|
node_modules/@huggingface/tasks/dist/commonjs/tasks/audio-to-audio/data.js
ADDED
|
@@ -0,0 +1,62 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
"use strict";
|
| 2 |
+
Object.defineProperty(exports, "__esModule", { value: true });
|
| 3 |
+
const taskData = {
|
| 4 |
+
datasets: [
|
| 5 |
+
{
|
| 6 |
+
description: "512-element X-vector embeddings of speakers from CMU ARCTIC dataset.",
|
| 7 |
+
id: "Matthijs/cmu-arctic-xvectors",
|
| 8 |
+
},
|
| 9 |
+
],
|
| 10 |
+
demo: {
|
| 11 |
+
inputs: [
|
| 12 |
+
{
|
| 13 |
+
filename: "input.wav",
|
| 14 |
+
type: "audio",
|
| 15 |
+
},
|
| 16 |
+
],
|
| 17 |
+
outputs: [
|
| 18 |
+
{
|
| 19 |
+
filename: "label-0.wav",
|
| 20 |
+
type: "audio",
|
| 21 |
+
},
|
| 22 |
+
{
|
| 23 |
+
filename: "label-1.wav",
|
| 24 |
+
type: "audio",
|
| 25 |
+
},
|
| 26 |
+
],
|
| 27 |
+
},
|
| 28 |
+
metrics: [
|
| 29 |
+
{
|
| 30 |
+
description: "The Signal-to-Noise ratio is the relationship between the target signal level and the background noise level. It is calculated as the logarithm of the target signal divided by the background noise, in decibels.",
|
| 31 |
+
id: "snri",
|
| 32 |
+
},
|
| 33 |
+
{
|
| 34 |
+
description: "The Signal-to-Distortion ratio is the relationship between the target signal and the sum of noise, interference, and artifact errors",
|
| 35 |
+
id: "sdri",
|
| 36 |
+
},
|
| 37 |
+
],
|
| 38 |
+
models: [
|
| 39 |
+
{
|
| 40 |
+
description: "A speech enhancement model.",
|
| 41 |
+
id: "ResembleAI/resemble-enhance",
|
| 42 |
+
},
|
| 43 |
+
{
|
| 44 |
+
description: "A model that can change the voice in a speech recording.",
|
| 45 |
+
id: "microsoft/speecht5_vc",
|
| 46 |
+
},
|
| 47 |
+
],
|
| 48 |
+
spaces: [
|
| 49 |
+
{
|
| 50 |
+
description: "An application for speech separation.",
|
| 51 |
+
id: "younver/speechbrain-speech-separation",
|
| 52 |
+
},
|
| 53 |
+
{
|
| 54 |
+
description: "An application for audio style transfer.",
|
| 55 |
+
id: "nakas/audio-diffusion_style_transfer",
|
| 56 |
+
},
|
| 57 |
+
],
|
| 58 |
+
summary: "Audio-to-Audio is a family of tasks in which the input is an audio and the output is one or multiple generated audios. Some example tasks are speech enhancement and source separation.",
|
| 59 |
+
widgetModels: ["speechbrain/sepformer-wham"],
|
| 60 |
+
youtubeId: "iohj7nCCYoM",
|
| 61 |
+
};
|
| 62 |
+
exports.default = taskData;
|