Skip to content

Adding New Tokens #608

Closed
Closed

Description

@ekmekovski

Hello, I hope you are doing well. Firstly thank you for the very well-developed framework, and sorry about my question but I could not find a way to reload the save model after adding new tokens while fine-tuning the process. How can I reload a model after adding new tokens in fine-tuning?
Thnx a lot

Activity

  1. danielhanchen commented on Jun 11, 2024

    @danielhanchen
    Member

    Thanks! So sorry on the delay - I was actually trying to add support for that :) It'll work in the next release hopefully!

  2. ekmekovski commented on Jun 15, 2024

    @ekmekovski
    Author

    I'm looking forward to it, thank you :))

  3. practicingman commented on Jul 11, 2024

    @practicingman

    I think this is supported now? based on #377

  4. danielhanchen commented on Jul 12, 2024

    @danielhanchen
    Member

    If you search for add_new_tokens in our repo - it's a prelim method for adding new tokens

  5. rubentorresbonet commented on Oct 28, 2024

    @rubentorresbonet

    I tried to use unsloth.tokenizer_utils.add_new_tokens(model, tokenizer, [tokens]) without luck.
    During training I get this exception: RuntimeError: Inference tensors cannot be saved for backward. To work around you can make a clone to get a normal tensor and use it in autograd.

  6. danielhanchen commented on Oct 29, 2024

    @danielhanchen
    Member

    @Erland366 Would you mind having a look at add_new_tokens to see if it functions? :)

  7. Erland366 commented on Oct 29, 2024

    @Erland366
    Collaborator

    I'll check it out!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions