MCPcopy Create free account
hub / github.com/kyegomez/BitNet / decode_tokens

Method decode_tokens

bitnet/inference.py:52–54  ·  view source on GitHub ↗

Decodes a sequence of tokens into a string.

(tokens)

Source from the content-addressed store, hash-verified

50
51 @staticmethod
52 def decode_tokens(tokens):
53 """Decodes a sequence of tokens into a string."""
54 return "".join(list(map(BitNetInference.decode_token, tokens)))
55
56 def generate(self, input_str, length):
57 """Generates a sequence of tokens based on the input string."""

Callers 1

generateMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected