Instructions to use hypaai/hypa-tiny-keys-tokenizer with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use hypaai/hypa-tiny-keys-tokenizer with Transformers:
# pip install -U transformers accelerate # Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("hypaai/hypa-tiny-keys-tokenizer", device_map="auto") - Notebooks
- Google Colab
- Kaggle
Download chat_template.jinja from hypaai/hypa-tiny-keys-tokenizer: direct link, hf CLI and curl.
- Browser
- Download file 859 Bytes
-
https://huggingface.co/hypaai/hypa-tiny-keys-tokenizer/resolve/main/chat_template.jinja
- Command line
-
hf download hf://hypaai/hypa-tiny-keys-tokenizer/chat_template.jinja
-
curl -L -o chat_template.jinja https://huggingface.co/hypaai/hypa-tiny-keys-tokenizer/resolve/main/chat_template.jinja
859 Bytes
| {{- bos_token }}{%- for message in messages %}{%- set content = message.get('content') or '' %}{%- set reasoning = (message.get('thinking') or '') | trim %}{%- set calls = message.get('tool_calls') %}{%- set responses = message.get('tool_responses') %}{%- if message['role'] in ['tool', 'ipython'] or responses %}{{- '<|start_header_id|>ipython<|end_header_id|> | |
| ' }}{{- (responses | tojson) if responses else content }}{{- '<|eot_id|>' }}{%- else %}{{- '<|start_header_id|>' + message['role'] + '<|end_header_id|> | |
| ' }}{%- if reasoning %}{{- '<|start_thinking|>' + reasoning + '<|end_thinking|>' }}{%- endif %}{%- if calls %}{{- '<|python_tag|>' + (calls | tojson) + '<|eom_id|>' }}{%- else %}{{- content + '<|eot_id|>' }}{%- endif %}{%- endif %}{%- endfor %}{%- if add_generation_prompt %}{{- '<|start_header_id|>assistant<|end_header_id|> | |
| ' }}{%- endif %} |