diff --git a/litellm/llms/prompt_templates/factory.py b/litellm/llms/prompt_templates/factory.py index d62db1d80a7..4056e43e985 100644 --- a/litellm/llms/prompt_templates/factory.py +++ b/litellm/llms/prompt_templates/factory.py @@ -111,7 +111,7 @@ def prompt_factory(model: str, messages: list): return wizardcoder_pt(messages=messages) elif "phind/phind-codellama" in model: return phind_codellama_pt(messages=messages) - elif "togethercomputer/llama-2" in model: + elif "togethercomputer/llama-2" in model and "instruct" in model: return togetherai_llama_2_chat_pt(messages=messages) else: return default_pt(messages=messages) \ No newline at end of file