You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
OpenChrome already journals tool calls and exposes checkpoint/session continuity primitives. The missing layer is a compact, caller-facing handoff summary that helps an LLM resume after context compaction, process restart, or a long-running browser session without redoing completed work.
src/tools/journal.ts — journal-facing MCP surface, using the current journal-facing MCP surface; if absent, extend src/tools/journal.ts or add it in this issue.
src/tools/checkpoint.ts — task progress and tab state persistence.
src/mcp-server.ts — _sessionContext and hint injection into tool results.
Add a compact resume/handoff summary surface over existing journal/checkpoint data so host agents can recover state without OpenChrome owning the agent lifecycle.
Non-goals
Do not implement a planner, memory agent, or autonomous retry loop.
Do not store raw sensitive page payloads in the summary.
Expose a summary through the existing journal/checkpoint tool surface, by extending the existing journal/checkpoint tool surface. Preferred order:
oc_journal action: handoff_summary
oc_checkpoint action: handoff
a small new read-only tool only if the current tool contracts make extension awkward
The output should be structured JSON with:
period: start/end timestamps and source checkpoint id when supplied
currentState: latest known session id, tab ids, URL/title, tab health when present in persisted artifacts; otherwise return an explicit unavailable reason
completedMilestones: condensed journal milestones since checkpoint or timestamp
recentFailures: failed tool calls grouped by tool/signature/error class
stuckSignals: recent ProgressTracker/HintEngine stuck or stalling hints when present in persisted artifacts; otherwise return an explicit unavailable reason
pendingSteps: from checkpoint task state when present
recommendedRecoveryOptions: non-authoritative options such as refresh DOM snapshot, choose a different selector, reload page, ask user for auth/CAPTCHA
limits: explicit statement when data is unavailable, redacted, stale, or outside retention
Implementation checkpoints
Identify the current journal MCP surface and choose the smallest compatible action name.
Build the read-only summary generator over TaskJournal and checkpoint metadata.
Add deterministic redaction, grouping, scoping, and size caps.
Add empty-state and restart-persistence tests.
Add the real-server E2E scenario and document the exact output schema.
Acceptance criteria
Summary generation is read-only and safe to call frequently.
Sensitive args remain redacted using the journal redaction rules.
The summary remains small and bounded; large tool args/results are summarized, not embedded.
The summary can be scoped by since, checkpointId, and/or sessionId where existing data permits.
Empty/no-journal states return a useful empty summary, not an error.
The response clearly distinguishes evidence from recommendations.
Tests
Add tests covering:
no journal/checkpoint data returns an empty but valid summary.
milestones are included and ordered.
failures are grouped without leaking redacted args.
scoping by checkpoint or timestamp excludes older entries.
output remains under a deterministic size cap for a large synthetic journal.
Real OpenChrome verification after implementation
Add an E2E scenario using a real OpenChrome MCP server:
Start OpenChrome with a temp home/profile.
Navigate to a local fixture page.
Perform at least one successful read/action and one intentionally failing call, such as find for a missing selector or an interaction with a stale/missing ref.
Save an oc_checkpoint with completed/pending steps.
Call the handoff summary action.
Assert the summary contains:
latest URL/title or tab id evidence,
the completed milestone,
the failed call grouped under recentFailures,
redacted sensitive fields if any were included in tool args,
a bounded recommendation list that does not claim automatic recovery occurred.
Restart OpenChrome with the same temp home and assert the handoff summary can still be produced from persisted artifacts.
Suggested command evidence:
New targeted journal/handoff unit tests.
npm run test:e2e -- --runTestsByPath tests/e2e/scenarios/journal-handoff.e2e.ts.
Direction-fit review notes
This is directionally sound only as a read-only summary layer. It should help host LLMs reduce wandering after compaction but must not become a second task ledger or planner. If #855 or #873 already implements equivalent fields by the time this is picked up, close this as duplicate or narrow it to journal-derived failure/stuck summarization.
Curated scope, overlap handling, and verification checklist
Scope classification
Canonical lane: compact caller-facing resume/handoff summary over journal/checkpoint data.
Primary deliverable: resume summary surface that helps a host recover after context compaction/restart without OpenChrome owning lifecycle.
Add or extend a journal-facing MCP surface for compact resume/handoff summary with latest goal/context, completed work, current page/tab, blockers, and evidence links.
Derive summaries from existing journal/checkpoint data with redaction and strict size bounds.
Include source entry IDs/timestamps so the summary remains auditable.
Add tests for normal summary, empty journal, long journal truncation, redaction, restart/reload, and checkpoint linkage.
Document when hosts should request the summary before/after compaction.
Success criteria
A host can resume a long session using a compact summary without replaying the full journal.
The summary is bounded, redacted, and source-linked.
Missing journal/checkpoint data yields clear partial/empty diagnostics.
Background
OpenChrome already journals tool calls and exposes checkpoint/session continuity primitives. The missing layer is a compact, caller-facing handoff summary that helps an LLM resume after context compaction, process restart, or a long-running browser session without redoing completed work.
Relevant OpenChrome anchors:
src/journal/task-journal.ts— recent entries, milestones, summaries, redaction.src/tools/journal.ts— journal-facing MCP surface, using the current journal-facing MCP surface; if absent, extendsrc/tools/journal.tsor add it in this issue.src/tools/checkpoint.ts— task progress and tab state persistence.src/mcp-server.ts—_sessionContextand hint injection into tool results.Related issues to avoid duplicating:
oc_contextportable context handle.oc_task_ledgerpersistent async task table.Goal
Add a compact
resume/handoffsummary surface over existing journal/checkpoint data so host agents can recover state without OpenChrome owning the agent lifecycle.Non-goals
Proposed scope
Expose a summary through the existing journal/checkpoint tool surface, by extending the existing journal/checkpoint tool surface. Preferred order:
oc_journalaction:handoff_summaryoc_checkpointaction:handoffThe output should be structured JSON with:
period: start/end timestamps and source checkpoint id when suppliedcurrentState: latest known session id, tab ids, URL/title, tab health when present in persisted artifacts; otherwise return an explicitunavailablereasoncompletedMilestones: condensed journal milestones since checkpoint or timestamprecentFailures: failed tool calls grouped by tool/signature/error classstuckSignals: recent ProgressTracker/HintEngine stuck or stalling hints when present in persisted artifacts; otherwise return an explicitunavailablereasonpendingSteps: from checkpoint task state when presentrecommendedRecoveryOptions: non-authoritative options such as refresh DOM snapshot, choose a different selector, reload page, ask user for auth/CAPTCHAlimits: explicit statement when data is unavailable, redacted, stale, or outside retentionImplementation checkpoints
TaskJournaland checkpoint metadata.Acceptance criteria
since,checkpointId, and/orsessionIdwhere existing data permits.Tests
Add tests covering:
Real OpenChrome verification after implementation
Add an E2E scenario using a real OpenChrome MCP server:
findfor a missing selector or an interaction with a stale/missing ref.oc_checkpointwith completed/pending steps.recentFailures,Suggested command evidence:
npm run test:e2e -- --runTestsByPath tests/e2e/scenarios/journal-handoff.e2e.ts.Direction-fit review notes
This is directionally sound only as a read-only summary layer. It should help host LLMs reduce wandering after compaction but must not become a second task ledger or planner. If #855 or #873 already implements equivalent fields by the time this is picked up, close this as duplicate or narrow it to journal-derived failure/stuck summarization.
Curated scope, overlap handling, and verification checklist
Scope classification
feat/1027-journal-handoff). Continue there.Overlap and conflict resolution
oc_context: context handles can reference the summary, but this issue owns journal/checkpoint-derived resume summary.Implementation checklist
Success criteria
Post-merge OpenChrome live verification checklist