Solution exploration and implementation. Generate 2-3 approaches, pick simplest. Never implement first idea. Triggers: build, implement, create, feature, add.
From kernelnpx claudepluginhub ariaxhan/kernel-claude --plugin kernelThis skill is limited to using the following tools:
reference/build-research.mdImplements structured self-debugging workflow for AI agent failures: capture errors, diagnose patterns like loops or context overflow, apply contained recoveries, and generate introspection reports.
Designs and optimizes AI agent action spaces, tool definitions, observation formats, error recovery, and context for higher task completion rates.
Compares coding agents like Claude Code and Aider on custom YAML-defined codebase tasks using git worktrees, measuring pass rate, cost, time, and consistency.
Minimal code through maximum research. The best code is code you don't write. Your first solution is never right. Explore, compare, choose simplest.
Prerequisite: AgentDB read-start has already run. Tier classification done via /kernel:ingest.
Reference: skills/build/reference/build-research.md
GOAL: [What are we building?]
CONSTRAINTS: [Limitations, requirements, must-haves]
INPUTS: [What do we have to work with?]
OUTPUTS: [What should exist when done?]
DONE-WHEN: [How do we know it's complete?]
Rule: Generate 2-3 approaches minimum. Never implement first idea.
Per solution, document:
Evaluation criteria (ordered):
Rules:
_meta/plans/{feature}.mdBefore web search, check for cached research in _meta/research/.
Cache format — research files use frontmatter:
---
query: "{original search query}"
date: "YYYY-MM-DD"
ttl: 7 # days
domain: "{tech domain}"
---
TTL rules:
Cache check protocol:
ls _meta/research/ for topic matchestoday - date < ttl: use cached result, skip web searchCold start: No behavior change when cache empty — search normally, create cache entry.
Note: Cache hits still check agentdb for learnings. Learnings are never cached — always fresh.
Confirm (not guess) max 6 per category:
BEFORE each step: review research doc, check if fewer lines possible. DURING: use researched package, minimal changes, follow existing patterns, one commit per logical unit. AFTER: verify works, count lines (can reduce?), commit, update plan.
If tier 2+: You are the surgeon. Follow contract scope exactly.
Automated (run what exists):
npm test / pytest / cargo test / go testeslint / ruff / clippytsc --noEmit / mypyManual: walk through done-when criteria. Document how verified.
Edge cases (at least 3): empty/null, boundary, error/failure path.
git checkout or git stashReport: feature name, branch, files changed, validation results, next steps.
agentdb write-end '{"skill":"build","feature":"X","files":["Y"],"approach":"Z"}'
Subagent scoping: When spawning agents for implementation, scope each agent to a single file or function boundary. Cross-file agents produce merge conflicts and silent overrides.
Prefer Read before Write: Always read the target file before editing it, even when the task is purely additive. Prevents format drift and ensures you match existing style.
Minimal footprint: Request only the permissions and file access actually needed. Touch the minimum viable set of files. Unanticipated side effects compound across agents.
Interrupt-safe commits: Commit every working state, not just at milestone boundaries. If an agent is interrupted mid-task, the last commit must be valid and buildable.
Clarify before long tasks: For tasks estimated >5 min, surface ambiguities before starting. Mid-task clarification requests cause partial-state problems.
Long build sessions degrade model performance as context fills. Mitigate:
/compact before context degrades. Signal: responses
getting shorter, earlier instructions being ignored, more mistakes per edit./clear between unrelated tasks.The Velocity Paradox (METR 2025): Developers with AI assistance feel ~20% faster but measure ~19% slower. Root cause: shifting to ~10% planning / ~90% implementation — AI makes coding cheap, so people skip planning. Fix: 50-70% planning / 30-50% implementation → 50% fewer refactors, 3x overall velocity.
Invest in:
Verification-first multiplier: Providing tests, screenshots, or expected outputs BEFORE asking Claude to implement changes quality dramatically. Claude can run verification against its own output throughout the session — not just at the end. State verification criteria at session START.
Adaptive thinking (Claude 4.6): Claude Opus/Sonnet 4.6 uses adaptive thinking, not budget_tokens.
When spawning agents for deep reasoning, guide effort via instruction:
"After reviewing tool results, reflect carefully before proceeding""This is straightforward, implement directly"--quick: skip confirmations, minimal prompts--plan-only: stop after planning--resume: continue in-progress work--validate-only: skip to validation