AI Assistant

The development environment has a built-in AI agent. It works with any model compatible with the OpenAI API: the distribution includes examples for Groq, Google, OpenAI, and OpenRouter, but the list is open — any compatible provider can be connected by specifying an address and key.

The assistant is useful for quick function reference, analyzing someone else’s code, finding errors in a file, and generating snippets on the fly.

The request goes directly from the program to the provider: the store server is not involved and knows nothing about the keys. The key is stored in the development environment settings, with each developer having their own.

Configuring Agents

“Editor Settings → AI Assistant Agents”. A table of agents, with a system prompt field below it for the selected row.

Column What it defines
Quick Reference agent appears in the F1 menu
File Analysis agent appears in the Shift + F1 menu
Name arbitrary name under which the agent is visible in the selection menu
Model model identifier at the provider
Address OpenAI-compatible endpoint (.../chat/completions)
Key provider API key
Timeout how long to wait for a response, in seconds
Temperature response variance, from 0 to 1

System prompt — a base instruction for the agent, set individually for each table row. This is what makes agents differ from one another when using the same model: the ones supplied for quick reference say “explain the function in more detail and provide examples,” while the analysis agents say “find errors, especially logical ones.”

A single agent can be marked in both columns at once, or not marked anywhere — in that case it will only be available for a request with clarification, where the list is complete.

Levels in Names

Junior, Middle, and Senior in the names of the supplied agents are a distribution convention, not a platform mechanism: the platform only reads the model, address, and key.

A heavier model is not always better: on simple questions a fast model responds almost instantly, while waiting for a heavy one can take tens of seconds.

Provider Keys

Calling from the Editor

Three keyboard shortcuts, one for each mode. If there are multiple suitable agents, a selection menu appears at the cursor; if exactly one is marked, the request is sent immediately.

F1 — Quick Reference

Sends the word under the cursor, or the selected fragment if there is a selection. The response arrives formatted and is displayed in the assistant panel. This is the primary mode: you encounter an unfamiliar function — place the cursor on it, press F1.

Agents are taken from those marked in the “Quick Reference” column.

Ctrl + F1 — Request with Clarification

Opens a dialog. The selected code goes into the context field, with a separate field for your own question. The agent is also selected here, from the full list, not just the marked ones — allowing you to use a heavier model for a complex one-off question.

This mode is for everything that doesn’t fit into a single word: “why is there a memory leak here,” “rewrite this more compactly,” “explain what this query does.”

Shift + F1 — File Analysis

Sends the entire file with line numbers added. The prompt also appends a requirement to return strictly one JSON object of a defined form:

{result:[{
    line_start:  starting line number of the fragment,
    line_end:    last line number,
    type:        ERROR | WARNING | NOTICE,
    description: description,
    replace:     ready replacement code
    }]}

The program parses the response and displays a list of findings. Selecting an item highlights the corresponding lines in the editor, and the apply button replaces the fragment with the suggested code.

It is precisely because of the strict response format that stronger models are used in this mode: a weaker model readily drifts into explanations around the JSON, and parsing fails. If the response cannot be parsed, the environment will report a format error.

Agents are taken from those marked in the “File Analysis” column.

Follow-up Question

After a response in F1 and Ctrl + F1 modes, a follow-up button is available. It carries the previous request along with the received response into the context of the new question — this turns a short reference into a dialog, and the agent remembers what was discussed. Each follow-up accumulates context, so long chains are better started fresh rather than extended indefinitely.

Practical Notes

Temperature. For code work it is lowered: the supplied analysis agents are set to 0.2, and the reference agents to 1. The lower the value, the more predictable and terse the response; for finding errors, this is exactly what you need.

Timeout is chosen to match the model, not set high “just in case”: fast agents in the distribution have 30 seconds, heavy ones have 200. Too small a timeout on a heavy model will produce a connection error at exactly the moment when the response is almost ready.

Keys and data. The request sends the code you submitted: a word, a selected fragment, or the entire file. You should not send the contents of files containing access keys, passwords, and visitors’ personal data — this is a regular external service, not part of the platform.