[GH-ISSUE #8006] [Issue]: Scenes ignore the starred Roleplay profile, fail on loose JSON, and write the opening in the wrong voice #7513

Closed
opened 2026-10-24 04:03:45 +07:00 by bsakaguchi · 0 comments
Owner

Originally created by @JamesMowery on GitHub (Oct 21, 2026).
Original GitHub issue: https://github.com/Pasta-Devs/Marinara-Engine/issues/8006

Originally assigned to: @SpicyMarinara on GitHub.

Summary

Scenes started from a Conversation chat (/scene, or a character's Set up scene) have three problems. They ignore the starred Roleplay settings profile. Plan Scene fails on slightly broken JSON. And the opening message can be written in the wrong voice.

Expected behavior

  • The new scene starts from the starred Roleplay settings profile, as any new Roleplay chat does, and its opening is planned with that profile's writing rules (the same prompt preset the scene chat then uses).
  • Slightly broken JSON from the planner is repaired, as it is for agents, memory and summaries.
  • The opening is written in the opening character's voice, or by one narrating voice in a merged group scene. Spoken words are quoted, and the scene description is its own narrator message.

Actual behavior

  • A scene is a new Roleplay chat, but it was built only from the scene plan, so the starred profile was never applied. The opening was planned with a different prompt preset than the scene chat then used, so its POV, tense or dialogue rules could differ from every reply after it.
  • Plan Scene fails with "Model didn't return valid JSON" whenever the model slips on JSON: an unquoted key, single quotes, a trailing comma, or dialogue quotes inside a value ("firstMessage": "So. You came back.", The librarian smiles. "Again?").
  • The opening is credited to the scene's initiator, but the planner was never told who that is. In a group it could write as someone else: one character's first-person narration posted as another. The scene description was glued onto the front of the opening, so the character seemed to describe themselves in the third person, and spoken words weren't set apart from thoughts.

Steps to reproduce

  1. Star a Roleplay settings profile with its own prompt preset (for example one that writes dialogue in double quotes).
  2. In a Conversation chat with two characters, type /scene, leave Prompt preset on None, and click Plan Scene.
  3. The new scene has none of the profile's settings, and the opening can be written by the wrong character, with the description at its start.
  4. With a model that writes loose JSON, Plan Scene fails with "Model didn't return valid JSON".

Environment

  • Marinara Engine version: 2.5.1 (staging)
  • Install type: source
  • OS + version: Linux (Debian 13)
  • Browser or app shell: desktop browser

Logs, screenshots, or video

The planner error is "Model didn't return valid JSON".

Additional context

All three are fixed together in one PR, since they change the same Scene planning code and test. @SpicyMarinara for visibility.

Template check

Please uncheck (untick) the box below before submitting so we know you read the template. It is intentionally pre-checked:

  • I DID NOT read this template and provide the requested details.
Originally created by @JamesMowery on GitHub (Oct 21, 2026). Original GitHub issue: https://github.com/Pasta-Devs/Marinara-Engine/issues/8006 Originally assigned to: @SpicyMarinara on GitHub. ## Summary Scenes started from a Conversation chat (`/scene`, or a character's **Set up scene**) have three problems. They ignore the starred Roleplay settings profile. **Plan Scene** fails on slightly broken JSON. And the opening message can be written in the wrong voice. ## Expected behavior - The new scene starts from the starred Roleplay settings profile, as any new Roleplay chat does, and its opening is planned with that profile's writing rules (the same prompt preset the scene chat then uses). - Slightly broken JSON from the planner is repaired, as it is for agents, memory and summaries. - The opening is written in the opening character's voice, or by one narrating voice in a merged group scene. Spoken words are quoted, and the scene description is its own narrator message. ## Actual behavior - A scene is a new Roleplay chat, but it was built only from the scene plan, so the starred profile was never applied. The opening was planned with a different prompt preset than the scene chat then used, so its POV, tense or dialogue rules could differ from every reply after it. - **Plan Scene** fails with "Model didn't return valid JSON" whenever the model slips on JSON: an unquoted key, single quotes, a trailing comma, or dialogue quotes inside a value (`"firstMessage": "So. You came back.", The librarian smiles. "Again?"`). - The opening is credited to the scene's initiator, but the planner was never told who that is. In a group it could write as someone else: one character's first-person narration posted as another. The scene description was glued onto the front of the opening, so the character seemed to describe themselves in the third person, and spoken words weren't set apart from thoughts. ## Steps to reproduce 1. Star a Roleplay settings profile with its own prompt preset (for example one that writes dialogue in double quotes). 2. In a Conversation chat with two characters, type `/scene`, leave **Prompt preset** on **None**, and click **Plan Scene**. 3. The new scene has none of the profile's settings, and the opening can be written by the wrong character, with the description at its start. 4. With a model that writes loose JSON, **Plan Scene** fails with "Model didn't return valid JSON". ## Environment - Marinara Engine version: 2.5.1 (`staging`) - Install type: source - OS + version: Linux (Debian 13) - Browser or app shell: desktop browser ## Logs, screenshots, or video The planner error is "Model didn't return valid JSON". ## Additional context All three are fixed together in one PR, since they change the same Scene planning code and test. @SpicyMarinara for visibility. ## Template check Please **uncheck (untick)** the box below before submitting so we know you read the template. It is intentionally pre-checked: - [ ] I DID NOT read this template and provide the requested details.
bsakaguchi 2026-11-07 16:42:08 +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#7513
No description provided.