docs: Add Direct monorepo worktree example - #773
warp-agent-staging[bot] wants to merge 3 commits into
Conversation
Co-Authored-By: Oz <oz-agent@warp.dev>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
This PR was generated with Warp. Comment |
Co-Authored-By: Oz <oz-agent@warp.dev>
|
@warp-agent-staging[bot] I'm starting a first review of this pull request. You can view the conversation on Warp. I completed the review and no human review was requested for this pull request. Comment Powered by Oz |
There was a problem hiding this comment.
Overview
This PR adds a new Direct backend documentation page for using task-scoped Git worktrees with a shared monorepo base clone, updates the Direct backend and self-hosted worker reference pages, and adds the new page to the sidebar.
Concerns
- No blocking correctness, documentation quality, security, or spec-drift concerns found in the reviewed diff.
Verdict
Found: 0 critical, 0 important, 0 suggestions
Approve
Comment /warp-agent-review on this pull request to retrigger a review (up to 3 times on the same pull request).
Powered by Oz
There was a problem hiding this comment.
Review summary
The independent agent completed its review for this commit.
Findings
src/content/docs/platform/self-hosting/managed-direct.mdx:84- [NIT] The new sentence 'To reuse a large monorepo without sharing one checkout between concurrent tasks, see Direct backend monorepo worktrees.' runs on immediately after the existing line 83 sentence with no blank line between them, so it renders as the same paragraph instead of its own paragraph like the target_dir sentence two lines below. Requested change: insert a blank line before this sentence so it forms its own paragraph.- PR body
## Documentation risksection - [SUGGESTION] The section omits the 'Source files consulted' field from the doc-quality-policy.md template, even though the PR cites oz-agent-worker paths (internal/config/config.go, internal/worker/direct.go) under 'Unverified claims' instead. Requested change: add a 'Source files consulted' line to the Documentation risk section listing those paths and the verified commit SHA so engineering reviewers can find them without reading the full PR body.
Verdict
Approve with nits
Co-Authored-By: Oz <oz-agent@warp.dev>
There was a problem hiding this comment.
Review summary
The independent agent completed its review for this commit.
Findings
- PR description —
## Documentation risksection (right afterDocs override: none) — [SUGGESTION] The risk section omits theSource files consultedfield even though this PR isengineering-review-requiredand the source verification is described only in prose under## Unverified claims("verified against oz-agent-worker@530bbe934a632910dfe8818ab7b4c6027a3473ef, including internal/config/config.go, internal/worker/direct.go, and their tests"). Requested resolution: add aSource files consulted:line to the## Documentation risksection per the format in.agents/references/doc-quality-policy.md, e.g.Source files consulted: oz-agent-worker/internal/worker/direct.go@530bbe9, oz-agent-worker/internal/config/config.go@530bbe9. src/content/docs/platform/self-hosting/reference.mdx:167— [SUGGESTION] The newtarget_dirfield is documented under thebackend.directconfig-file schema, but the equivalent--target-dirCLI flag (confirmed in oz-agent-worker's main.go:TargetDir string help:"Run all tasks in this directory instead of creating per-task workspaces (direct backend only)") is missing from the "Worker flags" > "Optional" list above. Requested resolution: add a--target-dirbullet to the Optional worker flags list so CLI-only users can discover this option.
Verdict
Approve with nits



What this feature does
Direct backend setup and teardown hooks can create a dedicated Git worktree for each task, letting concurrent agents share monorepo Git objects without sharing a checkout. Shipped in worker release
v2026-09-18-23-15-02(2026-09-18).Summary
Adds a practical Direct backend deployment pattern for running concurrent agents against a large monorepo with isolated branches and working files.
Changes
direct-monorepo-worktrees.mdxwith a shared base clone, complete setup and teardown hooks, worker configuration, validation, and troubleshooting.OZ_WORKSPACE_ROOT/repoinstead of the already-created workspace root.ozin the task workspace and requires task prompts or loaded agent instructions to targetrepo/.target_dirand adds navigation and related-page links.Content design plan
Target audience and their JTBD: A platform engineer operating a Direct backend worker for a large monorepo who needs concurrent runs without repeated full clones or a shared mutable checkout.
Problem statement: The Direct backend documents lifecycle hooks but does not show how to use them to create and remove task-scoped Git worktrees. Creating a worktree at
OZ_WORKSPACE_ROOTfails because the worker has already populated that directory.Goals:
Purpose and value added: The page captures a reusable monorepo pattern and the non-obvious nested-worktree constraint without turning the general Direct backend page into a repository-management tutorial.
Content type and model: Feature documentation (combined) because the reader needs the lifecycle model, scripts, configuration, and recovery steps together.
Skills and templates to use:
draft_feature_docand.agents/templates/feature-doc.md, with procedural guidance fromdraft_procedural.High-impact scenarios: Covers concurrent tasks using one shared Git object store and a main-branch base. Excludes container isolation, submodule-specific setup, and customer-specific dependency bootstrapping.
Unverified claims
None. Direct workspace creation, CLI working directory, environment-file timing,
target_dir, and teardown ordering were verified againstoz-agent-worker@530bbe934a632910dfe8818ab7b4c6027a3473ef, includinginternal/config/config.go,internal/worker/direct.go, and their tests.Documentation risk
Risk: engineering-review-required
Rationale: Adds executable setup and teardown scripts and documents Direct backend workspace lifecycle behavior.
Source files consulted: oz-agent-worker/internal/config/config.go@530bbe9, oz-agent-worker/internal/worker/direct.go@530bbe9
Docs override: none
Verification
python3 .agents/skills/style_lint/style_lint.py --changed— exited 0 with one inherited meta-opener warning inmanaged-direct.mdx.npm run build— passed.python3 .agents/skills/check_for_broken_links/check_links.py --internal-only— passed with 0 broken links.python3 .agents/skills/doc_quality_policy/check_compression_contract.py src/content/docs/platform/self-hosting/direct-monorepo-worktrees.mdx --content-type feature-doc— passed.Co-Authored-By: Oz oz-agent@warp.dev