[PR #5279] [MERGED] Fix Professor Mari lorebook edit commands #6702

Closed
opened 2026-10-23 04:12:53 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/Pasta-Devs/Marinara-Engine/pull/5279
Author: @SpicyMarinara
Created: 8/19/2026
Status: ✅ Merged
Merged: 8/19/2026
Merged by: @SpicyMarinara

Base: staging ← Head: fix/professor-mari-lorebook-5271


📝 Commits (5)

  • fe12ebe fix Professor Mari lorebook edits
  • f418d1a Merge branch 'staging' into fix/professor-mari-lorebook-5271
  • a8e7d32 Merge staging into fix/professor-mari-lorebook-5271
  • 6b834d4 Merge remote Professor Mari branch
  • 8d09fa7 Merge remote-tracking branch 'origin/staging' into fix/professor-mari-lorebook-5271

📊 Changes

3 files changed (+69 additions, -3 deletions)

View changed files

📝 CHANGELOG.md (+1 -0)
📝 packages/server/src/services/professor-mari/workspace-agent.service.ts (+23 -3)
📝 scripts/regressions/prompt.regression.ts (+45 -0)

📄 Description

Why

Professor Mari workspace runs can stall when an OpenRouter model emits prose instead of the required JSON command frame. Separately, the mutation gate treated splitting a lorebook entry as only an update, then blocked the lorebook.addEntry command needed to save the split-off content.

Fixes #5271.

What changed

  • request JSON-object responses for Professor Mari workspace calls made through OpenRouter
  • recognize an explicit lorebook-entry split as authorization for the implied create and update operations
  • keep delete and unrelated-entity mutation boundaries unchanged
  • add focused prompt/authorization regressions and a changelog entry

Validation

  • Run pnpm check
  • Run the focused prompt regression
  • Manually verify an OpenRouter Professor Mari workspace response uses the JSON command protocol
  • Manually verify an authorized lorebook split can update the original entry and create split-off entries
  • Manually verify the same wording does not authorize deletion or unrelated entity creation

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/Pasta-Devs/Marinara-Engine/pull/5279 **Author:** [@SpicyMarinara](https://github.com/SpicyMarinara) **Created:** 8/19/2026 **Status:** ✅ Merged **Merged:** 8/19/2026 **Merged by:** [@SpicyMarinara](https://github.com/SpicyMarinara) **Base:** `staging` ← **Head:** `fix/professor-mari-lorebook-5271` --- ### 📝 Commits (5) - [`fe12ebe`](https://github.com/Pasta-Devs/Marinara-Engine/commit/fe12ebe6b6e696531cbc3a344e1d75404c6a1dd2) fix Professor Mari lorebook edits - [`f418d1a`](https://github.com/Pasta-Devs/Marinara-Engine/commit/f418d1a9246d7a5210403db170149ff2c99c6fcc) Merge branch 'staging' into fix/professor-mari-lorebook-5271 - [`a8e7d32`](https://github.com/Pasta-Devs/Marinara-Engine/commit/a8e7d32d477674e97b4810ecde231542fc396f59) Merge staging into fix/professor-mari-lorebook-5271 - [`6b834d4`](https://github.com/Pasta-Devs/Marinara-Engine/commit/6b834d45ede7b88682a7f3c74e86b868e04ad7da) Merge remote Professor Mari branch - [`8d09fa7`](https://github.com/Pasta-Devs/Marinara-Engine/commit/8d09fa7dcf6015042fac9f857aa4371acad89f0f) Merge remote-tracking branch 'origin/staging' into fix/professor-mari-lorebook-5271 ### 📊 Changes **3 files changed** (+69 additions, -3 deletions) <details> <summary>View changed files</summary> 📝 `CHANGELOG.md` (+1 -0) 📝 `packages/server/src/services/professor-mari/workspace-agent.service.ts` (+23 -3) 📝 `scripts/regressions/prompt.regression.ts` (+45 -0) </details> ### 📄 Description ## Why Professor Mari workspace runs can stall when an OpenRouter model emits prose instead of the required JSON command frame. Separately, the mutation gate treated splitting a lorebook entry as only an update, then blocked the `lorebook.addEntry` command needed to save the split-off content. Fixes #5271. ## What changed - request JSON-object responses for Professor Mari workspace calls made through OpenRouter - recognize an explicit lorebook-entry split as authorization for the implied create and update operations - keep delete and unrelated-entity mutation boundaries unchanged - add focused prompt/authorization regressions and a changelog entry ## Validation - [ ] Run `pnpm check` - [ ] Run the focused prompt regression - [ ] Manually verify an OpenRouter Professor Mari workspace response uses the JSON command protocol - [ ] Manually verify an authorized lorebook split can update the original entry and create split-off entries - [ ] Manually verify the same wording does not authorize deletion or unrelated entity creation --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-10-23 04:12:53 +07:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Pasta-Devs/Marinara-Engine#6702
No description provided.