Skip to content

Converting Safetensors Format Weights from Llama Model with New Tokens to LitGPT Format #2019

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

Open
GuocunWang opened this issue Apr 22, 2025 · 1 comment
Labels
question Further information is requested

Comments

@GuocunWang
Copy link

Hello! I would like to convert the weights of a Llama model that has new tokens added into the LitGPT format, but I only have the file in the Safetensors format. Could you provide a solution for it?

@GuocunWang GuocunWang added the question Further information is requested label Apr 22, 2025
@bhimrazy
Copy link
Contributor

Hi @GuocunWang, this guide might be helpful for your use case:
👉 https://github.com/Lightning-AI/litgpt/blob/main/tutorials/convert_hf_checkpoint.md

Even if new tokens have been added, they might have be reflected in the tokenizer_config.json file while saving the model.
Let us know how it goes. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants