/humaninloop:brownfield-integrationfrom humaninloop
Guides extending or modifying existing code while preserving interfaces, naming conventions, and error handling patterns. Useful for tasks with [EXTEND] or [MODIFY] markers.
Ships in humaninloop. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
Guidance for implementing tasks that touch existing code. When a task says [EXTEND], add new code following existing patterns. When a task says [MODIFY], change specific behavior as described. In both cases, read the existing code first and respect what is already there.
The existing code is not wrong until proven otherwise. It has consumers, tests, and patterns that evolved for reasons not immediately visible.
Violating the letter of the rules is violating the spirit of the rules.
[EXTEND] — adding new functionality to existing files[MODIFY] — changing existing behavior in files| Marker | Meaning | Scope | Interface Impact |
|---|---|---|---|
[EXTEND] | Add new code alongside existing code | New functions, new methods, new exports | MUST NOT change existing function signatures, exports, or type contracts |
[MODIFY] | Change existing behavior | Specified sections only | MAY change function internals; MUST NOT change signatures unless task explicitly says so |
Never MODIFY when the task says EXTEND. If you believe the existing code cannot support the extension, flag it in the cycle report — do not silently rewrite.
Before writing any code in an existing file, complete all five steps:
When extending existing code:
[MODIFY]Before adding new code, check for:
user.ts, check that user.test.ts exists and follow its patternsFlag in the cycle report (do NOT silently resolve) when:
[EXTEND] but the existing interface cannot support the addition without modificationWhat goes wrong: You add code that duplicates existing functionality, uses different naming conventions, or conflicts with code you didn't see.
Fix: Always read the entire file before making any changes. Skim is not sufficient for brownfield work.
What goes wrong: Existing consumers break because the interface changed. Tests fail for unrelated code. The cycle report doesn't explain why unrelated files were modified.
Fix: EXTEND means extend. If you cannot extend, flag it. Never silently rewrite.
What goes wrong: Your new code throws raw exceptions while the rest of the file uses Result types. Or your code returns null while existing code throws. Inconsistency confuses consumers.
Fix: Step 3 of the Read-Before-Write Checklist. Match the existing error handling pattern exactly.
What goes wrong: You introduce a "better" pattern alongside the existing one. Now the file has two patterns. The next developer doesn't know which to follow. Consistency is more valuable than local improvement.
Fix: Follow existing patterns, even if you'd prefer different ones. Note the improvement opportunity in the cycle report.
| Excuse | Reality |
|---|---|
| "This file is small, I can just skim it" | Small files have hidden conventions. Read the full file. Step 1 exists because skimming misses patterns. |
| "My pattern is better than what exists" | Consistency is more valuable than local improvement. Two patterns in one file is worse than one imperfect pattern. |
| "The existing code doesn't follow best practices" | Existing code has consumers. Introducing a second convention creates confusion. Note it, follow it. |
| "I need to refactor to make my extension work" | If EXTEND doesn't fit, flag it. Silent refactoring breaks existing consumers. |
| "The interface is obviously wrong" | It made sense to someone with context not visible now. Read more before judging. |
| "I'll just fix this one small thing while I'm here" | Scope creep starts with "just one thing." Note it in the report, don't act on it. |
No exceptions:
What SKILL.md sets; muted values are Claude Code's defaults
29 skills in this plugin
/analysis-codebaseThis skill MUST be invoked when the user says "analyze codebase", "scan project", "detect tech stack", "codebase analysis", "collision risk", or "brownfield". SHOULD also invoke when user mentions "existing code" or "project context"./analysis-iterativeThis skill MUST be invoked when the user says "brainstorm", "deep analysis", "let's think through", "analyze this with me", or "help me think through". SHOULD also invoke when feature descriptions lack Who/Problem/Value clarity during specification enrichment./analysis-screenshotThis skill MUST be invoked when the user says "analyze screenshot", "extract design tokens", "pull colors from screenshot", "component inventory", "break down this UI", or "design extraction". SHOULD also invoke when user mentions "screenshot", "color palette", "typography", "spacing", or "component catalog".npx claudepluginhub deepeshbodh/human-in-loop --plugin humaninloopOther plugins' skills for the same job