MCPcopy Create free account
hub / github.com/THUDM/GLM / IdToToken

Method IdToToken

data_utils/tokenization.py:593–595  ·  view source on GitHub ↗

ascii index to character

(self, Id)

Source from the content-addressed store, hash-verified

591 return Tokenization(tokens, processed_text, text, asIds=False)
592
593 def IdToToken(self, Id):
594 """ascii index to character"""
595 return chr(Id)
596
597 def TokenToId(self, token):
598 """ascii character to index"""

Callers 2

__init__Method · 0.95
DecodeIdsMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected