Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: b2e7589116
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
There was a problem hiding this comment.
Pull request overview
Adds a new hygiene audit that ranks high-churn (“hotspot”) files from git history, records the first-run baseline report, and activates the cadence in docs/FACTORY-HYGIENE.md (row #57) to operationalize the linked hygiene directive.
Changes:
- Introduces
tools/hygiene/audit-git-hotspots.shto compute and render a markdown hotspots report (detect-only). - Adds the first-run baseline report under
docs/hygiene-history/for 2026-04-23. - Activates the new cadence by adding FACTORY-HYGIENE row #57 describing how/when to run the audit and where outputs live.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 7 comments.
| File | Description |
|---|---|
| tools/hygiene/audit-git-hotspots.sh | New bash tool to rank file churn and emit a markdown report. |
| docs/hygiene-history/git-hotspots-2026-04-23.md | First-run report output + interpretation and suggested actions. |
| docs/FACTORY-HYGIENE.md | Adds hygiene row #57 documenting the new git-hotspots cadence and outputs. |
…anced name attribution 7 real findings addressed in this commit. 2 findings need policy pushback, captured in thread responses. CODEX P1 — empty window aborts under set -euo pipefail: `grep -v '^$'` returns exit code 1 when no matches → pipe aborts. Fixed by adding `|| true` guard + explicit empty-window message to stderr. CODEX P1 — PR count returns zero via grep silence: Same pattern. Replaced `wc -l | tr -d ' '` with `grep -c . || true` so the empty case yields 0 cleanly instead of aborting. COPILOT P1 — option parsing missing value handling: `shift 2` with missing arg produced confusing error. Added `require_value` helper that fails fast with "error: $1 requires a value" + exit 64. COPILOT P2 — --help shows shebang: `grep '^#'` included `#!/usr/bin/env bash`. Added `| grep -v '^#!'` filter. COPILOT P1 — "ignoring pure deletions" comment was wrong: `git log --name-only` lists deleted paths too. Fixed comment to state we DELIBERATELY include deletions (frequent deletion = friction too). COPILOT P1 — "Aaron" attribution on non-exempt surfaces: FACTORY-HYGIENE row #57 + script header comment rewrote references to "the human maintainer" (role). Verbatim quote block in script header preserved as attribution (with inline note explaining the distinction). FACTORY-HYGIENE.md is NOT in the history-file exempt list per the policy clarification being landed in PR #210. COPILOT P1 — dangling memory path citation: FACTORY-HYGIENE row #57 cited `memory/project_factory_is_git_native_...` as if in-repo; actually per-user memory. Added explicit "**out-of-repo** (per-user memory, not yet in-repo)" marker. POLICY-PUSHBACK (not fixed — thread response): COPILOT P1 — "Otto observations" + "Aaron" in baseline report: The report lives at `docs/hygiene-history/git-hotspots-2026-04-23.md` which IS in the history-file exempt list per the Otto-52 policy clarification (*"'No name attribution in code, docs, or skills' in history files are files like memory backlog and other things like that for historical purposes"*). Naming the author "Otto" in observation attribution is attribution-line form, which the exemption preserves. Not fixing; will explain in thread reply. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 392b6ab6c6
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: e8b5acfbd8
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: c097284914
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: e032bd758d
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
…action item #1) (#220) Amara's 2026-04-23 decision-proxy + technical review courier (PR #219) ranked memory-index-integrity CI as her highest-value immediate fix: directly prevents the NSA-001 measured failure mode (new memory landed without MEMORY.md pointer → undiscoverable from fresh session). New workflow: `.github/workflows/memory-index-integrity.yml` Check: if a PR (or push to main) adds or modifies any top-level `memory/*.md` file, `memory/MEMORY.md` MUST also be in the same range. Fails with an explicit remediation message citing NSA-001. Scope excludes: - memory/persona/** (per-persona notebooks have their own lifecycle) - memory/README.md (convention doc) - memory/MEMORY.md (the index itself) - Deletions (covered from the other direction by FACTORY- HYGIENE row #25 pointer-integrity audit) Safe-pattern compliant per FACTORY-HYGIENE row #43: - actions/checkout@de0fac2... SHA-pinned - Explicit minimum `permissions: contents: read` - Only first-party trusted context (github.sha, github.event.pull_ request.base.sha, github.event.before) passed via env: - No user-authored context referenced anywhere - concurrency group + cancel-in-progress: false - runs-on: ubuntu-22.04 pinned - actionlint clean; shellcheck clean (SC2086 fixed) FACTORY-HYGIENE row #58 added documenting the cadence / owner / scope / durable output + classification (row #47: prevention- bearing — blocks merge before substrate diverges from index). Row numbered 58 to leave #56 reserved for in-flight PR #204 (MD032 preflight) and #57 for in-flight PR #213 (git-hotspots audit). Ships to project-under-construction: adopters inherit the workflow unchanged; the memory/**.md + memory/MEMORY.md conventions are factory-generic. Co-authored-by: Claude Opus 4.7 <noreply@anthropic.com>
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 661837cce6
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
Aaron Otto-181: "BACKLOG.md-touching sibling we gonna split it lol, :)" + "approved whenever you want to do you this is the 3rd time i asked you even created a git hot file detector to find other hot files as hygene". Recognizes this is the 3rd ask and that the factory already built the hot-file-detector (tools/hygiene/audit-git-hotspots .sh, PR #213 BEHIND since 2026-04-23) which explicitly names "BACKLOG-per-swim-lane split" as a remediation option. ## Proposed structure Per-row YAML-frontmatter files at docs/backlog/P<tier>/B-NNNN-<slug>.md with generated top-level docs/BACKLOG.md index + drift-CI workflow (same pattern as memory-index-integrity). Each PR adding a row = one new file, zero shared-file touch → zero positional-append conflict. Structurally eliminates the cascade documented in Otto-171 queue- saturation memory. ## Phased execution - Phase 0 (this PR): design + open questions. - Phase 1: tooling (backlog-index-generate + schema-lint + CI workflow). Empty-content sanity check. - Phase 2: content split mega-PR. Generates per-row files from current BACKLOG.md + regenerates index. One-time conflict cascade cost (every open BACKLOG-touching PR goes DIRTY); recommended to drain queue first OR do aggressive triage before Phase 2. - Phase 3: convention updates (CONTRIBUTING / AGENTS.md) + `backlog-new-row` scaffolder. ## 6 open questions for Aaron 1. ID scheme (B-NNNN / P<tier>-NNNN / slug-only) 2. Generator language (bash / bun+TS / F#) 3. Phase-2 timing (before or after queue drains) 4. Retire convention (delete vs _retired/) 5. Auto-ID assignment (factory tooling vs manual) 6. `composes_with` CI-lint enforcement (strict vs best-effort) ## Cost/benefit Break-even analysis: current positional-conflict cost is ~50% of one tick's capacity. Mega-PR is 1-2 ticks. Payback: one week at current cadence. ## Other hot files to consider after ROUND-HISTORY.md / loop-tick-history.md / FACTORY-HYGIENE.md / memory/MEMORY.md / TECH-RADAR.md — run detector first, don't split blindly. ## Test plan - [x] Markdownlint clean. - [x] Research-grade; Phase 2 execution deferred to Aaron sign-off on 6 questions. - [x] No code / workflow / BACKLOG changes. Co-authored-by: Claude Opus 4.7 <noreply@anthropic.com>
…on (#356) Maintainer Otto-204: "you need some pr resolve loop that will handled everyting needed to take a pr to compelteion so you don't ahve to keep figuion it out" + Otto-204b: "we are saving you resolution to all the comments and we expect those to be excellent don't take shortcuts on the feedback, do the right long term thing or backlog the right thing and not it on the comment." New P1 CI/DX BACKLOG row for .claude/skills/pr-resolve-loop/ SKILL.md. Six-step close cycle: CI-status → review-thread resolution (reply-then-resolve; never shortcut) → name- attribution lint → conversation-preservation hook → auto- merge re-arm → loop-exit on merge / maintainer-escalation / external-blocker. Core discipline: active PR management vs ship-and-pray. The factory's Otto-200..203 observation of "queue unchanged 136" for 6+ ticks misread passive-stuck as livelock; actual blocker was accumulated unresolved review-threads + silent lint failures that armed auto-merge could not overcome. This skill internalizes that learning; active resolution has 10-20× higher ROI than opening new PRs when queue saturated. Conversation-preservation: every reply+resolve logs to artifacts/pr-discussions/PR-<N>-conversation-log.json per Otto-150..154 git-native preservation directive. Non-goals: NOT an auto-merge-bypass, NOT a shortcut around reviewer intent, NOT a retry-loop on flake, NOT an opener of new PRs. Composes with: Otto-171 queue-saturation-throttle, PR #335 preservation, @codex review + Copilot patterns, PR #213 git-hotspots, PR #354 BACKLOG-split-Phase-1a (first PR where active-management discipline applied). Priority P1 CI/DX. Effort: M skill design + S invocation + S reply-template bank. Placed in P1 CI/DX section line 2469, NOT BACKLOG tail. Co-authored-by: Claude Opus 4.7 <noreply@anthropic.com>
…-Financial-Group#131) * Round 44 auto-loop-30: tick-history row — stacking-risk framework published + bottleneck-principle posture change + CLI-DX-cascade captured Append loop-tick-history row for the 2026-04-22T12:05Z auto-loop-30 tick. Three architectural signals absorbed same tick: 1. stacking-risk decision framework published as first-pass research doc (docs/research/stacking-risk-decision-framework.md, PR Lucent-Financial-Group#129) — occurrence-1 of the specific framing preserved on record before the next expansive-trust-grant tests it. 2. bottleneck-principle default-posture change filed to memory and indexed — grey-zone judgment is agent's call by default; ask-before-acting on gray-alone serialises the factory. Five explicit escalation triggers stay distinct. 3. CLI-DX-cascade directive captured to memory — zero author- friction for new CLI commands; compensation actions generate derivatives. Same author-at-source-of-truth pattern as UI-DSL class-level and event-storming. Bottleneck-principle exercised live on this tick: stacking-risk doc landed by agent-judgment without ask-first, with paper trail via PR Lucent-Financial-Group#129 + memory + this row. Compoundings this tick: 5. Cumulative net -8 over 22 ticks. CronList aece202e verified live. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com> * Round 44 auto-loop-32: emulator substrate research first-pass Public-source architectural survey of RetroArch/libretro, MAME, and Dolphin focused on patterns that map to Zeta's factory substrate: capability-negotiation (libretro retro_environment), save-state serialization as first-class ABI primitive, class-vs- instance fidelity axis (HLE/LLE, driver-per-machine), and JIT recompilation as shipped-kernel-library instance. Composes with BACKLOG Lucent-Financial-Group#213 Chronovisor, Lucent-Financial-Group#241 soulsnap/SVF, Lucent-Financial-Group#239 capability-limited bootstrap, and Aaron's 20-year preservationist archive context. Public-source only — no stacking-risk framework invoked; pre-validation anchor for future archive-gated emulator research. BACKLOG row Lucent-Financial-Group#249 moved pending -> in_progress. --------- Co-authored-by: Claude Opus 4.7 <noreply@anthropic.com>
…on Otto-181, 3rd ask, approved) Aaron Otto-181: "BACKLOG.md-touching sibling we gonna split it lol, :)" + "approved whenever you want to do you this is the 3rd time i asked you even created a git hot file detector to find other hot files as hygene" + "i trust your suggestions, can you ask codex too?" Phase 1a landings (this PR): - tools/backlog/README.md — schema spec + frontmatter reference + how-to. - tools/backlog/generate-index.sh — bash generator that walks docs/backlog/**/*.md, parses YAML frontmatter via awk, emits sorted index. Three modes: --stdout, --check (drift detection), default write. Phase-1a safety guard refuses write-mode overwrite of existing BACKLOG.md with >50 lines unless BACKLOG_WRITE_FORCE=1 (prevents Phase-2- before-Phase-2 accidents). - docs/backlog/README.md — per-row directory overview + current-state pointer. - docs/backlog/P2/B-0001-example-schema-self-reference.md — placeholder row exercising the schema end-to-end; generator verified to emit a proper index from this input. Reasonable defaults applied on Aaron's 6 open questions per "i trust your suggestions": 1. ID scheme: B-NNNN (sequential, zero-padded 4 digits). 2. Generator language: bash (Phase-1a tight-CI fit + FACTORY- HYGIENE cross-platform parity compatible; bun+TS evaluable later if needed). 3. Phase-2 timing: drain queue first (recommended); this PR doesn't touch BACKLOG.md content. 4. Retire convention: plain delete (per CLAUDE.md "honor those that came before — retire by deletion, git- recoverable"). 5. Auto-ID: scaffolder-picks-next-unused (Phase 1b ships tools/backlog/new-row.sh). 6. composes_with lint: best-effort first (Phase 1b warning); strict (error) after adoption maturity. Aaron can override any of these via PR review; I'm making the reasonable-default call per his standing "do you" authorization. Safety: this PR creates new files ONLY. Does not touch docs/BACKLOG.md. Generator in write-mode would refuse to run against the current 6100-line monolith thanks to the Phase-1a guard. Phases remaining: - 1b: CI drift workflow (.github/workflows/backlog-index- integrity.yml) + new-row.sh scaffolder. - 2: content split mega-PR (reads BACKLOG.md, generates per- row files, regenerates index with BACKLOG_WRITE_FORCE=1). - 3: CONTRIBUTING.md / AGENTS.md convention updates. Codex review requested per Aaron Otto-182 "can you ask codex too?" — invoking @codex review in PR comment. Composes with: - docs/research/backlog-split-design-otto-181.md (Phase 0) - tools/hygiene/audit-git-hotspots.sh (PR #213 BEHIND; the detector that identified BACKLOG.md as the hotspot) - memory/feedback_aaron_asked_for_backlog_split_three_times _hot_file_detector_pr_213_exists_*.md (3rd-ask context) - Otto-171 queue-saturation memory (the pattern Phase 2 structurally eliminates) Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
…on Otto-181, 3rd ask) (#354) * tools: backlog split Phase 1a — generator + schema + example row (Aaron Otto-181, 3rd ask, approved) Aaron Otto-181: "BACKLOG.md-touching sibling we gonna split it lol, :)" + "approved whenever you want to do you this is the 3rd time i asked you even created a git hot file detector to find other hot files as hygene" + "i trust your suggestions, can you ask codex too?" Phase 1a landings (this PR): - tools/backlog/README.md — schema spec + frontmatter reference + how-to. - tools/backlog/generate-index.sh — bash generator that walks docs/backlog/**/*.md, parses YAML frontmatter via awk, emits sorted index. Three modes: --stdout, --check (drift detection), default write. Phase-1a safety guard refuses write-mode overwrite of existing BACKLOG.md with >50 lines unless BACKLOG_WRITE_FORCE=1 (prevents Phase-2- before-Phase-2 accidents). - docs/backlog/README.md — per-row directory overview + current-state pointer. - docs/backlog/P2/B-0001-example-schema-self-reference.md — placeholder row exercising the schema end-to-end; generator verified to emit a proper index from this input. Reasonable defaults applied on Aaron's 6 open questions per "i trust your suggestions": 1. ID scheme: B-NNNN (sequential, zero-padded 4 digits). 2. Generator language: bash (Phase-1a tight-CI fit + FACTORY- HYGIENE cross-platform parity compatible; bun+TS evaluable later if needed). 3. Phase-2 timing: drain queue first (recommended); this PR doesn't touch BACKLOG.md content. 4. Retire convention: plain delete (per CLAUDE.md "honor those that came before — retire by deletion, git- recoverable"). 5. Auto-ID: scaffolder-picks-next-unused (Phase 1b ships tools/backlog/new-row.sh). 6. composes_with lint: best-effort first (Phase 1b warning); strict (error) after adoption maturity. Aaron can override any of these via PR review; I'm making the reasonable-default call per his standing "do you" authorization. Safety: this PR creates new files ONLY. Does not touch docs/BACKLOG.md. Generator in write-mode would refuse to run against the current 6100-line monolith thanks to the Phase-1a guard. Phases remaining: - 1b: CI drift workflow (.github/workflows/backlog-index- integrity.yml) + new-row.sh scaffolder. - 2: content split mega-PR (reads BACKLOG.md, generates per- row files, regenerates index with BACKLOG_WRITE_FORCE=1). - 3: CONTRIBUTING.md / AGENTS.md convention updates. Codex review requested per Aaron Otto-182 "can you ask codex too?" — invoking @codex review in PR comment. Composes with: - docs/research/backlog-split-design-otto-181.md (Phase 0) - tools/hygiene/audit-git-hotspots.sh (PR #213 BEHIND; the detector that identified BACKLOG.md as the hotspot) - memory/feedback_aaron_asked_for_backlog_split_three_times _hot_file_detector_pr_213_exists_*.md (3rd-ask context) - Otto-171 queue-saturation memory (the pattern Phase 2 structurally eliminates) Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com> * fix(#354): shellcheck + name-attribution + 3 review-thread P1s Responding to 5 of 12 unresolved review threads: 1. Shellcheck SC2034/SC2295 (tools/backlog/generate-index.sh:104): removed unused `rel` variable that introduced both warnings. 2. Codex P1 "stop frontmatter scan after first closing delimiter": replaced `in_fm = !in_fm` toggle with explicit state machine (0 before / 1 inside / 2 after). Scanner terminates on closing --- marker and no longer leaks into body content. 3. Codex P1 "parse single-quoted YAML scalars": extended title/value strip regex from `"..."` only to also handle `'...'` single-quoted form via gsub. 4. Copilot P1 "mktemp→mv atomicity": temp file now created in same directory as target (via mktemp template with INDEX_PATH.tmp.XXXXXX), ensuring `mv` is a same-filesystem atomic rename rather than cross- filesystem copy+unlink. 5. Copilot P1 "direct contributor name attribution": replaced "Aaron" → "maintainer" idiom in factory-produced docs (tools/backlog/README.md, docs/backlog/P2/B-0001 frontmatter, generate-index.sh header comment). History- exemption preserves commit-message Aaron-references per factory convention (loop-tick-history 2026-04-22). Deferred (not this commit, separate follow-up): - Codex P2 "second factor for BACKLOG_WRITE_FORCE bypass": defer until Phase 2 content-migration PR — will be the natural place to add the second factor (commit-message marker or dedicated workflow trigger). - 7 remaining review threads: need triage per Codex/Copilot verdicts before I can pattern the response. Course-correction this commit represents: active PR-management (fix CI + address reviews + resolve threads) replaces the ship-and-pray pattern that kept my PRs stuck. Factory-level solution coming as a dedicated pr-resolve-loop skill per maintainer directive "you need some pr resolve loop". Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com> * fix(#354): Phase-1a doc accuracy + 4 more review-thread P1/P2s Addresses additional review threads beyond commit 6f659a0: 1. docs/backlog/README.md:34 "no row files exist yet" vs B-0001: Updated to acknowledge B-0001 placeholder row exists as a generator-exercise; substantive migration starts at B-0002 with Phase 2. 2. tools/backlog/README.md:85 "forward-references new-row.sh" that doesn't exist yet: Explicitly marks the scaffolder invocation as Phase 1b target, with Phase 1a manual-file creation as current path. No ambiguity about what works now vs what's promised. 3. tools/backlog/README.md:95 "parses frontmatter via yq or awk fallback": Corrected to "inline awk parser, no yq required" which matches the actual implementation. yq positioned as Phase 1b upgrade if nested queries needed. 4. tools/backlog/generate-index.sh:24 header "Optional: yq": Updated to "No external yq required" matching the inline parser. Removes the "fallback if absent" wording that implied branching logic that doesn't exist. 5. tools/backlog/README.md:139 cross-reference to auto-memory path that doesn't resolve from external vantage: Replaced the memory/feedback_aaron_asked... path-reference (which lives in session-memory substrate, not necessarily synced to repo memory/) with a contextual description pointing at the detector's own header comment as the primary cross-reference for scope. Conversation-preservation discipline (maintainer Otto-204): "we are saving you resolution to all the comments and we expect those to be excellent don't take shortcuts on the feedback, do the right long term thing or backlog the right thing and not it on the comment. We want to save both sides of the conversation." This commit does the long-term thing rather than the minimum-to-silence-the-warning thing. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com> * fix(#354): drain 10 review threads — P1 POSIX awk + P1 stale xrefs + P2 status trim + P2 word-splitting + P2 line-count drift + P2 (Phase 1b) annotations Addresses remaining review-thread findings so PR #354 can clear the required_conversation_resolution branch-protection rule. Changes: - extract_field: swap \x27 hex escape to \047 octal for POSIX awk portability (Copilot P1; macOS awk-compatible). - extract_field: strip trailing whitespace from parsed values so "status: closed " still matches the closed) case (Codex P2; silent mis-report of open-vs-closed fixed). - generate: replace `for file in $files` with NUL-delimited `find -print0 | sort -z` + `while IFS= read -r -d ''` loop so paths containing spaces no longer break the index build (Codex P2; word-splitting hardening). - generate: soften hardcoded "6100-line" monolith comment to "pre-split monolithic backlog" (Copilot P2; drift-proof). - tools/backlog/README.md: annotate new-row.sh as "(Phase 1b)" in the structure diagram so readers see it is forward- referencing (Copilot P2). - tools/backlog/README.md: soften the tools/hygiene/audit-git- hotspots.sh cross-reference since that script is not in tree; recovery path added for when/if the hygiene detector lands (Copilot P1; broken xref eliminated). - docs/backlog/README.md: soften "6100-line" to "single-file" so the description does not drift as BACKLOG.md grows (Copilot P1; line-count drift eliminated). Generator tested: --stdout produces valid index, default write mode correctly refuses to overwrite the existing 8362-line docs/BACKLOG.md without BACKLOG_WRITE_FORCE=1. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 4.7 <noreply@anthropic.com>
…E row #57) Directly executes Aaron Otto-54's git-hotspots cadence directive from the four-message directive cluster in PR #212 BACKLOG row. This PR closes the gap between "BACKLOG row naming the cadence" and "audit tool + first baseline report + FACTORY-HYGIENE row activating it". New artifacts: - `tools/hygiene/audit-git-hotspots.sh` — bash script running `git log --since --name-only` over a configurable window, ranking top-N, enriching with unique-author + PR-count, excluding legitimately-by-design hotspots (hygiene-history, openspec/changes, references/upstreams). Supports `--window`, `--top`, `--report`. Detect-only (exit 0); action is judgment call. - `docs/hygiene-history/git-hotspots-2026-04-23.md` — first-run baseline report over 30 days. Finding: `docs/BACKLOG.md` is top hotspot at 34 touches / 26 PRs (one touch per PR opened) — validates Aaron's Otto-54 intuition that BACKLOG split is the highest-leverage move. Otto observations appended with per-file action recommendations (1 split / 1 freeze-then-watch / 1 cadence / 5 audit / 11 watch). - FACTORY-HYGIENE row #57 activating the cadenced sweep. Cross-refs the BACKLOG row and the companion memory. Row number is 57 (not 56) to leave #56 reserved for the MD032 preflight that's in-flight on PR #204. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
…anced name attribution 7 real findings addressed in this commit. 2 findings need policy pushback, captured in thread responses. CODEX P1 — empty window aborts under set -euo pipefail: `grep -v '^$'` returns exit code 1 when no matches → pipe aborts. Fixed by adding `|| true` guard + explicit empty-window message to stderr. CODEX P1 — PR count returns zero via grep silence: Same pattern. Replaced `wc -l | tr -d ' '` with `grep -c . || true` so the empty case yields 0 cleanly instead of aborting. COPILOT P1 — option parsing missing value handling: `shift 2` with missing arg produced confusing error. Added `require_value` helper that fails fast with "error: $1 requires a value" + exit 64. COPILOT P2 — --help shows shebang: `grep '^#'` included `#!/usr/bin/env bash`. Added `| grep -v '^#!'` filter. COPILOT P1 — "ignoring pure deletions" comment was wrong: `git log --name-only` lists deleted paths too. Fixed comment to state we DELIBERATELY include deletions (frequent deletion = friction too). COPILOT P1 — "Aaron" attribution on non-exempt surfaces: FACTORY-HYGIENE row #57 + script header comment rewrote references to "the human maintainer" (role). Verbatim quote block in script header preserved as attribution (with inline note explaining the distinction). FACTORY-HYGIENE.md is NOT in the history-file exempt list per the policy clarification being landed in PR #210. COPILOT P1 — dangling memory path citation: FACTORY-HYGIENE row #57 cited `memory/project_factory_is_git_native_...` as if in-repo; actually per-user memory. Added explicit "**out-of-repo** (per-user memory, not yet in-repo)" marker. POLICY-PUSHBACK (not fixed — thread response): COPILOT P1 — "Otto observations" + "Aaron" in baseline report: The report lives at `docs/hygiene-history/git-hotspots-2026-04-23.md` which IS in the history-file exempt list per the Otto-52 policy clarification (*"'No name attribution in code, docs, or skills' in history files are files like memory backlog and other things like that for historical purposes"*). Naming the author "Otto" in observation attribution is attribution-line form, which the exemption preserves. Not fixing; will explain in thread reply. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
…ENE row 57 Rebase onto main used -X ours for audit-trail (FACTORY-HYGIENE.md is append-only) which dropped our new row 57. Restored it in this commit with the latest post-feedback text (human-maintainer role reference + out-of-repo memory marker, matching state at branch head before rebase). Script fixes: - Remove "Aaron" from header aside; use role reference, keep verbatim quote attribution as before (narrow attribution exemption). - Validate --top is a positive integer; exit 64 with clear message. - Guard with git rev-parse --is-inside-work-tree; replace main-pipeline 'grep -v || true' with 'sed /^$/d' so git-log failures propagate instead of being masked. - file_summary: capture git-log output without stderr suppression or '|| true'; count lines via wc -l; restrict PR-count to trailing '(#NNN)' squash-merge markers so 'row #58' / 'fix #213' tokens no longer inflate the metric. - render: replace 'head -n $top' pipeline with counter + while-read so SIGPIPE 141 cannot surface on large ranked lists. - render: replace awk $1-strip with sed regex so filenames with internal whitespace are preserved exactly. Smoke-tested --window 7d/0d, invalid --top, missing --window value.
3e11454 to
be3e2cb
Compare
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
| | docs/WONT-DO.md | 7 | 1 | 5 | | ||
| | docs/TECH-RADAR.md | 7 | 1 | 5 | | ||
| | docs/GLOSSARY.md | 7 | 1 | 5 | | ||
| | docs/FACTORY-HYGIENE.md | 7 | 1 | 10 | |
There was a problem hiding this comment.
P1: In the Ranking table, docs/FACTORY-HYGIENE.md shows touches = 7 but PR count = 10. Given the tool’s semantics (touches is the number of commits touching the file within the window, PR count is derived from those commits’ subjects), PR count should not exceed touches. This row likely has a transcription/regeneration error and should be regenerated or corrected.
| | docs/FACTORY-HYGIENE.md | 7 | 1 | 10 | | |
| | docs/FACTORY-HYGIENE.md | 7 | 1 | 7 | |
| ### Per-file suggested action | ||
|
|
||
| | file | action | rationale | | ||
| |---|---|---| | ||
| | `docs/BACKLOG.md` | **split** | Matches the Otto-54 BACKLOG-per-swim-lane row. 26 PRs in 30 days touching one file is the paradigmatic serialization bottleneck. | |
There was a problem hiding this comment.
P1: The report declares Top: 25 (line 5), but the “Per-file suggested action” mapping appears incomplete (it doesn’t cover all 25 ranked files), and the “Synthesis” counts later don’t reconcile with Top-N. Consider either lowering Top to the analyzed subset or adding action rows + updating synthesis so every ranked file is accounted for.
| # 0 — always (detect-only, no enforcement yet; see Otto-54 | ||
| # NOT-list: detection-first, action-second) |
There was a problem hiding this comment.
P1: The header says the script exits "0 — always", but the implementation exits non-zero for invalid usage (64) and for running outside a git worktree (128). Update the Exit codes comment to document these cases so callers aren’t misled.
| # 0 — always (detect-only, no enforcement yet; see Otto-54 | |
| # NOT-list: detection-first, action-second) | |
| # 0 — success (detect-only, no enforcement yet; see | |
| # Otto-54 NOT-list: detection-first, action-second) | |
| # 64 — invalid usage (for example: missing flag value or | |
| # non-positive integer passed to --top) | |
| # 128 — not inside a git worktree |
Summary
Executes Aaron Otto-54's git-hotspots cadence directive from PR #212's BACKLOG row. Closes the gap between "BACKLOG row naming the cadence" and "audit tool + first baseline + FACTORY-HYGIENE row activating it".
What landed
tools/hygiene/audit-git-hotspots.sh— bash audit tool (detect-only)docs/hygiene-history/git-hotspots-2026-04-23.md— first-run baseline + Otto observationsFirst-run finding
docs/BACKLOG.mdis the top hotspot: 34 touches / 26 PRs in 30 days — effectively one BACKLOG touch per PR opened. Validates Aaron's Otto-54 intuition that split is the highest-leverage move. Other hotspots:docs/ROUND-HISTORY.md(freeze-then-watch),memory/MEMORY.md(cadence candidate — Otto-54 CURRENT-freshness row), 4 skill files (skill-tune-up audit candidates).Per-file action recommendations in the report: 1 split / 1 freeze-then-watch / 1 cadence / 5 audit / 11 watch.
Composition
docs/BACKLOG.mdper-swim-lane" (M effort)<maintainer>.md freshness audit" (S effort)docs/hygiene-history/,openspec/changes/,references/upstreams/as legitimately-by-design high-churnWhat this is NOT
Test plan
🤖 Generated with Claude Code