Skip to content

Commit cea39c9

Browse files
committed
Having best evidence include the question, to make it clear
1 parent dba082b commit cea39c9

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/paperqa/agents/tools.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -280,7 +280,11 @@ async def gather_evidence(self, question: str, state: EnvironmentState) -> str:
280280
]
281281
)
282282

283-
best_evidence = f" Best evidence(s):\n\n{top_contexts}" if top_contexts else ""
283+
best_evidence = (
284+
f" Best evidence(s) for question {question!r}:\n\n{top_contexts}"
285+
if top_contexts
286+
else ""
287+
)
284288

285289
if f"{self.TOOL_FN_NAME}_completed" in self.settings.agent.callbacks:
286290
await asyncio.gather(

0 commit comments

Comments
 (0)