From 88d86ac948f0e782f88ee41496a1686669694c5b Mon Sep 17 00:00:00 2001 From: myan Date: Fri, 22 Nov 2024 10:30:36 +0800 Subject: [PATCH] Add the __doc__ of Signature class to system message for the react Signed-off-by: myan --- dspy/predict/react.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dspy/predict/react.py b/dspy/predict/react.py index ce8edaa46d..bf7afb1851 100644 --- a/dspy/predict/react.py +++ b/dspy/predict/react.py @@ -64,7 +64,7 @@ def __init__(self, signature, tools: list[Callable], max_iters=5): ) fallback_signature = ( - dspy.Signature({**signature.input_fields, **signature.output_fields}) + dspy.Signature({**signature.input_fields, **signature.output_fields}, signature.instructions) .append("trajectory", dspy.InputField(), type_=str) )