[GH-ISSUE #7286] [Issue]: Manual Tracker Panel edits are ignored when the edited reply is regenerated or swiped #4062

Closed
opened 2026-10-21 06:09:58 +07:00 by bsakaguchi · 2 comments
Owner

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

Originally assigned to: @SpicyMarinara on GitHub.

Summary

A manual edit made in the Tracker Panel is ignored when the same reply is regenerated or swiped. The regeneration starts from the previous reply's tracker state instead, which is the wrong value the user just corrected.

Reported by Mari (maintainer), 2026-10-08:

I was doing some swipes in roleplay mode and noticed that I had some bad tracker generation in world state for location. So I edited it manually and regenerated a message. However, my manual edit was NOT used for the regeneration; instead the old generation for the previous message was used — precisely the one I wanted to correct since it was wrong. I did the edit in Tracker Panel. As soon as the user MANUALLY edits any field in Tracker Panel/trackers, that value should replace the committed one and be used as a base for the next generation. Obviously the new generation should then replace it if it changes it.

Expected behavior

The maintainer's rule:

  • A manual edit of any tracker field in the Tracker Panel (World State and every other tracker shown there) replaces the committed value. It becomes the base for the next generation. That includes regenerating or swiping the same message the edit was made on, and the next new message.
  • The new generation may change that field. If it does, its result replaces the edit.
  • Edits survive reloads.
  • Swipes of other messages, branch switches and deleted messages do not bring back stale values or leak an edit into an unrelated branch.

Actual behavior

  • Regenerate or swipe the edited reply: the main prompt, the lorebook scan and every tracker agent's current state come from the previous reply's committed row. The edit is ignored. A real World State agent then writes the old location again.
  • Fields an agent leaves out on a regen are copied from the swipe just before the new one, not from the edited swipe.
  • Manual-tracker chats: a regen leaves no row for the new swipe. The panel and the next message fall back to the previous reply's row, so the edit disappears.
  • A new message sent from the edited swipe already uses the edit. So does Re-run trackers on the edited swipe.

Steps to reproduce

  1. In a Roleplay chat with World State enabled, send a message so the reply gets a tracker snapshot.
  2. In the Tracker Panel, change the reply's location (for example to "Right place").
  3. Regenerate or swipe that reply.
  4. Open Peek Prompt or the agent debug log. The world state still shows the previous reply's location, and the new swipe's tracker is built from it.

Environment

  • Marinara Engine version: 2.5.0 (staging 30c2e5beb)
  • Install type: source
  • OS + version: macOS
  • Browser or app shell: any

Logs, screenshots, or video

Reproduced through the real chat and generate routes, with a fake provider capturing the prompts.

  • After the edit, the regen's main prompt showed Location: Old town (the previous reply's value), not the edited Right place.
  • The tracker agents' current-state JSON was the previous reply's row.

Additional context

Root cause. A regeneration builds its base from the reply before the regenerated one: resolveRegenerationGameStateAnchor plus excludeMessageId in getForGeneration. The Tracker Panel PATCH writes the edit only onto the edited reply's own (message, swipe) row, which is exactly the row the regeneration base excludes. Nothing copies the edit into that base.

Ownership. Engine host code: game-state snapshots and the regeneration base. Not Marinara-Agents. The Relationship Tracker keeps its own state and is not on this path.

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 @SpicyMarinara on GitHub (Oct 7, 2026). Original GitHub issue: https://github.com/Pasta-Devs/Marinara-Engine/issues/7286 Originally assigned to: @SpicyMarinara on GitHub. ## Summary A manual edit made in the Tracker Panel is ignored when the same reply is regenerated or swiped. The regeneration starts from the previous reply's tracker state instead, which is the wrong value the user just corrected. Reported by Mari (maintainer), 2026-10-08: > I was doing some swipes in roleplay mode and noticed that I had some bad tracker generation in world state for location. So I edited it manually and regenerated a message. However, my manual edit was NOT used for the regeneration; instead the old generation for the previous message was used — precisely the one I wanted to correct since it was wrong. I did the edit in Tracker Panel. As soon as the user MANUALLY edits any field in Tracker Panel/trackers, that value should replace the committed one and be used as a base for the next generation. Obviously the new generation should then replace it if it changes it. ## Expected behavior The maintainer's rule: - A manual edit of any tracker field in the Tracker Panel (World State and every other tracker shown there) replaces the committed value. It becomes the base for the **next** generation. That includes regenerating or swiping the same message the edit was made on, and the next new message. - The new generation may change that field. If it does, its result replaces the edit. - Edits survive reloads. - Swipes of other messages, branch switches and deleted messages do not bring back stale values or leak an edit into an unrelated branch. ## Actual behavior - **Regenerate or swipe the edited reply:** the main prompt, the lorebook scan and every tracker agent's current state come from the previous reply's committed row. The edit is ignored. A real World State agent then writes the old location again. - **Fields an agent leaves out on a regen** are copied from the swipe just before the new one, not from the edited swipe. - **Manual-tracker chats:** a regen leaves no row for the new swipe. The panel and the next message fall back to the previous reply's row, so the edit disappears. - **A new message sent from the edited swipe** already uses the edit. So does Re-run trackers on the edited swipe. ## Steps to reproduce 1. In a Roleplay chat with World State enabled, send a message so the reply gets a tracker snapshot. 2. In the Tracker Panel, change the reply's location (for example to "Right place"). 3. Regenerate or swipe that reply. 4. Open Peek Prompt or the agent debug log. The world state still shows the previous reply's location, and the new swipe's tracker is built from it. ## Environment - Marinara Engine version: 2.5.0 (staging 30c2e5beb) - Install type: source - OS + version: macOS - Browser or app shell: any ## Logs, screenshots, or video Reproduced through the real chat and generate routes, with a fake provider capturing the prompts. - After the edit, the regen's main prompt showed `Location: Old town` (the previous reply's value), not the edited `Right place`. - The tracker agents' current-state JSON was the previous reply's row. ## Additional context **Root cause.** A regeneration builds its base from the reply before the regenerated one: `resolveRegenerationGameStateAnchor` plus `excludeMessageId` in `getForGeneration`. The Tracker Panel PATCH writes the edit only onto the edited reply's own (message, swipe) row, which is exactly the row the regeneration base excludes. Nothing copies the edit into that base. **Ownership.** Engine host code: game-state snapshots and the regeneration base. Not Marinara-Agents. The Relationship Tracker keeps its own state and is not on this path. ## 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-10-21 06:09:58 +07:00
  • closed this issue
  • added the
    in-pr
    bug
    labels
Author
Owner

@SpicyMarinara commented on GitHub (Oct 7, 2026):

Claude Code (working for @SpicyMarinara) is taking this one on branch fix/tracker-manual-edit-base. A PR to staging will follow.

<!-- gh-comment-id:6049104128 --> @SpicyMarinara commented on GitHub (Oct 7, 2026): Claude Code (working for @SpicyMarinara) is taking this one on branch `fix/tracker-manual-edit-base`. A PR to `staging` will follow.
Author
Owner

@SpicyMarinara commented on GitHub (Oct 8, 2026):

Fixed on staging by #7288. Ships to main with the next promotion.

<!-- gh-comment-id:6050406833 --> @SpicyMarinara commented on GitHub (Oct 8, 2026): Fixed on `staging` by #7288. Ships to `main` with the next promotion.
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#4062
No description provided.