mirror of
https://github.com/Pasta-Devs/Marinara-Engine.git
synced 2026-12-03 19:00:50 +07:00
[PR #7715] [MERGED] fix(expressions): give each Individual group reply its own expression #7892
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#7892
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/7715
Author: @SpicyMarinara
Created: 10/16/2026
Status: ✅ Merged
Merged: 10/16/2026
Merged by: @SpicyMarinara
Base:
staging← Head:fix/7712-individual-expressions📝 Commits (3)
cd4e181fix(expressions): give each Individual group reply its own expression076f044fix(expressions): keep saving the other replies if one write fails1826699fix(expressions): don't read an earlier Individual reply as a whole turn📊 Changes
4 files changed (+42 additions, -0 deletions)
View changed files
📝
packages/client/src/lib/sprite-expression-state.ts(+2 -0)📝
packages/server/src/routes/generate.routes.ts(+22 -0)📝
packages/shared/src/types/chat.ts(+2 -0)📝
scripts/regressions/expression-group-generation.regression.ts(+16 -0)📄 Description
Linked issue
Closes #7712
Why this change
In a Roleplay group chat set to Individual, each character replies as her own message. The Expression Engine then runs once for the whole turn and saved every character's expression on the last reply only. The earlier replies had no expression of their own: their expression avatars stayed blank, and deleting or retrying the last reply took the whole turn's expressions with it.
The Expression Engine already reads the turn as one labelled section per speaker and returns one pick per character. The fix saves those picks on the right replies. It makes no extra model calls.
What changed
generate.routes.ts: the Individual loop records each responder's reply (message and swipe). When the Expression Engine result is saved, each earlier reply also gets its own character's expression. Only that one entry is written, and no sprite list (expressionSpriteIds).expression-group-generation.regression.ts: runs a real Individual turn (Alice, then Bob) against a fixture provider. It checks that there is exactly one Expression Engine request, that Alice's reply has{ alice: happy }and no sprite list, and that Bob's last reply still has both characters and the full sprite list.Validation
pnpm checkpasses locallyCONTRIBUTING.mdAutomated evidence (agent-run):
scripts/regressions/expression-group-generation.regression.tspasses with the fix. With the server change reverted it fails withan earlier reply has its own expression(actualundefined, expected{ <alice>: 'happy' }).tsc --noEmit -p packages/server) and Prettier on the changed files pass. Other results are added below as they finish.Manual verification notes
spriteExpressionswith its own character, and the last reply also has the others.Docs and release impact
docs-i18nbranch updated to match, or a[docs-i18n]follow-up issue opened (see CONTRIBUTING.md § Translated documentation)No docs, UI copy or version files change.
UI evidence (if applicable)
Server-side data fix; no UI change.
🤖 Generated with Claude Code
Summary by CodeRabbit
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.