Skip to content

docs(claude): sharpen PR description guidance - #947

Merged
kovtcharov merged 1 commit into
mainfrom
docs/sharpen-pr-description-guidance
May 4, 2026
Merged

kovtcharov merged 1 commit into
mainfrom
docs/sharpen-pr-description-guidance

Conversation

@kovtcharov

Copy link
Copy Markdown
Contributor

The existing PR-description guidance in CLAUDE.md was directionally right ("tight and value-focused") but loose enough that a recent PR (#946 / #944) still shipped with a "What changed" enumeration the diff already showed and a "Summary" section that buried the user-observable impact behind implementation details. Future agents reading the file would do the same.

After this change the default shape is just two sections — "Why this matters" (with required before/after framing) and "Test plan" — with a "user-observable impact in <30s without reading the diff" litmus check, and three new anti-patterns lifted directly from the patterns the prior PR exhibited.

Test plan

The existing guidance said "tight and value-focused" but didn't make
the default shape concrete enough. The recent #944 PR shipped with a
"What changed" enumeration that the diff already showed and a "Summary"
section that buried the user-observable impact behind implementation
details — exactly the patterns the existing rules disclaimed but
allowed enough wiggle room to recur.

Tighten the default to two sections — "Why this matters" (with
explicit before/after framing) and "Test plan". Threads list is
opt-in, reserved for PRs that genuinely bundle multiple logical
changes a reviewer needs to evaluate independently. Add the
"user-observable impact in <30s without reading the diff" test as
the litmus check, and list three additional anti-patterns the prior
PR fell into so the next agent doesn't repeat them.
@kovtcharov
kovtcharov requested a review from kovtcharov-amd as a code owner May 3, 2026 03:10
@github-actions github-actions Bot added the devops DevOps/infrastructure changes label May 3, 2026
@github-actions

github-actions Bot commented May 3, 2026

Copy link
Copy Markdown
Contributor

Summary

Doc-only sharpening of the PR-description guidance in CLAUDE.md (+13 / −5). The change replaces the optional 3-section "Summary / threads / test plan" default with a stricter 2-section default ("Why this matters" + Test plan), adds a <30s user-observable impact litmus test, and lifts three concrete anti-patterns directly from the failure modes of the prior PR (#946) that motivated this. The PR description itself models the new guidance — before/after framing in paragraph one, two sections only, no file enumeration — which is the strongest signal that the rule is workable.

Issues Found

🟢 Minor — what / how framing has a small internal tension (CLAUDE.md:47)

The new prose says:

That's it. No "What changed" / "Files modified" / "Implementation notes" sections by default — the diff shows what changed; the commit messages explain how.

…but the very next "Hard rules" bullet (CLAUDE.md:52) says:

Cut exhaustive file-by-file enumeration and implementation walkthroughs. The diff is the source of truth for what files changed and how. The description is the source of truth for why a reviewer should care.

So one line attributes "how" to commit messages, the next attributes it to the diff. Both are defensible (diff = mechanical how, commit body = narrative how), but as written a future reader could read these as contradictory. Suggest tightening to a clean what / how / why split:

That's it. No "What changed" / "Files modified" / "Implementation notes" sections by default — the diff shows *what* and *how*; the description and commit messages explain *why*. The PR description's job is to sell the merge.

🟢 Minor — anti-pattern wording could match the section name it warns about (CLAUDE.md:67)

- ❌ Burying the user impact under a section labelled "Summary"; lead with the impact

The replacement section header is now Why this matters, but the anti-pattern still names "Summary" specifically. That's fine for the immediate migration (existing PRs will literally have "Summary" headers), but reads oddly long-term — the section being warned about no longer exists in the recommended template. Consider generalizing:

- ❌ Burying the user-observable impact under a generic "Summary" / "Overview" header instead of leading with it

Not blocking — current wording is still understandable.

Strengths

  • The PR practices what it preaches. gh pr view 947 body uses exactly the new shape: before/after paragraph + test plan, no "What changed" enumeration, no file names. That's the best validation a doc change of this kind can have.
  • The <30s without reading the diff test is concretely actionable — much sharper than the old "lead with why and impact" hand-wave because it gives the author a checkable criterion before they hit submit.
  • The three new anti-patterns are grounded in observed failure modes rather than invented hypotheticals (the PR body explicitly cites fix(agents): support parallel tool_calls (#944) #946 / Agent loop rejects parallel tool_calls from native tool-calling models (Gemma-4-E4B default) #944 as the trigger), which is the right way to evolve a style guide.
  • Scope discipline — touches only the section it sets out to change; doesn't drift into adjacent rules (commit-message style, attribution, etc.) that would dilute the review.

Verdict

Approve with suggestions — both nits are 🟢 minor wording refinements; nothing blocking. Safe to merge as-is, or apply the two suggestion blocks for slightly tighter internal consistency.

@kovtcharov
kovtcharov enabled auto-merge May 3, 2026 11:27
@kovtcharov
kovtcharov added this pull request to the merge queue May 4, 2026
Merged via the queue into main with commit 019ce01 May 4, 2026
19 checks passed
@kovtcharov
kovtcharov deleted the docs/sharpen-pr-description-guidance branch May 4, 2026 18:24
theonlychant pushed a commit to theonlychant/gaia that referenced this pull request May 5, 2026
The existing PR-description guidance in CLAUDE.md was directionally
right ("tight and value-focused") but loose enough that a recent PR
(amd#946 / amd#944) still shipped with a "What changed" enumeration the diff
already showed and a "Summary" section that buried the user-observable
impact behind implementation details. Future agents reading the file
would do the same.

After this change the default shape is just two sections — "Why this
matters" (with required before/after framing) and "Test plan" — with a
"user-observable impact in <30s without reading the diff" litmus check,
and three new anti-patterns lifted directly from the patterns the prior
PR exhibited.

## Test plan

- [x] No code changed; doc-only edit
- [x] Re-read the new section against amd#946 to confirm the prior
description fails the new rules
@itomek itomek mentioned this pull request May 7, 2026
5 of 6 tasks
theonlychant pushed a commit to theonlychant/gaia that referenced this pull request May 7, 2026
## Why this matters

Ships the v0.17.6 patch: a new Email Triage Agent with Gmail (every
email body stays on local Lemonade), the OAuth PKCE foundation that
backs it, settings UI card layout, and a sweep of installer fixes that
close the remaining first-launch failures uncovered after v0.17.5.
Custom Python agents that follow the template's
`super().__init__(**kwargs)` pattern no longer crash on the first
message in the Agent UI.

Full notes: `docs/releases/v0.17.6.mdx`.

## What's New

- **Email Triage Agent with Gmail**
([amd#965](amd#965)) — `EmailTriageAgent` with
25 tools across read / organize / reply / delete / calendar mixins.
Every email body processed locally on Lemonade; seven destructive tools
confirmation-gated; three layers of prompt-injection defense; SQLite
undo log via `DatabaseMixin`.
- **OAuth PKCE foundation for Google connections**
([amd#926](amd#926)) — Self-contained
`gaia.connections` module: refresh tokens in the OS keychain (Keychain /
DPAPI / SecretService), per-agent grants in
`~/.gaia/connections/grants.json`, async token cache with refresh
rotation. Baseline for the v0.17.7 connectors framework.
- **Settings UI card layout**
([amd#969](amd#969)) — Outlined cards with
accent left-stripe replace margin-separated blocks across all settings
sections; light + dark themes both updated.

## Bug Fixes

- **Custom Python agents crashed on first message**
([amd#974](amd#974), closes
[amd#973](amd#973)) — `python_factory` now
introspects the target class's `__init__` chain and only forwards kwargs
the chain accepts, so the bare `super().__init__(**kwargs)` template
pattern no longer crashes with `unexpected keyword argument
'rag_documents'`.
- **Windows installer failed at `ensure-uv`**
([amd#968](amd#968), closes
[amd#966](amd#966)) — `uv` binary now
bundled for `win-x64`; packaged Windows rescue installer included.
- **macOS installer failed at `ensure-uv` on clean Apple Silicon**
([amd#967](amd#967), closes
[amd#941](amd#941)) — Pinned `uv` v0.5.14
(`aarch64-apple-darwin`) shipped in the DMG; new `dmg-structural-smoke`
CI job blocks future drift.
- **AppImage users hit `gaia: command not found`**
([amd#942](amd#942), closes
[amd#782](amd#782)) — Startup writes a
`~/.local/bin/gaia` shim so `gaia` is on PATH after first launch (skips
creation if already present).
- **Windows fell back to Qwen instead of Gemma 4 default**
([amd#949](amd#949), closes
[amd#948](amd#948)) — Model-resolution logic
fixed so Gemma loads correctly on Windows.

## Tooling & Docs

- **`gaia-release` skill**
([amd#939](amd#939)) — Phased release flow
with hard gates before every irreversible step; encodes the manual
pre-tag verification that caught two release-blocking bugs in v0.17.4.
- **Internal-task issue template**
([amd#906](amd#906)) — Third issue template
for agent-assignable internal work.
- **Outlook via Power Automate plan**
([amd#954](amd#954)) — Enterprise-bypass spec
for v0.17.7 Outlook integration.
- **PR description guidance sharpened**
([amd#947](amd#947)) — `CLAUDE.md` "tight and
value-focused" rule with anti-patterns.
- **Stale `macOS uv fetch removed` orphan comment removed**
([amd#975](amd#975)).

## Thanks

External contributors in this release:

- [@theonlychant](https://github.com/theonlychant) — installer fixes
([amd#968](amd#968),
[amd#942](amd#942),
[amd#949](amd#949))
- [@BlueriteSoul](https://github.com/BlueriteSoul) — reported AppImage
`gaia: command not found`
([amd#782](amd#782))
- [@nuts23](https://github.com/nuts23) — reported Windows Gemma/Qwen
fallback ([amd#948](amd#948))

## Release checklist

- [x] `util/validate_release_notes.py docs/releases/v0.17.6.mdx --tag
v0.17.6` passes
- [x] `src/gaia/version.py` → `0.17.6`
- [x] `src/gaia/apps/webui/package.json` → `0.17.6`
- [x] Navbar label in `docs/docs.json` → `v0.17.6 · Lemonade 10.2.0`
- [x] All 14 commits in the range (v0.17.5..HEAD) are represented in the
notes
- [ ] Review from @kovtcharov-amd addressed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

devops DevOps/infrastructure changes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants