mirror of
https://github.com/Pasta-Devs/Marinara-Engine.git
synced 2026-12-03 19:00:50 +07:00
[PR #3876] [MERGED] fix: preserve Persona names in Name Prefix History #6139
Labels
No labels
android
bug
bugfix
ci
client
code freeze pause
container
dependencies
docs
documentation
duplicate
enhancement
feature
feature
feature
feature-creep
fixed-in-refactor
fixed-in-staging
good first issue
help wanted
in-pr
in-pr
needs-codeowner-decision
normal-scope
old-codebase
old-codebase
pull-request
qol
question
refactor
regression
revisit later
roadmap
scope-risk
scope-risk
server
server
shared
soup
upstream
windows
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Pasta-Devs/Marinara-Engine#6139
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/Pasta-Devs/Marinara-Engine/pull/3876
Author: @SpicyMarinara
Created: 7/20/2026
Status: ✅ Merged
Merged: 7/20/2026
Merged by: @SpicyMarinara
Base:
staging← Head:fix/name-prefix-history-persona-snapshots📝 Commits (1)
fdd831dfix: preserve Persona names in prefixed history📊 Changes
6 files changed (+55 additions, -1 deletions)
View changed files
📝
CHANGELOG.md(+1 -0)📝
packages/server/src/routes/generate.routes.ts(+3 -0)📝
packages/server/src/routes/generate/dry-run-route.ts(+4 -0)📝
packages/server/src/routes/generate/generate-route-utils.ts(+9 -1)📝
packages/server/src/services/generation/prompt-message-scope.ts(+1 -0)📝
scripts/regressions/prompt.regression.ts(+37 -0)📄 Description
Linked issue
No GitHub issue has been filed yet. This draft tracks a regression reported directly by the maintainer; an issue should be opened and linked before the PR is marked ready.
Why this change
When Name Prefix History is enabled, switching Personas relabels every historical user turn with the currently selected Persona. Messages originally sent as Powers That Be therefore reach the model as if Mari had sent them.
What changed
Root cause
The history prefixer accepted one generation-wide
personaNameand applied it to every user message. Although messages already persisted their send-timepersonaSnapshot, prompt mapping discarded that name before Name Prefix History ran.Validation
Automated commands run successfully:
pnpm regression:promptpnpm checkpnpm version:checkgit diff --checkpnpm checkpasses locallyContainer (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.mdManual verification notes
Docs and release impact
UI evidence (if applicable)
No UI changes.
Summary by CodeRabbit
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.