# Use HF tokenizer as a keras layer

**URL:** <https://discuss.huggingface.co/t/use-hf-tokenizer-as-a-keras-layer/33772>\
**Category:** 🤗Transformers\
**Created:** [March 14, 2023, 11:57am UTC](https://discuss.huggingface.co/t/use-hf-tokenizer-as-a-keras-layer/33772 "2023-03-14T11:57:03Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![adisomani2](https://avatars.discourse-cdn.com/v4/letter/a/b487fb/32.png) [@adisomani2](https://discuss.huggingface.co/u/adisomani2)\
**Post date:** [March 14, 2023, 11:57am UTC](https://discuss.huggingface.co/t/use-hf-tokenizer-as-a-keras-layer/33772/1 "2023-03-14T11:57:03Z")

</div>

Hello,

How can I know which tokenizers, e.g. DistilBertTokenizerFast or WhisperTokenizer can be used as a keras layer in my model? This will help me package both the tokenizer as well as the model together.
