Refactor subgame solver to take an algorithm as a policy parameter rather than a member function.