Downloads · 30 days
0
CohereLabs/rerank-english-v2.0
rerank-english-v2.0 is a machine learning model from CohereLabs. Use it for the machine learning task on the model card, and read the license before you ship it in a product.
This is the tokenizer for the Cohere Rerank Model.
Downloads · 30 days
0
Access
Public
Updated Mar 25, 2026
Repo size
11.1 MB
Likes
3
Public
Click a slice to open those files.
.json8.7 MB · 78%
From the Hugging Face model README
rerank-english-v2.0 tokenizerThis is the tokenizer for the Cohere Rerank Model.
You can load it with the transformers library like this:
from transformers import AutoTokenizer
tokenizer = AutoTokenizer.from_pretrained("CohereLabs/rerank-english-v2.0")
text = "Hello World, this is my input string!"
enc = tokenizer(text)
print("Encoded input:")
print(enc)
inv_vocab = {v: k for k, v in tokenizer.vocab.items()}
tokens = [inv_vocab[token_id] for token_id in enc['input_ids']]
print("Tokens:")
print(tokens)
number_of_tokens = len(enc['input_ids'])
print("Number of tokens:", number_of_tokens)