[PR #7973] [MERGED] feat(cards): apply field alternatives in selected chats #8034

Closed
opened 2026-10-24 04:09:50 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/Pasta-Devs/Marinara-Engine/pull/7973
Author: @SpicyMarinara
Created: 10/21/2026
Status: ✅ Merged
Merged: 10/21/2026
Merged by: @SpicyMarinara

Base: staging ← Head: feat/7969-card-field-alternatives


📝 Commits (10+)

  • bf1f658 feat: persist chat-scoped card field alternatives
  • 1e4276a feat(cards): apply alternatives consistently to chat prompt context
  • e4f6ad8 feat(cards): generate individual sections from editor drafts
  • 75ea378 feat(cards): edit alternatives and select eligible chats per field
  • ce56696 fix(cards): preserve base cards during scoped background work
  • 25b2a15 docs: explain card field wands and retain editor browser coverage
  • cd69252 Merge branch 'feat/7968-card-field-generation' into feat/7969-card-field-alternatives
  • 9c608f6 fix(prompt): inject persona dialogue fallback once
  • 88970ef docs: explain chat-specific card alternatives and retain browser coverage
  • b15522b Merge branch 'feat/7968-card-field-generation' into feat/7969-card-field-alternatives

📊 Changes

52 files changed (+2055 additions, -136 deletions)

View changed files

📝 docs/characters/creating-and-editing-characters.md (+20 -1)
📝 docs/characters/personas.md (+17 -1)
📝 e2e/bot-browser-download.e2e.ts (+11 -0)
➕ e2e/card-field-alternatives.e2e.ts (+438 -0)
📝 packages/client/src/components/bot-browser/BotBrowserView.tsx (+2 -0)
➕ packages/client/src/components/characters/CardFieldAlternatives.tsx (+240 -0)
📝 packages/client/src/components/characters/CharacterEditor.tsx (+72 -24)
📝 packages/client/src/components/personas/PersonaEditor.tsx (+47 -15)
📝 packages/client/src/localization/locales/en.json (+17 -0)
📝 packages/server/src/db/schema/characters.ts (+2 -0)
📝 packages/server/src/routes/backup.routes.ts (+4 -0)
📝 packages/server/src/routes/characters.routes.ts (+31 -2)
📝 packages/server/src/routes/chats.routes.ts (+3 -3)
📝 packages/server/src/routes/conversation.routes.ts (+4 -3)
📝 packages/server/src/routes/encounter.routes.ts (+14 -5)
📝 packages/server/src/routes/gallery.routes.ts (+7 -7)
📝 packages/server/src/routes/game.routes.ts (+16 -12)
📝 packages/server/src/routes/generate.routes.ts (+13 -7)
📝 packages/server/src/routes/generate/dry-run-route.ts (+10 -8)
📝 packages/server/src/routes/generate/retry-agents-route.ts (+4 -3)

...and 32 more files

📄 Description

Linked issue

Closes #7969

Builds on #7972, which landed in staging as e97c52fed4d1f931a911967474548d3cbb16a2f4. This PR contains the remaining alternatives feature.

Why this change

Authors need different card details in different chats without duplicating an entire Character or Persona or changing the base card everywhere.

What changed

  • Added + Add Alternative Field under all seven Card fields in both editors. Each alternative starts as a copy, has its own text and wand, and can target zero, one, or many eligible chats. Its wand uses the alternative's text as the seed and the other card fields as references. There is no arbitrary alternative-count cap.
  • A chat uses one alternative per field; selecting it on another alternative moves that assignment. Empty text intentionally clears that field. Deleting requires confirmation. All edits use the existing editor save/save-on-leave lifecycle.
  • Applied immutable, membership-checked card projections to chat-bound prompt reads, including live generation, preview/retry, macros, supported group and Game roles, scene/memory/lorebook and chat media references. Summaries and summary alternatives remain metadata. Existing explicit scenario and image-appearance overrides retain their normal priority.
  • Preserved alternatives through persistence and version restore. Card exports/imports, Character/Persona conversions, duplication and Bot Browser imports as Persona keep alternative text but clear chat assignments; full profile backups retain their installation state. Empty alternative text is preserved during import. Background schedule renewal writes only schedule/status fields so projected text cannot replace the base card. Mari persona creation, reads and review restoration preserve the alternatives JSON storage contract.
  • Kept asynchronous generation tied to its target: later typing in that alternative and deletion are protected, while editing a neighboring base field preserves that edit and still accepts the generated alternative.
  • Added localized help, confirmations, accessibility text, refreshed eligible-chat pickers, both user guides, and retained API/prompt/browser regression coverage. Documentation translations are tracked in #7975.

Hosted review

The full Dottore examination completed on ddb51c9b4 against landed F1: all three packets scouted, seven candidates judged, zero unverified/failed/capped, $2.896 within the then-approved $3 limit. One code bundle was truncated; the walkthrough's visibility limitations remain disclosed. Subsequent genuine incremental examinations on a828a23ad and ec4854880 recorded their exact SHAs without hitting the cap. Valid findings were repaired; source-based dispositions are in their review threads.

The final repair 48c06a9fa preserves portable export content by clearing chat assignments before checking array-level assignment conflicts. Both Character export builders reuse one local helper: strict unassignment first, then a fallback only for ZodError from malformed stored data. Unexpected errors are rethrown. The first export correction put normalization before unassignment; the next review and an actual failing API regression exposed that ordering mistake. The expanded proof now covers decoded and serialized conflicts, padded prose, empty overrides, malformed entries, null, object, duplicate-ID and absent/empty states in individual downloads and mixed ZIPs. No duplicate-ID salvage or rekeying is introduced; invalid stored shapes retain the declared fail-closed policy. Strict imports and direct saves remain unchanged.

Other resolved review points:

  • Portable imports validate entries, clear foreign selections, then validate final ID uniqueness. Malformed rows and duplicate IDs fail explicitly without partial card creation; valid text and empty values survive conflicting foreign assignments. Compatible imports retain their existing HTTP200 success:false failure transport.
  • Availability headers distinguish loading and unknown states. Active in counts eligible chats; dormant saved IDs are preserved and resume with membership, as documented. The reported unsaved-card loading path is unreachable because both creation modals save before opening editors, which mount only behind truthy detail IDs; the caller trace is documented.
  • Projection failures keep the raw row and emit rate-limited metadata-only debug diagnostics without original exception text or card prose. Schedule writes patch only status/schedule into base extensions; normal editor exits use the save gate, while leaveWithoutSaving follows successful deletion.

The final incremental examination completed on exact 48c06a9fa from recorded ec4854880: $0.444, 22 model calls, zero unverified/failed/capped. It explicitly verified the assignment-ordering correction. Its sole reported finding requested the already-declined duplicate-ID salvage policy, which existed unchanged at the parent; the source-based disposition and actual nine-shape API/ZIP proof are recorded. All review threads are resolved. This records a reported finding and its rejection, rather than claiming a finding-free hosted review. All eight required checks passed on the final head, and every review thread was resolved before the locked-head merge into staging as 73ee30f41b58c0aff8f1baaceb7abfbcf0a9a7a3. The source and merge commits are verified ancestors of origin/staging. Post-merge pipelines are separate proof and were still starting at the delivery check. After delivery, the maintainer disabled the estimated spend cap by setting DOTTORE_COST_LIMIT_USD=0; the figures above record the earlier token-price estimates.

Validation

  • pnpm check passes locally
  • Container (Docker / Podman) built and ran without issue
  • Ran the app, clicked through the changes manually
  • Checked edge cases (light + dark mode, mobile viewport, empty states, error paths)
  • Above manual verification completed (describe below)
  • Read and followed CONTRIBUTING.md

Automated evidence

  • Full pnpm check: passed on final export repair 48c06a9facf5632f1dd433a88af4f99240ed043f, including localization, formatting, types/lint, E2E types and production builds. The current alternatives-only diff is 52 files, +2055/−136. No new config, provider/model, version or installer changes are part of the feature repair.
  • Hosted complete Node suite: 963/963 passed on final head 48c06a9facf5632f1dd433a88af4f99240ed043f, with all ten platform artifact jobs passing on their first attempt and all eight required status contexts successful. Native Windows includes installer prerequisite/integrity controls and Ctrl+C/graceful shutdown. No reruns were needed.
  • Final export repair: the retained portable-import regression passes on 48c06a9fa, including native/compatible individual downloads and complete mixed ZIP archives with healthy, conflicting-assignment and malformed stored cards. Valid prose, empty overrides, cleared assignments and exact raw source rows are checked; all strict malformed-import assertions remain. The existing native-export memory regression also passed with a 128 MB heap limit (119 MB measured peak heap).
  • Portable import and projection-diagnostic regressions: failing-before/passing-after proof covers native Character/Persona and compatible imports, legacy serialized arrays, foreign conflicts, raw whitespace and empty values, malformed input/duplicate-ID rejection without partial writes, unchanged source cards, private debug fields, repeat suppression, raw-row fallback and valid scoped projection.
  • Availability browser regression: 6/6 passed on the repair across desktop Chromium, mobile Chromium and mobile WebKit. Real persisted assignments survive held/failed eligible-chat requests, an actual base-field save while dormant, and membership restoration. Baseline API-loading badges failed before the UI correction. Initial post-fix attempts exposed fixture sequencing (opening the picker refetches) and a disabled Save with no edit; preserved unchanged replays reproduced those test errors. The final fixture waits for that response and verifies a real saved base edit before checking the preserved assignment. Assertions and timeouts were not weakened.
  • Desktop shell smoke: 7/7 passed on the repair; all isolated browser ports closed. All three pnpm regression:prompt suites and five direct regressions (portable import, private projection diagnostics, alternatives API/prompt, schedule generation, and decoded Persona/identity reads) passed on exact a828a23ad.
  • Mari durability regression: passed at preceding head fe4ff9519. Creation failures were reproduced before the defaults/JSON-column fix; retained proof covers preview, apply, decoded reads, serialized storage and update restoration. F1 semantic summary/dialogue creation and updates, explicit empty/whitespace clearing, preserved trimming and omitted/non-string inputs are covered without changing other Persona fields. Every clearing shape reseeds the field and reads its own before/after state.
  • Actual alternatives API/assembled-prompt and Game Experience/provider-prompt regressions: passed at 6db44ca19, covering base/other-chat isolation, empty overrides, metadata summaries, supported entity roles, persistence/restore, portable cards and Game dialogue macros.
  • Persona dialogue regression: passed at 6db44ca19, including 54 actual Peek requests across XML/Markdown/plain wrapping. It checks stochastic macros, final preset variables, Unicode case transformations including capital ẞ, disabled sections/groups, selected and unselected choices, false conditionals, complete quoted examples and partial first-line collisions. Complete existing examples avoid a duplicate fallback; a partial first line still receives the complete fallback. Schedule-generation and Game character-sheet regressions passed during earlier integration; schedule preservation and missed Game scopes have failing-before/passing-after provider/API proof.
  • Assembler macro-budget regression: passed at 6db44ca19. The cross-section budget regression was reproduced before its repair. More than 2,000 tracked expansions across independent sections now resolve with deferral both off and on; variable values and fallback summaries keep their own allowance, the Persona example observer remains active, and nested expansions retain the existing runaway limit.
  • Focused alternative-generation browser cases: 6/6 passed at db739d111, covering both editors across desktop Chromium, mobile Chromium and mobile WebKit. They verify neighboring base edits survive while target typing and deletion remain protected.
  • Bot Browser PNG-to-Persona import cases: 6/6 passed at 19b35ea97, using real Persona POST/GET requests. Both authored/absent-summary fixtures retain alternative text and empty values and clear foreign chat assignments. The missing payload had a failing-before proof. Shell smoke: 7/7 passed after that correction; client lint and E2E types passed.
  • Broader alternatives browser suite: 12/12 passed at the earlier 2031ca907 head, with 12 regenerated and inspected desktop/mobile dark/light screenshots.
  • Local CodeRabbit reviewed the implementation and its corrections. Valid findings were fixed, including duplicate fallback, repeated chat reads, committed draft refs and help copy. Latest incremental reviews of portable Persona import and the alternative neighboring-edit proof completed with zero findings. Independent review also reproduced and fixed schedule preservation and Game scope defects. A fresh independent source audit found no new defect in the repair. The repair local review suggested warning-level projection logs; debug is intentional for this recovered malformed-legacy path and matches the hosted review contract. This does not claim zero reported findings for the feature as a whole. The prior two-file export repair received a completed local review with zero findings on ec4854880; its missed ordering case was subsequently caught by hosted review and added to the regression matrix. The final ordering repair received a completed two-file local review with zero findings on 48c06a9fa.

Manual verification notes

  • Manually verify alternative prose quality with a configured paid/real model provider. Browser wand responses are fixtures; public server routes and effective prompt payloads are tested offline, without paid-model prose validation.
  • Manually verify on physical Android and iOS devices. Desktop and mobile browser emulation are recorded separately.
  • No local container build was performed for this editor feature.

Docs and release impact

  • No docs changes needed
  • Updated docs as needed
  • Translated docs updated, or a follow-up issue opened
  • Version/release files updated, if needed

English guides are included; #7975 tracks every translated documentation pack. No version bump or release changelog edit is part of this feature.

UI evidence (if applicable)

Retained Playwright coverage exercises both editors, all seven add controls, eligible and ineligible chats, zero/multiple assignments, moving a chat between alternatives, empty replacement, save/reopen, confirmed/cancelled deletion, eligibility refresh, generation and draft protection, with desktop/mobile dark/light screenshots.


🔄 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/7973 **Author:** [@SpicyMarinara](https://github.com/SpicyMarinara) **Created:** 10/21/2026 **Status:** ✅ Merged **Merged:** 10/21/2026 **Merged by:** [@SpicyMarinara](https://github.com/SpicyMarinara) **Base:** `staging` ← **Head:** `feat/7969-card-field-alternatives` --- ### 📝 Commits (10+) - [`bf1f658`](https://github.com/Pasta-Devs/Marinara-Engine/commit/bf1f65882ab4dacc95c5ed6170589078890ac670) feat: persist chat-scoped card field alternatives - [`1e4276a`](https://github.com/Pasta-Devs/Marinara-Engine/commit/1e4276a4188c933cd238386e331462751bee64ca) feat(cards): apply alternatives consistently to chat prompt context - [`e4f6ad8`](https://github.com/Pasta-Devs/Marinara-Engine/commit/e4f6ad83b9d55502790bbd7ebe6bed55b412c7e2) feat(cards): generate individual sections from editor drafts - [`75ea378`](https://github.com/Pasta-Devs/Marinara-Engine/commit/75ea3783f1e4504ef5982f1f6331992b70f494f7) feat(cards): edit alternatives and select eligible chats per field - [`ce56696`](https://github.com/Pasta-Devs/Marinara-Engine/commit/ce56696545f21c989c95d837b9ecbafb13461993) fix(cards): preserve base cards during scoped background work - [`25b2a15`](https://github.com/Pasta-Devs/Marinara-Engine/commit/25b2a153ca24f257a72a2d8893bf0c312db71b8e) docs: explain card field wands and retain editor browser coverage - [`cd69252`](https://github.com/Pasta-Devs/Marinara-Engine/commit/cd69252dc49011c70216c5747799f82d683e0ac9) Merge branch 'feat/7968-card-field-generation' into feat/7969-card-field-alternatives - [`9c608f6`](https://github.com/Pasta-Devs/Marinara-Engine/commit/9c608f655027c13a6906a55ecb0046ff33b80598) fix(prompt): inject persona dialogue fallback once - [`88970ef`](https://github.com/Pasta-Devs/Marinara-Engine/commit/88970ef5c9f428772bf7f6b1ad99c8143bac0a1b) docs: explain chat-specific card alternatives and retain browser coverage - [`b15522b`](https://github.com/Pasta-Devs/Marinara-Engine/commit/b15522ba679d4e4258e7b0a736e7b38d14dddc41) Merge branch 'feat/7968-card-field-generation' into feat/7969-card-field-alternatives ### 📊 Changes **52 files changed** (+2055 additions, -136 deletions) <details> <summary>View changed files</summary> 📝 `docs/characters/creating-and-editing-characters.md` (+20 -1) 📝 `docs/characters/personas.md` (+17 -1) 📝 `e2e/bot-browser-download.e2e.ts` (+11 -0) ➕ `e2e/card-field-alternatives.e2e.ts` (+438 -0) 📝 `packages/client/src/components/bot-browser/BotBrowserView.tsx` (+2 -0) ➕ `packages/client/src/components/characters/CardFieldAlternatives.tsx` (+240 -0) 📝 `packages/client/src/components/characters/CharacterEditor.tsx` (+72 -24) 📝 `packages/client/src/components/personas/PersonaEditor.tsx` (+47 -15) 📝 `packages/client/src/localization/locales/en.json` (+17 -0) 📝 `packages/server/src/db/schema/characters.ts` (+2 -0) 📝 `packages/server/src/routes/backup.routes.ts` (+4 -0) 📝 `packages/server/src/routes/characters.routes.ts` (+31 -2) 📝 `packages/server/src/routes/chats.routes.ts` (+3 -3) 📝 `packages/server/src/routes/conversation.routes.ts` (+4 -3) 📝 `packages/server/src/routes/encounter.routes.ts` (+14 -5) 📝 `packages/server/src/routes/gallery.routes.ts` (+7 -7) 📝 `packages/server/src/routes/game.routes.ts` (+16 -12) 📝 `packages/server/src/routes/generate.routes.ts` (+13 -7) 📝 `packages/server/src/routes/generate/dry-run-route.ts` (+10 -8) 📝 `packages/server/src/routes/generate/retry-agents-route.ts` (+4 -3) _...and 32 more files_ </details> ### 📄 Description ## Linked issue Closes #7969 Builds on #7972, which landed in `staging` as `e97c52fed4d1f931a911967474548d3cbb16a2f4`. This PR contains the remaining alternatives feature. ## Why this change Authors need different card details in different chats without duplicating an entire Character or Persona or changing the base card everywhere. ## What changed - Added `+ Add Alternative Field` under all seven Card fields in both editors. Each alternative starts as a copy, has its own text and wand, and can target zero, one, or many eligible chats. Its wand uses the alternative's text as the seed and the other card fields as references. There is no arbitrary alternative-count cap. - A chat uses one alternative per field; selecting it on another alternative moves that assignment. Empty text intentionally clears that field. Deleting requires confirmation. All edits use the existing editor save/save-on-leave lifecycle. - Applied immutable, membership-checked card projections to chat-bound prompt reads, including live generation, preview/retry, macros, supported group and Game roles, scene/memory/lorebook and chat media references. Summaries and summary alternatives remain metadata. Existing explicit scenario and image-appearance overrides retain their normal priority. - Preserved alternatives through persistence and version restore. Card exports/imports, Character/Persona conversions, duplication and Bot Browser imports as Persona keep alternative text but clear chat assignments; full profile backups retain their installation state. Empty alternative text is preserved during import. Background schedule renewal writes only schedule/status fields so projected text cannot replace the base card. Mari persona creation, reads and review restoration preserve the alternatives JSON storage contract. - Kept asynchronous generation tied to its target: later typing in that alternative and deletion are protected, while editing a neighboring base field preserves that edit and still accepts the generated alternative. - Added localized help, confirmations, accessibility text, refreshed eligible-chat pickers, both user guides, and retained API/prompt/browser regression coverage. Documentation translations are tracked in #7975. ## Hosted review The [full Dottore examination](https://github.com/Pasta-Devs/Marinara-Engine/actions/runs/39652859395) completed on `ddb51c9b4` against landed F1: all three packets scouted, seven candidates judged, zero unverified/failed/capped, $2.896 within the then-approved $3 limit. One code bundle was truncated; the walkthrough's visibility limitations remain disclosed. Subsequent genuine incremental examinations on [`a828a23ad`](https://github.com/Pasta-Devs/Marinara-Engine/actions/runs/39660068870) and [`ec4854880`](https://github.com/Pasta-Devs/Marinara-Engine/actions/runs/39662504260) recorded their exact SHAs without hitting the cap. Valid findings were repaired; source-based dispositions are in their review threads. The final repair `48c06a9fa` preserves portable export content by clearing chat assignments **before** checking array-level assignment conflicts. Both Character export builders reuse one local helper: strict unassignment first, then a fallback only for `ZodError` from malformed stored data. Unexpected errors are rethrown. The first export correction put normalization before unassignment; the next review and an actual failing API regression exposed that ordering mistake. The expanded proof now covers decoded and serialized conflicts, padded prose, empty overrides, malformed entries, null, object, duplicate-ID and absent/empty states in individual downloads and mixed ZIPs. No duplicate-ID salvage or rekeying is introduced; invalid stored shapes retain the declared fail-closed policy. Strict imports and direct saves remain unchanged. Other resolved review points: - Portable imports validate entries, clear foreign selections, then validate final ID uniqueness. Malformed rows and duplicate IDs fail explicitly without partial card creation; valid text and empty values survive conflicting foreign assignments. Compatible imports retain their existing HTTP200 `success:false` failure transport. - Availability headers distinguish loading and unknown states. **Active in** counts eligible chats; dormant saved IDs are preserved and resume with membership, as documented. The reported unsaved-card loading path is unreachable because both creation modals save before opening editors, which mount only behind truthy detail IDs; [the caller trace is documented](https://github.com/Pasta-Devs/Marinara-Engine/pull/7973#discussion_r4341029622). - Projection failures keep the raw row and emit rate-limited metadata-only debug diagnostics without original exception text or card prose. Schedule writes patch only status/schedule into base extensions; normal editor exits use the save gate, while `leaveWithoutSaving` follows successful deletion. The [final incremental examination](https://github.com/Pasta-Devs/Marinara-Engine/actions/runs/39664656071) completed on exact `48c06a9fa` from recorded `ec4854880`: $0.444, 22 model calls, zero unverified/failed/capped. It explicitly verified the assignment-ordering correction. Its sole reported finding requested the already-declined duplicate-ID salvage policy, which existed unchanged at the parent; [the source-based disposition and actual nine-shape API/ZIP proof are recorded](https://github.com/Pasta-Devs/Marinara-Engine/pull/7973#discussion_r4341326956). All review threads are resolved. This records a reported finding and its rejection, rather than claiming a finding-free hosted review. All eight required checks passed on the final head, and every review thread was resolved before the locked-head merge into `staging` as `73ee30f41b58c0aff8f1baaceb7abfbcf0a9a7a3`. The source and merge commits are verified ancestors of `origin/staging`. Post-merge pipelines are separate proof and were still starting at the delivery check. After delivery, the maintainer disabled the estimated spend cap by setting `DOTTORE_COST_LIMIT_USD=0`; the figures above record the earlier token-price estimates. ## Validation - [ ] `pnpm check` passes locally - [ ] Container (Docker / Podman) built and ran without issue - [ ] Ran the app, clicked through the changes manually - [ ] Checked edge cases (light + dark mode, mobile viewport, empty states, error paths) - [ ] Above manual verification completed (describe below) - [ ] Read and followed `CONTRIBUTING.md` ### Automated evidence - Full `pnpm check`: passed on final export repair `48c06a9facf5632f1dd433a88af4f99240ed043f`, including localization, formatting, types/lint, E2E types and production builds. The current alternatives-only diff is 52 files, +2055/−136. No new config, provider/model, version or installer changes are part of the feature repair. - Hosted complete Node suite: [963/963 passed](https://github.com/Pasta-Devs/Marinara-Engine/actions/runs/39664635485/job/119446565456) on final head `48c06a9facf5632f1dd433a88af4f99240ed043f`, with all ten [platform artifact jobs](https://github.com/Pasta-Devs/Marinara-Engine/actions/runs/39664635506) passing on their first attempt and all eight required status contexts successful. Native Windows includes installer prerequisite/integrity controls and Ctrl+C/graceful shutdown. No reruns were needed. - Final export repair: the retained portable-import regression passes on `48c06a9fa`, including native/compatible individual downloads and complete mixed ZIP archives with healthy, conflicting-assignment and malformed stored cards. Valid prose, empty overrides, cleared assignments and exact raw source rows are checked; all strict malformed-import assertions remain. The existing native-export memory regression also passed with a 128 MB heap limit (119 MB measured peak heap). - Portable import and projection-diagnostic regressions: failing-before/passing-after proof covers native Character/Persona and compatible imports, legacy serialized arrays, foreign conflicts, raw whitespace and empty values, malformed input/duplicate-ID rejection without partial writes, unchanged source cards, private debug fields, repeat suppression, raw-row fallback and valid scoped projection. - Availability browser regression: 6/6 passed on the repair across desktop Chromium, mobile Chromium and mobile WebKit. Real persisted assignments survive held/failed eligible-chat requests, an actual base-field save while dormant, and membership restoration. Baseline API-loading badges failed before the UI correction. Initial post-fix attempts exposed fixture sequencing (opening the picker refetches) and a disabled Save with no edit; preserved unchanged replays reproduced those test errors. The final fixture waits for that response and verifies a real saved base edit before checking the preserved assignment. Assertions and timeouts were not weakened. - Desktop shell smoke: 7/7 passed on the repair; all isolated browser ports closed. All three `pnpm regression:prompt` suites and five direct regressions (portable import, private projection diagnostics, alternatives API/prompt, schedule generation, and decoded Persona/identity reads) passed on exact `a828a23ad`. - Mari durability regression: passed at preceding head `fe4ff9519`. Creation failures were reproduced before the defaults/JSON-column fix; retained proof covers preview, apply, decoded reads, serialized storage and update restoration. F1 semantic summary/dialogue creation and updates, explicit empty/whitespace clearing, preserved trimming and omitted/non-string inputs are covered without changing other Persona fields. Every clearing shape reseeds the field and reads its own before/after state. - Actual alternatives API/assembled-prompt and Game Experience/provider-prompt regressions: passed at `6db44ca19`, covering base/other-chat isolation, empty overrides, metadata summaries, supported entity roles, persistence/restore, portable cards and Game dialogue macros. - Persona dialogue regression: passed at `6db44ca19`, including 54 actual Peek requests across XML/Markdown/plain wrapping. It checks stochastic macros, final preset variables, Unicode case transformations including capital ẞ, disabled sections/groups, selected and unselected choices, false conditionals, complete quoted examples and partial first-line collisions. Complete existing examples avoid a duplicate fallback; a partial first line still receives the complete fallback. Schedule-generation and Game character-sheet regressions passed during earlier integration; schedule preservation and missed Game scopes have failing-before/passing-after provider/API proof. - Assembler macro-budget regression: passed at `6db44ca19`. The cross-section budget regression was reproduced before its repair. More than 2,000 tracked expansions across independent sections now resolve with deferral both off and on; variable values and fallback summaries keep their own allowance, the Persona example observer remains active, and nested expansions retain the existing runaway limit. - Focused alternative-generation browser cases: 6/6 passed at `db739d111`, covering both editors across desktop Chromium, mobile Chromium and mobile WebKit. They verify neighboring base edits survive while target typing and deletion remain protected. - Bot Browser PNG-to-Persona import cases: 6/6 passed at `19b35ea97`, using real Persona POST/GET requests. Both authored/absent-summary fixtures retain alternative text and empty values and clear foreign chat assignments. The missing payload had a failing-before proof. Shell smoke: 7/7 passed after that correction; client lint and E2E types passed. - Broader alternatives browser suite: 12/12 passed at the earlier `2031ca907` head, with 12 regenerated and inspected desktop/mobile dark/light screenshots. - Local CodeRabbit reviewed the implementation and its corrections. Valid findings were fixed, including duplicate fallback, repeated chat reads, committed draft refs and help copy. Latest incremental reviews of portable Persona import and the alternative neighboring-edit proof completed with zero findings. Independent review also reproduced and fixed schedule preservation and Game scope defects. A fresh independent source audit found no new defect in the repair. The repair local review suggested warning-level projection logs; debug is intentional for this recovered malformed-legacy path and matches the hosted review contract. This does not claim zero reported findings for the feature as a whole. The prior two-file export repair received a completed local review with zero findings on `ec4854880`; its missed ordering case was subsequently caught by hosted review and added to the regression matrix. The final ordering repair received a completed two-file local review with zero findings on `48c06a9fa`. ### Manual verification notes - Manually verify alternative prose quality with a configured paid/real model provider. Browser wand responses are fixtures; public server routes and effective prompt payloads are tested offline, without paid-model prose validation. - Manually verify on physical Android and iOS devices. Desktop and mobile browser emulation are recorded separately. - No local container build was performed for this editor feature. ## Docs and release impact - [ ] No docs changes needed - [ ] Updated docs as needed - [ ] Translated docs updated, or a follow-up issue opened - [ ] Version/release files updated, if needed English guides are included; #7975 tracks every translated documentation pack. No version bump or release changelog edit is part of this feature. ## UI evidence (if applicable) Retained Playwright coverage exercises both editors, all seven add controls, eligible and ineligible chats, zero/multiple assignments, moving a chat between alternatives, empty replacement, save/reopen, confirmed/cancelled deletion, eligibility refresh, generation and draft protection, with desktop/mobile dark/light screenshots. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-10-24 04:09:50 +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#8034
No description provided.