MCPcopy Create free account
hub / github.com/TransluceAI/observatory / decode

Method decode

lib/util/util/subject.py:217–218  ·  view source on GitHub ↗
(self, token_ids: int | list[int] | torch.Tensor)

Source from the content-addressed store, hash-verified

215 return toks[0]
216
217 def decode(self, token_ids: int | list[int] | torch.Tensor) -> str:
218 return self.tokenizer.decode(token_ids) # type: ignore
219
220 @property
221 def pad_token_id(self) -> int:

Callers 15

tokenize_singleMethod · 0.95
_get_outputMethod · 0.95
softmax_top_kMethod · 0.95
event_generatorFunction · 0.45
steer_and_generateFunction · 0.45
evaluate_controlFunction · 0.45
get_neuron_exemplarsMethod · 0.45
token_strsMethod · 0.45
to_strMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected