[GH-ISSUE #1121] [Issue]: Order sequence in preset prompts #552

Closed
opened 2026-10-20 17:30:06 +07:00 by bsakaguchi · 2 comments
Owner

Originally created by @muskdavid661-ai on GitHub (May 23, 2026).
Original GitHub issue: https://github.com/Pasta-Devs/Marinara-Engine/issues/1121

Originally assigned to: @SpicyMarinara on GitHub.

Summary

I'm not 100% certain if this is similar in silly or not. but the thing is whenever i set the order of my section of preset to depth(from the end of chat) normally it mean if goes x value above messages in the prompt send to ai. But during the start of the chat since there aren't that many messages. the prompt section goes to the very top of the prompt. now I'm fully aware it's kind of working right, but the thing is it's really messes up the preset prompt making the ai hallucinate and stuff. so maybe you could make it so even in those cases it never goes above the chat history and goes to the right depth when the x number of messages are there. I'm using it through tremux in Android.Thanks again for the hard work.

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 @muskdavid661-ai on GitHub (May 23, 2026). Original GitHub issue: https://github.com/Pasta-Devs/Marinara-Engine/issues/1121 Originally assigned to: @SpicyMarinara on GitHub. ## Summary I'm not 100% certain if this is similar in silly or not. but the thing is whenever i set the order of my section of preset to depth(from the end of chat) normally it mean if goes x value above messages in the prompt send to ai. But during the start of the chat since there aren't that many messages. the prompt section goes to the very top of the prompt. now I'm fully aware it's kind of working right, but the thing is it's really messes up the preset prompt making the ai hallucinate and stuff. so maybe you could make it so even in those cases it never goes above the chat history and goes to the right depth when the x number of messages are there. I'm using it through tremux in Android.Thanks again for the hard work. ## 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-20 17:30:06 +07:00
  • closed this issue
  • added the
    bug
    label
Author
Owner

@SpicyMarinara commented on GitHub (May 23, 2026):

Implemented in the local staging worktree.

Summary:

  • Changed depth-based prompt injection so preset/lorebook/character depth entries anchor to the chat-history span when the assembled prompt has one.
  • Depth entries now clamp to the first available history message instead of floating above the preset prompt context when a chat is shorter than the configured depth.
  • Updated strict role formatting to resolve the post-history boundary from history-marked messages after depth injection.
  • Updated CHANGELOG.md.

Validation:

  • pnpm --filter @marinara-engine/server lint
<!-- gh-comment-id:4524936290 --> @SpicyMarinara commented on GitHub (May 23, 2026): Implemented in the local staging worktree. Summary: - Changed depth-based prompt injection so preset/lorebook/character depth entries anchor to the chat-history span when the assembled prompt has one. - Depth entries now clamp to the first available history message instead of floating above the preset prompt context when a chat is shorter than the configured depth. - Updated strict role formatting to resolve the post-history boundary from history-marked messages after depth injection. - Updated CHANGELOG.md. Validation: - pnpm --filter @marinara-engine/server lint
Author
Owner

@muskdavid661-ai commented on GitHub (May 23, 2026):

thanks

<!-- gh-comment-id:4524938423 --> @muskdavid661-ai commented on GitHub (May 23, 2026): thanks
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#552
No description provided.