mirror of
https://github.com/Pasta-Devs/Marinara-Agents.git
synced 2026-12-03 18:55:07 +07:00
[GH-ISSUE #1974] [Issue]: Long-Term Memory whole-number settings fail to save when a decimal is typed #1850
Labels
No labels
agent: chess
agent: conversation-calls
agent: eightball
agent: haptic
agent: hierarchical-maps
agent: hierarchical-maps
agent: illustrator
agent: poker
agent: rock-paper-scissors
agent: tic-tac-toe
agent: uno
artifacts
bug
bugfix
build
catalog
ci
client
dependencies
docs
documentation
enhancement
feature
fixed-in-staging
in-pr
normal-scope
packages
pull-request
qol
regression
roadmap
scope-risk
server
soup
upstream
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Pasta-Devs/Marinara-Agents#1850
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 @Promansis on GitHub (Oct 31, 2026).
Original GitHub issue: https://github.com/Pasta-Devs/Marinara-Agents/issues/1974
Originally assigned to: @Promansis on GitHub.
Summary
Nine Long-Term Memory number fields hold settings that the server accepts only as whole numbers (
.int()), but the field passes a typed decimal through unchanged. Typing2.5into "Max memories", for example, makes the settings save fail validation. #1964 fixed the same problem for the Advanced Memory batch size by adding anintegerprop toNumberField. These nine fields don't pass that prop yet.Affected package
long-term-memory (1.5.20 on staging
92e3fd32d)Expected behavior
A whole-number field rounds a typed decimal after clamping it, then shows and saves the rounded value, the way the Advanced Memory batch size already does.
Actual behavior
The decimal goes into the form state unchanged. Saving sends it to the settings route, where the shared schema's
z.number().int()rejects it.Steps to reproduce
2.5into "Max memories" (or any field listed below) and leave the field.Environment
Logs, screenshots, or video
Found by code reading. Dottore asked about it on PR #1970 (2026-10-31).
Additional context
These fields, at staging
92e3fd32d, use.int()inshared/src/features/agents/long-term-memory/schema/settings.tsand have no rounding on the client:settings/MemorySettings.tsxlongTermMemoryBudgetTokens(line 676)longTermMemoryMaxChunks(690)longTermMemoryRecallContextMessages(698)extractionFormState.maxOutputTokens(1071)extractionFormState.maxSourceTokens(1186)extractionFormState.existingNoteMaxChunks(1200)extractionFormState.existingNoteMaxTokens(1215)ChatSettings.tsx(per-chat overrides)effectiveBudget→longTermMemoryBudgetTokens(128)effectiveMaxChunks→longTermMemoryMaxChunks(150)These stay decimal and are out of scope:
longTermMemoryScoreThreshold(782), the four recall weights (798–825) andtemperature(1170).Minimal fix
packages/long-term-memory/src/engine/packages/client/src/features/long-term-memory/settings/MemorySettings.tsxand.../long-term-memory/ChatSettings.tsx.integerprop to the nine<NumberField>callers listed above. Don't changeshared-controls.tsx: itsinteger ? Math.round(next) : nextclamp from #1964 already does the rounding.tests/long-term-memory-feedback-clarity-ui.regression.mjsnext to the #1964 block. Assert that each of the nine fields (matched by itsvalue={...}expression) carriesinteger, and that the six decimal fields don't.Template check
Please uncheck (untick) the box below before submitting so we know you read the template. It is intentionally pre-checked: