Method
DecodeTokens
(self, Tokens, type_token=False)
Source from the content-addressed store, hash-verified
| 1263 | return text |
| 1264 | |
| 1265 | def DecodeTokens(self, Tokens, type_token=False): |
| 1266 | if type_token: |
| 1267 | return ' '.join(t.token if isinstance(t, TypeToken) else t for t in Tokens) |
| 1268 | if isinstance(Tokens, Tokenization): |
| 1269 | Tokens = Tokens.tokenization |
| 1270 | return self.text_tokenizer.decode([self.TokenToId(tok) for tok in Tokens]) |
Callers
nothing calls this directly
Tested by
no test coverage detected