{% assign uri = include.uri %}
{% assign documents = site.data.annotations | group_by: "uri" %}
{% assign contributors = "" | split: "|" %}
{% assign count_annotations = 0 %}
{% assign count_comments = 0 %}
{% assign count_needs = 0 %}
{% for document in documents %}
{% if document.name contains uri %}
{% for annotation in document.items %}
{% assign contributors = contributors | push: annotation.user %}
{% assign current_needs = annotation.tags | where_exp: "t", "t contains 'need:'" | size %}
{% assign count_needs = count_needs | plus: current_needs %}
{% endfor %}
{% assign current_comments = document.items | where_exp: "a", "a.references" | size %}
{% assign current_annotations = document.items | size %}
{% assign count_annotations = count_annotations | plus: current_annotations %}
{% assign count_comments = count_comments | plus: current_comments %}
{% continue %}
{% endif %}
{% endfor %}
{{ contributors | uniq | size }}
{{ count_annotations }}
{{ count_comments }}
{{count_needs }}