Agent Path Convergence
Last updated
Was this helpful?
Last updated
Was this helpful?
When your agents take multiple steps to get to an answer or resolution, it's important to evaluate the pathway it took to get there. You want most of your runs to be consistent and not take unnecessarily frivolous or wrong actions.
One way of doing this is to calculate convergence:
Run your agent on a set of similar queries
Record the number of steps taken for each
Calculate the convergence score: avg(minimum steps taken for this query / steps in the run)
This will give a convergence score of 0-1, with 1 being a perfect score.
Some example code:
You can see a full notebook example below: