Skip to content

fix(knowledge): video-digest watch closes the slice before the corpus relayout can copy media #7177

Closed

Description

@kyle-sexton

Problem

watch-state.js close removes the slice's temp session (video, all frames). relayout-slice.js copies media/ and frames/all/ from that temp session, so on a closed slice only --no-media works. The script header says to run it before close, but the watch spine in plugins/knowledge/skills/video-digest/SKILL.md and Phase 9 of context/watch-pipeline.md never mention the relayout, so an agent following the phases closes first and loses the media.

Observed

A watch of yUuFvL1lK4k closed the slice and then hit this. Recovery meant re-running run-watch.js into a scratch work root and repointing run-state/watch.json tempSession at the regenerated dirs before relayout-slice.js --replace.

Suggested fix

Either add a corpus-relayout step before close in Phase 9 (and the checklist), or have close keep the temp session when a corpus target is configured. A one-line pointer is the smaller change.

Also seen: the templates/recommendations/README.md line Shards: research/findings/*.md fails the relayout link check as an unresolved path; research/findings/ passes.

🤖 Generated with Claude Code

Activity

  1. added
    needs-triage
    on Oct 11, 2026
  2. github-actions commented on Oct 11, 2026

    @github-actions
    Contributor

    Thanks for the detailed report and reproduction. Understood: watch-state.js close deletes the slice's temp session, but relayout-slice.js needs that session's media/ and frames/all/ to do a non---no-media relayout, and neither the video-digest SKILL.md watch spine nor Phase 9 of watch-pipeline.md calls out running the relayout before close, so following the documented phases in order loses the media. Your suggested fixes (add a pointer/step before close, or have close preserve the temp session when a corpus target is configured) both sound reasonable; a maintainer will decide which. The secondary note about templates/recommendations/README.md's Shards: research/findings/*.md line failing the relayout link check is also noted as a separate, smaller finding.

    Related but not a duplicate: #7034 (multi-video X post media selection in relayout, a different gap in the same area).

    Automated triage. A maintainer reviews it.

  3. removed
    needs-triage
    on Oct 12, 2026
  4. added theissue type on Oct 12, 2026
  5. kyle-sexton commented on Oct 13, 2026

    @kyle-sexton
    MemberAuthor

    Decision recorded. The owner approved applying independently verified recommendations (confirmed, low-risk set) on 2026-10-13.

    watch-state.js close deletes the temp session that relayout-slice.js copies media from, and neither SKILL.md nor Phase 9 of watch-pipeline.md mentions running the relayout before close. Still open on main, as is the 'Shards: research/findings/*.md' link-check failure.

    Verified by an independent fresh-context check (confirmed, risk low): gh issue view 7177 (open); output-contract.md:59-66 relayout command and 'Run it before close'; relayout-slice.js header:5-7 'Run it before close'; git grep relayout: no hit in SKILL.md or watch-pipeline.md; templates/recommendations/README.md:17 Shards line; gh pr list relayout: #7126 merged, nothing fixes this

    Admission to an agent lane stays with the work-class rules and owner ratification.

  6. kyle-sexton commented on Oct 18, 2026

    @kyle-sexton
    MemberAuthor

    Agent Brief

    Type: Bug
    Summary: Run the corpus relayout before closing a video-digest watch slice so media is not lost.

    Current behavior:
    Closing a watch slice removes its temp session (video and all frames). The corpus relayout copies media and frames from that temp session, so after close only no-media relayout works. The output contract and the relayout script say to run it before close, but the skill's watch spine, Phase 9 of the watch pipeline and the checklist never mention the relayout, so an agent closes first. Separately, the recommendations README template's Shards: research/findings/*.md line fails the relayout link check.

    Desired behavior:
    Phase 9 of the watch pipeline and the watch checklist template carry a relayout step before close whenever a corpus target is configured, and the skill's watch spine names it. The recommendations README template's Shards line uses a path the relayout link check resolves.

    Key interfaces:

    • The watch pipeline's Phase 9 step order.
    • The watch checklist template's rows.
    • The recommendations README template's Shards line.

    Acceptance criteria:

    • Phase 9 lists the relayout step before close.
    • The checklist template has a relayout row ordered before the close row.
    • The video-digest SKILL.md watch spine mentions the relayout before close.
    • The Shards line reads research/findings/ instead of research/findings/*.md.
    • scripts/run-test-file.sh passes on the checklist init test file.
    • CI's skill-quality passes on the PR (a PR check; this run does not run it).
    • scripts/check-changelog-fragments.sh passes.

    Out of scope:

    • Changing close to keep the temp session.
    • The relayout script itself.

    This was generated by AI during backlog shaping. Held, not admitted: this brief is drafted and checked, but the issue lane would stop on it today. It is admitted, by adding agent-ready, once the lane can run the skill-quality check scripts (Automation Lanes' PR #7912). Held under the owner's 2026-10-18 lane-narrowing course correction.

  7. added
    needs-human
    agent-ready
    and removed
    needs-human
    agent-ready
    on Oct 18, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    agent-ready

    Type

    Fields

    No fields configured for Bug.

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions