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

Method _encode

data_utils/tokenization.py:1210–1212  ·  view source on GitHub ↗
(self, text)

Source from the content-addressed store, hash-verified

1208 self._token_type_vocab = {t: Id for Id, t in self.type_id_map.items()}
1209
1210 def _encode(self, text):
1211 ids = self.text_tokenizer.encode(text)
1212 return ids
1213
1214 def EncodeAsTokens(self, text, process_fn=None):
1215 processed_text = text

Callers

nothing calls this directly

Calls 1

encodeMethod · 0.45

Tested by

no test coverage detected