[GH-ISSUE #4040] [Issue]: Improve card history versioning and diff view #2178

Closed
opened 2026-10-21 05:46:02 +07:00 by bsakaguchi · 4 comments
Owner

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

Originally assigned to: @SpicyMarinara on GitHub.

Summary

Make card history behave more like Git commits by preserving every saved version, including the current version. Provide a detailed diff view for comparing card versions. EDIT: My forgetful ass forgot we already have version comparison. BUT, the current view doesn't properly wrap the text (very long words). In most cases this is not a problem but in creator notes, people seem to love putting a lot of fancy html which includes links.

Expected behavior

Each saved card version should be preserved as a distinct history entry with its timestamp, and restoring an older version should not permanently lose newer versions. Users should also be able to view detailed differences between versions. Texts in the version comparisons should wrap.

Actual behavior

The current card version is not saved until a newer version is created, so its history timestamp reflects the later save. Restoring an older version can permanently lose the newer version. Comparisons only identify changed sections, not the detailed text differences.

Steps to reproduce

  1. Start with a card at version v1.
  2. Modify the card and save it as v2.
  3. Open version history and observe that v1 appears with the timestamp of the v2 save.
  4. Restore v1 and observe that v2 is no longer available in version history.
  5. Compare two versions and observe that only changed sections are shown, without an inline detailed diff.

Environment

  • Marinara Engine version: v2.3.4
  • Install type: Not provided
  • OS + version: Not provided
  • Browser or app shell: Not provided

Logs, screenshots, or video

Not provided

Additional context

The detailed diff view could resemble a GitHub-style diff, with old and new content displayed side by side. Marinara acknowledged that the version-history concern makes sense; the diff UI was considered potentially out of scope but feasible.

Discord thread: [Feature Request] Card history enchantments
Discord thread link: https://discord.com/channels/1417099416812392641/1530175005013446756
Requested by: Marinara (marinara_spaghetti, Discord ID 169561011928432653)

Discord thread transcript (2 messages)
[2026-07-24T11:29:10.472Z] czoko220: Hi, I love the functionality of seeing version history of character card and being able to revert to older ones. But using it for the first time was very confusing to me until I did some tests to figure out how it works. From my understanding, the current version of the card is not being displayed/saved in the version history? 
Why what is confusing to me? 
- Let's say right now my card version is v1, since it's the current version it's not saved in the version history. Then, I make some change to the card, thus creating a v2 version of it. The moment I press the save button, the v1 version of the card appears in the version history with the current timestamp - the timestamp of when I created v2, no v1. 
- Then, if I were to restore to v1 version, the v2 version would be lost forever since it wasn't saved in version history at any point. As far as I can tell, current version of the card is saved in history only when creating a newer version.

So in, short I believe it would be more intuitive (at least to me?) if the version history worked more like git commits rather than it's current state. 

I am not sure if this should be a separate post or not, but I also have another request related to the card history. Again, I really like the fact that I am able to compare current version of the card with older ones, but currently it only shows which section of the card has been changed. For example, description, starting message etc. This already is a huge help when comparing versions, but still, it means that if I really want to see the difference between two versions of 4k long character descriptions I need to manually copy both of them in some outside tool like diffchecker.com and compare them there. Having a view similar to that or github diff viewer would be amazing, but I will understand if you decide this is out of scope for what this feature should do or simply not worth the work for such niche functionality. 

ME version: v2.3.4
[Discord message: https://discord.com/channels/1417099416812392641/1530175005013446756/1530175005013446756]

[2026-07-24T11:36:25.492Z] Marinara: The first part definitely makes sense; the second is a little out of scope for now, since it would require coming up with a new UI… Well, actually, just a window displaying old on the left, new on the right? Shouldn't be too hard to implement.
[Discord message: https://discord.com/channels/1417099416812392641/1530175005013446756/1530176829619699834]

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 (Jul 24, 2026). Original GitHub issue: https://github.com/Pasta-Devs/Marinara-Engine/issues/4040 Originally assigned to: @SpicyMarinara on GitHub. ## Summary Make card history behave more like Git commits by preserving every saved version, including the current version. Provide a detailed diff view for comparing card versions. EDIT: My forgetful ass forgot we already have version comparison. BUT, the current view doesn't properly wrap the text (very long words). In most cases this is not a problem but in creator notes, people seem to love putting a lot of fancy html which includes links. ## Expected behavior Each saved card version should be preserved as a distinct history entry with its timestamp, and restoring an older version should not permanently lose newer versions. Users should also be able to view detailed differences between versions. Texts in the version comparisons should wrap. ## Actual behavior The current card version is not saved until a newer version is created, so its history timestamp reflects the later save. Restoring an older version can permanently lose the newer version. Comparisons only identify changed sections, not the detailed text differences. ## Steps to reproduce 1. Start with a card at version v1. 2. Modify the card and save it as v2. 3. Open version history and observe that v1 appears with the timestamp of the v2 save. 4. Restore v1 and observe that v2 is no longer available in version history. 5. Compare two versions and observe that only changed sections are shown, without an inline detailed diff. ## Environment - Marinara Engine version: v2.3.4 - Install type: Not provided - OS + version: Not provided - Browser or app shell: Not provided ## Logs, screenshots, or video Not provided ## Additional context The detailed diff view could resemble a GitHub-style diff, with old and new content displayed side by side. Marinara acknowledged that the version-history concern makes sense; the diff UI was considered potentially out of scope but feasible. Discord thread: [Feature Request] Card history enchantments Discord thread link: https://discord.com/channels/1417099416812392641/1530175005013446756 Requested by: Marinara (marinara_spaghetti, Discord ID 169561011928432653) <details> <summary>Discord thread transcript (2 messages)</summary> ```text [2026-07-24T11:29:10.472Z] czoko220: Hi, I love the functionality of seeing version history of character card and being able to revert to older ones. But using it for the first time was very confusing to me until I did some tests to figure out how it works. From my understanding, the current version of the card is not being displayed/saved in the version history? Why what is confusing to me? - Let's say right now my card version is v1, since it's the current version it's not saved in the version history. Then, I make some change to the card, thus creating a v2 version of it. The moment I press the save button, the v1 version of the card appears in the version history with the current timestamp - the timestamp of when I created v2, no v1. - Then, if I were to restore to v1 version, the v2 version would be lost forever since it wasn't saved in version history at any point. As far as I can tell, current version of the card is saved in history only when creating a newer version. So in, short I believe it would be more intuitive (at least to me?) if the version history worked more like git commits rather than it's current state. I am not sure if this should be a separate post or not, but I also have another request related to the card history. Again, I really like the fact that I am able to compare current version of the card with older ones, but currently it only shows which section of the card has been changed. For example, description, starting message etc. This already is a huge help when comparing versions, but still, it means that if I really want to see the difference between two versions of 4k long character descriptions I need to manually copy both of them in some outside tool like diffchecker.com and compare them there. Having a view similar to that or github diff viewer would be amazing, but I will understand if you decide this is out of scope for what this feature should do or simply not worth the work for such niche functionality. ME version: v2.3.4 [Discord message: https://discord.com/channels/1417099416812392641/1530175005013446756/1530175005013446756] [2026-07-24T11:36:25.492Z] Marinara: The first part definitely makes sense; the second is a little out of scope for now, since it would require coming up with a new UI… Well, actually, just a window displaying old on the left, new on the right? Shouldn't be too hard to implement. [Discord message: https://discord.com/channels/1417099416812392641/1530175005013446756/1530176829619699834] ``` </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 05:46:02 +07:00
Author
Owner

@SpicyMarinara commented on GitHub (Jul 24, 2026):

🔧 Owned by @SpicyMarinara (Claude agent session). Draft PR: incoming.

Addressed the two endorsed parts plus your EDIT:

  • Restore no longer loses the newer version — restoring now snapshots the current card to history first (git-style), so you can switch back.
  • Version timestamps fixed — a saved version keeps its own edit time instead of the later save's timestamp (fixes v1 showing v2's time).
  • Comparison wraps long text — the side-by-side panes now break long URLs/HTML in creator notes instead of overflowing.

Applied to both characters and personas. Left the fancy inline word-diff out (you'd deprioritized it, and the existing per-field side-by-side covers the comparison need).

<!-- gh-comment-id:5069610875 --> @SpicyMarinara commented on GitHub (Jul 24, 2026): 🔧 Owned by @SpicyMarinara (Claude agent session). Draft PR: incoming. Addressed the two endorsed parts plus your EDIT: - **Restore no longer loses the newer version** — restoring now snapshots the current card to history first (git-style), so you can switch back. - **Version timestamps fixed** — a saved version keeps its own edit time instead of the later save's timestamp (fixes v1 showing v2's time). - **Comparison wraps long text** — the side-by-side panes now break long URLs/HTML in creator notes instead of overflowing. Applied to both characters and personas. Left the fancy inline word-diff out (you'd deprioritized it, and the existing per-field side-by-side covers the comparison need).
Author
Owner

@SpicyMarinara commented on GitHub (Jul 24, 2026):

Reopening.

On latest staging Release: v2.3.5Build: 0577b91 and android/termux install, I see the wrapping is preventing my creator notes from exiting bounds, but version history insists my cards are always v1.0, and the timestamps are sometimes a few minutes away from the real time. I made that most recent, topmost version at 11:04AM (restarted Termux to triple check it wasnt my own device's clock melting.)

<!-- gh-comment-id:5073685366 --> @SpicyMarinara commented on GitHub (Jul 24, 2026): Reopening. On latest staging Release: v2.3.5Build: 0577b91 and android/termux install, I see the wrapping is preventing my creator notes from exiting bounds, but version history insists my cards are always v1.0, and the timestamps are sometimes a few minutes away from the real time. I made that most recent, topmost version at 11:04AM (restarted Termux to triple check it wasnt my own device's clock melting.)
Author
Owner

@SpicyMarinara commented on GitHub (Jul 24, 2026):

🔧 Ownership: @SpicyMarinara via Codex. Implementation is underway in draft PR #4060.

<!-- gh-comment-id:5073780492 --> @SpicyMarinara commented on GitHub (Jul 24, 2026): 🔧 Ownership: @SpicyMarinara via Codex. Implementation is underway in draft PR #4060.
Author
Owner

@SpicyMarinara commented on GitHub (Jul 24, 2026):

🔧 Ownership note: @SpicyMarinara is handling this in #4060 as part of the current open-issue sweep.

<!-- gh-comment-id:5073877746 --> @SpicyMarinara commented on GitHub (Jul 24, 2026): 🔧 Ownership note: @SpicyMarinara is handling this in #4060 as part of the current open-issue sweep.
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#2178
No description provided.