Skip to content

docs(skill): document oc_journal_compact cadence and pin round-trip stability#1444

Merged
shaun0927 merged 2 commits into
feat/1434-journal-compactfrom
feat/1434-compaction-cadence-docs
May 28, 2026
Merged

docs(skill): document oc_journal_compact cadence and pin round-trip stability#1444
shaun0927 merged 2 commits into
feat/1434-journal-compactfrom
feat/1434-compaction-cadence-docs

Conversation

@shaun0927
Copy link
Copy Markdown
Owner

@shaun0927 shaun0927 commented May 28, 2026

Summary

Stacked on #1442 (Part 1).

Test plan

  • Round-trip test 3/3 pass.

Review-pass changes

  • Added the sampling-unsupported test (asserts status:'unsupported_by_host' with no fabricated summary).
  • Softened the cadence table so the 20/50-step figures stay attributed to Webwright rather than implying an OpenChrome-measured benchmark (SSOT: OpenChrome as a host-neutral MCP browser harness #1359 P5).

Merge note: base branch is feat/1434-journal-compact (#1442). Landing this content on develop is gated on #1442, which is currently conflicting with develop.

Part 2 of #1434. Depends on #1442.

Co-Authored-By: Claude Opus 4.7 (1M context) noreply@anthropic.com

@chatgpt-codex-connector
Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.

…tability

Add docs/skills/trajectory-compaction.md describing recommended
compaction cadence (every 20–50 steps), strategy selection
(recent_k / checkpoint_only / sampling), and composition with the
LLM-free fast path (#1430 Part 2).

Add round-trip integration test that pins the lossy-but-stable
contract: two consecutive compactions over the same trajectory must
agree on open_assertions, last_checkpoint, and (for deterministic
strategies) the summary text. Without this gate, a future refactor of
the truncation logic could silently destabilise resume flows.

Part 2 of #1434.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@shaun0927 shaun0927 force-pushed the feat/1434-compaction-cadence-docs branch from 8abecc2 to 68e9a83 Compare May 28, 2026 13:56
@shaun0927
Copy link
Copy Markdown
Owner Author

Goal-review verdict — #1444

Intent vs SSOT (#1359)

  • Pillar A (MCP portability) + Pillar D (portable verified memory) — docs-only addition that pins the cadence guidance and locks the lossy-but-stable contract via a round-trip test. No tool surface change, no new host behavior; the doc explicitly states OpenChrome never falls back to a server-side LLM for the sampling strategy. Aligned with P2 (harness, not agent) and P4 (facts before decisions).

Code-level review

  • docs/skills/trajectory-compaction.md: cadence table is consistent with the empirical anchors in benchmark: episode budget shaper and early-stop using Webwright's marginal-utility curve #1428 (Webwright's "next 50 steps deliver only 3–4 additional accuracy points") and cross-links to docs/skills/llm-free-fast-path.md for composition.
  • tests/tools/oc-journal-compact-roundtrip.test.ts: 2/2 pass locally — open_assertions, last_checkpoint, fact count, and (deterministic) summary text are byte-identical across two passes. This is the right invariant for "lossy but stable".

CI fixes applied (rebased on the updated parent)

  • Rebased onto feat/1434-journal-compact head e756c47a (parent feat(tools): add oc_journal_compact deterministic core #1442) which carries the previously-missing TOOL_CAPABILITY_MAP entry and v1.11 snapshot row for oc_journal_compact. With those in place the inherited tests/capability-filter.test.ts failures clear.

Status

Merge-ready pending parent #1442 landing. No further changes to this PR's own diff.

…nce doc

Adds a third round-trip case asserting that strategy:'sampling' returns
status:'unsupported_by_host' with no fabricated summary when the host lacks
the sampling capability — the exact #1359 guarantee (never server-side) that
was previously only asserted in prose. Also softens the cadence table to keep
the 20/50-step figures attributed to Webwright rather than implying an
OpenChrome-measured benchmark (#1359 P5).

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@shaun0927
Copy link
Copy Markdown
Owner Author

Review analysis — merge-readiness

Intent & direction. Part 2 of #1434: documents the oc_journal_compact cadence/strategy and pins a round-trip stability contract (compaction is lossy-but-stable). Sound and matches the issue.

#1359 alignment — PASS. The docs correctly describe the sampling strategy as returning unsupported_by_host with no server-side fallback, and the implementation matches. The cadence figures are Webwright's, not OpenChrome benchmarks.

Findings & fixes applied this pass:

  • (was P1) Untested SSOT: OpenChrome as a host-neutral MCP browser harness #1359 guarantee. The "never server-side" claim was prose-only. Added a third round-trip test asserting strategy:'sampling'status:'unsupported_by_host' with no fabricated summary when the host lacks the capability (commit a8e838df).
  • (was P2) Doc over-claim. Softened the cadence table so the 20/50-step figures stay attributed to Webwright (SSOT: OpenChrome as a host-neutral MCP browser harness #1359 P5).
  • (P2) server as any test cast to reach the private tools map is acknowledged (eslint-disabled, author-aware); left as-is — low risk for an internal test.

Tests: oc-journal-compact-roundtrip.test.ts 3/3 pass locally; typecheck clean.

Merge logistics (the one real blocker for develop): base is feat/1434-journal-compact (#1442, Part 1), which is currently conflicting with develop. This PR is content-ready and is being merged into its base branch (the stacked-PR path); its content reaches develop only when #1442's conflict is resolved and #1442 merges.

Verdict: content MERGE-READY; landing on develop is gated on #1442.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant