Codex Commit Agent
Julian-adv/OpenMMO
Run the repository commit workflow when the user explicitly asks to commit changes or create a save-point commit.
Shrink a HuggingFace safetensors model to 1 hidden layer for fast debugging without loading the full model into memory.
$ npx skills add amd/Quark --skill quark-torch-shrink-model -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install amd/Quark quark-torch-shrink-model --agent claude-codeProject scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).
$ git clone --depth 1 https://github.com/amd/Quark.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/_legacy_impl/l1-atomic/torch/quark-torch-shrink-model .claude/skills/quark-torch-shrink-model && rm -rf skills-srcUse ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.
Claude Code skills documentation · loads skills from .claude/skills/
Install the "quark-torch-shrink-model" agent skill from https://github.com/amd/Quark/tree/release%2F0.13/skills/_legacy_impl/l1-atomic/torch/quark-torch-shrink-model into .claude/skills/quark-torch-shrink-model/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "quark-torch-shrink-model", then confirm the skill loads.Claude Code copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$skill-installer install https://github.com/amd/Quark/tree/release%2F0.13/skills/_legacy_impl/l1-atomic/torch/quark-torch-shrink-modelType this inside Codex. $skill-installer <name> installs a curated skill from openai/skills. The installer writes to $CODEX_HOME/skills (default ~/.codex/skills). Restart Codex if the skill does not show up.
$ npx skills add amd/Quark --skill quark-torch-shrink-model -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install amd/Quark quark-torch-shrink-model --agent codexProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/amd/Quark.git skills-src && mkdir -p .agents/skills && cp -r skills-src/skills/_legacy_impl/l1-atomic/torch/quark-torch-shrink-model .agents/skills/quark-torch-shrink-model && rm -rf skills-srcUse ~/.agents/skills/ instead of .agents/skills for a personal install.
Codex skills documentation · loads skills from .agents/skills/
Install the "quark-torch-shrink-model" agent skill from https://github.com/amd/Quark/tree/release%2F0.13/skills/_legacy_impl/l1-atomic/torch/quark-torch-shrink-model into .agents/skills/quark-torch-shrink-model/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "quark-torch-shrink-model", then confirm the skill loads.Codex copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add amd/Quark --skill quark-torch-shrink-model -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install amd/Quark quark-torch-shrink-model --agent cursorProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/amd/Quark.git skills-src && mkdir -p .cursor/skills && cp -r skills-src/skills/_legacy_impl/l1-atomic/torch/quark-torch-shrink-model .cursor/skills/quark-torch-shrink-model && rm -rf skills-srcUse ~/.cursor/skills/ instead of .cursor/skills for a personal install.
Cursor skills documentation · loads skills from .cursor/skills/, .agents/skills/, .claude/skills/, .codex/skills/
Install the "quark-torch-shrink-model" agent skill from https://github.com/amd/Quark/tree/release%2F0.13/skills/_legacy_impl/l1-atomic/torch/quark-torch-shrink-model into .cursor/skills/quark-torch-shrink-model/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "quark-torch-shrink-model", then confirm the skill loads.Cursor copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gemini skills install https://github.com/amd/Quark.git --path skills/_legacy_impl/l1-atomic/torch/quark-torch-shrink-model--scope user (default) or --scope workspace; --path is the subfolder of the repo that holds the skill; --consent skips the security confirmation prompt.
$ npx skills add amd/Quark --skill quark-torch-shrink-model -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install amd/Quark quark-torch-shrink-model --agent gemini-cliProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/amd/Quark.git skills-src && mkdir -p .gemini/skills && cp -r skills-src/skills/_legacy_impl/l1-atomic/torch/quark-torch-shrink-model .gemini/skills/quark-torch-shrink-model && rm -rf skills-srcUse ~/.gemini/skills/ instead of .gemini/skills for a personal install, then run /skills reload.
Gemini CLI skills documentation · loads skills from .gemini/skills/, .agents/skills/
Install the "quark-torch-shrink-model" agent skill from https://github.com/amd/Quark/tree/release%2F0.13/skills/_legacy_impl/l1-atomic/torch/quark-torch-shrink-model into .gemini/skills/quark-torch-shrink-model/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "quark-torch-shrink-model", then confirm the skill loads.Gemini CLI copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gh skill install amd/Quark quark-torch-shrink-modelInstalls for Copilot at project scope by default; add --scope user for a personal install. Preview a skill first with gh skill preview. Needs GitHub CLI 2.90.0 or later (public preview).
$ npx skills add amd/Quark --skill quark-torch-shrink-model -a github-copilotProject install goes to .agents/skills/; add -g for ~/.copilot/skills/.
$ git clone --depth 1 https://github.com/amd/Quark.git skills-src && mkdir -p .github/skills && cp -r skills-src/skills/_legacy_impl/l1-atomic/torch/quark-torch-shrink-model .github/skills/quark-torch-shrink-model && rm -rf skills-srcUse ~/.copilot/skills/ instead of .github/skills for a personal install. Commit .github/skills so cloud agent and code review can use it.
GitHub Copilot skills documentation · loads skills from .github/skills/, .claude/skills/, .agents/skills/
Install the "quark-torch-shrink-model" agent skill from https://github.com/amd/Quark/tree/release%2F0.13/skills/_legacy_impl/l1-atomic/torch/quark-torch-shrink-model into .github/skills/quark-torch-shrink-model/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "quark-torch-shrink-model", then confirm the skill loads.GitHub Copilot copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add amd/Quark --skill quark-torch-shrink-model -a opencodeOpenCode documents no install command of its own. Project install goes to .agents/skills/; add -g for ~/.config/opencode/skills/.
$ gh skill install amd/Quark quark-torch-shrink-model --agent opencodeProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/amd/Quark.git skills-src && mkdir -p .opencode/skills && cp -r skills-src/skills/_legacy_impl/l1-atomic/torch/quark-torch-shrink-model .opencode/skills/quark-torch-shrink-model && rm -rf skills-srcUse ~/.config/opencode/skills/ instead of .opencode/skills for a personal install.
OpenCode skills documentation · loads skills from .opencode/skills/, .claude/skills/, .agents/skills/
Install the "quark-torch-shrink-model" agent skill from https://github.com/amd/Quark/tree/release%2F0.13/skills/_legacy_impl/l1-atomic/torch/quark-torch-shrink-model into .opencode/skills/quark-torch-shrink-model/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "quark-torch-shrink-model", then confirm the skill loads.OpenCode copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
quark-torch-shrink-modelShrink a HuggingFace safetensors model to 1 hidden layer for fast debugging without loading the full model into memory.
Quark Torch Shrink Model is an agent skill from amd/Quark. Shrink a HuggingFace safetensors model to 1 hidden layer for fast debugging without loading the full model into memory.
Its SKILL.md is about 980 tokens, which your agent loads only when the skill is triggered. The skill folder holds 1 other file (for example `shrink_model.py`).
It sits in AI & LLM Engineering, covering Model hubs and datasets. It works with Hugging Face. The licence is MIT.
3 steps, taken from the first numbered list in SKILL.md.
Read from SKILL.md and the folder at commit 313cb0b. It shows what the files ask for, not the result of running them.
Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.
From allowed-tools in the SKILL.md frontmatter.
Ships script files (Python), which the agent can run.
Shell commands in SKILL.md call:
pythonpipFrom the folder's file list and the shell code blocks in SKILL.md.
No URLs in SKILL.md. Its commands use pip, which can reach the network depending on how they are called.
From URLs in SKILL.md, links to its own repository left out.
Names no API keys, tokens, secrets or passwords.
From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.
Quark Torch Shrink Model loads about 980 tokens when it runs. Until then it costs about 36 tokens; SKILL.md has 292 words of instructions outside code blocks.
Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.
The automated check found no risky patterns in SKILL.md.
Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.
The full file from amd/Quark at commit 313cb0b, republished under its MIT licence (© amd). 292 words, ~980 tokens.
.claude/skills/quark-torch-shrink-model/SKILL.md (or your agent's skills folder). This skill also uses 1 other file; get the full folder from GitHub.Produce a minimal 1-layer copy of any HuggingFace safetensors model for debugging Quark
workflows. The tool reads model.safetensors.index.json to determine layer structure and
rewrites only the necessary shards — the full model is never loaded into memory.
Non-layer weights (embeddings, final norm, lm_head) are always preserved so the output
is a structurally valid model that can be loaded with transformers.
source_model_directory — local directory containing safetensors files and config.jsondestination_model_directory — where to write the shrunk modeltest_mode (optional) — if the user wants only JSON files without tensor data, for structural validationAsk (or infer from context):
--test--test)The script lives in the skill directory and is invoked directly by path:
SKILL_DIR="skills/_legacy_impl/l1-atomic/torch/quark-torch-shrink-model"
# Full shrink (writes real safetensors shards)
python "$SKILL_DIR/shrink_model.py" \
--src /path/to/source/model \
--dst /path/to/output/tiny_model
# Test mode (JSON only, no safetensors — fast structural validation)
python "$SKILL_DIR/shrink_model.py" \
--src /path/to/source/model \
--dst /path/to/output/tiny_model \
--testimport sys
from pathlib import Path
skill_dir = Path("skills/_legacy_impl/l1-atomic/torch/quark-torch-shrink-model")
sys.path.insert(0, str(skill_dir))
from shrink_model import shrink_model
shrink_model(
source_model_directory=Path("/path/to/source/model"),
destination_model_directory=Path("/path/to/output/tiny_model"),
test_mode=False, # set True for JSON-only structural validation
)The tool auto-detects the layer naming convention from the weight keys:
| Pattern | Architectures |
|---|---|
model.layers.N. | LLaMA, Qwen, Mistral, Gemma, DeepSeek-V3/R1 |
layers.N. (no prefix) | DeepSeek-V4 |
transformer.h.N. | GPT-2, Falcon |
model.blocks.N. | MPT |
model.transformer.layer.N. | BERT-style |
If the user's model uses a different pattern, add a new entry to _LAYER_INDEX_PATTERNS
in skills/_legacy_impl/l1-atomic/torch/quark-torch-shrink-model/shrink_model.py.
After running, produce a brief report:
## Shrink Result
- **Source**: /path/to/source/model
- **Destination**: /path/to/output/tiny_model
- **Mode**: full / test
- **Layers detected**: 80 (0 ... 79)
- **Layer kept**: 0 → remapped to 0
- **Keys kept**: 12 / 723
- **config.json**: num_hidden_layers 80 → 1
- **Status**: successIf the run fails, include the error and the most likely fix:
| Error | Likely Cause | Fix |
|---|---|---|
Could not detect any layer indices in weight_map | Unsupported key naming | Add pattern to _LAYER_INDEX_PATTERNS |
Neither model.safetensors.index.json nor model.safetensors found in | Wrong source path | Verify --src points to the model directory |
ImportError: safetensors is required: pip install safetensors | safetensors not installed | pip install safetensors |
© amd, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file
SKILL.md and 1 other file in skills/_legacy_impl/l1-atomic/torch/quark-torch-shrink-model of amd/Quark.
Open the folder on GitHubat commit 313cb0b
Quark Torch Shrink Model next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.
| Skill | Stars | Used in | Tokens | Auto-check | Licence | Repo updated |
|---|---|---|---|---|---|---|
| Quark Torch Shrink Model this skillamd/Quark | 181 | — | ~980 | Automated safety check: Pass | MIT | |
| Codex Commit AgentJulian-adv/OpenMMO | 1.8k | — | ~1.3k | Automated safety check: Pass | Custom licence | |
| Hugging Face API Tool Builderhuggingface/skills | 11k | 2 repos | ~1.5k | Automated safety check: Pass | Apache-2.0 | |
| Comfy CLIsundial-org/awesome-openclaw-skills | 663 | — | ~1.5k | Automated safety check: Pass | None | |
| SageMaker Serving Image Selectionhuggingface/skills | 11k | 1 repos | ~4.6k | Automated safety check: Pass | Apache-2.0 | |
| Hugging Face Local Model Evalshuggingface/skills | 11k | 2 repos | ~1.6k | Automated safety check: Pass | Apache-2.0 |
Julian-adv/OpenMMO
Run the repository commit workflow when the user explicitly asks to commit changes or create a save-point commit.
huggingface/skills
Builds reusable command line scripts that fetch, enrich or process data from the Hugging Face API, aimed at chained, repeated or automated tasks.
sundial-org/awesome-openclaw-skills
Install, manage, and run ComfyUI instances. An agent skill from sundial-org/awesome-openclaw-skills.
huggingface/skills
Chooses the right serving container and current image URI for deploying a Hugging Face model to a SageMaker endpoint, preferring Hugging Face images over generic ones.
huggingface/skills
Runs evaluations of Hugging Face Hub models on local hardware with inspect-ai or lighteval, and helps choose between vLLM, Transformers and accelerate backends.
JimLiu/science-skills
Biohub ESMFold2 / ESMFold2-Fast all-atom co-folding (Candido et al.
amd/Quark
Author or restructure a Quark Agent Skill so it conforms to this project's template, contracts, and layer rules.
amd/Quark
Run, resume, monitor, diagnose, and report Quark Quant-Perf workflows for PyTorch and HuggingFace transformers models.
amd/Quark
Author a new ShapeShifter graph-transformation pass for AMD Quark (ONNX or PyTorch) so it conforms to the pass framework's conventions and auto-registers.
amd/Quark
Collect and normalize environment facts (OS, Python, GPU, CUDA/ROCm, container state) before Quark installation or PTQ planning.
amd/Quark
Install or verify the AMD Quark package and its dependencies.
amd/Quark
L3 recipe that runs quark.onnx.AutoSearchPro end-to-end on a user .onnx model: intake → preset selection (or custom search space) → calibration / eval data reader → standalone autosearch script…
Works with
Categories
Shrink a HuggingFace safetensors model to 1 hidden layer for fast debugging without loading the full model into memory. Quark Torch Shrink Model is an agent skill from amd/Quark. Shrink a HuggingFace safetensors model to 1 hidden layer for fast debugging without loading the full model into memory.
Quark Torch Shrink Model fits situations like: tasks that involve Model hubs and datasets.
Run `npx skills add amd/Quark --skill quark-torch-shrink-model -a claude-code`. Or copy the skill folder (skills/_legacy_impl/l1-atomic/torch/quark-torch-shrink-model in amd/Quark) into .claude/skills/quark-torch-shrink-model in your project. Claude Code loads it when a task matches its description.
Run `npx skills add amd/Quark --skill quark-torch-shrink-model -a codex`. Or copy the skill folder (skills/_legacy_impl/l1-atomic/torch/quark-torch-shrink-model in amd/Quark) into .agents/skills/quark-torch-shrink-model in your project. Codex loads it when a task matches its description.
Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add amd/Quark --skill quark-torch-shrink-model -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/quark-torch-shrink-model, .gemini/skills/quark-torch-shrink-model, .github/skills/quark-torch-shrink-model and .opencode/skills/quark-torch-shrink-model in your project.
Going by SKILL.md and its folder, Quark Torch Shrink Model needs Python for the scripts in its folder and the command-line tools its instructions call (python and pip). Our summary lists: Python 3.
SKILL.md contains no URLs. Its commands use pip, which can reach the network depending on how they are called. This is read from the text; nothing was executed.
Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.
Quark Torch Shrink Model is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.
About 980 tokens (SKILL.md is roughly 3.9k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.
Skills that share tags, products or a category with Quark Torch Shrink Model: Codex Commit Agent (Julian-adv/OpenMMO, 1.8k stars), Hugging Face API Tool Builder (huggingface/skills, 11k stars), Comfy CLI (sundial-org/awesome-openclaw-skills, 663 stars) and SageMaker Serving Image Selection (huggingface/skills, 11k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.
amd (a GitHub organization) maintains it in amd/Quark, which has 181 GitHub stars. The repository holds 37 skills in this directory. The repository was last updated on September 28, 2026.
Source: amd/Quark on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.