Skip to content

[DO NOT MERGE] Overleaf sync: working plans and handoff - #535

Draft
yaacovcorcos wants to merge 25 commits into
mainfrom
claude/overleaf-handoff-docs-20261013
Draft

yaacovcorcos wants to merge 25 commits into
mainfrom
claude/overleaf-handoff-docs-20261013

Conversation

@yaacovcorcos

@yaacovcorcos yaacovcorcos commented Oct 13, 2026 •

Copy link
Copy Markdown
Contributor

Do not merge. This PR is a shared space for temporary Overleaf sync plans between collaborators. It will be closed when the feature ships.

Permanent documentation ships with each feature PR: the coordinator steps update docs/internals/scient-overleaf-engine.md; PRs C1 (agent tools) and C2 (screens) add the agent, user and app documentation. Feature PRs should link here instead of carrying plans.

Start with docs/internals/overleaf/README.md: current status, build order, working rules and what is still open.

Two rules shape everything after the coordinator (owner, October 24): agents can do whatever a person can, with no Overleaf-specific permission, approval or stop (the composer's access setting is the only control); and, like GitHub sync, only a conflict stops a sync.

File Content
README.md Handoff: status, build order (step 5 → C1 agent tools → C2 screens), working rules, open items
pr-c-design.md October 24 product and agent decisions: folder model, ways to connect, sync behaviour, agent tools, screens, docs. Wins where files differ
implementation-plan.md Revision-5 plan (owner-approved October 2) with D4 replaced and D10–D14 added
pr-b-coordinator-contract.md Coordinator contract: owner decisions 1–6, evidence rules, acceptance cases A01–A32, step status
step-3b-design.md, step-4-design.md Design notes for the coordinator's local half and publication
cloud-qualification.md October 9 Overleaf Cloud test: what passed, product constraints, what was not qualified

Edit these files directly on this branch as decisions are made. Raw test data, logs, and the checker and prototype code stay outside the repository. These files contain no tokens, project URLs or account details.

Related: #486, #495, #555 (engine, applier, helper) · #536, #556, #626, #630, #633, #634 (coordinator steps 1–4, all merged) · #121 (original implementation, closed October 19)

🤖 Generated with Claude Code

Documentation only. Adds the revision-5 implementation plan, the PR B
coordinator contract, the Overleaf Cloud test results and a handoff README
under docs/internals/overleaf/, plus one index entry. No product code changes.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@yaacovcorcos yaacovcorcos added the documentation Improvements or additions to documentation label Oct 13, 2026
@github-actions github-actions Bot added size:XL vouch:trusted PR author is trusted by repo permissions or the VOUCHED list. labels Oct 13, 2026
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@yaacovcorcos
yaacovcorcos marked this pull request as draft October 13, 2026 09:21
@yaacovcorcos yaacovcorcos changed the title docs(overleaf): collaborator handoff for manual sync (docs only) [DO NOT MERGE] Overleaf sync: working plans and handoff Oct 13, 2026
@yaacovcorcos yaacovcorcos removed the documentation Improvements or additions to documentation label Oct 13, 2026
yaacovcorcos and others added 2 commits October 13, 2026 12:37
…in v1

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…FAT limits

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@github-actions

github-actions Bot commented Oct 13, 2026 •

Copy link
Copy Markdown
Contributor

Thread transfer impact

✅ Thread transfer remains within every enforced ceiling.

Provider Metric Main baseline This PR Impact PR ceiling
Codex Total thread wire 5.6 KiB 5.6 KiB 0 B (0.0%) 6.8 KiB ✅
Codex Thread snapshot wire 4.3 KiB 4.3 KiB 0 B (0.0%) 4.9 KiB ✅
Codex Live turn WebSocket wire 1.3 KiB 1.3 KiB 0 B (0.0%) 2.0 KiB ✅
Codex Live turn WebSocket decoded 26.2 KiB 26.2 KiB 0 B (0.0%) 29.3 KiB ✅
Codex Live turn messages 2 2 0 (0.0%) 8 ✅
Claude Total thread wire 5.6 KiB 5.6 KiB −36 B (−0.6%) 6.8 KiB ✅
Claude Thread snapshot wire 4.3 KiB 4.3 KiB 0 B (0.0%) 4.9 KiB ✅
Claude Live turn WebSocket wire 1.3 KiB 1.3 KiB −36 B (−2.6%) 2.0 KiB ✅
Claude Live turn WebSocket decoded 26.6 KiB 26.5 KiB −41 B (−0.2%) 29.3 KiB ✅
Claude Live turn messages 2 1 −1 (−50.0%) 8 ✅

Baseline: fded533 · PR result: cc7e2a3 · Source CI: failure

Scenario and decoded snapshot size

10 historical turns, 5 command tools per turn, 878.9 KiB retained MCP result per historical turn, and a 1.05 MiB retained result in the measured turn.
Full compact HTTP snapshot with live cursor.

  • Codex decoded thread snapshot: 133.1 KiB
  • Claude decoded thread snapshot: 133.4 KiB

Updated in place by a trusted workflow. PR artifacts are strictly validated and never executed.

…k rules

Decisions 2-4 answered; decision 1 specified: hidden .scient-overleaf vault
beside the checkout, volume UUID plus file ID identity with no device-number
fallback, capability check by atomic exchange through the #495 helper (exFAT
tested and refused), unplugged disks wait for the same vault, sync-managed
folders tested before release rather than refused. Adds the evidence rules
step 1 enforces, not-sent in sections 6 and 9, inline recovery in section 9,
the step status table, and a reveal-kept-copies requirement for PR C.
yaacovcorcos added a commit that referenced this pull request Oct 13, 2026
Owner decision 1: projects on another disk are supported. Retained copies
use the state directory when it shares the checkout's volume, otherwise a
hidden .scient-overleaf/<environment>/<connection> folder beside the
checkout. Locations are identified by volume UUID (diskutil) plus file ID,
never the device number; a recorded folder is verified, never recreated.
A capability probe exchanges files through the host helper (hard links only
for the development fallback), so exFAT and FAT are refused. Each refusal
has its own reason. Tests use real APFS and exFAT disk images for remount,
unplug, disk-root and capability cases.

Plans, contract and Cloud evidence move to the working-documents PR #535;
this PR keeps only the engine notes.
yaacovcorcos and others added 6 commits October 13, 2026 13:41
…ng IDs

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Only APFS supports exchange. Mac OS Extended and exFAT refuse it; FAT32
reports success but only renames, destroying the second file. Qualify the
file-ID reuse note and record round 6 in the step table.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
yaacovcorcos and others added 2 commits October 13, 2026 20:12
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… the applier tests

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
yaacovcorcos and others added 2 commits October 22, 2026 14:53
…le unpublished steps

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
yaacovcorcos and others added 2 commits October 22, 2026 21:03
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
yaacovcorcos and others added 2 commits October 23, 2026 13:39
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…t §9)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
yaacovcorcos and others added 2 commits October 23, 2026 20:13
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- New pr-c-design.md: agents can do whatever a person can, with no
  Overleaf-specific permission, approval or stop (the composer's access
  setting is the only control); one Overleaf project per folder; five ways
  to connect; only a conflict stops a sync, everything else is reported,
  with Undo; new files sent by default; agent tools (PR C1) before the
  screens (PR C2); the documentation set.
- Implementation plan: D4 replaced, D10-D14 added; flowchart, conflicts,
  review/result, connections, inventory, delivery, qualification and
  follow-ups updated.
- Contract: confirmation is the Sync click or the agent's call; only a file
  with conflict marks is held back; new-file rule; the other-agents line is
  reported, not acknowledged; agent tools use the same service; step 5
  gains five items; A01, A09, A27 reworded.
- README brought up to date (steps 1-4 merged, #121 closed).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@github-actions github-actions Bot added size:XXL and removed size:XL labels Oct 23, 2026
yaacovcorcos and others added 2 commits October 24, 2026 01:14
- Holding back only a file with conflict marks becomes its own engine
  addition after step 5, fully specified: two trees bound into the review
  (local target, publication tree), held paths followed through renames,
  a gate that accepts marker-only attention, verification of every
  non-held path, the attempt and base use the publication tree; tests.
- Undo specified: an accepted attempt, its parent/sent trees, additions,
  deletions and renames, edited files left alone, a recorded operation
  with its own receipt.
- Reviews the engine rebuilds are confirmed by the client unless they
  have a conflict; one automatic new sync after an out-of-date push;
  Start fresh needs no further approval.
- New-file rule: hidden files (not only hidden folders) skipped by
  default; "Send this file" overrides only default skips; hard exclusions
  and oversized new files are never sent; keep-only-here is for files
  not yet on Overleaf.
- Failures that still stop a sync listed in full; unknown-send wording no
  longer over-promises; limits table matches the merged coordinator.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- Holding back a conflicted file holds its whole file identity: every
  base, folder and Overleaf path linked by renames keeps Overleaf's entry
  in the publication tree. Marker records store the identity, follow
  renames and survive acceptance and restart. Tests cover renames on
  either or both sides and a resolved rename reaching Overleaf.
- Undo pins each eligible accepted attempt's parent and sent commits for
  as long as it is offered, and saves the folder's editors in every
  window before looking at any file; a failed save stops it first.
- D14 lists the full order, including the three engine additions.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@yaacovcorcos

Copy link
Copy Markdown
Contributor Author

October 24: product and agent decisions recorded (1dde595, 8371b33, cc7e2a3). Start with pr-c-design.md; it wins where files differ.

  • Agents can do whatever a person can. An agent on full access has full access: no Overleaf-specific permission, approval, confirmation or stop. The composer's access setting is the only control, and nothing changes it. The token goes once through the secure secret request.
  • Only a conflict stops a sync. Everything else is synced, then reported, with Undo.
  • One Overleaf project per dedicated folder. New files are sent by default.
  • Order: step 5 → three engine additions (hold back only a file with conflict marks; send a file kept only here; Undo) → agent tools (C1) → screens (C2).

Codex (gpt-6.1-sol, high) reviewed it in three rounds: round 1 found 3 P1, 7 P2 and 1 P3; round 2 found 1 P1, 2 P2 and 1 P3; round 3 judged it ready with no findings. Step 5 has not started.

🤖 Generated with Claude Code

This branch has not been deployed

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

Labels

size:XXL vouch:trusted PR author is trusted by repo permissions or the VOUCHED list.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant