{% extends "admin/_layout.html" %} {% from "_macros.html" import icon %} {% set section = "prompts" %} {% block title %}Prompts - {{ brand.name }}{% endblock %} {% block heading %}Prompts{% endblock %} {% block admin_content %}

Everything {{ brand.name }} puts in front of a model on its own: what day it is, how to use each tool, what it has been asked to remember. These sit above whichever system prompt was authored for the instance, the model or the chat — that prompt still wins where the two disagree. Clear a box to leave that piece out altogether; press Use default to put the built-in wording back.

{% if saved %}
{{ icon("check", "icon--sm") }} Prompts saved.
{% endif %} {# The editor first, the reference after, and that ordering is the fix rather than a preference. The Variables legend and the Preview both run to a screen each, and they used to sit *above* the tabs -- so the thing this page exists for started two screens down. Every tab switch then had to move the viewport to be any use, and `ui.js` did: it put the tab bar at the top of the scroller. On a short panel the scroller cannot go that far, so the browser clamped to the maximum and left the panel stranded above a screen of nothing, which reads as a page that failed to load. That is the empty space; the scrolling was the cause and not the cure. With the tabs near the top there is nothing to scroll past: switching panels changes what is below the bar and leaves the bar where it is. The reference cards keep their place in the reading order -- after the work, where you go to look something up -- and the preview still watches the form through `hx-include`, which does not care about document order. #}
{% for key, label, fragments in groups %} {% endfor %}
{% for key, label, fragments in groups %}
{% for fragment in fragments %} {% with value = values[fragment.key], overridden = fragment.key in overridden %} {% include "admin/_prompt_field.html" %} {% endwith %} {% endfor %}
{% endfor %}

Length

Everything above is cut off past this. 0 means the built-in {{ default_harness_chars }}. It is a backstop against a large skill index or memory list quietly eating the context window, not a budget to tune.

{# data-confirm-button, not data-confirm: this button acts on its own through formaction, and confirming the whole form would also catch plain Save. #}

Variables

Write these in double braces. Anything in double braces that is not on this list is left exactly as you typed it — variable names are lowercase letters, digits and underscores, so {"total": 1} and ${PATH} are never mistaken for one. A variable with nothing in it takes its whole line with it, so a section never appears empty.

{% for variable in variables %}
{{{{ variable.name }}}} {{ variable.description }} {% if variable.name not in resolved %} only in the title request {% elif resolved[variable.name] %} {{ resolved[variable.name] | truncate(80) }} {% else %} empty {% endif %}
{% endfor %}
{# The preview posts both the controls and the editing form, so what it shows is the text in the boxes rather than the text last saved. Triggers live on this wrapper and the swap is innerHTML, so the element carrying `load` is never replaced -- an outerHTML swap would re-fire it and loop forever. #}

Preview

The whole system message, assembled from what is in the boxes below — including changes you have not saved yet. Your own memories and skills are used, because a preview against invented ones cannot tell you whether it reads well against what is actually there.

Empty means a chat that can see everything.

{# The two axes a tool family cannot reach. Without them every fragment gated on a chat -- the whole agent surface, both scheduling fragments and the helper warning -- was missing from the preview whatever was ticked below, because the preview passes no Chat and those variables are only filled when there is one. #}

Only reaches the prompt with agent ticked below. The machine, directory and plan shown there are samples.

Tools offered {% for family in families %} {% endfor %}

Tool descriptions

Defined in code — part of the schema sent to the endpoint alongside the prompt, not guidance layered on top of it. They are statements of fact about what each tool does, so they change when the tool does; editing them here would let the text quietly become a lie. A custom tool's description will be editable, because a custom tool is a row rather than a function.

{% for tool in registry %}
{{ tool.name }} {{ tool.description }} {{ tool.family }}
{% endfor %}
{% endblock %}