Add handling for multiple agents to PDF