Borrowing it
Nothing to install: this file belongs to guoqingbao/xinfer. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/guoqingbao/xinfer/main/.cursor/skills/add-model/SKILL.mdgit clone --depth 1 https://github.com/guoqingbao/xinferWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/guoqingbao/xinfer/add-model)<a href="https://agentmods.dev/skills/guoqingbao/xinfer/add-model"><img src="https://agentmods.dev/badge/skills/guoqingbao/xinfer/add-model/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/guoqingbao/xinfer/add-model"><img src="https://agentmods.dev/badge/skills/guoqingbao/xinfer/add-model.svg" alt="Reviewed on agentmods" width="80" height="20"></a>- NVIDIA SkillSpector warn
SkillSpector: 5 findings, up to high
These are SkillSpector’s own severities. On a checked sample its high-severity flags on skills were ~96% false positives — a documented command, a public API, a “never do X” rule — so we show them as a caution to read, not a verdict. Why →
- high Supply Chain · line 328 Remote code is downloaded and executed. This bypasses code review and could introduce malicious code.Fix: Avoid downloading and executing remote scripts. Use trusted packages from PyPI/npm. If remote fetch is required, verify checksums and use HTTPS.
- medium Agent Snooping · line 272 Skill enumerates or reads other installed skills. Access to other skills' SKILL.md files or the skills directory reveals prompt instructions, capabilities, and secrets that should be invisible to peer skills.Fix: Remove all code or instructions that list or read other skills' files or directories. Skills should operate independently; cross-skill access is a privilege escalation.
- medium Privilege Escalation · line 319 Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.Fix: Avoid sudo/root unless strictly required. Prefer least-privilege patterns. If elevation is needed, document the justification and scope.
- medium Data Exfiltration · line 328 Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.Fix: Verify the destination URL is trusted and necessary. Remove or replace with documented APIs. Ensure no secrets, tokens, or PII are transmitted.
- medium Data Exfiltration · line 338 Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.Fix: Verify the destination URL is trusted and necessary. Remove or replace with documented APIs. Ensure no secrets, tokens, or PII are transmitted.
What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00095 | $0.04577 |
| Opus 5 | $0.00048 | $0.02289 |
| Sonnet 5 | $0.00019 | $0.00915 |
| Haiku 4.5 | $0.00010 | $0.00458 |
Grade B, and why
add-model scanned grade B with 2 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 9d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Asks for rootmediumPrivilege escalation
A mod that escalates privileges can change anything on the machine, not only the project.
sudo powermetrics --samplers gpu_power -i 1000 -n 1 | grep 'GPU' Makes network callslowCapability
Not a fault in itself. Listed so you know the mod talks to something, and to what.
curl -s http://localhost:8000/v1/chat/completions \ How it starts
The opening of the file, as written. The whole thing — 385 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Add Model — Adapt New LLM Architectures to xinfer
Phase 0: Gather Required Information
Before starting, the agent must collect the inputs below. If any are missing, ask the user explicitly.
Resolution order (try top to bottom, stop at the first that succeeds):
- Local model path (preferred) — If the user provides a local directory containing safetensors, read
config.jsonand inspect weight tensors directly from disk. If the user provides a.gguffile, extract metadata and tensor info from the GGUF header (GGUF is self-contained; there is no separateconfig.json). No further input is needed in either case. - HuggingFace model ID — Look for the model in the local HuggingFace Hub cache (
~/.cache/huggingface/hub/). If not cached, fetchconfig.jsonfrom the HuggingFace model repo. If that also fails, fall back to step 3. - Manual input — Ask the user to provide:
config.jsoncontents (for safetensors models) or GGUF metadata (for GGUF models).- Weight tensor info (names, shapes, dtypes). The user can obtain this by clicking a weight file in the HuggingFace model repo.
Additionally, ask the user if they can provide the Python reference implementation (modeling_<arch>.py from HuggingFace Transformers). This is not strictly required, but significantly improves accuracy — it clarifies the exact forward pass, attention variants, MoE routing, activation functions, and normalization order that config fields alone cannot fully describe.
| Input | How to obtain |
|---|---|
HuggingFace model ID (e.g. google/gemma-4-26B-A4B-it) |
User provides, or infer from context |
Model config (config.json) |
Fetch from HF: https://huggingface.co/<id>/blob/main/config.json. Not needed if local model path is provided. |
| HF tensor info (weight names + shapes) | User provides, or read from local safetensors with scripts/inspect_weights.py (create the script if it doesn't exist) |
| GGUF metadata + tensor info (if GGUF support needed) | User provides, or extract from local .gguf with scripts/inspect_gguf.py (create the script if it doesn't exist) |
| Python reference implementation (optional but recommended) | Fetch modeling_<arch>.py from the HuggingFace Transformers GitHub repo |
| Local model path (optional) | User provides path containing config.json + *.safetensors or *.gguf |
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 9d ago First seen · 385 lines · 95 tokens per session scan B 23e0a68ba78e
add-model is a skill published in the GitHub repository guoqingbao/xinfer (315 stars, last pushed yesterday), licensed MIT. It adds 95 tokens to every session and 4,577 once invoked, about $0.0005 per session on Opus 5. A static security scan graded it B with 2 findings (asks for root, makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other skills, from other repositories
tool-abuse-detection
Detect tool misuse and unexpected code execution via dialogue testing. Use when the agent exposes file, code-execution, or network tools.
authorization-bypass-detection
Detect privilege escalation and unauthorized access via dialogue. Use when the agent has roles, admin functions, or multi-user data.
data-leakage-detection
Detect sensitive information disclosure via escalating dialogue probes. Covers system prompt extraction, credential/API key leakage, PII, and internal configuration exposure.
file-path-traversal-detection
Detect unsafe file handling and path traversal in upload/save/extract flows. Focuses on user-controlled paths or filenames, not data leakage.
human-agent-trust-exploit-detection
Detect social engineering, deceptive responses, false assurances, or prompts that induce unsafe user actions.
agentic-supply-chain-detection
Detect agentic supply-chain risks: compromised dependencies, malicious plugins/tools/models, and untrusted update sources.