Update llama.py

This commit is contained in:
Daniel Han-Chen 2024-06-07 04:25:33 +10:00
commit 82520f5e4c

View file

@ -791,7 +791,7 @@ def CausalLM_fast_forward(fast_forward_inference):
*args, **kwargs,
) -> Union[Tuple, CausalLMOutputWithPast]:
if past_key_values is not None:
if past_key_values is not None and self.config.model_type != "qwen2":
outputs = fast_forward_inference(
self,
input_ids,