Skip to content

lensLlama2

LensLlama2

LensLlama2(unembed, bias, n_head, d_model, d_vocab)

Bases: Lens

get_lens classmethod

get_lens(name: str) -> type[Lens]

This takes the name of the lens and queries the registry to grab the corresponding Lens subclas.

Parameters:

  • name (str) –

    The name of the child Lens implementation.

Returns:

  • type[Lens]

    Subclass Lens implementation.

forward

forward(input_tensor)

This is optimizing \(f(x) = \sum_{...} ...\) (TODO)

Parameters:

  • input_tensor

Returns: