Agent feature prompt and tool

Overview

The agent feature prompt is a dynamic system message injected into every chat stream that tells the model which mouaif features are enabled, disabled, or authorized for the current project and chat session. It is accompanied by a list_features tool the model can call at any time to get the complete structured feature state — especially useful under the very-small prompt profile, where tool descriptions are trimmed.

Together they solve the problem of "the model doesn't know what it can do": without them, the model only learns about a tool when it receives its full schema in the tools field. The feature prompt gives a one-line summary of every available capability up front, and the tool delivers the full detail on demand.

Usage

Feature injection

The feature summary is assembled server-side and injected as its own system message in the upstream message array, after agent files and before tagged files. It lists:

list_features tool

The model has a list_features tool available in every chat. It takes no arguments and returns a JSON object with these keys:

KeyTypeDescription
toolsobjectEach built-in tool family (shell, subagent, file, ask_user) with mode, allowlist, defaultTimeoutMs, maxTimeoutMs.
mcparrayEach MCP server with name, slug, status, tools, authorization.
agentFilesobjectenabled (boolean), fileNames (the names looked for), discovered (files actually found with size).
agentsobjectdiscovered (named subagent personas found, by name).
fileTaggingobjectactive (boolean), count (number of tags).
tracebooleanWhether trace-to-file is on for this chat.
promptProfileobjectid and label of the active prompt profile.

The tool bypasses the authorization gate — it is read-only metadata and never requires user approval.

Chat controls

When discovered agent files are shown in the chat card, every file row has a checkbox next to the file name. Because agent-file injection is currently a chat-level on/off state, toggling any row controls whether all discovered files are injected on the next turn. The card lists discovered files even when the current chat has agent files disabled, so the chat card and Settings → Project remain consistent. The checkboxes are disabled and marked as locked when agent files are disabled in project settings.

Behavior