[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M7884M8H9EKJ0C1G8X5VNACT":3,"skill-same:01M7884M8H9EKJ0C1G8X5VNACT":47},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":19,"linkOnly":20,"markdownContent":21,"markdownBody":22,"frontMatter":23,"refName":25,"commitSha":26,"skillDirectory":27,"forksCount":28,"repositoryHtmlUrl":29,"repositoryHomepageUrl":6,"ownerHtmlUrl":30,"ownerBlogUrl":31,"ownerDescription":6,"updatedAt":32,"install":33,"resources":46},"01M7884M8H9EKJ0C1G8X5VNACT","to-invariants",null,"Distill the invariants — properties that must always hold — out of the current conversation and codebase, and write them to an in-repo doc. Use when the user wants to capture invariants, pin down what must always be true, harden a design, or turn a discussion\u002Fspec\u002FPRD into checkable properties.","officialunofficial\u002Fskills","officialunofficial","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F127067914?v=4","01M78827JABEMMN63AC8J1RCXV","Official Unofficial, Inc.","01M78827KC164SFKN4DXTCKK7N",7,"Apache-2.0","https:\u002F\u002Fgithub.com\u002Fofficialunofficial\u002Fskills\u002Fblob\u002Fmain\u002Fskills\u002Fengineering\u002Fto-invariants\u002FSKILL.md",[],[],"2026-11-15 14:19:17",false,"---\nname: to-invariants\ndescription: Distill the invariants — properties that must always hold — out of the current conversation and codebase, and write them to an in-repo doc. Use when the user wants to capture invariants, pin down what must always be true, harden a design, or turn a discussion\u002Fspec\u002FPRD into checkable properties.\nargument-hint: \"[output-path]  (default: docs\u002FINVARIANTS.md)\"\n---\n\nTake the current conversation context and codebase understanding and produce a set of **invariants**: properties that must ALWAYS hold for the system to be correct. Do NOT interview the user — synthesize what you already know. Two audiences, two sections: design-level *system invariants* and *enforceable invariants* that map to a concrete check.\n\nAn invariant is not a feature, a requirement, or a nice-to-have. It is a condition whose violation means the system is broken. \"Users can reset their password\" is a feature. \"A session token is never valid after logout\" is an invariant.\n\n## Process\n\n### 1. Explore (if needed)\n\nIf you have not already, skim the code in the area under discussion to ground the invariants in the real data structures, state machines, and boundaries. Use the project's own vocabulary. An invariant you cannot point at a place in the code for is a guess — mark it as one.\n\n### 2. Discover invariants\n\nSweep the design through these lenses — each tends to surface a different class of invariant. Aim for coverage, not volume; skip lenses that don't apply.\n\n- **Representation** — internal consistency a data structure must always satisfy (no dangling refs, sorted, no duplicates, sums to a stored total, non-null where required).\n- **State machine \u002F lifecycle** — only valid transitions occur; terminal states are terminal; nothing escapes a state it shouldn't (e.g. \"a cancelled order is never fulfilled\").\n- **Round-trip \u002F inverse** — `decode(encode(x)) == x`; save→load, serialize→parse, redo(undo) are identity.\n- **Conservation \u002F accounting** — a quantity is neither created nor destroyed (money, inventory, reference counts balance before and after).\n- **Idempotence** — applying an operation twice equals applying it once (retries, upserts, dedup).\n- **Ordering \u002F monotonicity** — timestamps, versions, sequence numbers never go backwards; causality is preserved.\n- **Uniqueness \u002F referential integrity** — IDs are unique; every foreign reference resolves; no orphans.\n- **Boundary \u002F authority** — inputs stay within range; trust\u002Fpermission boundaries are never crossed (no privilege escalation, no reading another tenant's data).\n- **Metamorphic** — a relationship between related runs holds (adding an item never decreases the count; sorting twice == sorting once).\n\n### 3. Classify and locate\n\nFor each invariant, decide which section it belongs in, and find where it lives in the code:\n\n- **System invariant** — a design-level truth, possibly too broad or too semantic for a single assertion. Capture the property and *why it holds*.\n- **Enforceable invariant** — expressible as an assertion, precondition\u002Fpostcondition, property-based test, type, DB constraint, or runtime check. Find where it is enforced today; if nowhere, mark **GAP** — an unenforced invariant is a latent bug.\n\nA single invariant can appear in both sections: stated as a system truth, then listed with its concrete check.\n\n### 4. Write the doc\n\nWrite to the path in `{{ARGUMENTS}}`, or `docs\u002FINVARIANTS.md` by default. If the file exists, merge — don't clobber invariants already recorded; add, refine, and flag conflicts. Use the template below.\n\n### 5. Report\n\nSummarize to the user: how many invariants, and — most important — the **GAPs** (invariants with no enforcement). Ask whether they want the gaps turned into tests or tickets (do not do it unless asked).\n\n\u003Cinvariants-template>\n\n# Invariants\n\n> Properties that must ALWAYS hold. A violation is a bug, by definition.\n> Scope: \u003Cthe system\u002Ffeature\u002Fmodule these cover>\n\n## System invariants\n\nDesign-level properties. Each: the property, why it holds, and the blast radius if it breaks.\n\n### INV-1: \u003Cone-line property, stated as an absolute>\n\n- **Always:** \u003Cthe precise condition — universally quantified, no \"usually\">\n- **Because:** \u003Cthe mechanism or design decision that makes it true>\n- **If violated:** \u003Cwhat breaks downstream — why this matters>\n\n## Enforceable invariants\n\nEach maps to a concrete check. `[x]` = enforced today; `[ ]` = **GAP**, not enforced.\n\n- [x] **INV-2:** \u003Cproperty> — enforced by `\u003Ctest \u002F assertion \u002F constraint \u002F type>` at `\u003Clocation>`.\n- [ ] **INV-3:** \u003Cproperty> — **GAP**: no current check. Suggested: `\u003Cproperty test \u002F precondition \u002F DB constraint>`.\n\n## Assumptions & non-invariants\n\n- \u003Cthing people might assume is invariant but is NOT — state it explicitly to prevent false reliance>\n- \u003Cinvariant that holds only under a stated condition, with the condition named>\n\n\u003C\u002Finvariants-template>\n\n## What makes an invariant good\n\n- **Absolute.** It holds for *all* valid states, always. If it needs \"usually\" or \"should\", it's a heuristic, not an invariant — either tighten it or move it to non-invariants.\n- **Falsifiable.** You can describe a concrete state that would violate it. If nothing could ever contradict it, it says nothing.\n- **Observable \u002F contractual.** It constrains behavior or observable state, not an incidental implementation detail that a valid refactor could change.\n- **Atomic.** One property per invariant. Split conjunctions (\"unique AND sorted\") so each can be checked and cited independently.\n- **Located.** It names where it's enforced, or admits it isn't (GAP).\n\n\u003Cexamples>\n\u003Cgood>\nINV: A token presented after its session's logout is always rejected.\nAbsolute, falsifiable (present a post-logout token → must 401), enforceable (auth-middleware test), atomic.\n\u003C\u002Fgood>\n\u003Cbad>\nINV: The auth system is secure.\nNot falsifiable, not atomic, not checkable — it's a wish, not an invariant.\n\u003C\u002Fbad>\n\u003Cbad>\nINV: Passwords are hashed with bcrypt cost 12.\n\"bcrypt cost 12\" is an implementation detail. The invariant is \"passwords are never stored in recoverable form\"; the algorithm is a how, not a must-always-hold.\n\u003C\u002Fbad>\n\u003C\u002Fexamples>\n\nTask: distill the invariants from the current context and write them to the doc. {{ARGUMENTS}}\n","Take the current conversation context and codebase understanding and produce a set of **invariants**: properties that must ALWAYS hold for the system to be correct. Do NOT interview the user — synthesize what you already know. Two audiences, two sections: design-level *system invariants* and *enforceable invariants* that map to a concrete check.\n\nAn invariant is not a feature, a requirement, or a nice-to-have. It is a condition whose violation means the system is broken. \"Users can reset their password\" is a feature. \"A session token is never valid after logout\" is an invariant.\n\n## Process\n\n### 1. Explore (if needed)\n\nIf you have not already, skim the code in the area under discussion to ground the invariants in the real data structures, state machines, and boundaries. Use the project's own vocabulary. An invariant you cannot point at a place in the code for is a guess — mark it as one.\n\n### 2. Discover invariants\n\nSweep the design through these lenses — each tends to surface a different class of invariant. Aim for coverage, not volume; skip lenses that don't apply.\n\n- **Representation** — internal consistency a data structure must always satisfy (no dangling refs, sorted, no duplicates, sums to a stored total, non-null where required).\n- **State machine \u002F lifecycle** — only valid transitions occur; terminal states are terminal; nothing escapes a state it shouldn't (e.g. \"a cancelled order is never fulfilled\").\n- **Round-trip \u002F inverse** — `decode(encode(x)) == x`; save→load, serialize→parse, redo(undo) are identity.\n- **Conservation \u002F accounting** — a quantity is neither created nor destroyed (money, inventory, reference counts balance before and after).\n- **Idempotence** — applying an operation twice equals applying it once (retries, upserts, dedup).\n- **Ordering \u002F monotonicity** — timestamps, versions, sequence numbers never go backwards; causality is preserved.\n- **Uniqueness \u002F referential integrity** — IDs are unique; every foreign reference resolves; no orphans.\n- **Boundary \u002F authority** — inputs stay within range; trust\u002Fpermission boundaries are never crossed (no privilege escalation, no reading another tenant's data).\n- **Metamorphic** — a relationship between related runs holds (adding an item never decreases the count; sorting twice == sorting once).\n\n### 3. Classify and locate\n\nFor each invariant, decide which section it belongs in, and find where it lives in the code:\n\n- **System invariant** — a design-level truth, possibly too broad or too semantic for a single assertion. Capture the property and *why it holds*.\n- **Enforceable invariant** — expressible as an assertion, precondition\u002Fpostcondition, property-based test, type, DB constraint, or runtime check. Find where it is enforced today; if nowhere, mark **GAP** — an unenforced invariant is a latent bug.\n\nA single invariant can appear in both sections: stated as a system truth, then listed with its concrete check.\n\n### 4. Write the doc\n\nWrite to the path in `{{ARGUMENTS}}`, or `docs\u002FINVARIANTS.md` by default. If the file exists, merge — don't clobber invariants already recorded; add, refine, and flag conflicts. Use the template below.\n\n### 5. Report\n\nSummarize to the user: how many invariants, and — most important — the **GAPs** (invariants with no enforcement). Ask whether they want the gaps turned into tests or tickets (do not do it unless asked).\n\n\u003Cinvariants-template>\n\n# Invariants\n\n> Properties that must ALWAYS hold. A violation is a bug, by definition.\n> Scope: \u003Cthe system\u002Ffeature\u002Fmodule these cover>\n\n## System invariants\n\nDesign-level properties. Each: the property, why it holds, and the blast radius if it breaks.\n\n### INV-1: \u003Cone-line property, stated as an absolute>\n\n- **Always:** \u003Cthe precise condition — universally quantified, no \"usually\">\n- **Because:** \u003Cthe mechanism or design decision that makes it true>\n- **If violated:** \u003Cwhat breaks downstream — why this matters>\n\n## Enforceable invariants\n\nEach maps to a concrete check. `[x]` = enforced today; `[ ]` = **GAP**, not enforced.\n\n- [x] **INV-2:** \u003Cproperty> — enforced by `\u003Ctest \u002F assertion \u002F constraint \u002F type>` at `\u003Clocation>`.\n- [ ] **INV-3:** \u003Cproperty> — **GAP**: no current check. Suggested: `\u003Cproperty test \u002F precondition \u002F DB constraint>`.\n\n## Assumptions & non-invariants\n\n- \u003Cthing people might assume is invariant but is NOT — state it explicitly to prevent false reliance>\n- \u003Cinvariant that holds only under a stated condition, with the condition named>\n\n\u003C\u002Finvariants-template>\n\n## What makes an invariant good\n\n- **Absolute.** It holds for *all* valid states, always. If it needs \"usually\" or \"should\", it's a heuristic, not an invariant — either tighten it or move it to non-invariants.\n- **Falsifiable.** You can describe a concrete state that would violate it. If nothing could ever contradict it, it says nothing.\n- **Observable \u002F contractual.** It constrains behavior or observable state, not an incidental implementation detail that a valid refactor could change.\n- **Atomic.** One property per invariant. Split conjunctions (\"unique AND sorted\") so each can be checked and cited independently.\n- **Located.** It names where it's enforced, or admits it isn't (GAP).\n\n\u003Cexamples>\n\u003Cgood>\nINV: A token presented after its session's logout is always rejected.\nAbsolute, falsifiable (present a post-logout token → must 401), enforceable (auth-middleware test), atomic.\n\u003C\u002Fgood>\n\u003Cbad>\nINV: The auth system is secure.\nNot falsifiable, not atomic, not checkable — it's a wish, not an invariant.\n\u003C\u002Fbad>\n\u003Cbad>\nINV: Passwords are hashed with bcrypt cost 12.\n\"bcrypt cost 12\" is an implementation detail. The invariant is \"passwords are never stored in recoverable form\"; the algorithm is a how, not a must-always-hold.\n\u003C\u002Fbad>\n\u003C\u002Fexamples>\n\nTask: distill the invariants from the current context and write them to the doc. {{ARGUMENTS}}\n",{"name":5,"description":7,"argument-hint":24},"[output-path]  (default: docs\u002FINVARIANTS.md)","main","e1e71e8aa302edca3e052370aefa9272f86d07ee","skills\u002Fengineering\u002Fto-invariants",0,"https:\u002F\u002Fgithub.com\u002Fofficialunofficial\u002Fskills","https:\u002F\u002Fgithub.com\u002Fofficialunofficial","officialunofficial.com","2026-11-06 10:07:10",{"source":8,"skillName":5,"commands":34,"prompt":44,"zipAvailable":45},[35,38,41],{"tool":36,"command":37},"npx","npx skills add officialunofficial\u002Fskills --skill to-invariants",{"tool":39,"command":40},"bunx","bunx skills add officialunofficial\u002Fskills --skill to-invariants",{"tool":42,"command":43},"pnpm","pnpm dlx skills add officialunofficial\u002Fskills --skill to-invariants","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fofficialunofficial\u002Fskills\u002Fblob\u002Fmain\u002Fskills\u002Fengineering\u002Fto-invariants\u002FSKILL.md",true,[],[48,55,62,69,76,83],{"skillNo":49,"name":50,"nameZh":6,"description":51,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":52,"categories":53,"keywords":54,"publishedAt":19},"01M7887BDP2BC5HFHEKCNMBZ4Q","writing-great-skills","Reference for writing and editing skills well — the vocabulary and principles that make a skill predictable.","https:\u002F\u002Fgithub.com\u002Fofficialunofficial\u002Fskills\u002Fblob\u002Fmain\u002Fskills\u002Fproductivity\u002Fwriting-great-skills\u002FSKILL.md",[],[],{"skillNo":56,"name":57,"nameZh":6,"description":58,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":59,"categories":60,"keywords":61,"publishedAt":19},"01M788772K4QYXCZX3Y2P2AX9V","technical-writing","House style for technical writing — the voice, sentence craft, formatting, and user-facing-copy rules that make docs and product text clear, direct, and consistent. Use when writing or editing a README, docs, a spec, release notes, a changelog, help text, or any error\u002FCLI\u002FUI copy a person reads; when reviewing a diff that touches prose or messages; or when a project needs a writing standard. Reference-heavy mechanics live in REFERENCE.md.","https:\u002F\u002Fgithub.com\u002Fofficialunofficial\u002Fskills\u002Fblob\u002Fmain\u002Fskills\u002Fproductivity\u002Ftechnical-writing\u002FSKILL.md",[],[],{"skillNo":63,"name":64,"nameZh":6,"description":65,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":66,"categories":67,"keywords":68,"publishedAt":19},"01M78875087F1XKP7C6VRC49CY","teach","Teach the user a new skill or concept, within this workspace.","https:\u002F\u002Fgithub.com\u002Fofficialunofficial\u002Fskills\u002Fblob\u002Fmain\u002Fskills\u002Fproductivity\u002Fteach\u002FSKILL.md",[],[],{"skillNo":70,"name":71,"nameZh":6,"description":72,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":73,"categories":74,"keywords":75,"publishedAt":19},"01M78872Z38MACN22AQDY9410P","handoff","Compact the current conversation into a handoff document for another agent to pick up.","https:\u002F\u002Fgithub.com\u002Fofficialunofficial\u002Fskills\u002Fblob\u002Fmain\u002Fskills\u002Fproductivity\u002Fhandoff\u002FSKILL.md",[],[],{"skillNo":77,"name":78,"nameZh":6,"description":79,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":80,"categories":81,"keywords":82,"publishedAt":19},"01M78870FVRDYRT1WVP9HJ6FQ3","grilling","Interrogate the user's plan or design one decision at a time until you both share the same understanding. Use when the user wants to pressure-test an idea before building it, or reaches for any 'grill' trigger phrase.","https:\u002F\u002Fgithub.com\u002Fofficialunofficial\u002Fskills\u002Fblob\u002Fmain\u002Fskills\u002Fproductivity\u002Fgrilling\u002FSKILL.md",[],[],{"skillNo":84,"name":85,"nameZh":6,"description":86,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":87,"categories":88,"keywords":89,"publishedAt":19},"01M7886XGPEWXZYDA6K310HNYP","grill-me","A relentless, one-decision-at-a-time interview that sharpens a plan or design.","https:\u002F\u002Fgithub.com\u002Fofficialunofficial\u002Fskills\u002Fblob\u002Fmain\u002Fskills\u002Fproductivity\u002Fgrill-me\u002FSKILL.md",[],[]]