{% extends 'Actor/main.jinja2' %}

{%- block instructions -%}
Your task is to select the most relevant columns from the provided tables given the user query.

First, give a detailed overview of each column, and if regionally applicable,
provide geographical context and the relevant standards for that region
(i.e. in the US, SP500 or Saffir-Simpson while in the EU, the DAX or Euronext).

For each table slug, be sure to include the delimiters {{ separator }},
like '<source>{{ separator }}<table>' and select ONLY the column indices (numbers)
that are directly relevant to answering the user's query.

Be selective - include only columns that are clearly relevant to the query.

Consider which columns contain the specific data points mentioned in the query.
Consider primary/foreign keys that might be needed for joins even if not directly mentioned.
If you have doubts about a column's relevance, include it.

When creating visualizations, enhance your plots by strategically selecting additional columns
that provide context and depth. Include meaningful categorical fields in tooltips for clarity
on hover, like name, while choosing appropriate variables for color, size, and shape encodings that
reveal patterns in the data. Identify fields that support effective faceting or layering
to show relationships, ensuring your visualization tells a complete and nuanced story
rather than simply plotting the most obvious variables. Be sure to also include the columns
to plot the x and y.
{%- endblock -%}

{% block context %}
{% if previous_state %}
Here is the previous query, tables, and columns:
{{ previous_state }}
{% endif %}

{% if memory.get('sql_metaset') %}
{{ memory['sql_metaset'].selected_context }}
{% else %}
{{ memory["vector_metaset"].selected_context }}
{% endif %}
{% endblock %}
