mirror of
https://github.com/Pasta-Devs/Marinara-Engine.git
synced 2026-12-03 19:00:50 +07:00
[GH-ISSUE #8832] [Feature]: Layered summarization for long Roleplay context #8515
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#8515
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 @qvazzar on GitHub (Nov 4, 2026).
Original GitHub issue: https://github.com/Pasta-Devs/Marinara-Engine/issues/8832
Originally assigned to: @SpicyMarinara on GitHub.
What problem does this solve?
Long Roleplay chats eventually exceed the model's useful context window. Users currently have three imperfect choices:
Marinara already has Chat Summary, automatic summaries, hidden-from-AI messages, summary connections, prompt markers, and Advanced Memory. However, the Roleplay Chat Summary path has no concept of a bounded, layered memory: old summaries remain a flat list, and there is no automatic promotion of older material into progressively denser summaries. This makes it difficult to keep a long chat both coherent and small in the prompt.
The goal is a layered summarization mode for Roleplay that keeps recent turns verbatim, compresses older turns into short snippets, and recursively compresses old snippets into deeper layers. It should use Marinara's own storage and prompt pipeline rather than introducing a second parallel memory system.
Proposed solution
Add an optional Layered engine mode to the existing Roleplay Chat Summary:
Core behavior
Data model
Reuse the existing
ChatSummaryEntrystorage shape where possible rather than adding a second list of memory records. Layered entries need enough metadata to identify:ChatMetadataneeds per-chat settings and a small checkpoint so an interrupted run can resume.Settings
Per chat, at minimum:
Global settings and templates:
Reuse the existing Summary Connection and Maximum output size controls.
Automatic behavior and recovery
UI
Scope and interactions
Recent message tailmust behave as a strict limit for covered messages, or clearly report unsummarized backlog.Out of scope
Alternatives considered
Additional context
against
staging. I can start once the scope is agreed. I haveread
CONTRIBUTING.mdand will follow the repository's validation and reviewprocess.
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 (Nov 4, 2026):
Already covered by Advanced Memory Recall.