Repository navigation
docs: reduce root agent policy and remove ClawSweeper rubric - #139258
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. ClawSweeper review completeClawSweeper finished reviewing this revision. The review result is being finalized. |
|
Codex review: needs maintainer review before merge. Reviewed September 5, 2026, 2:07 PM ET / 18:07 UTC. ClawSweeper reviewWhat this changesThe PR shortens OpenClaw’s root agent instructions, removes the embedded ClawSweeper rubric, and directs detailed procedures to existing guides. Merge readiness✅ Ready for maintainer review Keep open with no blocking findings. This remains a distinct, useful cleanup beyond the earlier merged work, and its maintainer protection excludes automatic closure. Priority: P3 Review scores
Verification
How this fits togetherThe root agent instructions guide coding agents working on OpenClaw. They establish repository-wide safeguards and route each task to relevant skills and subsystem documentation. flowchart TD
A[Repository task] --> B[Root agent instructions]
B --> C[Safety and approval boundaries]
B --> D[Relevant subsystem guides]
D --> E[Task skills and procedures]
C --> F[Scoped work and validation]
E --> F
Before mergeNone. Agent review detailsSecurityNone. PR surfaceDocs -211. Total -211 across 1 file. View PR surface stats
Review metrics
Technical reviewBest possible solution: Keep cross-cutting safeguards in the root policy and detailed procedures with their existing subsystem and automation owners. Do we have a high-confidence way to reproduce the issue? Not applicable: this is an instruction rewrite; its stated size reduction is directly verifiable from the two document versions. Is this the best way to solve the issue? Yes. Removing duplicated rubric text at its source reduces universal context while retaining explicit safeguards and discoverable owner guidance. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against cf98f896d173. LabelsLabel changes:
Label justifications:
EvidenceWhat I checked:
Likely related people:
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
|
|
Ready to land at d20e9c6. Root AGENTS.md is 2,112 words, down from 6,938 (69.6%). The separate ClawSweeper policy section is deleted, with no replacement policy file. The root retains repository-wide safety/approval decisions, architectural invariants, proportional testing, and routing to existing owners. Production and test LOC deltas are zero. Validation: Exact-head CI passed: https://github.com/openclaw/openclaw/actions/runs/33982760046. ClawSweeper also completed exact-head review with no correctness/security findings and no requested before-merge work: #139258 (comment). This is an explicitly maintainer-directed instruction cleanup. No runtime test or live product proof is needed, and no bot enforcement code or deployment changes. |
|
Merged via squash.
|
* commit '911d7d5b0c107f7274f2415ca9655dcc6105f0e8': (867 commits) fix(skills): deliver pending Workshop approval controls (#139248) fix(gateway): deliver loopback ask_user prompts to the originating channel (#138831) docs: keep root agent instructions focused on repository policy (#139258) fix(matrix): exclude archived state roots from scans and selection (#112329) perf(agents): prepare exact tool names once per catalog batch (#139267) fix: preserve Swarm progress and simplify owner plumbing (#139269) fix(tailscale): release claims after gateway process-group exit (#139261) refactor(cli): simplify lazy command registration (#139108) test(ui): retain synthetic widget failure evidence (#139229) fix(buzz): keep implicit replies at thread root (#138879) test(diagnostics): await graceful Gateway shutdown before cleanup (#139247) fix(ci): unblock releases with different tooling package managers (#139259) feat(ui): add social preview links for private sessions (#139250) fix(codex): retain failed conversations for guarded continuation (#139246) chore(ui): refresh control ui locales (#139200) fix(ci): run browser checks for real-gateway inputs (#139256) fix(llama-cpp): reconcile managed router state before requests (#136363) chore(i18n): refresh native locales (#139237) refactor(worker): unify inference payload handling (#139245) refactor(terminal): replay wrapped prefixes in one pass (#139240) ...
What Problem This Solves
The root agent instructions still consumed nearly 7,000 words after the earlier cleanup, mixing repository-wide policy with subsystem details, repeated workflows, and ClawSweeper's review rubric. Every task loaded those rules regardless of relevance.
Related: #139236 (first instruction cleanup).
Why This Change Was Made
Rewrite the root around cross-cutting decisions, safety/approval boundaries, architectural invariants, proportional validation, and scoped guidance. Remove the separate ClawSweeper policy section entirely: its prompt treats target AGENTS as optional policy, its schema does not require that section, and its rubric and deterministic mutation gates are owned in the ClawSweeper repository. Keep substantive review follow-through and maintainer product judgment as ordinary repository rules.
This intentionally removes LOC-based risk scoring, arbitrary prompt-length severity, mandatory evidence matrices, blanket screenshots for session behavior, compulsory related-item sweeps, per-comment announcements, and bot-specific scoring/re-review rituals. Detailed subsystem contracts route to existing guides; no replacement policy dump is added.
User Impact
Much less universal instruction context. The root is 2,112 words instead of 6,938 (69.6% smaller), with the requested testing guidance retained. Owner approval, source-trust isolation, operator-instance protection, schema/config/protocol gates, confidentiality, regression proof, and exact-head native landing remain explicit. No runtime or ClawSweeper enforcement code changes.
Evidence
git diff --check, targetedoxfmt --check AGENTS.md, and docs MDX validation passed using canonical installed tooling.CLAUDE.mdremains the canonical symlink.