mirror of
https://github.com/Pasta-Devs/Marinara-Engine.git
synced 2026-12-03 19:00:50 +07:00
[PR #8366] [MERGED] fix(mari): make write results say what actually happened #8320
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#8320
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/8366
Author: @ylli-selmani
Created: 10/26/2026
Status: ✅ Merged
Merged: 10/26/2026
Merged by: @ylli-selmani
Base:
staging← Head:fix/mari-result-honesty📝 Commits (1)
406eec8fix(mari): make write results say what actually happened📊 Changes
6 files changed (+34 additions, -5 deletions)
View changed files
📝
packages/server/src/services/mari-db/mari-db.service.ts(+2 -1)📝
packages/server/src/services/professor-mari/workspace-agent.service.ts(+9 -2)📝
packages/server/src/services/professor-mari/workspace-round-review.ts(+1 -1)📝
scripts/regressions/mari-write-readback.regression.ts(+13 -0)📝
scripts/regressions/mari/lorebook-selective-notice.regression.ts(+5 -0)📝
scripts/regressions/professor-mari/round-review.regression.ts(+4 -1)📄 Description
Linked issue
Closes #8365
Why this change
Professor Mari reads her own tool results literally, and four of them said something other than what happened. Strong models (GLM 5.3, Claude) already acted on them wrongly in live runs; smaller models will do worse:
approval: { status: "pending" }. That is the change card's undo window, but next to "Applied and saved" she read it as "waiting for Accept" and told users a saved change was still pending (seen three times, once on a memory).validationsat after the before/after preview, so on a long result the truncation cut the notices first, even though the message tells her to read them.selective: false.What changed
Mari's view of a write result (
compactMutationResult,workspace-agent.service.ts)changeCard: { undoUntil }instead ofapproval. Non-applied results keepapprovalas before.reviewIdlookup, and the keep/undo routes all read the raw result, never this view. "Staged" detection uses the sensitive-file text, notapproval.validationmoves up to sit right afterreadBack, so it survives truncation.Lorebook selective notice (
selectiveKeysNotice,mari-db.service.ts)Completion-claim repair (
workspace-round-review.ts)Regressions
mari-write-readbacknow pins: the raw result keepsapproval.status: "pending", her view has noapprovalkey,changeCard.undoUntilequals the review'sexpiresAt, no"pending"appears anywhere in the applied view, andvalidationcomes beforesummary.mari/lorebook-selective-noticeandprofessor-mari/round-reviewpin the new wording.No handbook (
mari-skills/*.md) teaches theapprovalfield, so no skill text changes.Validation
pnpm checkpasses locallyCONTRIBUTING.mdManual verification notes
Agent-run:
pnpm checkexits 0 (one pre-existing client lint warning this branch doesn't touch).node scripts/run-regressions.mjs --filterpasses formari-write-readback,round-review,lorebook-selective-notice,dry-run-enforcement,pi-runtime,character-onboarding.selectiveon and no secondary keys, Mari's notice offersselective: false.Docs and release impact
docs-i18nbranch updated to match, or a[docs-i18n]follow-up issue opened (see CONTRIBUTING.md § Translated documentation)UI evidence (if applicable)
No UI changes; the change is in the engine's tool results.
🤖 Generated with Claude Code
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.