Skip to content

fix: add tool info to concisenss, harmfulness, helpfulness and response relevance evaluators#132

Merged
poshinchen merged 3 commits intostrands-agents:mainfrom
ybdarrenwang:bugfix/eval-tool
Feb 12, 2026
Merged

fix: add tool info to concisenss, harmfulness, helpfulness and response relevance evaluators#132
poshinchen merged 3 commits intostrands-agents:mainfrom
ybdarrenwang:bugfix/eval-tool

Conversation

@ybdarrenwang
Copy link
Copy Markdown
Collaborator

@ybdarrenwang ybdarrenwang commented Feb 10, 2026

Description

Previously, PR #77 intended to add tool info into traces for evaluation. However, some downstream evaluators didn't pick up that info properly, due to different implementation of the _format_prompt method.

This PR fixed this issue by:

  • Duplicating the correctly implemented _format_prompt method from Faithfulness evaluator into the following evaluators:
    • Helpfulness
    • Harmfulness
    • Conciseness
    • Response Relevance
  • Extracting the above 5 evaluators' shared method into parent class for reusability.
  • Extending the unit tests making sure tool traces are presented to these evaluators in both sync and async evaluation calls.

Related Issues

#77

Documentation PR

N/A

Type of Change

Bug fix

Testing

How have you tested the change? Verify that the changes do not break functionality or introduce warnings in consuming repositories: agents-docs, agents-tools, agents-cli

  • I ran hatch run prepare

Checklist

  • I have read the CONTRIBUTING document
  • I have added any necessary tests that prove my fix is effective or my feature works
  • I have updated the documentation accordingly
  • I have added an appropriate example to the documentation to outline the feature, or no new docs are needed
  • My changes generate no new warnings
  • Any dependent changes have been merged and published

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

JackYPCOnline
JackYPCOnline previously approved these changes Feb 11, 2026
@poshinchen poshinchen merged commit bc5c27d into strands-agents:main Feb 12, 2026
12 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

Development

Successfully merging this pull request may close these issues.

4 participants