[PR #6282] [MERGED] fix: sweep Roleplay commands, chat setup, mobile zoom and memory processing #7122

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

📋 Pull Request Information

Original PR: https://github.com/Pasta-Devs/Marinara-Engine/pull/6282
Author: @SpicyMarinara
Created: 9/17/2026
Status: ✅ Merged
Merged: 9/17/2026
Merged by: @SpicyMarinara

Base: staging ← Head: fix/6267-6281-issue-sweep


📝 Commits (4)

  • df5531b fix: clarify roleplay interruption guidance
  • ca70e11 fix: improve roleplay commands, mobile zoom, and scene helper limits
  • 38fd9a7 fix: preserve selected chat characters and leading dice positions
  • 6a6d7cb test: clean up the restart fixture tree after failed startup

📊 Changes

21 files changed (+805 additions, -77 deletions)

View changed files

📝 CHANGELOG.md (+8 -0)
📝 e2e/core-flows.e2e.ts (+57 -2)
📝 e2e/issue-sweep-defaults.e2e.ts (+79 -0)
📝 e2e/roleplay-commands.e2e.ts (+95 -21)
📝 packages/client/src/components/chat/ChatMessage.tsx (+74 -18)
📝 packages/client/src/components/chat/ChatSetupWizard.tsx (+6 -2)
📝 packages/client/src/components/chat/RoleplayCommandResults.tsx (+110 -2)
📝 packages/client/src/components/chat/RoleplayDocument.tsx (+10 -2)
📝 packages/client/src/components/layout/AppShell.tsx (+3 -0)
📝 packages/client/src/lib/dice-roll-result.ts (+32 -1)
📝 packages/client/src/styles/roleplay-documents.css (+162 -0)
📝 packages/server/src/routes/connections.routes.ts (+8 -2)
📝 packages/server/src/routes/generate.routes.ts (+25 -2)
📝 packages/server/src/services/advanced-memory.ts (+10 -3)
📝 packages/server/src/services/generation/roleplay-commands.ts (+1 -1)
📝 packages/shared/src/types/roleplay-command.ts (+5 -0)
📝 scripts/regressions/advanced-memory-summary.regression.ts (+12 -0)
📝 scripts/regressions/connection-test-parameters.regression.ts (+34 -0)
📝 scripts/regressions/game-text-dice.regression.ts (+20 -5)
📝 scripts/regressions/restart-supervisor.regression.ts (+14 -16)

...and 1 more files

📄 Description

Roleplay command documents lacked variety, rolls appeared only in command details, mobile pinch zoom was mistaken for a keyboard resize, and Advanced Memory scene decisions could exhaust a hardcoded 1,024-token budget before producing an answer. This sweep gives each document occurrence one of three built-in styles per kind, inserts real dice cards at the saved command position, preserves the unzoomed layout during pinch zoom, and lets scene decisions use the connection's output cap or a 4,096-token default within the context limit.

Closes #6278, closes #6279, closes #6280, closes #6281, closes #6284. Owner: @SpicyMarinara; implementation by Codex.

Starting from a character card now preserves that explicit participant choice when saved wizard defaults are applied, in both Conversation and Roleplay. The revised interruption prompt is included verbatim. Document choices and dice positions are saved with message/swipe extras. Existing dice values, modifiers, animations and reduced-motion behavior are reused. Complete Markdown/HTML is parsed before display-only dice markers are replaced; saved prose and model prompts contain no markers. Edited or legacy replies retain their real rolls at the end if the original position cannot be identified. Translation-only display keeps each visible paragraph's dice after its translated prose.

Related triage:

  • #6268: localhost and 127.0.0.1 model discovery both pass with a keyless local mock provider. A refused connection now exposes its network code and logs the underlying error. The reported Windows/LM Studio cause remains unverified, so this PR does not close it.
  • #6269: the dice test passed three repetitions and the full one-worker WebKit CI shard passed locally (72 passed, 32 existing skips). GitHub reproduced a navigation stall on the initial prompt-only commit. The root cause remains open; no forced clicks, sleeps, quarantines or browser timeout increases were added. A later CI run hit a WebKit internal error on an unrelated wizard reload; the original dice shard passed.
  • #6267: all ten documentation packs are being updated separately against docs-i18n in #6283.

Validation:

  • pnpm check passed on the final code. The added card-selection/defaults and isolated language browser cases passed on all three browser targets (21 cases).
  • Prompt regressions, Advanced Memory regressions, Roleplay command/position regressions, keyless connection discovery and refused-connection diagnostics passed.
  • Multiple real Roleplay rolls passed on both subscription transports, including placement and modifiers.
  • All 36 Roleplay browser cases passed across desktop Chromium, mobile Chromium and mobile WebKit. All 21 document treatments were exercised in both themes, with safe text, editing and reload checks.
  • Four additional desktop/WebKit cases passed after the renderer review fix, covering dice inside Markdown bold and HTML, ordering, reload and translation-only display.
  • Mobile viewport regression failed before the pinch-zoom guard and passed afterwards, including the existing keyboard checks.
  • The language test now stubs its unrelated agent-catalog request after CI captured an upstream HTTP 500. The native restart integration test gives cold initial compilation 20 seconds, retains the 10-second restart deadline, and records both timings; local real restart proof passed. The next full native jobs passed on Windows (7.4-second initial startup, 4.8-second restart) and Intel macOS (5.7-second initial startup, 3.1-second restart). A separate cold Windows launcher job exposed incomplete failure cleanup; the fixture now terminates its entire owned process tree and captures startup diagnostics, with its local restart proof passing.
  • Leading dice positions use following text as their edit anchor; unique, missing, ambiguous and empty anchors have regression coverage.
  • Local container builder image completed. Final-head native desktop, Windows launcher, Android, full/Lite containers on both architectures, complete Node regressions and all browser shards passed. Linux WebKit shard 3 passed on rerun after the retained failure documented in #6269; that unresolved intermittent report remains open. GitHub CodeRabbit reviewed the final head and reported no actionable findings.
  • Local CodeRabbit completed the main sweep after the translation-only and formatting fixes. Follow-up local review covered all nine changed files for the card issue, leading-anchor correction and CI fixtures and completed with zero findings. Its remaining suggestion was to extract helpers for two one-line token budgets and their identical error checks; those local expressions remain inline to avoid extra indirection. The earlier single-caller offset-helper suggestion was also declined for the same minimalism reason.

Desktop and mobile browser screenshots.

Manual verification:

  • Verify pinch zoom on a physical iPhone with Roleplay images and normal keyboard opening.
  • Verify an affected DeepSeek v4 Flash or GLM 5.3 helper connection against its real provider.
  • Review the document treatments and dice animation in the browser, including reduced motion.

🔄 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/6282 **Author:** [@SpicyMarinara](https://github.com/SpicyMarinara) **Created:** 9/17/2026 **Status:** ✅ Merged **Merged:** 9/17/2026 **Merged by:** [@SpicyMarinara](https://github.com/SpicyMarinara) **Base:** `staging` ← **Head:** `fix/6267-6281-issue-sweep` --- ### 📝 Commits (4) - [`df5531b`](https://github.com/Pasta-Devs/Marinara-Engine/commit/df5531b67d8e91b32af44c3550d9a8d710e0e641) fix: clarify roleplay interruption guidance - [`ca70e11`](https://github.com/Pasta-Devs/Marinara-Engine/commit/ca70e11455d856698f05c3f4a7f358ab234abb73) fix: improve roleplay commands, mobile zoom, and scene helper limits - [`38fd9a7`](https://github.com/Pasta-Devs/Marinara-Engine/commit/38fd9a77898f1b9f17a8a848e29d8d76ad0ad2a3) fix: preserve selected chat characters and leading dice positions - [`6a6d7cb`](https://github.com/Pasta-Devs/Marinara-Engine/commit/6a6d7cb82723682741ba37c52dedab869d902edb) test: clean up the restart fixture tree after failed startup ### 📊 Changes **21 files changed** (+805 additions, -77 deletions) <details> <summary>View changed files</summary> 📝 `CHANGELOG.md` (+8 -0) 📝 `e2e/core-flows.e2e.ts` (+57 -2) 📝 `e2e/issue-sweep-defaults.e2e.ts` (+79 -0) 📝 `e2e/roleplay-commands.e2e.ts` (+95 -21) 📝 `packages/client/src/components/chat/ChatMessage.tsx` (+74 -18) 📝 `packages/client/src/components/chat/ChatSetupWizard.tsx` (+6 -2) 📝 `packages/client/src/components/chat/RoleplayCommandResults.tsx` (+110 -2) 📝 `packages/client/src/components/chat/RoleplayDocument.tsx` (+10 -2) 📝 `packages/client/src/components/layout/AppShell.tsx` (+3 -0) 📝 `packages/client/src/lib/dice-roll-result.ts` (+32 -1) 📝 `packages/client/src/styles/roleplay-documents.css` (+162 -0) 📝 `packages/server/src/routes/connections.routes.ts` (+8 -2) 📝 `packages/server/src/routes/generate.routes.ts` (+25 -2) 📝 `packages/server/src/services/advanced-memory.ts` (+10 -3) 📝 `packages/server/src/services/generation/roleplay-commands.ts` (+1 -1) 📝 `packages/shared/src/types/roleplay-command.ts` (+5 -0) 📝 `scripts/regressions/advanced-memory-summary.regression.ts` (+12 -0) 📝 `scripts/regressions/connection-test-parameters.regression.ts` (+34 -0) 📝 `scripts/regressions/game-text-dice.regression.ts` (+20 -5) 📝 `scripts/regressions/restart-supervisor.regression.ts` (+14 -16) _...and 1 more files_ </details> ### 📄 Description Roleplay command documents lacked variety, rolls appeared only in command details, mobile pinch zoom was mistaken for a keyboard resize, and Advanced Memory scene decisions could exhaust a hardcoded 1,024-token budget before producing an answer. This sweep gives each document occurrence one of three built-in styles per kind, inserts real dice cards at the saved command position, preserves the unzoomed layout during pinch zoom, and lets scene decisions use the connection's output cap or a 4,096-token default within the context limit. Closes #6278, closes #6279, closes #6280, closes #6281, closes #6284. Owner: @SpicyMarinara; implementation by Codex. Starting from a character card now preserves that explicit participant choice when saved wizard defaults are applied, in both Conversation and Roleplay. The revised interruption prompt is included verbatim. Document choices and dice positions are saved with message/swipe extras. Existing dice values, modifiers, animations and reduced-motion behavior are reused. Complete Markdown/HTML is parsed before display-only dice markers are replaced; saved prose and model prompts contain no markers. Edited or legacy replies retain their real rolls at the end if the original position cannot be identified. Translation-only display keeps each visible paragraph's dice after its translated prose. Related triage: - #6268: localhost and 127.0.0.1 model discovery both pass with a keyless local mock provider. A refused connection now exposes its network code and logs the underlying error. The reported Windows/LM Studio cause remains unverified, so this PR does not close it. - #6269: the dice test passed three repetitions and the full one-worker WebKit CI shard passed locally (72 passed, 32 existing skips). GitHub reproduced a navigation stall on the initial prompt-only commit. The root cause remains open; no forced clicks, sleeps, quarantines or browser timeout increases were added. A later CI run hit a WebKit internal error on an unrelated wizard reload; the original dice shard passed. - #6267: all ten documentation packs are being updated separately against `docs-i18n` in #6283. Validation: - `pnpm check` passed on the final code. The added card-selection/defaults and isolated language browser cases passed on all three browser targets (21 cases). - Prompt regressions, Advanced Memory regressions, Roleplay command/position regressions, keyless connection discovery and refused-connection diagnostics passed. - Multiple real Roleplay rolls passed on both subscription transports, including placement and modifiers. - All 36 Roleplay browser cases passed across desktop Chromium, mobile Chromium and mobile WebKit. All 21 document treatments were exercised in both themes, with safe text, editing and reload checks. - Four additional desktop/WebKit cases passed after the renderer review fix, covering dice inside Markdown bold and HTML, ordering, reload and translation-only display. - Mobile viewport regression failed before the pinch-zoom guard and passed afterwards, including the existing keyboard checks. - The language test now stubs its unrelated agent-catalog request after CI captured an upstream HTTP 500. The native restart integration test gives cold initial compilation 20 seconds, retains the 10-second restart deadline, and records both timings; local real restart proof passed. The next full native jobs passed on Windows (7.4-second initial startup, 4.8-second restart) and Intel macOS (5.7-second initial startup, 3.1-second restart). A separate cold Windows launcher job exposed incomplete failure cleanup; the fixture now terminates its entire owned process tree and captures startup diagnostics, with its local restart proof passing. - Leading dice positions use following text as their edit anchor; unique, missing, ambiguous and empty anchors have regression coverage. - Local container builder image completed. Final-head native desktop, Windows launcher, Android, full/Lite containers on both architectures, complete Node regressions and all browser shards passed. Linux WebKit shard 3 passed on rerun after the retained failure documented in #6269; that unresolved intermittent report remains open. GitHub CodeRabbit reviewed the final head and reported no actionable findings. - Local CodeRabbit completed the main sweep after the translation-only and formatting fixes. Follow-up local review covered all nine changed files for the card issue, leading-anchor correction and CI fixtures and completed with zero findings. Its remaining suggestion was to extract helpers for two one-line token budgets and their identical error checks; those local expressions remain inline to avoid extra indirection. The earlier single-caller offset-helper suggestion was also declined for the same minimalism reason. [Desktop and mobile browser screenshots](https://gist.github.com/SpicyMarinara/808c6aa10a4c64fd2cb88af77ee90406). Manual verification: - [ ] Verify pinch zoom on a physical iPhone with Roleplay images and normal keyboard opening. - [ ] Verify an affected DeepSeek v4 Flash or GLM 5.3 helper connection against its real provider. - [ ] Review the document treatments and dice animation in the browser, including reduced motion. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-10-23 04:16:44 +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#7122
No description provided.