mirror of
https://github.com/Pasta-Devs/Marinara-Engine.git
synced 2026-12-03 19:00:50 +07:00
[GH-ISSUE #5813] [Issue]: Replace character card {{original}} macros with an empty string #3206
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#3206
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?
Originally created by @SpicyMarinara on GitHub (Sep 3, 2026).
Original GitHub issue: https://github.com/Pasta-Devs/Marinara-Engine/issues/5813
Originally assigned to: @SpicyMarinara on GitHub.
Summary
Support SillyTavern-compatible character cards by removing
{{original}}from card-defined system prompts and post-history instructions. Marinara Engine already injects these fields through{{charSysInfo}}and{{charPostHistory}}, so preserving the macro can cause incorrect instruction composition.Expected behavior
When processing a character card's
system_promptorpost_history_instructions, Marinara Engine should replace every{{original}}macro with an empty string while preserving the rest of the character-defined text.Actual behavior
Marinara Engine does not automatically remove
{{original}}from these character card fields. Users must manually edit it out of each affected character, which is impractical for large character libraries.Steps to reproduce
{{original}}.{{charSysInfo}}or{{charPostHistory}}.{{original}}is not automatically replaced with an empty string and must be removed manually.Environment
fbde0b5ad8)Logs, screenshots, or video
No error logs provided. One screenshot was attached in Discord: https://cdn.discordapp.com/attachments/1544749756629127168/1544835727085281363/image.png?ex=6a99f3e2&is=6a98a262&hm=4b2721fa1a33d0ee0f60b4228a65d5810ac72c802a0baf860a34e2f82f39fac8&
Additional context
In SillyTavern,
{{original}}preserves the user's existing System Prompt or Post-History Instruction when a card adds its own instructions; omitting it allows the card field to override the existing instruction. Marinara Engine instead uses preset-owned instructions and injects card fields with{{charSysInfo}}and{{charPostHistory}}, so SillyTavern's replacement behavior may duplicate or incorrectly merge instructions. Character Card v2 specification: https://github.com/malfoyslastname/character-card-spec-v2/blob/main/spec_v2.md. Maintainers should determine whether replacement belongs in card import or generation-time macro processing.Discord thread: [FR]: Support for ST's {{original}} macro to be replaced with empty string
Discord thread link: https://discord.com/channels/1417099416812392641/1544749756629127168
Requested by: gunterlie (part of the problem) (gunterlie, Discord ID 282074442962829312)
Discord thread transcript (11 messages)
Template check
Please uncheck (untick) the box below before submitting so we know you read the template. It is intentionally pre-checked:
@SpicyMarinara commented on GitHub (Sep 5, 2026):
Owner: @SpicyMarinara, implementation by Codex in Issue Sweep PR #5865. I have read the issue and all current comments. Work will target staging, reuse existing code, and include focused regression proof; unrelated open/draft PRs remain untouched.
@SpicyMarinara commented on GitHub (Sep 5, 2026):
Completed on staging in #5865 (merge
314a71a586).Resolved character-card original macros to an empty string, preserving saved card content and literal replacement-pattern text.
Focused regression proof and manual verification boundaries are documented in the PR. Required checks and the full final regression matrix passed; CodeRabbit completed review with all threads resolved. Closing as completed on staging, not a main release.