docs(#189): add API pattern replication guidance to AGENTS.md - #205
docs(#189): add API pattern replication guidance to AGENTS.md#205fullsend-ai-coder[bot] wants to merge 2 commits into
Conversation
Add a new section after "Forge abstraction" instructing agents to read existing sibling methods before implementing new ones that call the same API endpoint or use the same multi-step pattern. The guidance covers replicating error handling (truncation checks, 404-to-ErrNotFound mapping), retry logic (retryOnTransient), and response validation, with the Git Trees API pattern in internal/forge/github/github.go as a concrete example. Closes #189
Review — ApprovePR: #205 — SummaryThis PR adds a new "API pattern replication" section to AGENTS.md, instructing agents to read existing sibling methods before implementing new ones that call the same API endpoint, and to replicate error handling, retry logic, and response validation. It also adds a corresponding "When reviewing PRs" directive. The change closes issue #189. Dimensions reviewed
VerdictClean across all reviewed dimensions. The new guidance is technically accurate, properly scoped to the linked issue, stylistically consistent with the surrounding content, and well-placed in the document structure. No findings.
Previous runReview — PR #205Verdict: Approve SummaryThis PR adds a 4-line "API pattern replication" section to Verified claimsAll technical references in the new section were verified against the codebase:
Dimension assessment
Notes
Previous run (2)ReviewVerdict: Approve — no blocking findings. Two low-severity observations noted below. Scope: 4 lines added to What was checked
Findings1. "Several methods" overstates current stateSeverity: Low · Category: technical-accuracy · File:
Only one method — The guidance is still sound as a forward-looking rule (future methods should replicate the pattern), but the concrete example weakens credibility because a reader checking the code will find one shared implementation, not several. Consider rewording to: "...has a method ( 2. No "When reviewing PRs" counterpartSeverity: Low · Category: document-consistency · File: The two comparable sections — "Forge abstraction" and "Architecture Decision Records" — both include a bold When reviewing PRs: paragraph that tells reviewers what to flag. The new section provides implementation guidance but no review instruction. Adding something like "When reviewing PRs: Flag new forge methods that omit error handling or retry patterns present in existing methods using the same API endpoint" would close the loop and make the rule enforceable during review, not just during authoring.
Previous run (3)Review — commentPR: docs(#189): add API pattern replication guidance to AGENTS.md This PR adds an "API pattern replication" section to AGENTS.md, instructing agents to read existing sibling methods before implementing new ones that call the same API endpoint. The change traces to issue #189, which was created by the repo owner after a retro on PR fullsend-ai#2360 where a missing truncation check required a full fix iteration. Findings1. Technical accuracy — "several methods" claim ·
|
|
/fs-review |
|
/fs-review |
|
🤖 Finished Review · ✅ Success · Started 10:19 AM UTC · Completed 10:23 AM UTC |
|
/fs-fix |
|
🤖 Finished Fix · ✅ Success · Started 11:12 AM UTC · Completed 11:19 AM UTC |
- Replace 'several methods' with specific reference to commitFilesTo, which is the only method implementing the full Git Trees API pattern - Add 'When reviewing PRs' paragraph for consistency with adjacent Forge abstraction and ADR sections Addresses review feedback on #205
🔧 Fix agent — iteration 1 (human-triggered)Addressed 2 review findings: (1) fixed factual inaccuracy where 'several methods' overstated the number of independent Git Trees API implementations — only commitFilesTo has the full pattern, (2) added 'When reviewing PRs:' paragraph for document consistency with adjacent sections. Both findings were verified against internal/forge/github/github.go. Fixed (2):
Tests: passed Updated by fullsend fix agent |
|
🤖 Finished Review · ✅ Success · Started 11:25 AM UTC · Completed 11:31 AM UTC |
Add a new section after "Forge abstraction" instructing agents to read existing sibling methods before implementing new ones that call the same API endpoint or use the same multi-step pattern. The guidance covers replicating error handling (truncation checks, 404-to-ErrNotFound mapping), retry logic (retryOnTransient), and response validation, with the Git Trees API pattern in internal/forge/github/github.go as a concrete example.
Closes #189
Post-script verification
agent/189-api-pattern-replication-guidance)f96750babbed5ada406a9ae04e8068449701d9c7..HEAD)