Skip to content

Move Compact Chat to Global Settings - #740

Merged
RANGROO merged 1 commit into
unstablefrom
codex/compact-chat-global-unstable
Aug 26, 2026
Merged

Move Compact Chat to Global Settings#740
RANGROO merged 1 commit into
unstablefrom
codex/compact-chat-global-unstable

Conversation

@RANGROO

@RANGROO RANGROO commented Aug 26, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • Move Compact Chat from the retired chat/profile toggle into shared Global Settings.
  • Show Compact Chat under Prompt & Rechat in both the PHP and Prisma settings surfaces.
  • Enable it by default while continuing to exclude the Narrator from history compaction.
  • Preserve an existing chim_context_mode choice during migration, then remove the legacy row and Focus Mode runtime path.
  • Publish compact_chat through the status APIs expected by the CHIM client already merged in Dwemer-Dynamics/CHIM#173.
  • Update the Local LLM Quickstart path to enable the new global setting instead of recreating the retired option.

Recovery context

PR #739 was mistakenly stacked on #733 and therefore merged into that feature branch rather than unstable. This recovery branch starts directly from current origin/unstable and contains only the Compact Chat feature. After this lands, #733 should be rebased without reintroducing its duplicate Compact Chat changes.

Migration and compatibility

Migration general_settings 20260825001 is idempotent:

  • Keep an existing COMPACT_CHAT_ENABLED value when present.
  • Otherwise import the legacy public.conf_opts.chim_context_mode value.
  • Otherwise use the schema default of true.
  • Delete the legacy row only after the global setting is written successfully.

Validation

  • PHP lint passed for all 24 changed PHP files.
  • JSON schema parse passed: global boolean, default true.
  • Focused PHPUnit passed: 8 tests, 14 assertions.
  • Catalog, Quickstart, migration-version, and CHIM unstable protocol contract probes passed.
  • Full PHPUnit comparison:
    • Feature: 271 tests, 2627 assertions, 16 errors, 2 failures, 1 warning.
    • Exact unstable base: 270 tests, 2625 assertions, the same 16 errors, 2 failures, and 1 warning.
    • The shared failures are existing Windows database/PGPASSWORD, missing ZipArchive, and order-dependent baseline failures.

Performance

No new recurring query or polling path is added. Runtime reads the already-loaded global value instead of querying the legacy conf_opts row, and enabled Compact Chat reduces conversation-history prompt size. Quickstart adds one settings upsert only when its Local LLM preset is applied.

Review size

25 files, 159 changed lines reported by Git; 151 are substantive and 8 are line-ending-only churn around the added sample-config line.

Limits

  • Not deployed.
  • The migration was not executed against a live database.
  • No live HTTP/Prisma render or in-game test was performed.
  • No screenshot is attached because this branch was not deployed; the settings row is generated from the validated shared catalog.

@RANGROO
RANGROO marked this pull request as ready for review August 26, 2026 05:33
@RANGROO
RANGROO merged commit 58dc029 into unstable Aug 26, 2026
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