replaced AgentRef by IDRef