Skip to content

fix(react): do not abort ReAct loop on first zero-result tool return#382

Merged
ASuresh0524 merged 1 commit into
mainfrom
fix/react-agent-zero-result-exit-381
Jun 26, 2026
Merged

fix(react): do not abort ReAct loop on first zero-result tool return#382
ASuresh0524 merged 1 commit into
mainfrom
fix/react-agent-zero-result-exit-381

Conversation

@ASuresh0524

Copy link
Copy Markdown
Collaborator

Fixes #381. A single empty leann_search/web_search at iteration >= 2 no longer forces an ungrounded LLM answer; the agent continues until Final Answer or max_iterations.

Checklist

  • Tests pass (uv run pytest)
  • Code formatted (ruff format and ruff check)
  • Pre-commit hooks pass (pre-commit run --all-files)

Fixes #381. A single empty leann_search/web_search at iteration >= 2 no
longer forces an ungrounded LLM answer; the agent continues until Final
Answer or max_iterations.

Co-authored-by: Cursor <cursoragent@cursor.com>
@ASuresh0524 ASuresh0524 merged commit b925681 into main Jun 26, 2026
31 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

1 participant