mirror of
https://github.com/Pasta-Devs/Marinara-Engine.git
synced 2026-12-03 19:00:50 +07:00
[PR #2731] [MERGED] [codex] Normalize post-history system prompt roles #5717
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#5717
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/2731
Author: @SpicyMarinara
Created: 6/21/2026
Status: ✅ Merged
Merged: 6/21/2026
Merged by: @SpicyMarinara
Base:
staging← Head:codex/prompt-post-history-role-normalization📝 Commits (2)
e1ca5abNormalize post-history system prompt roles324111fPreserve prompt metadata when appending system content📊 Changes
4 files changed (+101 additions, -24 deletions)
View changed files
📝
packages/server/src/routes/chats.routes.ts(+10 -2)📝
packages/server/src/routes/generate.routes.ts(+3 -11)📝
packages/server/src/routes/generate/dry-run-route.ts(+3 -11)📝
packages/server/src/routes/generate/generate-route-utils.ts(+85 -0)📄 Description
Linked issue
No linked issue. Maintainer-requested fix from a prompt preview / preset assembly bug report; open a tracking issue if public discussion is needed.
Why this change
Roleplay prompt presets can include system-role sections after the chat history marker. Those sections should not be hoisted or sent as mid-conversation system messages; they need to preserve provider-safe system/user/assistant alternation.
What changed
Validation
pnpm checkpasses locallyCONTRIBUTING.mdManual verification notes
Commands run locally:
pnpm --filter @marinara-engine/server lintpnpm --filter @marinara-engine/server buildpnpm checkgit diff --checkpnpm checkcompleted successfully. Local environment still prints the existing Node/Vite version warnings.Docs and release impact
UI evidence (if applicable)
Server-side prompt assembly fix; no screenshot attached.
Summary by CodeRabbit
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.