principles
Engineering principles index. Use when writing, changing, or reviewing tests, or when the user cites an engineering principle or asks which one applies.
- License 许可
- MIT
- 所属仓库
- syanga/astack
- 最近更新
- 2026-11-14
- Stars
- ★ 0
- Forks
- 0
01 前言 Front Matter
- name
- principles
- description
- Engineering principles index. Use when writing, changing, or reviewing tests, or when the user cites an engineering principle or asks which one applies.
02 资源文件 28
- 参考文档attack-the-premise.md1.5 KB
- 参考文档boundary-discipline.md1.5 KB
- 参考文档build-the-lever.md2.1 KB
- 参考文档deep-modules.md5.6 KB
- 参考文档encode-lessons-in-structure.md1.3 KB
- 参考文档exhaust-the-design-space.md771 B
- 参考文档experience-first.md1021 B
- 参考文档explain-the-number.md1.9 KB
- 参考文档fix-root-causes.md1.4 KB
- 参考文档foundational-thinking.md1.3 KB
- 参考文档guard-the-context-window.md817 B
- 参考文档laziness-protocol.md1.1 KB
- 许可证LICENSE1.0 KB
- 许可证LICENSE-mattpocock1.0 KB
- 参考文档make-operations-idempotent.md1.7 KB
- 参考文档migrate-callers-then-delete-legacy-apis.md751 B
- 参考文档minimize-reader-load.md1.8 KB
- 参考文档model-the-domain.md1.9 KB
- 参考文档never-block-on-the-human.md1.2 KB
- 参考文档outcome-oriented-execution.md564 B
- 参考文档prove-it-works.md1.5 KB
- 参考文档redesign-from-first-principles.md539 B
- 参考文档scale-the-workflow.md1.6 KB
- 参考文档separate-before-serializing-shared-state.md1.2 KB
- 参考文档sequence-verifiable-units.md1.7 KB
- 参考文档subtract-before-you-add.md709 B
- 参考文档test-behavior-not-implementation.md3.7 KB
- 参考文档type-system-discipline.md4.5 KB
03 SKILL.md 正文
Principles
Before applying a principle, read its file in full. In the reply, name the decision the principle changed.
Shaping a change
laziness-protocol.md. Refactoring, sizing a diff, or adding a layer.foundational-thinking.md. Choosing core types and data structures, or sequencing setup before feature work.subtract-before-you-add.md. Sequencing an addition or a refactor.redesign-from-first-principles.md. Integrating a new requirement into an existing design.attack-the-premise.md. Repeated fixes for an imbalance across actors share one premise and have failed the same check.outcome-oriented-execution.md. Planned rewrites and migrations with explicit phase boundaries.experience-first.md. Product, UX, or feature-scope tradeoffs.exhaust-the-design-space.md. Novel interactions or architectural choices with no established precedent.minimize-reader-load.md. Reviewing code that is hard to trace, or adding a layer or a piece of state.build-the-lever.md. Work beyond a couple of obvious edits.encode-lessons-in-structure.md. Writing the same instruction twice, or handling a correction from the user or a failed test.
Designing structure
deep-modules.md. Designing module interfaces, choosing seams, or evaluating abstraction depth.model-the-domain.md. Stateful logic, or code that branches a lot or repeats a shape assumption across files.boundary-discipline.md. Validation, error handling, framework adapters.type-system-discipline.md. Designing a type or a signature in a typed language.make-operations-idempotent.md. Commands and loops that must survive crashes and retries.migrate-callers-then-delete-legacy-apis.md. A new internal API while old callers still exist.separate-before-serializing-shared-state.md. Concurrent actors that might write the same file, branch, or key.
Verifying the work
prove-it-works.md. Before you call the work done.explain-the-number.md. Before you measure or estimate a run time, and before you trust, report, or act on a measured number.fix-root-causes.md. Debugging.sequence-verifiable-units.md. Multi-step work, and stacking commits and PRs.test-behavior-not-implementation.md. Writing, changing, or keeping a test.
Managing the work
guard-the-context-window.md. Large outputs, long files, repeated reads, or plans for parallel work.never-block-on-the-human.md. Deciding whether to ask for permission during an authorized task.scale-the-workflow.md. Delegation, grounding, review, and delivery in a fix or diagnosis workflow.
04 同仓库更多 Skills
replace-with-skill-name
Replace with when this skill should be reached.
writing-for-agents
Writing documents for agents. Use when creating or editing skills, or modifying AGENTS.md or CLAUDE.md.
worktree-cleanup
Worktree cleanup. Use for cleanup, resource audits, close this lane, or close out.
wizard
Generate an interactive Bash wizard that walks a human through steps only they can perform. Use when provisioning, credential setup, or a one-off migration needs such steps.
why
Use for 'why does X work this way', 'why we picked Y', design rationale, regressions, postmortems, or data-backed thresholds. Returns a cited read on decisions and tradeoffs.
wayfinder
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 until the way to the destination is clear.