[GH-ISSUE #7321] [Issue]: Limit Context Messages ignored in roleplay mode #4081

Closed
opened 2026-10-21 06:10:13 +07:00 by bsakaguchi · 1 comment
Owner

Originally created by @SpicyMarinara on GitHub (Oct 9, 2026).
Original GitHub issue: https://github.com/Pasta-Devs/Marinara-Engine/issues/7321

Originally assigned to: @SpicyMarinara on GitHub.

Summary

The Limit Context Messages setting is not being applied in roleplay mode. A limit of 45 still allows more than 200 messages to be sent in the prompt.

Expected behavior

Prompts in roleplay mode should include no more than the configured limit of 45 context messages.

Actual behavior

The prompt includes more than 200 context messages despite the limit being set to 45.

Steps to reproduce

  1. Open Marinara Engine 2.5.0 and use roleplay mode.
  2. Set Limit Context Messages to 45.
  3. Send a prompt in a conversation containing more than 200 messages.
  4. Observe that more than 200 messages are included instead of the configured maximum of 45.
  5. Change the limit and restart Marinara Engine; observe that the issue persists.

Environment

  • Marinara Engine version: 2.5.0 (build 2.5.0+c56501495a8b, commit c56501495a)
  • Install type: Not provided
  • OS + version: Windows 10.0.19045 x64
  • Browser or app shell: Firefox 157.0 on Windows 10.0

Logs, screenshots, or video

Support diagnostics were provided. No additional logs, screenshots, or video were provided.

Additional context

The setting worked before the update and previously limited token usage. The reporter tried changing the limit several times and restarting the entire program. Active connection: OpenR Mimo 2.6 Pro via OpenRouter; model: xiaomi/mimo-v2.6-pro.

Discord thread: Limit Context Messages isn't working.
Discord thread link: https://discord.com/channels/1417099416812392641/1557875771945521152
Requested by: Marinara (marinara_spaghetti, Discord ID 169561011928432653)

Discord thread transcript (3 messages)
[2026-10-08T22:02:07.964Z] Mekata: Limit Context Messages isn't working for me. I set limit to 45 messages and prompt is still sending over 200 of them. Before the update it was working fine and limited my token usage. I'm using it on roleplay mode.

` ` `
Marinara Engine diagnostics
Version: 2.5.0
Build: 2.5.0+c56501495a8b
Commit: c56501495a8b
Server OS: Windows 10.0.19045 (x64)
Server memory: heap 160.1 / 4288 MiB; RSS 254.8 MiB
Background wake lock: not reported
Last detected freeze: none detected
Client OS: Windows 10.0
Browser / app shell: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:157.0) Gecko/20100101 Firefox/157.0
Client runtime: {"build":"2.5.0+c56501495a8b","page":"mv02ee3y-umrxhqmr","persistence":"local","navigation":"navigate","standalone":false,"view":[901,0,0,0],"events":[{"at":1791495893230,"page":"mv02ee3y-umrxhqmr","build":"2.5.0+c56501495a8b","kind":"page-start","view":[901,0,0,0]}]}
GPU: ANGLE (NVIDIA, NVIDIA GeForce GTX 980 Direct3D11 vs_5_0 ps_5_0), or similar
Server GPU: NVIDIA GeForce GTX 980, 4096 MiB total, 1329 MiB used, driver 560.94
Main sidecar: not configured
Utility sidecar: not configured
Decision sidecar: not configured
Sidecar load: not measured
Active connection: OpenR Mimo 2.6 Pro
Connection provider: openrouter
LLM model: xiaomi/mimo-v2.6-pro
Mari last acted on: none recorded this session
` ` `
[Discord message: https://discord.com/channels/1417099416812392641/1557875771945521152/1557875771945521152]

[2026-10-08T22:02:08.569Z] Professor Mari [bot]: Howdy!

Thank you for submitting a new bug report/feature request, your support means a lot. A member of the team will look into it as soon as possible, and if they find it valid, they will open a GitHub Issue out of it. You can check whether it was addressed on the staging build of Marinara Engine. **Do not ping any of the developers, this will not speed up the process.**

**Please include a Support Diagnostic in the post if you haven't done it yet.** Otherwise, ignore this step. To grab it, go to the Marinara Engine tab:

`Settings -> Advanced -> Support Diagnostics -> Copy Support Diagnostics.`

If your report is about any of the **Agents**, please provide **the Agent's version** which you can grab from here:

`Agents -> Download Agents -> Installed Agents -> Selected Agent -> Installed Version`

Thank you, this will help tremendously.

This is an automated message, but if you reply to it, I will do my best to assist you using my LLM-powered brain. That said, it's best for a human to handle this case.

Cheers!
[Discord message: https://discord.com/channels/1417099416812392641/1557875771945521152/1557875774483341394]

[2026-10-08T22:04:25.592Z] Mekata: Also changed limit few times and reset the whole program before writing here.
[Discord message: https://discord.com/channels/1417099416812392641/1557875771945521152/1557876349199319183]

Template check

Please uncheck (untick) the box below before submitting so we know you read the template. It is intentionally pre-checked:

  • I DID NOT read this template and provide the requested details.
Originally created by @SpicyMarinara on GitHub (Oct 9, 2026). Original GitHub issue: https://github.com/Pasta-Devs/Marinara-Engine/issues/7321 Originally assigned to: @SpicyMarinara on GitHub. ## Summary The Limit Context Messages setting is not being applied in roleplay mode. A limit of 45 still allows more than 200 messages to be sent in the prompt. ## Expected behavior Prompts in roleplay mode should include no more than the configured limit of 45 context messages. ## Actual behavior The prompt includes more than 200 context messages despite the limit being set to 45. ## Steps to reproduce 1. Open Marinara Engine 2.5.0 and use roleplay mode. 2. Set Limit Context Messages to 45. 3. Send a prompt in a conversation containing more than 200 messages. 4. Observe that more than 200 messages are included instead of the configured maximum of 45. 5. Change the limit and restart Marinara Engine; observe that the issue persists. ## Environment - Marinara Engine version: 2.5.0 (build 2.5.0+c56501495a8b, commit c56501495a8b) - Install type: Not provided - OS + version: Windows 10.0.19045 x64 - Browser or app shell: Firefox 157.0 on Windows 10.0 ## Logs, screenshots, or video Support diagnostics were provided. No additional logs, screenshots, or video were provided. ## Additional context The setting worked before the update and previously limited token usage. The reporter tried changing the limit several times and restarting the entire program. Active connection: OpenR Mimo 2.6 Pro via OpenRouter; model: xiaomi/mimo-v2.6-pro. Discord thread: Limit Context Messages isn't working. Discord thread link: https://discord.com/channels/1417099416812392641/1557875771945521152 Requested by: Marinara (marinara_spaghetti, Discord ID 169561011928432653) <details> <summary>Discord thread transcript (3 messages)</summary> ```text [2026-10-08T22:02:07.964Z] Mekata: Limit Context Messages isn't working for me. I set limit to 45 messages and prompt is still sending over 200 of them. Before the update it was working fine and limited my token usage. I'm using it on roleplay mode. ` ` ` Marinara Engine diagnostics Version: 2.5.0 Build: 2.5.0+c56501495a8b Commit: c56501495a8b Server OS: Windows 10.0.19045 (x64) Server memory: heap 160.1 / 4288 MiB; RSS 254.8 MiB Background wake lock: not reported Last detected freeze: none detected Client OS: Windows 10.0 Browser / app shell: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:157.0) Gecko/20100101 Firefox/157.0 Client runtime: {"build":"2.5.0+c56501495a8b","page":"mv02ee3y-umrxhqmr","persistence":"local","navigation":"navigate","standalone":false,"view":[901,0,0,0],"events":[{"at":1791495893230,"page":"mv02ee3y-umrxhqmr","build":"2.5.0+c56501495a8b","kind":"page-start","view":[901,0,0,0]}]} GPU: ANGLE (NVIDIA, NVIDIA GeForce GTX 980 Direct3D11 vs_5_0 ps_5_0), or similar Server GPU: NVIDIA GeForce GTX 980, 4096 MiB total, 1329 MiB used, driver 560.94 Main sidecar: not configured Utility sidecar: not configured Decision sidecar: not configured Sidecar load: not measured Active connection: OpenR Mimo 2.6 Pro Connection provider: openrouter LLM model: xiaomi/mimo-v2.6-pro Mari last acted on: none recorded this session ` ` ` [Discord message: https://discord.com/channels/1417099416812392641/1557875771945521152/1557875771945521152] [2026-10-08T22:02:08.569Z] Professor Mari [bot]: Howdy! Thank you for submitting a new bug report/feature request, your support means a lot. A member of the team will look into it as soon as possible, and if they find it valid, they will open a GitHub Issue out of it. You can check whether it was addressed on the staging build of Marinara Engine. **Do not ping any of the developers, this will not speed up the process.** **Please include a Support Diagnostic in the post if you haven't done it yet.** Otherwise, ignore this step. To grab it, go to the Marinara Engine tab: `Settings -> Advanced -> Support Diagnostics -> Copy Support Diagnostics.` If your report is about any of the **Agents**, please provide **the Agent's version** which you can grab from here: `Agents -> Download Agents -> Installed Agents -> Selected Agent -> Installed Version` Thank you, this will help tremendously. This is an automated message, but if you reply to it, I will do my best to assist you using my LLM-powered brain. That said, it's best for a human to handle this case. Cheers! [Discord message: https://discord.com/channels/1417099416812392641/1557875771945521152/1557875774483341394] [2026-10-08T22:04:25.592Z] Mekata: Also changed limit few times and reset the whole program before writing here. [Discord message: https://discord.com/channels/1417099416812392641/1557875771945521152/1557876349199319183] ``` </details> ## Template check Please **uncheck (untick)** the box below before submitting so we know you read the template. It is intentionally pre-checked: - [ ] I DID NOT read this template and provide the requested details.
bsakaguchi 2026-10-21 06:10:13 +07:00
  • closed this issue
  • added the
    in-pr
    bug
    labels
Author
Owner

@SpicyMarinara commented on GitHub (Oct 9, 2026):

Fixed on staging by #7331.

<!-- gh-comment-id:6079415024 --> @SpicyMarinara commented on GitHub (Oct 9, 2026): Fixed on staging by #7331.
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#4081
No description provided.