Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MoE Merge Rework #263

Merged
merged 11 commits into from
Apr 16, 2024
Merged

MoE Merge Rework #263

merged 11 commits into from
Apr 16, 2024

Conversation

cg123
Copy link
Collaborator

@cg123 cg123 commented Apr 12, 2024

Expands the script mergekit-moe to support two new output architectures, Deepseek MoE and Qwen 2 MoE.

Both architectures include support for "shared" experts. Currently the script supports adding a single shared expert. The Deepseek architecture uses the shared experts ungated and unweighted, so you probably want to set the new residual_scale option on the shared expert to a relatively low value (think 0.1ish) to keep the model from being completely overcooked. Qwen 2 MoE has a gate parameter associated with the shared expert so this is less necessary, but still advisable.

Deepseek MoE supports either Llama or Mistral based models as inputs.
Qwen 2 MoE supports Llama, Mistral, or Qwen2 based models.

Addresses #117, #244, and #134.

@cg123 cg123 merged commit 215f767 into main Apr 16, 2024
6 checks passed
@cg123 cg123 deleted the moe-rework branch April 16, 2024 00:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant