emerging-techniques-moe-training — Claude Code skill
Provides guidance and code templates for training Mixture of Experts models with DeepSpeed and Transformers. Scales model capacity without matching compute growth.
npx claude-code-templates@latest --skill ai-research/emerging-techniques-moe-trainingWhat emerging-techniques-moe-training does
This skill guides developers through implementing sparse Mixture of Experts (MoE) architectures like Mixtral 8x7B or DeepSeek-V3. It helps write custom routing layers and combine outputs from active experts.
The template covers Top-1 and Top-2 routing alongside expert choice mechanisms. To keep the router stable, it details auxiliary balancing loss and router z-loss calculations that prevent tokens from flooding a single expert.
Running the training scripts requires torch, deepspeed, transformers, and accelerate. Without installing these Python packages, distributed execution will fail immediately.
What it helps with
- build custom PyTorch MoE layers with Top-1 or Top-2 gating
- implement auxiliary loss terms to balance expert utilization
- set up DeepSpeed flags for distributed expert parallelism
- train sparse architectures comparable to Mixtral or DeepSeek-V3
Example prompts for the agent
- Help me build a custom PyTorch MoE layer with Top-2 gating and auxiliary loss
- Write a DeepSpeed launch command for pretraining an MoE model with 128 experts
How to install emerging-techniques-moe-training
1claude-code-templates
npx claude-code-templates@latest --skill ai-research/emerging-techniques-moe-training2Skills CLI (Vercel)
npx skills add davila7/claude-code-templates --skill emerging-techniques-moe-training -a claude-code3Manually: put the files in place
~/.claude/skills/emerging-techniques-moe-training/SKILL.mdCopy the whole skill folder; for one project use .claude/skills/emerging-techniques-moe-training/
Manually: put the files in place
.agents/skills/emerging-techniques-moe-training/SKILL.mdFor all projects use ~/.agents/skills/
Manually: put the files in place
.cursor/skills/emerging-techniques-moe-training/SKILL.mdCursor also reads .agents/skills/ and .claude/skills/
1GitHub CLI
gh skill install davila7/claude-code-templates emerging-techniques-moe-training2Manually: put the files in place
.github/skills/emerging-techniques-moe-training/SKILL.mdPlatform CLI
gemini skills install https://github.com/davila7/claude-code-templates --path cli-tool/components/skills/ai-research/emerging-techniques-moe-trainingManually: put the files in place
.devin/skills/emerging-techniques-moe-training/SKILL.mdThe legacy .windsurf/skills/ path still works
Claude.ai
Zip the folder and upload it in Settings → Capabilities → Skills
Step by step, with commands for each platform: How to install skills in Claude Code: five ways
Questions about emerging-techniques-moe-training
How to install emerging-techniques-moe-training in Claude Code?
Run npx claude-code-templates@latest --skill ai-research/emerging-techniques-moe-training in your environment. The template will be installed into your project.
What is the main purpose of this skill?
It assists in designing and training sparse Mixture of Experts architectures, reducing compute demands compared to dense models.
Which dependencies are required to run the code?
Your Python environment must have torch, deepspeed (version 0.6.0 or higher), transformers, and accelerate installed.