Skip to content

armgit / dspy

Public Imported from GitHub
0

DSPy: The framework for programming—not prompting—language models

Python

fixed bug in previous commit

Thomas D Ahle3ca2c0fa24f8
diff --git a/dspy/teleprompt/random_search.py b/dspy/teleprompt/random_search.py
index c6118c421..da5bf24ce 100644
--- a/dspy/teleprompt/random_search.py
+++ b/dspy/teleprompt/random_search.py
@@ -70,8 +70,8 @@ class BootstrapFewShotWithRandomSearch(Teleprompter):
elif seed == -2:
# labels only
- teleprompter = LabeledFewShot(k=self.max_labeled_demos, sample=labeled_sample)
- program2 = teleprompter.compile(student, trainset=trainset2)
+ teleprompter = LabeledFewShot(k=self.max_labeled_demos)
+ program2 = teleprompter.compile(student, trainset=trainset2, sample=labeled_sample)
elif seed == -1:
# unshuffled few-shot