Artifact f82a16efe04acd24dcd24b1c763bd4cdf3817be1cbfaf32f7b552fe4e47a073b:
- File docs/design/settings-panel.md — part of check-in [166931a6d8] at 2026-11-23 22:23:57 on branch settings-dialog — The settings list in core: get_settings, and set_setting and pic settings refuse values a setting does not take (user: dmestas, size: 2330) [annotate] [blame] [check-ins using] [more...]
The settings panel
Status: approved 2026-11-23; landing 1 (the settings list in core) built.
Tier: core for the settings list (settings.c) and its commands (get_settings, the checked
set_setting, pic settings); client for the panel (tui/panel.c) and the renderer's box. Clock:
pi for the list (most keys are Pi's), taste for the panel. Record: none new; values stay in
picu_setting in ~/.pic/pic.sqlite. Default: on.
The decisions
- One settings list in core feeds the terminal's panel,
pic settings, RPC and the phone. Each row has the stored key (and the field inside it, forcompactionandbranchSummary), a group, a name, a kind (a choice, a whole number in a range, checked text, or a picker), the default, a description and when a change applies. - Core refuses a value the list does not allow, in
set_settingandpic settingsalike, with a message naming what it takes. Keys the list does not know (per-model thinking levels, active keys, Pi's own) pass as before. A field is reached by its dotted name (compaction.reserveTokens) and written inside its object as JSON of the type its readers take. get_settingsanswers every row with its stored and effective value and whether the stored one is allowed; a bad stored value reads as the default. It carries the database's change counter (PRAGMA data_versionplus this process's own writes); withsinceit answersunchanged.- Left out of the list on purpose:
lastModel(pic writes it), per-model thinking levels and active keys (/thinkingand/keyown them),compaction.modelOverridesandretry(objects),lapseHoldoutandbranchSummary.reserveTokens(measurement knobs). All stay inpic settings. - The panel opens over anything, a running reply included, with
/settings,/configor the rebindable actionapp.settings.open(F2), and closes without touching what was under it. It floats in fullscreen at 64 columns by 14 rows of conversation or more, sits above the footer otherwise, and shrinks to one line in a tiny window.
Locked in
The fields get_settings returns, once the phone reads them; that core refuses bad values; the
action name app.settings.open. The box's look and size rules, the key and which settings are
listed are cheap to change.