mirror of
https://github.com/Pasta-Devs/Marinara-Engine.git
synced 2026-12-03 19:00:50 +07:00
[PR #7601] [MERGED] fix(memory): default the summary and recall budget to 10% of the context #7828
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#7828
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/7601
Author: @SpicyMarinara
Created: 10/14/2026
Status: ✅ Merged
Merged: 10/14/2026
Merged by: @SpicyMarinara
Base:
staging← Head:fix/memory-budget-default-10pct📝 Commits (2)
76ebb3dfix(memory): default the summary and recall budget to 10% of the context1a1366fMerge branch 'staging' into fix/memory-budget-default-10pct📊 Changes
3 files changed (+33 additions, -4 deletions)
View changed files
📝
packages/shared/src/types/advanced-memory.ts(+10 -3)📝
scripts/regressions/advanced-memory-post-generation.regression.ts(+7 -1)📝
scripts/regressions/advanced-memory-recall.regression.ts(+16 -0)📄 Description
Linked issue
No linked issue: decided by the maintainer on 2026-10-14.
Why this change
What changed
packages/shared/src/types/advanced-memory.ts:DEFAULT_ADVANCED_MEMORY_SETTINGSnow sets the budget to 10% of the default context limit, rounded to whole tokens (6,500).normalizeAdvancedMemorySettingsuses these defaults when a chat has no saved Advanced Memory settings.updateSettingssaves the whole settings object, so any chat that has saved settings already stores a budget.advanced-memory-recallnow checks that a new chat saves 6,500. It also checks that a chat saved with 4,096, and a chat saved without a budget, both still store 4,096 after an unrelated settings change.advanced-memory-post-generation: two fixtures spread the defaults and had summaries sized to go over 70% of the old 4,096 default. They now setsummaryBudgetTokens: 4096explicitly. Their assertions are unchanged.Validation
pnpm checkpasses locallyCONTRIBUTING.mdCommands run by the agent:
node ./scripts/run-regressions.mjs --filter scripts/regressions/advanced-memory-recall.regression.ts:node ./scripts/run-regressions.mjs --filter advanced-memory: 16/16 passed.memory-recall-exclusivity,roleplay-regeneration-context,roleplay-interrupt-generation,roleplay-whisper-hidden-recipient,context-message-limit-modesregressions: all passed.pnpm localization:check: passed.pnpm check: passed. One existing lint warning in a client file this PR doesn't touch.coderabbit review --agent --committed): one trivial finding, no change needed. It asked to confirm that the UI doesn't show 10% for settings saved without a budget. It doesn't: the panel reads the samenormalizeAdvancedMemorySettingsresult as the server and shows the saved 4,096.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)docs/agents/memory.mddoesn't mention the budget's default, so this PR changes no docs and needs no translation follow-up. A sentence about the new default could go into the budget bullet after #7595 merges, since #7595 edits that line.UI evidence (if applicable)
None. No UI code changed; the budget field only shows a different starting value.
Summary by CodeRabbit
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.