branch-context-impl
Use when a user explicitly wants to implement from an attached branch-context plan on the current branch — "implement the branch context", "load the attached…
Skill by nseng-ai
Install
Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.
npx agentmarket install skill/nseng-ai-branch-context-impl
Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.
Get the weekly diff
The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.
About
Reviews
Write a reviewNo reviews yet. Installed it? Reviews come from verified installers only. How reviews work
Permissions
What this skill can do and what it asks for, from its SKILL.md. Checked Oct 25, 2026.
- Tools
- No tools found
- Secrets
- None asked for
- Install scripts
- None found
Network hosts it talks to 1
codeload.github.com· found in install command
Files it touches
~/.claude/skills/branch-context-impl
What's inside
- Skill name
branch-context-impl- Description
- Use when a user explicitly wants to implement from an attached branch-context plan on the current branch — "implement the branch context", "load the attached branch-context plan", "continue from the branch context plan" — or to continue a Pi `/ns:branch-context:impl-attached-plan` handoff.
- License
- MIT
- Instructions
- 37 lines in SKILL.md · view on GitHub
Files (2)
- SKILL.md
- openai.yaml · agents/
SKILL.md (first lines)
# branch-context-impl
Load the attached plan from Branch Memory and implement from it as the source of truth. Part of the branch-context family — load the `branch-context` umbrella for the shared lifecycle, storage, and safety model.
## Command
```bash
prompt_dir=$(mktemp -d "${TMPDIR:-/tmp}/branch-context-impl.XXXXXXXX")
prompt_file="$prompt_dir/prompt.md"
ns branch-context exec load [key] --prompt-file "$prompt_file" --format json
```
- Reads the current branch by default and auto-selects the attached plan only when Branch Memory namespace `branch-context` has exactly one supported named Markdown entry. If multiple supported entries exist, pass an explicit key; an optional argument is treated as an exact attached Branch Memory key selector.
- Fallback: if the current branch has no attached branch-context entry and no explicit key was requested, the loader falls back to the current session's saved plan evidence, then the latest `.md` file in the current repo/source-branch local plan store.
- Legacy `plan.md` entries are unsupported; reattach under a named Markdown key such as `<slug>.md` before loading.
- JSON output uses the standard Clinkr envelope; bounded metadata lives under `data`.
- Do not use `--include-content` or `--include-prompt` during normal agent operation; those flags can exceed harness stdout limits on large plans.
## Workflow
1. Create a temp prompt file, then run `load --prompt-file "$prompt_file" --format json` (include an explicit key only when the user provided one).
2. Read the returned `data.implementationPromptFile` with the file-reading tool before editing code.
3. Treat the attached plan in that prompt as authoritative unless current repo state proves it stale; if stale, explain the discrepancy before changing scope. Plan findings with provenance and anchors are inherited evidence: verify the anchors, do not rerun reconnaissance the plan captured, and name the trigger before expanding beyond that evidence. See `docs/conventions/agent-context-economy.md`. If you go beyond or against what the plan settled, anything the plan ruled out becomes an open question again — recheck why it was ruled out, and look for an existing sibling that already does what you are about to build, before designing the extension.
4. Apply the branch-context plan contract protocol when the Attached plan has contract sections. If it includes current-state excerpts, scope boundaries, verification gates, or STOP conditions, compare excerpts against live repo state before executing the plan's first step; an excerpt mismatch is a STOP. If those sections are absent, explicitly recognize an old-format/pre-contract plan and do not invent gates or half-apply excerpt checks.
5. Stop and report instead of guessing on any STOP trigger: content/excerpt anchors no longer match live code; ambiguity or internal inconsistency; implementation requires touching an out-of-scope file/area; the plan asks for mutating Branch Memory; or no attached plan is available where one is required. One scoped exception, for stale branch names only: a stale recorded branch name or branch-name STOP gate is not by itself a STOP — the loader-selected branch/key/ref is the runtime identity when the current branch is non-trunk and loader evidence, `git branch --show-current`, and the Branch Memory target agree; document that as a minimal adaptation. If those three disagree, stop.
6. Document minimal adaptations: report what changed, why the plan prediction was wrong, and which validation covers the adaptation. Silent deviations are failures.
7. Implement in focused steps; investigate validation failures, rerun appropriate gates after fixes, report unresolved failures accurately, and note any skipped declared gate and why.
8. Before finishing, compare changed files to the plan's scope. Note autofixer-only formatting outside scope separately; intentional executor edits outside scope require user approval.
9. Report implemented changes, files changed/tree state, validation results, plan deviations, unresolved follow-up, and for any STOP: observed vs expected plus the exact gate/assumption that failed.
## Recovery
- No attached entry and saved-plan fallback also fails: report both failures and ask whether to run `branch-context-from-plan`, switch to the implementation branch, or pass an explicit saved plan to `/ns:branch-context:from-plan` first.
- Missing, unexpected, or ambiguous attached plan key: inspect `brmem list --namespace branch-context --branch <branch>` and rerun `load <key>` only when the user explicitly chooses the key.
- Current branch is trunk/default/detached: stop and ask for the intended implementation branch.From nseng-ai/ns, MIT.
More from nseng-ai/ns
- 0.553score
branch-context-from-plan
nseng-ai
Use when a user explicitly wants to create an implementation branch from a saved plan and attach its branch context as a named Markdown key — "from plan"…
SkillBFreshness: B★ 2Claude Code +9 - 0.537score
diagnosing-bugs
nseng-ai
Diagnosis loop for hard bugs and performance regressions.
SkillBFreshness: B★ 2Claude Code +9 - 0.532score
pocock-review
nseng-ai
Review the changes since a fixed point (commit, branch, tag, or merge-base) along two axes — Standards (does the code follow this repo's documented coding…
SkillBFreshness: B★ 2Claude Code +9 - 0.532score
domain-modeling
nseng-ai
Build and sharpen a project's domain model.
SkillBFreshness: B★ 2Claude Code +9 - 0.532score
codebase-design
nseng-ai
Shared vocabulary for designing deep modules.
SkillBFreshness: B★ 2Claude Code +9 - 0.531score
writing-for-agents
nseng-ai
Writing documents for agents.
SkillBFreshness: B★ 2Claude Code +9 - 0.529score
wayfinder
nseng-ai
Plan a huge chunk of work — more than one agent session can hold — as a shared map of decision tickets on your issue tracker, and resolve them one at a time…
SkillBFreshness: B★ 2Claude Code +9 - 0.529score
improve-codebase-architecture
nseng-ai
Scan a codebase for deepening opportunities, present them as a visual HTML report, then grill through whichever one you pick.
SkillBFreshness: B★ 2Claude Code +9 - 0.527score
grilling
nseng-ai
Grill the user relentlessly about a plan, decision, or idea.
SkillBFreshness: B★ 2Claude Code +9 - 0.507score
fdt-refactor-mock-to-fake
nseng-ai
Refactor tests that use unittest.mock.patch or MagicMock into erk's gateway-based fake pattern.
SkillCFreshness: C★ 2Claude Code +9 - 0.476score
pocock-resolving-merge-conflicts
nseng-ai
Use when you need to resolve an in-progress git merge/rebase conflict.
SkillCFreshness: C★ 2Claude Code +9
Signals
- Stars
- 2
- Forks
- 0
- Open issues
- 4
- Last commit (this folder)
- Aug 9, 2026 (2 months ago)
From GitHub (fetched Oct 24, 2026).
Details
- License
- MIT
- Repository
- github.com/nseng-ai/ns
- First seen
- Oct 24, 2026
- Last checked
- Oct 24, 2026
- Source
- GitHubgithub-graphql
More from nseng-ai
- 0.553score
branch-context-from-plan
nseng-ai
Use when a user explicitly wants to create an implementation branch from a saved plan and attach its branch context as a named Markdown key — "from plan"…
SkillBFreshness: B★ 2Claude Code +9 - 0.537score
diagnosing-bugs
nseng-ai
Diagnosis loop for hard bugs and performance regressions.
SkillBFreshness: B★ 2Claude Code +9 - 0.532score
pocock-review
nseng-ai
Review the changes since a fixed point (commit, branch, tag, or merge-base) along two axes — Standards (does the code follow this repo's documented coding…
SkillBFreshness: B★ 2Claude Code +9 - 0.532score
domain-modeling
nseng-ai
Build and sharpen a project's domain model.
SkillBFreshness: B★ 2Claude Code +9 - 0.532score
codebase-design
nseng-ai
Shared vocabulary for designing deep modules.
SkillBFreshness: B★ 2Claude Code +9 - 0.531score
writing-for-agents
nseng-ai
Writing documents for agents.
SkillBFreshness: B★ 2Claude Code +9
Cite this page
branch-context-impl skill. Agent Mart. https://agentmart.dev/skills/nseng-ai-branch-context-impl (last updated 2026-10-24)