↓ 6 callersFunctionrepeat_kv This is the equivalent of torch.repeat_interleave(x, dim=1, repeats=n_rep). The hidden states go from (batch, num_key_value_heads, seqlen, he
train/patch/modeling_llama.py:266
↓ 1 callersMethodchat(self, tokenizer, query: str, history: List[Dict] = None, role: str = "user",
max_length: int = 8
train/patch/modeling_chatglm.py:876
Method__init__(self, dim, rope_ratio=1, original_impl=False, device=None, dtype=None)
train/patch/modeling_chatglm.py:95
Method__init__(self, normalized_shape, eps=1e-5, device=None, dtype=None, **kwargs)
train/patch/modeling_chatglm.py:158