Skip to content
/ Lonca
Documentation contents

Configuration

The Configurator

The agent that writes config.yaml from your repositories: where it is, its steps, setting up a new repository, and its bounds.

You do not write config.yaml by hand. The Configurator, Lonca’s configuration agent and a run of Claude Code or Codex, reads your repositories (build files, CI, test configs, the README) and writes the configuration from them: each repository’s commands, its tests and pre-PR gate, its E2E setup, its sign-in script, the agents and orchestration. It checks every command it writes by running it, in a narrowed form, before it keeps it. Lonca, not the agent, saves the result, and only after you have seen it.

Where it is

The Configurator is an icon in the title bar, between the notifications bell and Settings; its tooltip says Configurator. It opens as a view of its own in the main area, the way the Orchestration chip opens the Orchestration view, headed Configurator and Configures Lonca from your repositories. It changes nothing in them, and you see every change before it is saved. Selecting a task or opening the Orchestration view closes it; closing it does not stop a run.

A dot on the icon tells you how a run is doing while its view is closed:

DotTooltipMeans
Blue, pulsingConfigurator: workingA turn is running
YellowConfigurator: waiting for your answerIt asked you something
GreenConfigurator: ready to applyA new file waits for Apply
NoneConfiguratorNothing waits on you

Until 11.5.0 it was a tab of Settings, Configuration agent. That tab is gone.

What it writes

Two kinds of file, and nothing else:

  • ~/.config/lonca/config.yaml, within Lonca’s schema. The config.yaml reference describes it block by block.
  • The files the config names under prompts/ beside it: the instructions a stage agent or the leads take (prompt_file), and a repository’s or a named sign-in’s script under prompts/sign-in/ (sign_in.file).

It never writes a password, a token or a key. Those are entered in Settings and kept encrypted: the Jira token under Settings → Jira connection, a repository’s sign-in credentials under Settings → Workspaces or in the sign-in test card, the Figma token under Settings → Figma.

One step at a time

A run goes through four steps, shown as a bar under the Provider and Model fields: Request → Working → Review → Done. Only the current step fills the view, so you never scroll to find what comes next. The step follows the run: open the view again, even after a restart, and it is on the step the run is on.

Request
What you want: one of the starters below, or your own words under Or ask in your words.
Working
A large loader, what it is doing now in plain words (Running a command, Reading files, Searching) with the call itself on one line under it, how long it has worked (for 21s), and its last few steps. When it asks you something, the step reads Your answer, in yellow, and shows its questions.
Review
Its report, the sign-in test cards, and the files it offers, as tabs. A plain answer, when nothing should change, is read here too.
Done
Configuration saved, with Restart now and Restart later where Lonca can restart itself, and New conversation.

The actions stay pinned at the bottom of the view, whatever the step: Cancel while a turn runs, Send answers while it asks, Run again and Apply on an offer, and New conversation. The messages before the current one sit in a Conversation column on the right, which folds away (Hide the conversation) and stays folded until you open it again. A run that fails or is cancelled marks the step where it stopped in red, with the reason.

When it runs

At first setup

The setup wizard asks only what cannot be found out: the workspace, the repository folders, the Jira connection (optional) and your language. Under How should Lonca be configured?, Let Lonca configure it (recommended) hands the rest to the Configurator; Set up by hand is the other way. The wizard runs the same stepped panel, with the conversation folded above the step instead of a column. See First setup.

On request

The Request step offers three starters, each a card with a line under it, and a message box:

StarterUnder itWhat it does
Check my configurationAgainst your repositories as they are nowChecks the whole file against your repositories and offers what should change
Set up authenticationHow Lonca signs in to one repository, or a named sign-inWrites one repository’s sign-in, or one named sign-in of a workspace; see below
Set up a repositoryOne that is not set up yetShown while a repository is not set up; see below
Or ask in your wordsA change, or an explanation, in your own words

After every update

A release that changes what config.yaml should say (a new key, a rename, a placeholder a command now needs, a default that moved) ships a config note. At the first start after an update whose notes your file has not had, before Lonca reads the file, it opens on Lonca was updated: the two versions, the notes of each release in between, and the Configurator, already at work. The same stepped panel runs there, from Working on. Look at what it changed, then press Apply. It changes only what the notes ask. This works even when the update made your file stop loading: the agent reads it loosely and works on it either way.

Open the file opens the file itself. Skip these changes starts Lonca without them; when the file loads, the notes count as applied, and when it does not, the next start offers the Configurator again. See Updates and versions.

Setting up a new repository

A repository you add in Settings → Workspaces has no commands, tests or gate yet. Lonca offers to have the Configurator set it up; it never starts the run by itself.

  • After the save that adds it, a toast says billing-api was added. Set it up with Configurator., with Set up.
  • Its card in Settings → Workspaces carries a note led by Not set up: Configurator can read billing-api and write its commands, tests, gate, E2E and sign-in. You review every change before it is saved., with Set up with Configurator and Not now.
  • The Configurator’s Request step shows Set up a repository while any repository is not set up.

A repository counts as not set up while its entry has neither gate: nor tests:, until a set-up, a first setup or a check that named it is applied, or you press Not now, which stops the offer for that repository. Each way in closes Settings and opens the Configurator on the repository’s form (Repository, then Set up billing-api); you start the run there. Unsaved edits in Settings hold it back (Save your changes first), since closing Settings would lose them. A repository you have saved can be set up before the restart that loads it.

The run sets the repository up as a first setup would: its base branch, run command and ports, its E2E block, its tests and gate, its jobs, figma, and its sign-in when its app needs one. It may change only that repository’s entry, and write at most its sign-in script (prompts/sign-in/<id>.mjs). When the repository is better signed in to by name, it may also add a new named sign-in that only this repository uses, in every workspace that lists it, with its script; it never changes one that exists. Lonca refuses anything else. What the repository would want outside its entry (an archive.remove folder, a setup.include_file) goes into its report, as a suggestion for a later Check my configuration. It is a conversation like any other: it can ask, and you can write on. Every plan has it, Free included.

Its provider and model

The Configurator runs on Claude Code (claude) or Codex (codex), whichever you choose; until you choose, Claude Code when it is installed, else Codex. Pick it in the setup wizard, at the top of the Configurator, or on the update screen, with two fields:

Provider
The CLI it runs on. Only the CLIs found on your PATH are offered. If the chosen one goes missing, it stays chosen, marked “(not installed)”, and Lonca says so with how to install it instead of switching to another one.
Model
Optional; empty means the CLI’s default. Letters, digits and . - _ : / [ ] only, starting with a letter or a digit.

The choice is kept in Lonca’s own state, not in config.yaml, and the config’s ai: block does not move it. A change applies to the next run. A conversation in progress keeps the provider it started with: start a New conversation to change it.

It runs headless, with shell and file-reading tools and no editing tool, in a scratch folder of its own under ~/.config/lonca/config-agent/ (emptied when the next run starts), on your CLI’s own account. Your own MCP servers, plugins, hooks and skills are left out on both providers. On Codex your $CODEX_HOME/AGENTS.md still reaches it, since no Codex flag leaves it out; Lonca’s instructions come after it.

How it works

  1. It reads before it writes. Each repository’s root files, its CI definitions (the best evidence of how a suite really runs), its test runner configs, README and .env.example, and how its dev server takes its port.
  2. It chooses the repository’s own commands: the scripts and targets the repository defines and CI runs, through its monorepo tool where it has one.
  3. It verifies every command, bounded. A gate command runs on one project or one spec, with the same tool and flags, and must write its JUnit report where Lonca expects it. A rerun command runs one real spec. Test patterns are tried against the commands they must and must not match. It never runs a whole suite only to check a command, and it times each run to set the timeouts.
  4. It writes the E2E block against throwaway data. It works out how Lonca’s runner reaches the app (a port, or an Electron launch from a clean folder) and checks it in a throwaway clone under its scratch folder, an Electron launch with Lonca’s own runner, so your repository is never built in. When the app cannot start without touching real data, it writes no e2e: block and reports the change that would allow one.
  5. It names the repository’s review skills. It looks in .claude/skills/*/SKILL.md and .claude/commands/*.md for skills and commands meant for review, and lists them under review_skills (see Review skills). It writes only the key: it never creates, edits or moves a skill.
  6. It reports what it ran to verify each command and how long it took, what it could not verify and why, and every change from the file it was given, one line each, with the reason.

Missing dependencies in a repository are a finding, not a task: it does not install them there, and marks the commands that need them as unverified.

What you see before anything is saved

Review shows its report first. When it offers a new file, the files follow in tabs:

TabShows
ChangesThe new file against the old one, line by line (not at first setup, where there is no old one)
New config.yamlThe whole new file
Prompt files (n)Each prompt file and sign-in script it writes, marked new, changed or unchanged, with its changes

Ask for a change opens the message box in place, without leaving the offer. Apply saves through the same path as every Settings save: the file must load, the previous one is kept in backups/ (the last 20), and a native macOS dialog asks you to confirm anything that decides what runs or where secrets go: a new or changed command, an instructions file, the test policy, a sign-in address. The page cannot click that dialog for you.

When Lonca refuses the result, The file was not saved says why, beside Apply. A file holding an invisible or control character is always refused, and so is a file that changed on disk while the agent worked: run it again.

Restart

A saved file applies after Lonca restarts. The Done step says Configuration saved and It takes effect after Lonca restarts., with Restart now right there, and Restart later, which leaves it to the next start. The stage agents live in tmux and survive the restart. A restart due from elsewhere (a Settings save) shows its banner at the top of the Configurator, and at the top of Settings, where it stays in sight as you scroll.

What it may and may not change

Its work is Lonca’s configuration, and Lonca enforces that whatever the agent’s reply says:

  • It has no editing tool. Lonca writes the files from its reply. A file must sit under prompts/ (a prompt file) or prompts/sign-in/ (a sign-in script) and be named by the config; nothing is written through a link or outside the config’s folder.
  • A narrow run stays narrow. Set up authentication may change only that repository’s sign_in (or that named sign-in) and its script; Set up a repository, only that repository’s entry, its sign-in script and a new named sign-in only it uses. Lonca refuses an offer that changes anything else.
  • It never changes a repository, Lonca, your machine, your shell or your tools. Its shell is open, because it runs your repositories’ build tools, so Lonca checks before it starts and after every turn: each repository’s git status, and fingerprints of each repository’s .git/config and .git/hooks/ and of Lonca’s own files (config.yaml, the encrypted credential and key files, the license and trial record, the agent’s own provider choice, and prompts/). Any change fails the run, and nothing is saved. The one exception is a branch's tracking in .git/config (its remote and upstream, or its entry removed whole): those entries do not count as a change.
  • A fix that belongs in a repository is reported, never applied. A test config that should write JUnit to LONCA_JUNIT_DIR, a dev server that should read PORT: the report names the file and gives the exact lines for you to add, and the config is written to work without them.
  • On Codex it runs in Codex’s workspace sandbox. It can write only into your repositories (which the check above holds to no change), its scratch folder (where npm, pnpm, Yarn, Gradle and Maven keep their caches for the run) and the system’s temporary folders. A write anywhere else, your home folder included, is refused.

When it asks you

Asking is the exception. When a sensible default exists, it writes the default and lists the question in its report, with what it assumed. It asks only when it cannot write a working config without your answer: for example, two apps, and nothing in the repositories says which one the E2E checks should drive.

Its questions arrive on the Your answer step as controls, at most eight at once: a choice, a list, checkboxes, a text field, or yes and no. Its own guess is already chosen, and each has Add a note. Answer them together, add anything else in the box below if you like, and press Send answers; the same run goes on with your answers. The title bar’s dot is yellow meanwhile.

It never asks for a password, a token or a key; in Set up authentication and Set up a repository, the message box reminds you not to write one there.

Your language

Everything it writes for you (its report, its questions, its replies) is in your language: reply_language from your config, else your system’s. The config and the prompt files stay in English, as Lonca’s own files do.

It writes short and in plain words: what you must do first, then the rest. The commands, file lines and paths it reports stay exact.

The conversation

PlansFreeStandardProTeamCheck my configuration and the conversation

In the Configurator the agent answers each message in one of three ways: a changed file you look at and apply, questions, or a plain answer when nothing should change (an explanation, a check that found the file right). You can write on after any of them, under Write to the Configurator; ⌘Enter sends. It continues the same session, so a correction after a finished config is read in context.

  • Cancel stops a running turn. A question waits for you until you answer it or press New conversation. Run again starts a check over, or an update on the update screen.
  • The conversation is kept across a restart (applying needs one) until you press New conversation, which waits for a running turn to end.
  • The start forms of Set up authentication and Set up a repository say Starting ends the conversation there is. over a finished conversation. Over a running turn they wait (A run is in progress: wait for it or cancel it.): nothing is cancelled for you.
  • Every Configurator box, the answers to its questions and the start forms included, takes a pasted screenshot, and files from the paperclip (Attach files) or dropped on it. They are kept in state/configurator/attachments/ under the config folder, where the agent can read them. See Message boxes.

Set up authentication

Set up authentication sets up how Lonca signs in to one project’s app, for its E2E runs and its stage agents, or one named sign-in of a workspace (see Named sign-ins). A repository without a sign-in links here from Settings → Workspaces: Set it up closes Settings and opens the Configurator on this form, for that repository; a named sign-in links here from its section with Change it with the Configurator, and a task's sign-in question with Fix with the Configurator, the failure filled in.

  1. Choose the workspace and the project, or one of its named sign-ins, and say what you already know of how it signs in (a token endpoint, the login page), never a password. Press Start.
  2. The agent reads the project (for a named sign-in, the projects that use it) and offers the sign-in and its script under prompts/sign-in/. On a project it may change that project’s sign_in, a named sign-in only that project uses, or turn the project’s own block into a named sign-in only it uses; a named sign-in other projects use too is changed from its own section in Settings. On a named sign-in it changes only that sign-in and its script. Lonca refuses any other change.
  3. In the Sign-in test card, enter the credentials the script names and press Save and test. They are kept encrypted and are never shown to the agent. Lonca runs the offered script, not yet saved, on a browser profile and session of its own, so the project’s real session is untouched. A named sign-in signs in at its own url; a project's, against an app of the project that is already up, the sign-in’s own address when that is not on this machine, or an app it starts for the test in a temporary worktree (Stop takes it down). When it cannot start one, or with Test another address, give the App address of one you started.
  4. The masked result goes into the conversation. A failure goes to the agent, which fixes the script, at most three times in a row before it waits for you. Refused credentials do not go to the agent: they are yours to correct.
  5. Apply saves the config and the script like any other change of the agent’s. It is offered before a passing test too, marked Not tested yet.

The same Sign-in test card appears whenever the Configurator offers a sign-in it wrote, a repository's or a named one, one card per sign-in: at first setup, after an update, in a check, in a repository’s set-up. How Lonca then uses the script: E2E runner and sign-in.

On each plan

FreeStandard, Pro, Team
First setup✓✓
Set up authentication✓✓
Set up a repository✓✓
Config notes after an update✓✓
Check my configuration—✓
The conversation—✓

Once plans apply, Free shows Check my configuration and the message box locked, with See plans. An update never leaves a Free config behind. See Plans.

Where it keeps its things

~/.config/lonca/
config.yaml                    the file it writes
backups/                       the previous versions (the last 20)
prompts/                       the prompt files and sign-in scripts it writes
config-agent/                  its scratch folder
state/config-agent.json        the version it last brought the file up to, and the repositories set up or put off
state/config-agent-chat.json   the conversation, until New conversation
state/config-agent-runner.json its provider and model