A formal framework supporting the specification of the interactions between agents