branch-context
Explicit branch-context (branch context) work: enriched-plan local plan store, source branch plan file, branch-context slug, attached plan, Branch Memory attachment, change/retarget a saved plan's source branch, move/copy saved plans, inspect plan store, repair branch-context metadata, or Pi commands `/ns:branch-context:from-plan`, `/ns:branch-context:upstack-impl-from-plan`, `/ns:branch-context:impl-attached-plan`. Not for generic planning, branch creation, or implementation unless branch-context intent is explicit.
- License 许可
- MIT
- 所属仓库
- nseng-ai/ns
- 最近更新
- 2026-10-02
- Stars
- ★ 2
- Forks
- 0
01 前言 Front Matter
- name
- branch-context
- description
- Explicit branch-context (branch context) work: enriched-plan local plan store, source branch plan file, branch-context slug, attached plan, Branch Memory attachment, change/retarget a saved plan's source branch, move/copy saved plans, inspect plan store, repair branch-context metadata, or Pi commands `/ns:branch-context:from-plan`, `/ns:branch-context:upstack-impl-from-plan`, `/ns:branch-context:impl-attached-plan`. Not for generic planning, branch creation, or implementation unless branch-context intent is explicit.
02 资源文件 2
- 参考文档references/diagnostics-admin.md4.2 KB
- 参考文档references/lifecycle.md5.4 KB
03 SKILL.md 正文
branch-context
Shared lifecycle, terminology, safety posture, diagnostics, and administration for the branch-context skill family. Each operation's command contract lives in its step skill.
Skill family
Step entrypoints carry their own command and recovery and are runnable standalone:
branch-context-from-plan— create a branch and attach a named plan key as branch context from a saved plan.branch-context-impl— load and implement an attached plan.
The Pi /ns:branch-context:upstack-impl-from-plan command has no separate step skill: it composes branch-context-from-plan (create/attach) and then branch-context-impl (implementation) in a fresh session.
Use this skill for the shared model the step skills assume, and for diagnostics, admin, and repair work the step skills do not cover.
Do not use this skill for
- Generic Branch Memory work unless it concerns the branch-context namespace/attached-plan contract.
- Replacing the step skills for a specific write/create/implement request; it is their shared reference, not a substitute.
Default safety posture
- Inspect before mutating.
- Refuse collisions, existing files, existing branches, and existing Branch Memory entries unless the user gives explicit replacement/destructive intent.
- Prefer deterministic
enriched-planread commands for Saved plans andns branch-context execcommands for branch/attachment operations when available. - Use read-only Branch Memory inspection only for diagnostics.
References
Each step skill carries its own command, slug rule, recovery, and report fields inline, so the common path needs no reference hop. Load a reference only when the task needs the shared model or a non-happy-path flow:
references/lifecycle.md— terms, lifecycle, storage boundaries, Pi/CLI surfaces, branch creation policy. Load to keep Saved plan vs Attached plan, the two slug kinds, and the two storage locations distinct.references/diagnostics-admin.md— inspection, recovery, read-only Branch Memory inspection, retarget/copy admin, collision handling, destructive-change safety. Load for repair, inspection, or admin.
04 同仓库更多 Skills
pr-make-accountable
Interview a PR author to establish shared understanding of intent and design decisions, then co-author the What / Why / Changes PR body with opt-in Requested reviewer focus.
typescript-style
Opinionated style guide for strict, portable TypeScript. Use when writing, designing, or reviewing TypeScript: type design, boundary validation, error handling, module architecture, and review discipline.
typescript-fake-driven-testing
TypeScript fake-driven testing architecture. Use when writing or reviewing TS code with external dependencies, gateway interfaces, real adapters, in-memory fakes, or CLI scenario tests.
ns-typescript
TypeScript overlay for ns-style projects. Use when editing or reviewing TS in this repo: tsconfig baseline, pnpm/Vitest/oxlint/oxfmt/native tsc commands, relative .ts imports, workspace subpath exports, and the exactOptionalPropertyTypes spread idiom. Repo-specific enforcement (test lanes, time seams, style guard) lives in the host repo's AGENTS.md.
ns-typescript-style-tripwire
Invoke the ns TypeScript style Tripwire against a supplied diff or current branch.
skill-management
Manage skills with `npx skills`: add, edit, remove, rename, update, or list skills (local or GitHub), and the nested `skills/<disposition>/.../<name>/` / flat `.agents/skills/` layout conventions.