{% set ws = '' %}

<option value="-1">{{ 'allQuestion' | trans }}</option>
<option value="-2">{{ 'my models' | trans }}</option>
{% for Exo in listExo %}
    {% if ws != Exo['name'] %}
        {% if ws !='' %}
            </optgroup>
        {% endif %}
        {% set ws = Exo['name'] %}
        <optgroup label="{{ Exo['name'] }}">
    {% endif %}
    <option value="{{ Exo['id'] }}">
        {{ Exo['title'] }}
    </option>
{% endfor %}
</optgroup>
