[PR #4173] [MERGED] Fix chat polish regressions and Spotify repeat #6268

Closed
opened 2026-10-23 04:08:46 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/Pasta-Devs/Marinara-Engine/pull/4173
Author: @SpicyMarinara
Created: 7/27/2026
Status: ✅ Merged
Merged: 7/27/2026
Merged by: @SpicyMarinara

Base: staging ← Head: agent/chat-polish-echo-spotify-cyoa


📝 Commits (4)

  • 5096cbb fix chat persistence, playback repeat, and roleplay input
  • 060c3b5 normalize CYOA dialogue quote formats
  • d674d8e address CodeRabbit review feedback
  • 9c3c916 verify Spotify repeat state before success

📊 Changes

9 files changed (+515 additions, -29 deletions)

View changed files

📝 packages/client/src/components/chat/ChatMessage.tsx (+1 -2)
📝 packages/client/src/components/chat/EchoChamberPanel.tsx (+64 -11)
📝 packages/client/src/stores/ui.store.ts (+48 -1)
📝 packages/client/src/styles/globals.css (+4 -0)
📝 packages/server/src/services/agents/agent-executor.ts (+3 -1)
➕ packages/server/src/services/agents/cyoa-choice-normalization.ts (+25 -0)
📝 packages/server/src/services/tools/tool-executor.ts (+39 -14)
📝 scripts/regressions/prompt.regression.ts (+284 -0)
📝 scripts/regressions/roleplay-streaming.regression.ts (+47 -0)

📄 Description

Linked issue

Closes #4168
Closes #4170
Closes #4171
Closes #4172

Why this change

  • Echo Chamber dimensions should follow the chat where the user set them.
  • Spotify Music DJ repeat should loop a complete multi-song selection, not only its final track.
  • Roleplay typing should paint as promptly as Conversation and Game even over a populated live scene.
  • CYOA choice dialogue should accept either JSON-escaped double quotes or single-quote delimiters without corrupting apostrophes.

What changed

  • Persisted and restored Echo Chamber dimensions per chat, committing only completed resizes.
  • Started repeatable Spotify track selections as one URI list and applied context repeat while retaining track repeat for a single song.
  • Isolated Roleplay composer paint and stopped inactive guided actions from subscribing to draft presence.
  • Normalized only CYOA choice text from single-quote dialogue delimiters to ordinary double quotes; valid escaped JSON quotes continue through unchanged.
  • Added deterministic regressions for the affected paths, including end-to-end CYOA agent parsing.

Validation

  • pnpm check passes locally
  • Container (Docker / Podman) built and ran without issue
  • Ran the app, clicked through the changes manually
  • Checked edge cases (light + dark mode, mobile viewport, empty states, error paths)
  • Above manual verification completed (describe below)
  • Read and followed CONTRIBUTING.md

Automated and focused verification notes

  • pnpm check
  • pnpm regression:prompt
  • pnpm --filter @marinara-engine/server exec tsx ../../scripts/regressions/roleplay-streaming.regression.ts
  • Roleplay typographic quote/caret browser regression
  • Browser-verified that Echo Chamber dimensions remain independent across two chats and survive reload.
  • Profiled a dense Roleplay transcript against Conversation and Game.
  • Spotify playback tests use mocked Web API responses; a live Spotify Premium account was not used.

Docs and release impact

  • No docs changes needed
  • Updated docs (README / CONTRIBUTING / android/README / CHANGELOG) as needed
  • Translated docs on the docs-i18n branch updated to match, or a [docs-i18n] <paths> follow-up issue opened (see CONTRIBUTING.md § Translated documentation)
  • Version/release files updated (only if this PR includes a version bump)

UI evidence (if applicable)

Behavioral UI changes were exercised in the local browser. No new visual design or user-facing copy is introduced.

Summary by CodeRabbit

  • New Features
    • Echo Chamber panel size is now stored per chat and restored when returning.
    • Enhanced Spotify “Music DJ” repeat behavior for multi-track vs single-track selections.
  • Bug Fixes
    • CYOA agent outputs now normalize dialogue quotation marks more consistently.
    • Guided regeneration controls now correctly reflect whether input is available.
  • Performance
    • Improved Roleplay text area rendering with paint containment.
  • Tests
    • Expanded regression coverage for Echo Chamber persistence, CYOA normalization, Spotify repeat flows, and Roleplay behavior.

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/Pasta-Devs/Marinara-Engine/pull/4173 **Author:** [@SpicyMarinara](https://github.com/SpicyMarinara) **Created:** 7/27/2026 **Status:** ✅ Merged **Merged:** 7/27/2026 **Merged by:** [@SpicyMarinara](https://github.com/SpicyMarinara) **Base:** `staging` ← **Head:** `agent/chat-polish-echo-spotify-cyoa` --- ### 📝 Commits (4) - [`5096cbb`](https://github.com/Pasta-Devs/Marinara-Engine/commit/5096cbb7e7317a6b1c81c8080e64448ed117a3ee) fix chat persistence, playback repeat, and roleplay input - [`060c3b5`](https://github.com/Pasta-Devs/Marinara-Engine/commit/060c3b539f5cabe8cb40410ad7fa81c72355eaaa) normalize CYOA dialogue quote formats - [`d674d8e`](https://github.com/Pasta-Devs/Marinara-Engine/commit/d674d8e43669c68d1b745c0276024f6124ae6513) address CodeRabbit review feedback - [`9c3c916`](https://github.com/Pasta-Devs/Marinara-Engine/commit/9c3c91625ad793569dcb7b184181553668645b64) verify Spotify repeat state before success ### 📊 Changes **9 files changed** (+515 additions, -29 deletions) <details> <summary>View changed files</summary> 📝 `packages/client/src/components/chat/ChatMessage.tsx` (+1 -2) 📝 `packages/client/src/components/chat/EchoChamberPanel.tsx` (+64 -11) 📝 `packages/client/src/stores/ui.store.ts` (+48 -1) 📝 `packages/client/src/styles/globals.css` (+4 -0) 📝 `packages/server/src/services/agents/agent-executor.ts` (+3 -1) ➕ `packages/server/src/services/agents/cyoa-choice-normalization.ts` (+25 -0) 📝 `packages/server/src/services/tools/tool-executor.ts` (+39 -14) 📝 `scripts/regressions/prompt.regression.ts` (+284 -0) 📝 `scripts/regressions/roleplay-streaming.regression.ts` (+47 -0) </details> ### 📄 Description ## Linked issue Closes #4168 Closes #4170 Closes #4171 Closes #4172 ## Why this change - Echo Chamber dimensions should follow the chat where the user set them. - Spotify Music DJ repeat should loop a complete multi-song selection, not only its final track. - Roleplay typing should paint as promptly as Conversation and Game even over a populated live scene. - CYOA choice dialogue should accept either JSON-escaped double quotes or single-quote delimiters without corrupting apostrophes. ## What changed - Persisted and restored Echo Chamber dimensions per chat, committing only completed resizes. - Started repeatable Spotify track selections as one URI list and applied context repeat while retaining track repeat for a single song. - Isolated Roleplay composer paint and stopped inactive guided actions from subscribing to draft presence. - Normalized only CYOA choice text from single-quote dialogue delimiters to ordinary double quotes; valid escaped JSON quotes continue through unchanged. - Added deterministic regressions for the affected paths, including end-to-end CYOA agent parsing. ## Validation - [ ] `pnpm check` passes locally - [ ] Container (Docker / Podman) built and ran without issue - [ ] Ran the app, clicked through the changes manually - [ ] Checked edge cases (light + dark mode, mobile viewport, empty states, error paths) - [ ] Above manual verification completed (describe below) - [ ] Read and followed `CONTRIBUTING.md` ### Automated and focused verification notes - `pnpm check` - `pnpm regression:prompt` - `pnpm --filter @marinara-engine/server exec tsx ../../scripts/regressions/roleplay-streaming.regression.ts` - Roleplay typographic quote/caret browser regression - Browser-verified that Echo Chamber dimensions remain independent across two chats and survive reload. - Profiled a dense Roleplay transcript against Conversation and Game. - Spotify playback tests use mocked Web API responses; a live Spotify Premium account was not used. ## Docs and release impact - [ ] No docs changes needed - [ ] Updated docs (README / CONTRIBUTING / android/README / CHANGELOG) as needed - [ ] Translated docs on the `docs-i18n` branch updated to match, or a `[docs-i18n] <paths>` follow-up issue opened (see CONTRIBUTING.md § Translated documentation) - [ ] Version/release files updated (only if this PR includes a version bump) ## UI evidence (if applicable) Behavioral UI changes were exercised in the local browser. No new visual design or user-facing copy is introduced. <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **New Features** * Echo Chamber panel size is now stored per chat and restored when returning. * Enhanced Spotify “Music DJ” repeat behavior for multi-track vs single-track selections. * **Bug Fixes** * CYOA agent outputs now normalize dialogue quotation marks more consistently. * Guided regeneration controls now correctly reflect whether input is available. * **Performance** * Improved Roleplay text area rendering with paint containment. * **Tests** * Expanded regression coverage for Echo Chamber persistence, CYOA normalization, Spotify repeat flows, and Roleplay behavior. <!-- end of auto-generated comment: release notes by coderabbit.ai --> --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-10-23 04:08:46 +07:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Pasta-Devs/Marinara-Engine#6268
No description provided.