How to Persist and Resume Video Editing Sessions Using project.md
The project.md file acts as the built-in memory system for the video-use skill, automatically storing session summaries in Markdown format that enable seamless resumption of video editing work across multiple sessions.
The video-use repository from browser-use provides a lightweight mechanism to persist and resume video editing sessions through a simple file-based persistence layer. By maintaining a chronological journal of editing decisions, strategies, and outstanding tasks in <videos_dir>/edit/project.md, the system creates a human-readable audit trail that integrates naturally with version control workflows. This approach eliminates external database dependencies while ensuring editing context survives restarts and collaborators can pick up work seamlessly.
Understanding the project.md Architecture
The persistence system centers on a single Markdown file that lives inside your dedicated edit directory alongside outputs from helper scripts.
File Location and Initialization
When you initiate a video editing session, the skill looks for project.md inside <edit>/ (the edit directory located within your configured <videos_dir>/edit/ folder). According to SKILL.md, this file is created automatically upon the completion of your first editing session, not before【https://github.com/browser-use/video-use/blob/main/SKILL.md#L45-L46】. The path resolves alongside outputs from render.py and grade.py, ensuring all session artifacts exist in a single location【https://github.com/browser-use/video-use/blob/main/SKILL.md#L38-L56】.
Session Logging Template
Each session entry follows a fixed Markdown template that structures institutional knowledge into four categories. As defined in the source documentation, the template appears as:
## Session N — YYYY‑MM‑DD
**Strategy:** <one‑paragraph description of the approach>
**Decisions:** <take choices, cuts, grades, animations + why>
**Reasoning log:** <one‑line rationale for non‑obvious decisions>
**Outstanding:** <deferred items>
This structure is appended to the file after each confirmed final render, with the session number incrementing automatically to create a chronological journal【https://github.com/browser-use/video-use/blob/main/SKILL.md#L291-L303】.
Resuming Previous Sessions
The video-use skill implements automatic session detection that surfaces previous work immediately upon startup without requiring manual file parsing.
Startup Resume Logic
When launching a new session, the skill checks for the existence of project.md. If present, it reads the file, extracts the most recent section following the ## Session heading, and generates a one-sentence summary of the previous work before prompting the user to continue【https://github.com/browser-use/video-use/blob/main/SKILL.md#L291-L304】. This "resume point" allows you to pick up exactly where you left off, whether the interruption lasted minutes or weeks, using only standard file I/O operations.
Persisting Session Data
After confirming your editing plan and producing the final render, the skill automatically writes session context to preserve it for future reference.
Appending New Sessions
The persistence mechanism triggers upon render completion, appending rather than overwriting to maintain a complete historical record. The skill writes the strategy, decisions, reasoning, and outstanding items using the template described above, ensuring the log grows organically with each editing round【https://github.com/browser-use/video-use/blob/main/SKILL.md#L291-L303】.
Programmatically Interacting with project.md
Developers can interact with project.md directly using standard file operations, enabling custom tooling and automation workflows that mirror the skill's internal behavior.
Reading the Latest Session Summary
To extract the most recent session strategy programmatically, parse the file for the last ## Session heading and extract the Strategy line:
import pathlib
import re
def latest_summary(edit_dir: pathlib.Path) -> str:
"""Return the one‑sentence summary of the most recent session."""
project_md = edit_dir / "project.md"
if not project_md.is_file():
return "" # No previous history
# Grab the last “## Session” block
blocks = project_md.read_text().split("\n## Session")
if len(blocks) < 2:
return ""
last = blocks[-1] # The newest block
# Extract the first line that starts with "**Strategy:**"
m = re.search(r"\*\*Strategy:\*\*\s*(.+)", last)
return m.group(1).strip() if m else ""
# Example usage
edit_dir = pathlib.Path("/my/videos/edit")
print("Previous session:", latest_summary(edit_dir))
This approach mirrors the skill's startup behavior, using regex to capture the strategy description that summarizes the previous editing approach.
Appending a New Session Record
To manually append a session record while maintaining the correct numbering and formatting:
import pathlib
from datetime import date
def append_session(edit_dir: pathlib.Path,
strategy: str,
decisions: str,
reasoning: str,
outstanding: str) -> None:
"""Add a new Markdown block to project.md."""
project_md = edit_dir / "project.md"
session_num = 1
if project_md.is_file():
# Count existing "## Session" headings to generate the next number
session_num = sum(1 for line in project_md.read_text().splitlines()
if line.startswith("## Session")) + 1
today = date.today().isoformat()
block = f"""\
## Session {session_num} — {today}
**Strategy:** {strategy}
**Decisions:** {decisions}
**Reasoning log:** {reasoning}
**Outstanding:** {outstanding}
"""
# Ensure a trailing newline for readability
existing = project_md.read_text() if project_md.is_file() else ""
project_md.write_text(existing + "\n" + block)
# Example usage
edit_dir = pathlib.Path("/my/videos/edit")
append_session(
edit_dir,
strategy="Cut the intro to 10s, add warm cinematic grade, overlay title animation.",
decisions="Chose take C0103 for intro, kept beat-sync cuts, applied warm_cinematic preset.",
reasoning="Take C0103 had the clearest voice and no filler.",
outstanding="Add background music after next review."
)
This helper preserves the exact Markdown template the skill expects, automatically incrementing session numbers and maintaining file integrity.
Quick Shell Inspection
For rapid command-line inspection of the previous session without opening a text editor:
# Show the last “## Session …” block (works on any POSIX shell)
awk '/^## Session/{p=1} p && /^$/{exit} {print}' edit/project.md | tail -n +2
This awk command identifies the latest session heading, prints until the first blank line, and skips the heading itself to display only the content.
Key Repository Files
Several files in the browser-use/video-use repository define the project.md lifecycle:
SKILL.md(lines 45-46, 291-304): Documents the persistence mechanism, template structure, and resume logic【https://github.com/browser-use/video-use/blob/main/SKILL.md#L45-L46】【https://github.com/browser-use/video-use/blob/main/SKILL.md#L291-L304】.gitignore(line 60): Excludesproject.mdfrom version control by default, appropriate for user-generated session logs【https://github.com/browser-use/video-use/blob/main/.gitignore#L60】
Summary
-
project.mdserves as the video-use skill's persistent memory, stored in<videos_dir>/edit/project.mdalongside render outputs -
Automatic resumption occurs at startup when the skill detects existing session history and surfaces a one-sentence summary of previous work from the most recent
## Sessionblock -
Structured logging uses a four-field Markdown template (Strategy, Decisions, Reasoning log, Outstanding) appended after each final render confirmation
-
Plain-text architecture enables version control compatibility, human readability, and programmatic access without database dependencies or binary serialization
-
Integration points exist in
SKILL.md(lines 291-304) for the resume and persistence logic, utilizing standard file I/O operations
Frequently Asked Questions
Where is the project.md file located in the video-use repository?
The project.md file resides in your configured videos directory under the edit subdirectory, specifically at <videos_dir>/edit/project.md. According to the implementation in SKILL.md, this path aligns with other editing outputs like those generated by render.py and grade.py, ensuring all session artifacts exist in a single location【https://github.com/browser-use/video-use/blob/main/SKILL.md#L45-L46】.
How does the video-use skill know to resume a previous session?
At startup, the skill checks for the existence of project.md in the edit directory. If found, it parses the file to locate the most recent ## Session block, extracts the strategy and decisions, and presents a one-sentence summary to the user before asking whether to continue—this logic is documented at lines 291-304 of SKILL.md【https://github.com/browser-use/video-use/blob/main/SKILL.md#L291-L304】.
What information gets saved when persisting a video editing session?
Each session appends a Markdown section containing four fields: Strategy (the overall editing approach), Decisions (specific take choices, cuts, and grades), Reasoning log (rationale for non-obvious choices), and Outstanding (deferred tasks). This template is written after the final render is confirmed, creating a chronological journal of the editing process【https://github.com/browser-use/video-use/blob/main/SKILL.md#L291-L303】.
Can project.md be tracked in version control?
While technically possible because it uses plain Markdown without binary data, the repository's .gitignore file explicitly excludes project.md by default at line 60. This is recommended because the file contains user-generated editing decisions and session state that changes frequently, though you can manually enable tracking if your workflow requires collaborative session history【https://github.com/browser-use/video-use/blob/main/.gitignore#L60】.
Have a question about this repo?
These articles cover the highlights, but your codebase questions are specific. Give your agent direct access to the source. Share this with your agent to get started:
curl -s "https://instagit.com/install.md" Maintain an open-source project? Get it listed too →