From dfb29bd016649f9acefe426bf3b085b53d64c4e3 Mon Sep 17 00:00:00 2001 From: Dan Bolser Date: Fri, 12 Apr 2024 02:06:12 +0100 Subject: [PATCH] Add missing provider condition for groq in inspect_history in LM class This was triggering an unhandled exception when calling --- dsp/modules/lm.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dsp/modules/lm.py b/dsp/modules/lm.py index 4af1dc80ec..9f08439107 100644 --- a/dsp/modules/lm.py +++ b/dsp/modules/lm.py @@ -46,7 +46,7 @@ def inspect_history(self, n: int = 1, skip: int = 0): prompt = x["prompt"] if prompt != last_prompt: - if provider == "clarifai" or provider == "google": + if provider == "clarifai" or provider == "google" or provider == "groq": printed.append((prompt, x["response"])) elif provider == "anthropic": blocks = [{"text": block.text} for block in x["response"].content if block.type == "text"]