MCPcopy
hub / github.com/huggingface/transformers / update

Method update

src/transformers/tokenization_python.py:57–65  ·  view source on GitHub ↗

Updates the Trie with new tokens provided as arguments. Args: *args: Variable number of words to be added to the Trie.

(self, *args)

Source from the content-addressed store, hash-verified

55 self.update(*args)
56
57 def update(self, *args):
58 """
59 Updates the Trie with new tokens provided as arguments.
60
61 Args:
62 *args: Variable number of words to be added to the Trie.
63 """
64 for token in tuple(*args):
65 self.add(token)
66
67 def add(self, word: str):
68 """

Callers 2

__init__Method · 0.95
__init__Method · 0.45

Calls 1

addMethod · 0.95

Tested by

no test coverage detected