Show all template ids and number of documents using each template.
return templates ;return documents using #1 ;return number of  #2 for each  #1 ;return ids of  #1 ;return #4 ,  #3
['select', 'project', 'group', 'project', 'union']