Skip to content

[WIP]feature(mixtral): support Mixtral-8x7B SFT, Reward, and Alignment - #95

Open
haolin-nju wants to merge 33 commits into
mainfrom
mixtral
Open

[WIP]feature(mixtral): support Mixtral-8x7B SFT, Reward, and Alignment#95
haolin-nju wants to merge 33 commits into
mainfrom
mixtral

Conversation

@haolin-nju

Copy link
Copy Markdown
Collaborator

This PR involves:

  1. Support Mixture-of-Experts model and Expert Parallel (EP) in ChatLearn;
  2. Implement an example on Mixtral-8x7B SFT, Reward, RLHF, DPO, and other alignment algorithms.

@haolin-njuhaolin-nju changed the title [WIP] Feature: Support Mixtral-8x7B SFT, Reward, Alignment[WIP] Feature: Support Mixtral-8x7B SFT, Reward, and AlignmentSep 24, 2024
@haolin-njuhaolin-nju changed the title [WIP] Feature: Support Mixtral-8x7B SFT, Reward, and Alignment[WIP][feature] Support Mixtral-8x7B SFT, Reward, and AlignmentOct 22, 2024
NNODES=$WORLD_SIZE


dp=$(($WORLD_SIZE * $GPUS_PER_NODE / $tp / $pp / $ep))

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it's not supposed to divide ep here.

Copy link
Copy Markdown
CollaboratorAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

NNODES=$WORLD_SIZE


dp=$(($WORLD_SIZE * $GPUS_PER_NODE / $tp / $pp / $ep))

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

neither is here.

Copy link
Copy Markdown
CollaboratorAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

cd ${CHATLEARN}/examples/megatron/alignment/reward

torchrun $DISTRIBUTED_ARGS \
finetune_reward.py \

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should be entry/train_reward.py

Copy link
Copy Markdown
CollaboratorAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

cd ${CHATLEARN}/examples/megatron/sft

torchrun $DISTRIBUTED_ARGS \
finetune_sft.py \

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

shold be entry/train_sft.py

Copy link
Copy Markdown
CollaboratorAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

@haolin-njuhaolin-nju changed the title [WIP][feature] Support Mixtral-8x7B SFT, Reward, and Alignment[WIP]feature(mixtral): support Mixtral-8x7B SFT, Reward, and AlignmentJan 6, 2025
Sign up for freeto 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.

2 participants

@haolin-nju@loofahcus