group: add interface for number of groups