added a helper method for our dfs/idaStar agent