[PR #8010] fix(conversation): plain video history notes, notes in Peek Prompt, and group video requests #8056

Open
opened 2026-10-24 04:10:01 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/Pasta-Devs/Marinara-Engine/pull/8010
Author: @JamesMowery
Created: 10/21/2026
Status: 🔄 Open

Base: staging ← Head: fix/conversation-video-notes


📝 Commits (10+)

  • daf2bad fix(conversation): plainer video notes, notes in Peek Prompt, group videos
  • c18c513 fix(conversation): nested JSON video prompts keep their words in the history note
  • 5d6fce4 fix(conversation): the video note leaves out negative prompts and reads JSON inside a string
  • e83d045 fix(conversation): the video note drops every bracketed cue and keeps prose labels
  • 86ef1b6 fix(conversation): an unclosed cue's words leave the video note too
  • be5018d fix(conversation): an unclosed cue in one JSON field leaves the next field in the note
  • e86902d fix(conversation): the video note's cue strip runs in one pass, and catches plain labels
  • 94c9cc2 refactor(conversation): the video note relies on videoPromptWords leaving no bracket
  • a7cd84a fix(conversation): strip technical labels in any case from video notes
  • 8c00a12 fix(conversation): more technical label words in video notes

📊 Changes

7 files changed (+429 additions, -27 deletions)

View changed files

📝 packages/server/src/routes/generate.routes.ts (+13 -13)
📝 packages/server/src/routes/generate/conversation-prompt-formatting.ts (+152 -4)
📝 packages/server/src/routes/generate/dry-run-route.ts (+20 -8)
📝 packages/server/src/routes/generate/generate-route-utils.ts (+21 -0)
📝 packages/server/src/services/generation/conversation-selfie-command-runtime.ts (+1 -1)
📝 scripts/regressions/convo-video-command.regression.ts (+213 -1)
📝 scripts/regressions/prompt.regression.ts (+9 -0)

📄 Description

Important

Contributions target staging. Only SpicyMarinara may promote this repository's staging branch or a same-repository hotfix/* branch to main.
Outside and first-time contributors also require an approving review from SpicyMarinara.

Linked issue

Closes #8009
Part of #7545 (a follow-up). @SpicyMarinara

Why this change

  • The "sent a video message" note in a Conversation's history carried the raw video prompt. With Video Prompting Instructions that ask for a technical format (JSON, field labels, [Shot 1] …), characters copied that format into their own [video: …] tags, whose inner brackets then broke the tag: it showed as text and made no clip.
  • Peek Prompt left those notes out, so it didn't show what the model is sent.
  • A "group video" wasn't a group request, so its selfie first frame showed only the sender.

What changed

  • The video history note keeps only the words of a prompt in a technical format (conversation-prompt-formatting.ts): JSON fields are read one per line (nested objects and JSON inside a string too, negative prompts left out), field labels are stripped where they start a line (camera:, shot_1:, OVERALL_SOUNDSCAPE:; a name like Ana: or a link stays), and every bracketed cue ([Shot 1: close-up], [cut to window], nested ones, an unclosed one through the end of its line or field) goes in one pass (stripBracketedCues), so the note holds exactly one bracket pair.
  • Peek Prompt adds the same photo, selfie and video notes to assistant messages as generation does, through one shared appendSentMediaNotes used by both (generate.routes.ts, dry-run-route.ts).
  • "group video/clip" and "video/clip … together/everyone" count as a group request in GROUP_SELFIE_REQUEST_RE, like group selfies.
  • Independent of #7993, which makes the [video] tag reader itself tolerate brackets; the two touch some of the same files, so whichever merges second may need a small rebase.

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 runs on 2026-10-21 on staging 5e7468ab4, Node 24.21.0:

  • pnpm check: passes. Its one lint warning, in HomeProfessorMariChat.tsx, is not from this PR.
  • pnpm localization:check: passes.
  • convo-video-command: the history note for a JSON prompt, a labelled [Shot 1] prompt and a nested-JSON shot list reads as plain words; the shared appendSentMediaNotes that generation and Peek Prompt both use adds video and selfie notes; "Send me a group video of you two!" names both characters for the selfie first frame. These check the helpers directly, not Peek Prompt's route. prompt: its source checks follow the shared note helper.
  • Full pnpm regression on c18c51381 (before the CodeRabbit fix): 960/960 pass. On 5d6fce492: server type check, convo-video-command and prompt pass.
  • Local CodeRabbit (CLI) on the branch: 1 finding, fixed in 5d6fce492: a negative_prompt read in the note as if the clip showed it, and JSON kept inside a string field leaked its syntax. Negative-prompt keys are skipped and JSON inside a string is read as JSON; convo-video-command covers both and fails without the fix. A review of that commit: 0 findings.
  • Not run: pnpm smoke:ui and pnpm regression:ui (server-only change).

Manual verification notes

  • Manually verify that after a video message whose connection's instructions ask for JSON or a shot list, Peek Prompt shows a plain "sent a video message" note with no JSON, labels or [Shot N].
  • Manually verify Peek Prompt shows selfie and video notes on the messages that sent them.
  • Manually verify that in a group Conversation with First frame on a new selfie, "send a group video" makes a selfie with everyone.

Docs and release impact

  • No docs changes needed
  • Updated docs (README / CONTRIBUTING / android/README) as needed
  • Translated docs on the docs-i18n branch updated to match, or a [docs-i18n] follow-up issue opened (see CONTRIBUTING.md § Translated documentation)
  • Version/release files updated (only if this PR includes a version bump)

UI evidence (if applicable)

No UI changes; Peek Prompt shows notes it already showed for real generations.

🤖 Generated with Claude Code


🔄 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/8010 **Author:** [@JamesMowery](https://github.com/JamesMowery) **Created:** 10/21/2026 **Status:** 🔄 Open **Base:** `staging` ← **Head:** `fix/conversation-video-notes` --- ### 📝 Commits (10+) - [`daf2bad`](https://github.com/Pasta-Devs/Marinara-Engine/commit/daf2bad7fb77c7e883767a738da7987afcd962b9) fix(conversation): plainer video notes, notes in Peek Prompt, group videos - [`c18c513`](https://github.com/Pasta-Devs/Marinara-Engine/commit/c18c513811f73e79c34816d7f697685e084ee3ff) fix(conversation): nested JSON video prompts keep their words in the history note - [`5d6fce4`](https://github.com/Pasta-Devs/Marinara-Engine/commit/5d6fce492193267013836576a69133c29728fd09) fix(conversation): the video note leaves out negative prompts and reads JSON inside a string - [`e83d045`](https://github.com/Pasta-Devs/Marinara-Engine/commit/e83d045dc7d1cb3b556b7ac38069e50cb4edff19) fix(conversation): the video note drops every bracketed cue and keeps prose labels - [`86ef1b6`](https://github.com/Pasta-Devs/Marinara-Engine/commit/86ef1b62504bf9b8ad28f8c97913e6ed433e1fc4) fix(conversation): an unclosed cue's words leave the video note too - [`be5018d`](https://github.com/Pasta-Devs/Marinara-Engine/commit/be5018df05c298f7b8ec9309dd6b904823e3d5e0) fix(conversation): an unclosed cue in one JSON field leaves the next field in the note - [`e86902d`](https://github.com/Pasta-Devs/Marinara-Engine/commit/e86902dcc3e0345004d365deb063e79aba0af9c6) fix(conversation): the video note's cue strip runs in one pass, and catches plain labels - [`94c9cc2`](https://github.com/Pasta-Devs/Marinara-Engine/commit/94c9cc21c98ef96c523cf2ae488c123748560396) refactor(conversation): the video note relies on videoPromptWords leaving no bracket - [`a7cd84a`](https://github.com/Pasta-Devs/Marinara-Engine/commit/a7cd84a8208eccc16da40f308c1c97a912413318) fix(conversation): strip technical labels in any case from video notes - [`8c00a12`](https://github.com/Pasta-Devs/Marinara-Engine/commit/8c00a12e8171519412d57e784a63e6bf6ce7e744) fix(conversation): more technical label words in video notes ### 📊 Changes **7 files changed** (+429 additions, -27 deletions) <details> <summary>View changed files</summary> 📝 `packages/server/src/routes/generate.routes.ts` (+13 -13) 📝 `packages/server/src/routes/generate/conversation-prompt-formatting.ts` (+152 -4) 📝 `packages/server/src/routes/generate/dry-run-route.ts` (+20 -8) 📝 `packages/server/src/routes/generate/generate-route-utils.ts` (+21 -0) 📝 `packages/server/src/services/generation/conversation-selfie-command-runtime.ts` (+1 -1) 📝 `scripts/regressions/convo-video-command.regression.ts` (+213 -1) 📝 `scripts/regressions/prompt.regression.ts` (+9 -0) </details> ### 📄 Description > [!IMPORTANT] > Contributions target `staging`. Only `SpicyMarinara` may promote this repository's `staging` branch or a same-repository `hotfix/*` branch to `main`. > Outside and first-time contributors also require an approving review from `SpicyMarinara`. <!-- See CONTRIBUTING.md § Branches. --> ## Linked issue Closes #8009 Part of #7545 (a follow-up). @SpicyMarinara ## Why this change - The "sent a video message" note in a Conversation's history carried the raw video prompt. With **Video Prompting Instructions** that ask for a technical format (JSON, field labels, `[Shot 1] …`), characters copied that format into their own `[video: …]` tags, whose inner brackets then broke the tag: it showed as text and made no clip. - Peek Prompt left those notes out, so it didn't show what the model is sent. - A "group video" wasn't a group request, so its selfie first frame showed only the sender. ## What changed - The video history note keeps only the words of a prompt in a technical format (`conversation-prompt-formatting.ts`): JSON fields are read one per line (nested objects and JSON inside a string too, negative prompts left out), field labels are stripped where they start a line (`camera:`, `shot_1:`, `OVERALL_SOUNDSCAPE:`; a name like `Ana:` or a link stays), and every bracketed cue (`[Shot 1: close-up]`, `[cut to window]`, nested ones, an unclosed one through the end of its line or field) goes in one pass (`stripBracketedCues`), so the note holds exactly one bracket pair. - Peek Prompt adds the same photo, selfie and video notes to assistant messages as generation does, through one shared `appendSentMediaNotes` used by both (`generate.routes.ts`, `dry-run-route.ts`). - "group video/clip" and "video/clip … together/everyone" count as a group request in `GROUP_SELFIE_REQUEST_RE`, like group selfies. - Independent of #7993, which makes the `[video]` tag reader itself tolerate brackets; the two touch some of the same files, so whichever merges second may need a small rebase. ## Validation <!-- Required: include commands run and/or manual checks performed --> - [x] `pnpm check` passes locally - [x] Container (Docker / Podman) built and ran without issue - [x] Ran the app, clicked through the changes manually - [x] Checked edge cases (light + dark mode, mobile viewport, empty states, error paths) - [x] Above manual verification completed (describe below) - [x] Read and followed `CONTRIBUTING.md` Automated runs on 2026-10-21 on `staging` `5e7468ab4`, Node 24.21.0: - `pnpm check`: passes. Its one lint warning, in `HomeProfessorMariChat.tsx`, is not from this PR. - `pnpm localization:check`: passes. - `convo-video-command`: the history note for a JSON prompt, a labelled `[Shot 1]` prompt and a nested-JSON shot list reads as plain words; the shared `appendSentMediaNotes` that generation and Peek Prompt both use adds video and selfie notes; "Send me a group video of you two!" names both characters for the selfie first frame. These check the helpers directly, not Peek Prompt's route. `prompt`: its source checks follow the shared note helper. - Full `pnpm regression` on `c18c51381` (before the CodeRabbit fix): 960/960 pass. On `5d6fce492`: server type check, `convo-video-command` and `prompt` pass. - Local CodeRabbit (CLI) on the branch: 1 finding, fixed in `5d6fce492`: a `negative_prompt` read in the note as if the clip showed it, and JSON kept inside a string field leaked its syntax. Negative-prompt keys are skipped and JSON inside a string is read as JSON; `convo-video-command` covers both and fails without the fix. A review of that commit: 0 findings. - Not run: `pnpm smoke:ui` and `pnpm regression:ui` (server-only change). ### Manual verification notes - Manually verify that after a video message whose connection's instructions ask for JSON or a shot list, Peek Prompt shows a plain "sent a video message" note with no JSON, labels or `[Shot N]`. - Manually verify Peek Prompt shows selfie and video notes on the messages that sent them. - Manually verify that in a group Conversation with First frame on a new selfie, "send a group video" makes a selfie with everyone. ## Docs and release impact - [x] No docs changes needed - [ ] Updated docs (README / CONTRIBUTING / android/README) as needed - [ ] Translated docs on the `docs-i18n` branch updated to match, or a `[docs-i18n]` follow-up issue opened (see CONTRIBUTING.md § Translated documentation) - [ ] Version/release files updated (only if this PR includes a version bump) ## UI evidence (if applicable) No UI changes; Peek Prompt shows notes it already showed for real generations. 🤖 Generated with [Claude Code](https://claude.com/claude-code) --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
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#8056
No description provided.