Is it possible to create a template entity that is stateless that just has a bunch of buttons?

I am trying to create a template entity for a fan. I don’t like how it works because it uses percentages. I want the entity to have buttons for all the speeds and to toggle the light on and off.

I know I can create multiple template buttons but I was wondering if I could do something like that but all wrapped into a single entity? That way I can expose the single entity to Google Home speakers to control my fan.

Use the preset modes option. There is an example in the docs:

https://www.home-assistant.io/integrations/template/#state-based-fan---fan-with-preset-modes

        preset_modes:
          - "off"
          - "low"
          - "medium"
          - "high"
        preset_mode: >
          {% if is_state('fan.percentage_fan', 'on') %}
            {% if state_attr('fan.percentage_fan', 'percentage') == 100  %}
              high
            {% elif state_attr('fan.percentage_fan', 'percentage') == 66 %}
              medium
            {% else %}
              low
            {% endif %}
          {% else %}
            off
          {% endif %}
        set_preset_mode:
          - action: fan.set_percentage
            target:
              entity_id: fan.percentage_fan
            data:
              percentage: >-
                {% if preset_mode == 'high' %}
                  100
                {% elif preset_mode == 'medium' %}
                  66
                {% elif preset_mode == 'low' %}
                  33
                {% else %}
                  0
                {% endif %}