transformers
Allow apply_chat_template to pass kwargs to the template and support a dict of templates
#29658
Merged

Allow apply_chat_template to pass kwargs to the template and support a dict of templates #29658

Rocketknight1 merged 11 commits into main from allow_chat_template_kwargs
Rocketknight1
Rocketknight1 Allow apply_chat_template to pass kwargs to the template
1e908c7c
Rocketknight1 Fix priority for template_kwargs
024f786b
Rocketknight1 Fix docstring
02220776
Rocketknight1 style fix
2cb238cd
HuggingFaceDocBuilderDev
Rocketknight1 Add the option for the model to have a dict of templates
1df5db7a
Rocketknight1 Rocketknight1 changed the title Allow apply_chat_template to pass kwargs to the template Allow apply_chat_template to pass kwargs to the template and support a dict of templates 1 year ago
Rocketknight1 Error message cleanup
6a39d6c7
Rocketknight1 Add test for chat template dicts
8d9789c5
Rocketknight1 Simplify the chat template dict test and apply it to all tokenizers i…
53ca0fb2
LysandreJik
LysandreJik commented on 2024-03-14
LysandreJik
LysandreJik approved these changes on 2024-03-14
Rocketknight1 Save chat template dicts as lists with fixed key names
6b71e6e8
Rocketknight1 Add test for serialization/reloading
e814006a
Rocketknight1 Add require_jinja just to be safe, even though I don't think we use it
97442a6b
Rocketknight1 Rocketknight1 merged 48fbab73 into main 1 year ago
Rocketknight1 Rocketknight1 deleted the allow_chat_template_kwargs branch 1 year ago

Login to write a write a comment.

Login via GitHub

Reviewers
Assignees
No one assigned
Labels
Milestone