Skip to content
Back to skills

Pstack Principles

ASecurity

Use before refactoring, debugging, design, or any software engineering related task

  • 2 stars
  • 0 votes
  • 0 copies
  • 7 views
  • Added November 14, 2026
code-qualityrustdebuggingrefactoringgitapiperformance

Works with

  • cursor
  • api

Security analysis

A100/100

Pro scans all 20 files and shows the line behind each finding

Scanned November 14, 2026

npx -y skills add anntnzrb/agents --skill pstack-principles --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Pstack Principles?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Pstack Principles
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/anntnzrb-pstack-principles/badge)](https://www.skillsdirectory.com/skills/anntnzrb-pstack-principles)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: pstack-principles
description: "Use before refactoring, debugging, design, or any software engineering related task"
license: AGPL-3.0-or-later
---

# Pstack Principles

Twenty-four engineering principles from pstack (Lauren Tan, MIT). One bundled skill, not twenty-four, to protect the skill-inventory metadata budget.

**Rules of use:**

- Match the task to rows whose When column fits. Read the referenced file in full before applying. Applying from the index line alone is not allowed.
- When you report, name each principle that shaped a decision and the specific choice it changed. A citation with no decision behind it means you skipped the leaf file.
- If principles conflict, the smaller change wins unless a verification principle says otherwise.
- Ported from https://github.com/cursor/plugins/tree/main/pstack (MIT). Cross-references point to local files.

## Required follow-up reads

| Need | Read | When |
| --- | --- | --- |
| Laziness Protocol rule | [references/principle-laziness-protocol.md](references/principle-laziness-protocol.md) | Refactoring, sizing a diff, or tempted to add abstractions, layers, or signal threading |
| Foundational Thinking rule | [references/principle-foundational-thinking.md](references/principle-foundational-thinking.md) | Before writing logic: core types and data structures, scaffold-vs-feature sequencing, what concurrent actors share |
| Redesign from First Principles rule | [references/principle-redesign-from-first-principles.md](references/principle-redesign-from-first-principles.md) | Integrating a new requirement into an existing design |
| Subtract Before You Add rule | [references/principle-subtract-before-you-add.md](references/principle-subtract-before-you-add.md) | Sequencing an addition, refactor, or rewrite |
| Minimize Reader Load rule | [references/principle-minimize-reader-load.md](references/principle-minimize-reader-load.md) | Reviewing or shaping code that is hard to trace |
| Outcome-Oriented Execution rule | [references/principle-outcome-oriented-execution.md](references/principle-outcome-oriented-execution.md) | Planned rewrites and migrations with explicit phase boundaries |
| Experience First rule | [references/principle-experience-first.md](references/principle-experience-first.md) | Product, UX, or feature-scope tradeoffs |
| Exhaust the Design Space rule | [references/principle-exhaust-the-design-space.md](references/principle-exhaust-the-design-space.md) | A novel interaction or architectural decision with no precedent |
| Build the Lever rule | [references/principle-build-the-lever.md](references/principle-build-the-lever.md) | Any non-trivial work: edits, migrations, analyses, checks |
| Model the Domain rule | [references/principle-model-the-domain.md](references/principle-model-the-domain.md) | Writing stateful logic, or code that branches a lot or repeats a shape assumption across files |
| Boundary Discipline rule | [references/principle-boundary-discipline.md](references/principle-boundary-discipline.md) | Wiring validation, error handling, or framework adapters |
| Type System Discipline rule | [references/principle-type-system-discipline.md](references/principle-type-system-discipline.md) | Designing types or a signature in any typed language |
| Make Operations Idempotent rule | [references/principle-make-operations-idempotent.md](references/principle-make-operations-idempotent.md) | Designing commands, lifecycle steps, or loops that run amid crashes and retries |
| Migrate Callers Then Delete Legacy APIs rule | [references/principle-migrate-callers-then-delete-legacy-apis.md](references/principle-migrate-callers-then-delete-legacy-apis.md) | Introducing a new internal API while old callers exist |
| Separate Before Serializing Shared State rule | [references/principle-separate-before-serializing-shared-state.md](references/principle-separate-before-serializing-shared-state.md) | Concurrent actors might write the same file, branch, key, or object |
| Prove It Works rule | [references/principle-prove-it-works.md](references/principle-prove-it-works.md) | After a task, before declaring done |
| Test Behavior, Not Implementation rule | [references/principle-test-behavior-not-implementation.md](references/principle-test-behavior-not-implementation.md) | Writing, changing, or keeping a test |
| Explain the Number rule | [references/principle-explain-the-number.md](references/principle-explain-the-number.md) | Before measuring, trusting, reporting, or acting on a speedup, regression, latency, or eval result; performance numbers also need [references/benchmark-checklist.md](references/benchmark-checklist.md) |
| Fix Root Causes rule | [references/principle-fix-root-causes.md](references/principle-fix-root-causes.md) | Debugging: trace each symptom to its root cause |
| Attack the Premise rule | [references/principle-attack-the-premise.md](references/principle-attack-the-premise.md) | Two or more fixes sharing one premise failed the same gate |
| Sequence Work into Verifiable Units rule | [references/principle-sequence-verifiable-units.md](references/principle-sequence-verifiable-units.md) | Multi-step work and how you stack commits and PRs |
| Guard the Context Window rule | [references/principle-guard-the-context-window.md](references/principle-guard-the-context-window.md) | Context fills up: large outputs, long files, repeated reads, fan-out planning |
| Never Block on the Human rule | [references/principle-never-block-on-the-human.md](references/principle-never-block-on-the-human.md) | Tempted to ask "should I do X?" on reversible work |
| Encode Lessons in Structure rule | [references/principle-encode-lessons-in-structure.md](references/principle-encode-lessons-in-structure.md) | You catch yourself writing the same instruction a second time |

Files in this skill

  • NOTICE.md1.5 KB
  • SKILL.md5.7 KB
  • UPSTREAM.json4.3 KB
  • references/benchmark-checklist.md4.3 KB
  • references/principle-attack-the-premise.md1.5 KB
  • references/principle-boundary-discipline.md1.5 KB
  • references/principle-build-the-lever.md2 KB
  • references/principle-encode-lessons-in-structure.md1.7 KB
  • references/principle-exhaust-the-design-space.md879 B
  • references/principle-experience-first.md932 B
  • references/principle-explain-the-number.md1.5 KB
  • references/principle-fix-root-causes.md1.5 KB
  • references/principle-foundational-thinking.md1.2 KB
  • references/principle-guard-the-context-window.md670 B
  • references/principle-laziness-protocol.md1.1 KB
  • references/principle-make-operations-idempotent.md1.5 KB
  • references/principle-migrate-callers-then-delete-legacy-apis.md862 B
  • references/principle-minimize-reader-load.md1.7 KB
  • references/principle-model-the-domain.md1.6 KB
  • references/principle-never-block-on-the-human.md751 B

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in code-quality →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.