Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Optional AnswerSetting.max_answer_attempts to allow a new unsure branch #673

Merged
merged 3 commits into from
Nov 8, 2024

Conversation

jamesbraza
Copy link
Collaborator

This PR adds in an optional AnswerSetting.max_answer_attempts so we can declare ourselves as unsure if we attempt gen_answer too many times, with test coverage.

To do so, it tracks a tool names used in environment state as tool_history

@jamesbraza jamesbraza added the enhancement New feature or request label Nov 8, 2024
@jamesbraza jamesbraza self-assigned this Nov 8, 2024
@dosubot dosubot bot added the size:M This PR changes 30-99 lines, ignoring generated files. label Nov 8, 2024
agent=SimpleAgent(),
dataset=dataset,
callbacks=[storage_callback],
)
await evaluator.evaluate()
for traj in storage_callback.eval_trajectories:
assert not traj.failed
assert traj.done
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This specific assertion will not pass before this PR without this new setting

Copy link
Collaborator

@mskarlin mskarlin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok nice -- looks good.

@dosubot dosubot bot added the lgtm This PR has been approved by a maintainer label Nov 8, 2024
@jamesbraza jamesbraza merged commit 405f885 into main Nov 8, 2024
5 checks passed
@jamesbraza jamesbraza deleted the max-answer-attempts branch November 8, 2024 20:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request lgtm This PR has been approved by a maintainer size:M This PR changes 30-99 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants