[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M6EKP2DFDBSCMCBH5EQ8TMFE":3,"skill-same:01M6EKP2DFDBSCMCBH5EQ8TMFE":62},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":15,"categories":16,"keywords":17,"publishedAt":29,"linkOnly":30,"markdownContent":31,"markdownBody":32,"frontMatter":33,"refName":34,"commitSha":35,"skillDirectory":36,"forksCount":37,"repositoryHtmlUrl":38,"repositoryHomepageUrl":6,"ownerHtmlUrl":39,"ownerBlogUrl":6,"ownerDescription":40,"updatedAt":41,"install":42,"resources":55},"01M6EKP2DFDBSCMCBH5EQ8TMFE","principle-model-the-domain",null,"Apply when writing stateful logic, or when code branches a lot or repeats a shape assumption across files.","minghinmatthewlam\u002Fagent-guards","minghinmatthewlam","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F14224566?v=4","01M6EKJNHJ92TMD70DDV4AJFQA","01M6EKJNNSX01GNTK9NJ5RKHFM",46,"MIT","https:\u002F\u002Fgithub.com\u002Fminghinmatthewlam\u002Fagent-guards\u002Fblob\u002Fmain\u002Fplugins\u002Fpstack\u002Fskills\u002Fprinciple-model-the-domain\u002FSKILL.md",[],[18,19,20,21,22,23,24,25,26,27,28],"principle model the domain","model","domain","writing","code","shape","files","branches","across","logic","false","2026-11-10 10:12:30",false,"---\nname: principle-model-the-domain\ndescription: \"Apply when writing stateful logic, or when code branches a lot or repeats a shape assumption across files.\"\nuser-invocable: false\n---\n\n# Model the Domain\n\nEncode the real domain in a data structure instead of scattering it across conditionals. A structure that matches the domain makes invalid states unrepresentable and deletes branches. Choosing it at write time is cheap. Recovering it later reads as a refactor and gets deferred.\n\nReach for:\n\n- A state machine instead of scattered booleans, phases, or lifecycle checks.\n- A typed model instead of loose parameters or repeated shape assumptions.\n- A map, registry, lookup table, or discriminated union instead of branching spread across files.\n- A reducer or command\u002Fevent model instead of ad hoc state mutations.\n- A module organized around one body of domain knowledge instead of a sequence such as load, validate, transform, and save. Execution order is not ownership.\n- A small module boundary that gathers repeated behavior, ownership, or invariants.\n- A queue, cache, index, graph, tree, or normalized collection where the access pattern calls for it.\n- Any other structure that fits. When none fits, work out what the code must never allow and how the data gets read, then find the structure that encodes exactly that.\n\nDo not force an abstraction. Prefer boring code if the current shape is already clear, local, and unlikely to grow. Be skeptical of an abstraction that adds indirection without removing branches, duplicated rules, invalid states, or lifecycle risk.\n\nThe sign that you skipped this is a new feature that grows an existing if\u002Felse chain by one more branch, or a second boolean that must stay in sync with the first. Temporal decomposition is another sign. Phase-named modules repeat the same domain rules across steps.\n","# Model the Domain\n\nEncode the real domain in a data structure instead of scattering it across conditionals. A structure that matches the domain makes invalid states unrepresentable and deletes branches. Choosing it at write time is cheap. Recovering it later reads as a refactor and gets deferred.\n\nReach for:\n\n- A state machine instead of scattered booleans, phases, or lifecycle checks.\n- A typed model instead of loose parameters or repeated shape assumptions.\n- A map, registry, lookup table, or discriminated union instead of branching spread across files.\n- A reducer or command\u002Fevent model instead of ad hoc state mutations.\n- A module organized around one body of domain knowledge instead of a sequence such as load, validate, transform, and save. Execution order is not ownership.\n- A small module boundary that gathers repeated behavior, ownership, or invariants.\n- A queue, cache, index, graph, tree, or normalized collection where the access pattern calls for it.\n- Any other structure that fits. When none fits, work out what the code must never allow and how the data gets read, then find the structure that encodes exactly that.\n\nDo not force an abstraction. Prefer boring code if the current shape is already clear, local, and unlikely to grow. Be skeptical of an abstraction that adds indirection without removing branches, duplicated rules, invalid states, or lifecycle risk.\n\nThe sign that you skipped this is a new feature that grows an existing if\u002Felse chain by one more branch, or a second boolean that must stay in sync with the first. Temporal decomposition is another sign. Phase-named modules repeat the same domain rules across steps.\n",{"name":5,"description":7,"user-invocable":30},"main","0c773e8ba99fe384310af3f9ee59741106a53d95","plugins\u002Fpstack\u002Fskills\u002Fprinciple-model-the-domain",3,"https:\u002F\u002Fgithub.com\u002Fminghinmatthewlam\u002Fagent-guards","https:\u002F\u002Fgithub.com\u002Fminghinmatthewlam","Builder. Less optimizing agents setup, more building","2026-11-08 05:41:31",{"source":8,"skillName":5,"commands":43,"prompt":53,"zipAvailable":54},[44,47,50],{"tool":45,"command":46},"npx","npx skills add minghinmatthewlam\u002Fagent-guards --skill principle-model-the-domain",{"tool":48,"command":49},"bunx","bunx skills add minghinmatthewlam\u002Fagent-guards --skill principle-model-the-domain",{"tool":51,"command":52},"pnpm","pnpm dlx skills add minghinmatthewlam\u002Fagent-guards --skill principle-model-the-domain","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fminghinmatthewlam\u002Fagent-guards\u002Fblob\u002Fmain\u002Fplugins\u002Fpstack\u002Fskills\u002Fprinciple-model-the-domain\u002FSKILL.md",true,[56],{"path":57,"resourceType":58,"resourceTypeDesc":59,"sizeBytes":60,"sourceHtmlUrl":61},"agents\u002Fopenai.yaml","REFERENCE","参考文档",43,"https:\u002F\u002Fgithub.com\u002Fminghinmatthewlam\u002Fagent-guards\u002Fblob\u002Fmain\u002Fplugins\u002Fpstack\u002Fskills\u002Fprinciple-model-the-domain\u002Fagents\u002Fopenai.yaml",[63,92,117,137,161,180],{"skillNo":64,"name":65,"nameZh":6,"description":66,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":67,"categories":68,"keywords":74,"publishedAt":29},"01M6EKT039SVAX6PXWNJZNZ4EX","teach","Build a working mental model of code: the components and how they interact, then the interfaces, schemas, and function signatures. Use when asked to teach or explain how code works, walk through an architecture, deep-dive a subsystem, or understand a change, including code outside the current repo. For a concept with no code, use pstack:teach.","https:\u002F\u002Fgithub.com\u002Fminghinmatthewlam\u002Fagent-guards\u002Fblob\u002Fmain\u002Fskills\u002Fteach\u002FSKILL.md",[69],{"categoryNo":70,"categoryName":71,"taxonomyType":72,"taxonomyTypeDesc":73},"01JBSEEDCAT000000000000039","教师与教育","PROFESSION","适用职业",[65,75,76,19,77,78,79,80,22,81,82,83,84,85,86,87,88,89,90,91],"change","build","how","repo","understand","use","explain","with","concept","deep","for","mental model","signatures","pstack","no code","components","when",{"skillNo":93,"name":94,"nameZh":6,"description":95,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":96,"categories":97,"keywords":98,"publishedAt":29},"01M6EKSX03CR18TFCATJ5ARTN7","skills-audit","Audit agent skills for triggering quality, correctness, context efficiency, redundancy, structure, failure guidance, and coverage gaps. Use when the user asks to review, improve, compare, simplify, or evaluate skills in global, repo-local, Claude, Codex, or custom skill paths.","https:\u002F\u002Fgithub.com\u002Fminghinmatthewlam\u002Fagent-guards\u002Fblob\u002Fmain\u002Fskills\u002Fskills-audit\u002FSKILL.md",[],[99,100,101,102,103,78,104,105,106,107,108,80,109,110,111,112,113,114,115,116],"audit","skills audit","coverage","structure","codex","quality","local","guidance","paths","improve","custom skill","simplify","coverage gaps","user","context","compare","review","efficiency",{"skillNo":118,"name":119,"nameZh":6,"description":120,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":121,"categories":122,"keywords":123,"publishedAt":29},"01M6EKSSTYVXDV0REZEF7J9X6F","repo-setup","Set up or refactor a repository so agents naturally follow its intended architecture and important mistakes fail mechanically. Use when the user invokes $repo-setup, asks to make a repo agent-friendly, or wants important repository rules enforced through structure, types, tooling, tests, or CI.","https:\u002F\u002Fgithub.com\u002Fminghinmatthewlam\u002Fagent-guards\u002Fblob\u002Fmain\u002Fskills\u002Frepo-setup\u002FSKILL.md",[],[78,124,125,126,102,127,128,129,130,131,132,80,133,134,135,112,136],"repo setup","setup","SET","types","tooling","repository","up","ci","tests","Rules","refactor","architecture","make",{"skillNo":138,"name":139,"nameZh":6,"description":140,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":141,"categories":142,"keywords":143,"publishedAt":29},"01M6EKSPNRZKCDWWV9FK57PFPB","record-screen","Record a small MP4 while demonstrating or verifying a UI change, then attach the video as proof. Linux cloud sessions record the private virtual display; macOS records only the app window under test. Use for any repo whenever a UI change is verified or demoed.","https:\u002F\u002Fgithub.com\u002Fminghinmatthewlam\u002Fagent-guards\u002Fblob\u002Fmain\u002Fskills\u002Frecord-screen\u002FSKILL.md",[],[144,145,146,147,148,149,150,151,78,152,153,154,155,80,156,75,157,158,159,160],"record screen","record","screen","virtual","mp4","Video","app","as","records","linux","sessions","only","test","attach","proof","cloud","ui",{"skillNo":162,"name":163,"nameZh":6,"description":164,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":165,"categories":166,"keywords":167,"publishedAt":29},"01M6EKSME0SDX0X052A8ZY0SMB","ori-pr","Take an OpenRouterIncubator\u002Fori or OpenRouterTeam\u002Fopenrouter-web PR from ready to merged. Matthew runs \u002Fori-pr once he has decided the PR is ready and understands the change. Asks perry for review once CI is green, handles perry's comments, and enqueues the merge once perry approves the head and CI is green, within quiet hours.","https:\u002F\u002Fgithub.com\u002Fminghinmatthewlam\u002Fagent-guards\u002Fblob\u002Fmain\u002Fskills\u002Fori-pr\u002FSKILL.md",[],[168,169,170,171,75,172,173,174,115,131,175,176,177,85,178,179],"pr","ori pr","take","ready","head","green","merge","perry","openrouter","web","true","comments",{"skillNo":181,"name":182,"nameZh":6,"description":183,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":184,"categories":185,"keywords":186,"publishedAt":29},"01M6EKSGFS2DZNXYFH7A9GJ4BD","new-task","Clarify a new task by stating the goal the agent believes the user wants, showing its current understanding, and asking only product-related or high-priority questions that could materially change the outcome. Use before planning or implementation when the task needs alignment.","https:\u002F\u002Fgithub.com\u002Fminghinmatthewlam\u002Fagent-guards\u002Fblob\u002Fmain\u002Fskills\u002Fnew-task\u002FSKILL.md",[],[187,188,189,155,75,190,191,80,192,193,194,195,112],"new task","task","alignment","implementation","clarify","product","planning","goal","outcome"]