Skip to content

[Chat][Bug][Feature]Add Peft support and fix the bug when ptx_coef is enabled#3433

Merged
ht-zhou merged 10 commits intohpcaitech:mainfrom
yynil:main
Apr 6, 2023
Merged

[Chat][Bug][Feature]Add Peft support and fix the bug when ptx_coef is enabled#3433
ht-zhou merged 10 commits intohpcaitech:mainfrom
yynil:main

Conversation

@yynil
Copy link
Copy Markdown
Contributor

@yynil yynil commented Apr 4, 2023

[Chat][Bug][Feature]Add Peft support and fix the bug when ptx_coef is enabled

📌 Checklist before creating the PR

  • [ x] I have created an issue for this PR for traceability
  • The title follows the standard format: [doc/gemini/tensor/...]: A concise description
  • I have added relevant tags if possible for us to better distinguish different PRs

🚨 Issue number

issues/3432
issues/3454

📝 What does this PR do?

  1. Fix bug of wrong data fetching when pretrained data loss is enabled.
  2. Add Huggingface Peft model support for SFT and Prompts(aka. Stage-1 and Stage-3) training.

💥 Checklist before requesting a review

  • [ x] I have linked my PR to an issue (instruction)
  • [ x] My issue clearly describes the problem/feature/proposal, with diagrams/charts/table/code if possible
  • [ x] I have performed a self-review of my code
  • [ x] I have added thorough tests.
  • [ x] I have added docstrings for all the functions/methods I implemented

⭐️ Do you enjoy contributing to Colossal-AI?

  • [ x] 🌝 Yes, I do.
  • 🌚 No, I don't.

Tell us more if you don't enjoy contributing to Colossal-AI.

Fix the bug of fetching wrong batch data
In stage-1 and stage-3, the peft model supports are added. So the trained artifacts will be only a small lora additions instead of the whole bunch of files.
@yynil yynil changed the title Fix the bug of fetching wrong data when pretrained data loss is enabled [Chat][Bug][Feature]Add Peft support and fix the bug when ptx_coef is enabled Apr 5, 2023
Comment thread applications/Chat/examples/test_pretrained.txt Outdated
@ht-zhou
Copy link
Copy Markdown
Contributor

ht-zhou commented Apr 6, 2023

Thank you for your nice work .
We suggest you to make a folder under example folder named "community" to store your code there.
Or you can choose to add a flag named "peft".
Also, we suggest you to delete the Chinese comment.

@yynil
Copy link
Copy Markdown
Contributor Author

yynil commented Apr 6, 2023

Thank you for your nice work . We suggest you to make a folder under example folder named "community" to store your code there. Or you can choose to add a flag named "peft". Also, we suggest you to delete the Chinese comment.

Very nice suggestions. I just move all my codes to community folder and remove the Chinese comments while keeping the original files untackled.

@ht-zhou ht-zhou self-assigned this Apr 6, 2023
@ht-zhou ht-zhou merged commit 62f4e2e into hpcaitech:main Apr 6, 2023
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.

2 participants