Skip to content

refactor(settings): seed system prompt body to show in settings panel#142

Merged
quiet-node merged 3 commits intomainfrom
worktree-iridescent-waddling-wall
May 7, 2026
Merged

refactor(settings): seed system prompt body to show in settings panel#142
quiet-node merged 3 commits intomainfrom
worktree-iridescent-waddling-wall

Conversation

@quiet-node
Copy link
Copy Markdown
Owner

Summary

  • Settings panel was showing the System Prompt as empty because the on-disk
    [prompt] system field was treated as "use built-in" when blank, so the
    textarea had nothing to render. The persona was hidden inside a Rust
    constant the user could not see or edit.
  • This change makes the config file the single source of truth: on first
    run the loader seeds [prompt] system with the full built-in body, so
    the textarea always shows the actual prompt the model receives. Editing
    the textarea now edits the prompt in place, no fallback constant
    consulted at runtime.
  • The slash-command appendix continues to be auto-composed at load time
    (still never written to disk) so /search etc. keep working.
  • Default textarea height bumped (rows 16) and char cap raised (8000 → 32000)
    so the ~17 KB built-in body is readable without manual resizing.
  • Tiny gitignore tidy: ignore SearXNG settings.yml.new dump.

Test plan

  • bun run test:all:coverage — 100% lines/branches/funcs frontend; cargo llvm-cov passes --fail-under-lines 100
  • bun run validate-build — zero warnings, zero errors
  • Fresh-install smoke: delete ~/Library/Application Support/com.quietnode.thuki/config.toml, launch app, open Settings → AI → Prompt, confirm textarea is prefilled with the persona body
  • Edit textarea, confirm change persists across app relaunch
  • Clear textarea entirely, confirm [prompt] system = "" saves cleanly and only the slash-command appendix is sent

@quiet-node quiet-node force-pushed the worktree-iridescent-waddling-wall branch from 88b5e4b to 67a2c75 Compare May 7, 2026 06:00
@quiet-node quiet-node changed the title feat(settings): seed system prompt body into config so it shows in panel refactor(settings): seed system prompt body so settings panel shows it May 7, 2026
@quiet-node quiet-node changed the title refactor(settings): seed system prompt body so settings panel shows it refactor(settings): seed system prompt body to show in settings panel May 7, 2026
quiet-node added 3 commits May 7, 2026 12:11
Signed-off-by: Logan Nguyen <lg.131.dev@gmail.com>
Signed-off-by: Logan Nguyen <lg.131.dev@gmail.com>
…ack exception

Signed-off-by: Logan Nguyen <lg.131.dev@gmail.com>
@quiet-node quiet-node force-pushed the worktree-iridescent-waddling-wall branch from 67a2c75 to 3eba59f Compare May 7, 2026 17:13
@quiet-node quiet-node merged commit 42c4cd2 into main May 7, 2026
3 checks passed
@quiet-node quiet-node deleted the worktree-iridescent-waddling-wall branch May 7, 2026 17:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant