mirror of
https://github.com/Pasta-Devs/Marinara-Engine.git
synced 2026-12-03 19:00:50 +07:00
[PR #7379] [MERGED] fix(expressions): show the persona only on turns the player wrote #7707
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#7707
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/7379
Author: @SpicyMarinara
Created: 10/9/2026
Status: ✅ Merged
Merged: 10/9/2026
Merged by: @SpicyMarinara
Base:
staging← Head:fix/persona-expression-only-when-present📝 Commits (4)
f189e05fix(expressions): show the persona only on turns the player wrotecdd011afix(expressions): keep the persona for the whole turn the player wrote9635ea1Merge branch 'staging' into fix/persona-expression-only-when-presentffc38a3fix(expressions): offer the persona's sprite when a short-context retry needs it📊 Changes
5 files changed (+128 additions, -7 deletions)
View changed files
📝
CHANGELOG.md(+1 -0)📝
packages/server/src/routes/generate.routes.ts(+9 -0)📝
packages/server/src/routes/generate/expression-agent-utils.ts(+18 -0)📝
packages/server/src/routes/generate/retry-agents-route.ts(+17 -7)📝
scripts/regressions/expression-group-generation.regression.ts(+83 -0)📄 Description
Linked issue
Fixes #7378
Why this change
With Only show active sprites on, the persona's sprite stayed visible after the persona had left the scene. The maintainer's chat shows the cause. From message #1244 onward, the Expression Engine's own result (
spriteExpressions) correctly left Mari out: a Tighnari reply records only{Tighnari: determined}. But every reply'sexpressionSpriteIds, which drives the display, still listed her, even narrator replies with no expression result.The Engine itself added the persona to the required expression targets whenever any user message was still in the recent context:
getLatestUserExpressionSource();recentMessages.some(role === "user").completeRequiredSpriteExpressionEntriesthen filled in an expression from the player's old message on every reply.What changed
generate.routes.ts: the persona is a required expression target only when this request carries the player's message (currentTurnUserMessageId). Impersonation already adds it on its own.retry-agents-route.ts: the persona is required only when the retried reply directly answered a player message.Validation
pnpm checkpasses locallyCONTRIBUTING.mdAutomated evidence (the boxes above are for a human):
pnpm checkpassed locally.expression-group-generationregression: two replies with no new player message, where the Expression Engine leaves the persona out, no longer list the persona. Retrying the Expression Engine on such a reply doesn't add it either. Each assertion fails without its fix: I reverted the generation and retry changes separately to check. The existing "the active persona keeps its existing expression request" case (a turn the player wrote, and impersonation) still passes.manual-agent-retry-resolution,agent-runtime,roleplay-streaming,sprite-backgroundandexpression-tool-retirementpass.Manual verification notes
Docs and release impact
docs-i18nbranch updated to match, or a[docs-i18n]follow-up issue opened (see CONTRIBUTING.md § Translated documentation)One CHANGELOG entry, and no docs changes.
Summary by CodeRabbit
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.