{% extends "layout.html" %} {% block content %} {% set page_mode = creation_mode | default(form_data.get('creation_mode', 'cloud')) %}

Admin Only

New Configuration

{% if page_mode == 'local' %} Local mode uses your machine's dbt project folder. Governor reads target/manifest.json automatically. {% else %} Cloud mode starts with a GCS-backed manifest and shared-infrastructure defaults. {% endif %}

{# Cloud runtime only. In local/CLI mode there is no other mode to switch to — the route always re-renders the local form, so the button would be a dead no-op. #} {% if page_mode != 'local' %} Change Mode {% endif %}
{% if errors and errors.get('_general') %}
{{ errors['_general'][0] }}
{% endif %} {% if not gcp_projects %}
No GCP projects were discovered automatically. You can still continue by entering the project ID manually.
{% endif %}
{# In local/CLI mode the GCP project is read straight from target/manifest.json (every dbt node carries it in the ``database`` field), so we don't ask the user to type it. We still surface any validation error that bubbles back. #} {% if page_mode == 'local' %} {% if errors and errors.get('gcp_project_id') %}

{{ errors['gcp_project_id'][0] }}

{% endif %} {% else %}
{% for project in gcp_projects %} {% endfor %}

Manual entry works even when project discovery is unavailable.

{% if errors and errors.get('gcp_project_id') %}

{{ errors['gcp_project_id'][0] }}

{% endif %}
{% endif %} {% if page_mode == 'local' %}

Local dbt Project

Point Governor to your dbt project folder and it will read target/manifest.json automatically. Run dbt compile or dbt build first so the manifest is available.

Local mode does not expose background sync schedules, queue pages, or multi-user management.

Governor reads target/manifest.json from this folder. Also used to apply reviewed solutions directly into your working tree.

{% if errors and errors.get('local_project_path') %}

{{ errors['local_project_path'][0] }}

{% endif %}
{% if errors and errors.get('manifest_upload') %}

{{ errors['manifest_upload'][0] }}

{% endif %} {% endif %} {% if page_mode == 'cloud' %}
Loading...
{% if errors and errors.get('github_repo') %}

{{ errors['github_repo'][0] }}

{% endif %}
{% endif %} {% if page_mode == 'cloud' %}

Manifest Location

Cloud mode uses a GCS-backed manifest.

{% if errors and errors.get('manifest_location') %}

{{ errors['manifest_location'][0] }}

{% endif %}
Loading...
Select a bucket first
{% endif %} {% if page_mode == 'local' %} {% else %} {% include "configurations/_schedule_fields.html" %} {% endif %}

Advanced Settings

{% if page_mode == 'local' %} Configure detection and generated solution settings for this local project. {% else %} Configure detection and PR submission settings for this project. {% endif %}

{# Detection group + Watched Rules are cloud-only. In local/CLI mode the user optimises against the latest local dbt run — there is no historical time window, no per-project rule selection, and no multi-day resolution period, so detail.html hides them the same way. #} {% if page_mode != 'local' %}

Detection

Number of days to track detection frequency. Opportunities are reported as "detected in X of the last Y days".

{% if errors and errors.get('lookback_window_days') %}

{{ errors['lookback_window_days'][0] }}

{% endif %}

Number of consecutive days without detection before an opportunity is marked as resolved.

{% if errors and errors.get('resolution_period_days') %}

{{ errors['resolution_period_days'][0] }}

{% endif %}

Watched Rules

Choose which optimization rules Governor watches for this project.

{% if detection_analysis_surfaces %}
{% for surface in detection_analysis_surfaces %}

{{ surface.title }}

{{ surface.description }}

{% endfor %}
{% endif %} {% if unknown_watched_rule_types %}
Some submitted rule ids are no longer available: {{ unknown_watched_rule_types | join(', ') }}.
{% endif %}
{% if detection_rule_groups %} {% for group in detection_rule_groups %}
{% for rule in group.rules %} {% endfor %}
{% endfor %} {% else %}

No project-level detection rules are currently registered.

{% endif %}

Leaving every rule unchecked is valid and means Governor will skip project-level detection for this configuration.

{% if errors and errors.get('watched_rule_types') %}

{{ errors['watched_rule_types'][0] }}

{% endif %}
{% endif %}

Solution Guardrails

Allowed Solution Types

Choose which remediation families Governor may generate for this project. Detection still runs independently.

{% if unknown_solution_policy_tags %}
Some submitted solution policy tags are no longer available: {{ unknown_solution_policy_tags | join(', ') }}.
{% endif %}
{% if solution_policy_catalog %} {% for policy in solution_policy_catalog %} {% endfor %} {% else %}

No solution policy tags are currently registered.

{% endif %}

Leaving every policy unchecked is valid and means Governor can still detect opportunities, but it will not store new solutions for this project.

{% if errors and errors.get('allowed_solution_policy_tags') %}

{{ errors['allowed_solution_policy_tags'][0] }}

{% endif %} {# Spec 124: auto-run shadow validation for Safe solutions. Mirrors the detail.html field. #} {# Spec 130: pre-checked in CLI/local mode when the form is first rendered. The hidden "_submitted" marker lets the form handler distinguish "user explicitly unchecked" from "form was never rendered" for this field. #}

Solution Generation

$

Only generate solutions for opportunities where the query cost exceeds this amount. Opportunities below this threshold are still detected but won't receive solutions. Default: $5.00.

{% if errors and errors.get('min_solution_cost_usd') %}

{{ errors['min_solution_cost_usd'][0] }}

{% endif %}
{% if page_mode == 'cloud' %}

PR Submission

Override the organisation-level auto-PR threshold for this project. Leave as "Use organisation default" to inherit the global setting.

{% endif %}

Storage Billing

$ /month

Only surface storage billing opportunities where switching to physical billing saves at least this amount per month. Leave blank to show all datasets with any savings.

{% if errors and errors.get('storage_billing_min_savings_usd') %}

{{ errors['storage_billing_min_savings_usd'][0] }}

{% endif %}
Cancel
{% endblock %}