Repository navigation
feat(ci): doc-accuracy reviewer (Layer 2) + weekly audit (Layer 3) - #510
Conversation
Implements Layer 2 and Layer 3 of the doc-accuracy design (claude/design/doc-accuracy-and-generated-artifacts.md) — the semantic half no linter or generator can catch (prose contradicting code). - coverage/docs-affected-map.json — coarse source-area -> doc-page map, the hand-authored twin of the test-affected map. Generous values; routes Transactions/ECS/Query/Storage -> the agent-guidance page. - scripts/docs-affected.py — resolver: changed files -> affected pages; surfaces unmapped source areas and stale map entries (self-healing). - .github/workflows/doc-accuracy-review.yml — Layer 2: scoped, advisory per-PR reviewer (reuses the issue-triage auth), one comment citing file:line for both the doc line and the contradicting code line; fork PRs skipped. - .github/workflows/doc-accuracy-audit.yml — Layer 3: weekly whole-corpus sweep that files issues (the recall safety net for what the scoped map misses), deduped against open findings and capped. Also folds in the doc edits from the #498/#502 pass: the agent-guidance page coherence fix, plus the attribute-arg fix surfaced by the #502 A/B (bare [Component]/[Archetype] -> the required-arg forms) in the page primer and the llms.txt preamble. Part of #490. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01E8KzH4pPW5Dq7Y94NXfgrM
|
📝 Doc-accuracy review (advisory · scoped · Layer 2) Reviewed: Finding:
Advisory & scoped to the pages the change touches — recall for cross-cutting or unmapped drift is covered by the weekly Layer 3 audit. |
The Layer-2 doc-accuracy reviewer added in this PR ran on this PR and
flagged that the idioms table row 1 still showed bare [Component] /
[Archetype] while the §5 primer and §4 example use the required-arg
forms. Make row 1 consistent: [Component("Name", rev)] / [Archetype(id)].
A live demonstration of the net catching real drift on its own PR.
Part of #490.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01E8KzH4pPW5Dq7Y94NXfgrM
|
📝 Doc-accuracy review (advisory · scoped · Layer 2) Reviewed: Findings:
Advisory & scoped to the pages the change touches — recall for cross-cutting or unmapped drift is covered by the weekly Layer 3 audit. |
Second finding from the Layer-2 reviewer dogfooding on this PR: the §4 minimal-example comment still asserted the pre-#505 "never the global one" rule, contradicting the softened idiom #1. Align it — a named namespace is tidier, the global namespace also works. Part of #490. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01E8KzH4pPW5Dq7Y94NXfgrM
|
📝 Doc-accuracy review (advisory · scoped · Layer 2) Reviewed: No contradictions found in the reviewed pages. Cross-checks performed against the diff's substantive claims:
Advisory & scoped to the pages the change touches — recall for cross-cutting or unmapped drift is covered by the weekly Layer 3 audit. |
Summary
Implements Layer 2 + Layer 3 of the doc-accuracy design (
claude/design/doc-accuracy-and-generated-artifacts.md) — the semantic drift (prose contradicting code) that no linter or generator can catch. Layer 1 (telemetry--check+ broken-link/xref gates) is already live inbuild-docs.yml.What's here
coverage/docs-affected-map.json— coarse source-area → doc-page map, the hand-authored twin of the test-affected map. Generous values; routes Transactions/ECS/Query/Storage → the agent-guidance page (part of Author 'Using Typhon with an AI coding agent' guidance (idioms + gotchas) #498). Validated: 0 stale entries across all 18 source areas.scripts/docs-affected.py— resolver: changed files → affected pages; surfaces unmapped source areas and stale map entries so the map self-heals..github/workflows/doc-accuracy-review.yml— Layer 2: scoped, advisory per-PR reviewer (reuses the issue-triage auth — no new secrets). Posts one comment citingfile:linefor both the doc line and the contradicting code line; fork PRs skipped..github/workflows/doc-accuracy-audit.yml— Layer 3: weekly whole-corpus sweep that files issues (the recall safety net for what per-PR scoping misses), deduped against open[doc-audit]issues and capped at 5/run.Also folds in the doc edits from the #498/#502 pass: the agent-guidance page coherence fix, and the attribute-arg fix surfaced by the #502 A/B (bare
[Component]/[Archetype]→ the required-arg forms) in the page primer and the llms.txt preamble.Design constraints honored (from the design doc)
file:linefor both sides.generate > lint > LLM-judgeprecedence — the LLM only ever sees the irreducible prose residue.Validation (local)
Foundation/Concurrency/AccessControlSmall.csroutes correctly (the design's headline example).🐕 Dogfood — the net caught real drift on its own PR
Contrary to my initial assumption, a new
pull_requestworkflow does run on the PR that introduces it. Thereviewcheck ran the Layer-2 reviewer against this PR's doc change, passed, and correctly flagged that the idioms table row 1 still showed bare[Component]/[Archetype]while the §5 primer + §4 example used the required-arg forms — grounding the finding insrc/Typhon.Schema.Definition/Attributes.cs(args are required) and citingfile:lineon both sides. Fixed in22c9301. The net demonstrated itself on commit #1.Part of #490.
🤖 Generated with Claude Code
https://claude.ai/code/session_01E8KzH4pPW5Dq7Y94NXfgrM