mment %}
    <script>
      $(function () {
        let availableNames = [
          {% for entry in autocomplete %}
            '{{ entry.name|escapejs }}{% if entry.tags.names %} ({{ entry.tags.names|get_tags_list|escapejs }}){% endif %}',
          {% endfor %}
        ];
        $('#id_name').autocomplete({
          source: availableNames
        });
      });

      $(function () {
        let availableTags = [
          {% for tag in tags %}
            '{{ tag.name|escapejs }}',
          {% endfor 