个人作者
Matthew Shen
Computer Science and Biology @ McGill University | making computer do cool thing
- Skills
- 50
- 仓库
- 1
- 职业覆盖
- 0
- 场景覆盖
- 0
- Stars
- ★ 0
Matthew Shen 的 Skills 50
unslop
Edit substantive human-facing prose to remove AI writing patterns while preserving meaning and tone.
pstack-principle-type-system-discipline
Apply when designing types, reviewing a function signature, or writing code in any statically-typed language. Make illegal states unrepresentable, brand semantic primitives, parse external data at boundaries, refuse to lie to the compiler, exhaust variants, derive from authoritative schemas.
pstack-principle-test-behavior-not-implementation
Apply when you write, change, or keep a test. Call the code the way its users do and assert the result they observe against a literal expected value. If the test would still pass when every imported function returns undefined, rewrite the assertion or delete the test.
pstack-principle-subtract-before-you-add
Apply when sequencing an addition, refactor, or rewrite. Remove dead weight, redundant validators, and stub references first, then build on the simpler base.
pstack-principle-sequence-verifiable-units
Sequence migrations or dependent changes around meaningful verification boundaries.
pstack-principle-separate-before-serializing-shared-state
Apply when concurrent actors might write to the same file, branch, key, or state object. Eliminate the sharing first; serialize structurally only when one shared writer is a real invariant.
pstack-principle-redesign-from-first-principles
Apply when integrating a new requirement into an existing design. Redesign as if the requirement had been a foundational assumption from day one, instead of bolting it on.
pstack-principle-prove-it-works
Choose direct evidence when a completion claim depends on runtime behavior, integration, or a delegated artifact.
pstack-principle-outcome-oriented-execution
Apply during planned rewrites and migrations with explicit phase boundaries. Converge on the target architecture; don't preserve smooth intermediate states with throwaway compatibility code.
pstack-principle-never-block-on-the-human
Resolve unnecessary approval pauses during already-authorized, reversible work.
pstack-principle-model-the-domain
Apply when writing stateful logic, or when code branches a lot or repeats a shape assumption across files. Encode the domain in a structure instead of scattered conditionals.
pstack-principle-minimize-reader-load
Apply when reviewing or shaping code that's hard to trace. Count layers between question and answer, and hidden state in the reader's head; collapse one-caller wrappers and shrink mutable scope.
pstack-principle-migrate-callers-then-delete-legacy-apis
Apply when introducing a new internal API while old callers still exist. Migrate callers and delete the old API in the same wave instead of preserving compatibility layers.
pstack-principle-make-operations-idempotent
Apply when designing commands, lifecycle steps, or processing loops that run amid crashes, restarts, and retries. Converge to the same end state regardless of partial prior runs.
pstack-principle-laziness-protocol
Apply when refactoring, evaluating diff size, or tempted to add abstractions, layers, or signal threading. Bias toward deletion and the smallest change that solves the problem.
pstack-principle-guard-the-context-window
Reduce context pressure from large outputs, broad exploration, or repeated reads.
pstack-principle-foundational-thinking
Apply before writing logic: choosing core types and data structures, sequencing scaffold-vs-feature work, asking what concurrent actors share. Get the data structures right so downstream code becomes obvious.
pstack-principle-fix-root-causes
Apply when debugging. Trace each symptom to its root cause and fix it there; reproduce first, ask why until you reach it, resist nil-check guards that silence crashes.