[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M6JGGKG5KD3VMYFAPRY3QACH":3,"skill-same:01M6JGGKG5KD3VMYFAPRY3QACH":63},{"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":23,"publishedAt":37,"linkOnly":38,"markdownContent":39,"markdownBody":40,"frontMatter":41,"refName":42,"commitSha":43,"skillDirectory":44,"forksCount":45,"repositoryHtmlUrl":46,"repositoryHomepageUrl":6,"ownerHtmlUrl":47,"ownerBlogUrl":6,"ownerDescription":6,"updatedAt":48,"install":49,"resources":62},"01M6JGGKG5KD3VMYFAPRY3QACH","predictive-accounting",null,"For shrink\u002Frefactor\u002Foptimize\u002Fcleanup tasks — present baseline + predicted delta + dependency cost BEFORE implementation, not after","muratovv\u002Fai-hats","muratovv","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F7502801?v=4","01M6JGCBN4KEJX012GPJVSH04T","Fedor Muratov","01M6JGCBSNMN7CW3RGTPPE0MN2",3,"MIT","https:\u002F\u002Fgithub.com\u002Fmuratovv\u002Fai-hats\u002Fblob\u002Fmaster\u002Fpackages\u002Fai-hats-library\u002Fsrc\u002Fai_hats_library\u002Fcore\u002Fskills\u002Fpredictive-accounting\u002FSKILL.md",[18],{"categoryNo":19,"categoryName":20,"taxonomyType":21,"taxonomyTypeDesc":22},"01JBSEEDCAT000000000000040","财务","PROFESSION","适用职业",[24,25,26,27,28,29,30,31,32,33,34,35,36],"accounting","predictive accounting","tasks","cleanup","refactor","baseline","dependency","cost","implementation","delta","optimize","present","for","2026-11-10 10:12:30",false,"---\nname: predictive-accounting\ndescription: >-\n  For shrink\u002Frefactor\u002Foptimize\u002Fcleanup tasks — present baseline +\n  predicted delta + dependency cost BEFORE implementation, not after\nlicense: MIT\n---\n\n# Predictive Accounting\n\nFor tasks in the **shrink \u002F refactor \u002F extract \u002F optimize \u002F cleanup** family —\nshow the user, **before any code changes**:\n\n1. The current baseline of the metric being improved (tokens, lines, time, allocations).\n2. The predicted delta after the proposed changes.\n3. The dependency cost: does the win materialize immediately, or only after another task lands?\n4. The rough work cost (number of files \u002F commits \u002F phases).\n\nAsk for confirmation **before** starting implementation. Do not arrive at\n1-2 commits of \"structural prep\" that, at that moment, makes the metric\n**worse** — and then surface the honest accounting post-hoc.\n\n## When to Use\n\n- Task description verbs: **shrink \u002F trim \u002F refactor \u002F extract \u002F optimize \u002F cleanup \u002F consolidate \u002F split**.\n- Task mentions a **target saving** (e.g., \"~150 lines\", \"drop ~500 tokens\") with or without precise numbers.\n- Plan touches large refactors of existing components where short-term cost is non-trivial.\n\n## Checklist\n\n### Before writing the plan\n\n1. **Measure the current baseline.** Run the actual count (tokens, lines, prompt size). Do not estimate.\n2. **Predict the delta from each proposed change.** For each change, estimate:\n   - Short-term delta (right after the commit lands).\n   - Long-term delta (after dependent tasks land, if any).\n3. **List dependencies.** If a refactor's full saving is gated on another unmerged task — name it (`HATS-XXX`) and quantify the gated portion separately.\n4. **Estimate work.** Number of files, commits, phases. Hours-of-attention if relevant.\n\n### Present accounting to the user before execute\n\nShow a table:\n\n| Change                      | Short-term delta | Long-term delta | Dependency        | Work cost |\n| --------------------------- | ---------------- | --------------- | ----------------- | --------- |\n| Inline skill X into trait Y | +1086 tokens     | -458 tokens     | needs the removal task first | 1 commit  |\n| Collapse traits A+B+C → D   | -205 tokens      | -205 tokens     | none              | 1 commit  |\n| ...                         | ...              | ...             | ...               | ...       |\n\nWait for explicit confirmation. If short-term is **negative**, the user\nshould be able to choose: \"skip\", \"do only the dependency-free wins\",\n\"proceed knowing temporary regression\".\n\n### After execute\n\n5. Re-measure. Compare to the predicted delta. If off by >20% — log in the work_log; useful for future predictive accuracy.\n\n## Worked Example\n\n**A \"shrink ~120-150 lines\" request.**\n\nThe agent (without this skill) made:\n\n- **Commit 1**: rules-pass refactor (inline skill bodies into traits).\n- **Commit 2**: traits-pass refactor (collapse adjacent traits).\n\nThen presented honest accounting:\n\n- **Short-term**: +1086 tokens (new skill bodies inlined permanently grow prompts).\n- **Long-term**: -458 tokens, **only after** the follow-up lands that removes the now-redundant skill files.\n\nUser reverted both commits, kept only the trait-collapse work which delivered a clean **-205 tokens immediately**, no dependency.\n\nThe waste: two days of design + two commits + one revert. Filed as **HYP-013**\n(\"predictive accounting prevents sunk-cost commits in shrink tasks\").\n\n## Anti-Patterns\n\n- **Starting refactor commits before measuring baseline.**\n- **\"It'll be cleaner anyway\" justification** without delta numbers.\n- **Bundling all changes into one PR** when some have no dependencies — give the user the option to take the wins-now subset.\n- **Post-hoc accounting** (\"here's what it cost\") after the user is already psychologically invested in your work.\n- **Hiding gated savings** — \"this saves X\" without \"after HATS-Y lands\".\n\n## Completion\n\nThe task passes the accounting gate when:\n\n- Baseline numbers are recorded in `plan.md` or work_log.\n- Predicted delta is presented before execute.\n- User has explicitly confirmed (proceed \u002F partial \u002F abort).\n- Post-execute delta is compared to prediction; major drift logged.\n\n## See also\n\n- `design-minimalism` — same upstream principle (don't add primitives without justification), applied at design phase.\n- `scope-guard` — implementation-stage discipline; this skill is upstream.\n- `request-supervisor` — when negative short-term delta means user-decision territory.\n","# Predictive Accounting\n\nFor tasks in the **shrink \u002F refactor \u002F extract \u002F optimize \u002F cleanup** family —\nshow the user, **before any code changes**:\n\n1. The current baseline of the metric being improved (tokens, lines, time, allocations).\n2. The predicted delta after the proposed changes.\n3. The dependency cost: does the win materialize immediately, or only after another task lands?\n4. The rough work cost (number of files \u002F commits \u002F phases).\n\nAsk for confirmation **before** starting implementation. Do not arrive at\n1-2 commits of \"structural prep\" that, at that moment, makes the metric\n**worse** — and then surface the honest accounting post-hoc.\n\n## When to Use\n\n- Task description verbs: **shrink \u002F trim \u002F refactor \u002F extract \u002F optimize \u002F cleanup \u002F consolidate \u002F split**.\n- Task mentions a **target saving** (e.g., \"~150 lines\", \"drop ~500 tokens\") with or without precise numbers.\n- Plan touches large refactors of existing components where short-term cost is non-trivial.\n\n## Checklist\n\n### Before writing the plan\n\n1. **Measure the current baseline.** Run the actual count (tokens, lines, prompt size). Do not estimate.\n2. **Predict the delta from each proposed change.** For each change, estimate:\n   - Short-term delta (right after the commit lands).\n   - Long-term delta (after dependent tasks land, if any).\n3. **List dependencies.** If a refactor's full saving is gated on another unmerged task — name it (`HATS-XXX`) and quantify the gated portion separately.\n4. **Estimate work.** Number of files, commits, phases. Hours-of-attention if relevant.\n\n### Present accounting to the user before execute\n\nShow a table:\n\n| Change                      | Short-term delta | Long-term delta | Dependency        | Work cost |\n| --------------------------- | ---------------- | --------------- | ----------------- | --------- |\n| Inline skill X into trait Y | +1086 tokens     | -458 tokens     | needs the removal task first | 1 commit  |\n| Collapse traits A+B+C → D   | -205 tokens      | -205 tokens     | none              | 1 commit  |\n| ...                         | ...              | ...             | ...               | ...       |\n\nWait for explicit confirmation. If short-term is **negative**, the user\nshould be able to choose: \"skip\", \"do only the dependency-free wins\",\n\"proceed knowing temporary regression\".\n\n### After execute\n\n5. Re-measure. Compare to the predicted delta. If off by >20% — log in the work_log; useful for future predictive accuracy.\n\n## Worked Example\n\n**A \"shrink ~120-150 lines\" request.**\n\nThe agent (without this skill) made:\n\n- **Commit 1**: rules-pass refactor (inline skill bodies into traits).\n- **Commit 2**: traits-pass refactor (collapse adjacent traits).\n\nThen presented honest accounting:\n\n- **Short-term**: +1086 tokens (new skill bodies inlined permanently grow prompts).\n- **Long-term**: -458 tokens, **only after** the follow-up lands that removes the now-redundant skill files.\n\nUser reverted both commits, kept only the trait-collapse work which delivered a clean **-205 tokens immediately**, no dependency.\n\nThe waste: two days of design + two commits + one revert. Filed as **HYP-013**\n(\"predictive accounting prevents sunk-cost commits in shrink tasks\").\n\n## Anti-Patterns\n\n- **Starting refactor commits before measuring baseline.**\n- **\"It'll be cleaner anyway\" justification** without delta numbers.\n- **Bundling all changes into one PR** when some have no dependencies — give the user the option to take the wins-now subset.\n- **Post-hoc accounting** (\"here's what it cost\") after the user is already psychologically invested in your work.\n- **Hiding gated savings** — \"this saves X\" without \"after HATS-Y lands\".\n\n## Completion\n\nThe task passes the accounting gate when:\n\n- Baseline numbers are recorded in `plan.md` or work_log.\n- Predicted delta is presented before execute.\n- User has explicitly confirmed (proceed \u002F partial \u002F abort).\n- Post-execute delta is compared to prediction; major drift logged.\n\n## See also\n\n- `design-minimalism` — same upstream principle (don't add primitives without justification), applied at design phase.\n- `scope-guard` — implementation-stage discipline; this skill is upstream.\n- `request-supervisor` — when negative short-term delta means user-decision territory.\n",{"name":5,"license":15,"description":7},"master","b4819add93efbaf4d80627118ec34680406b309b","packages\u002Fai-hats-library\u002Fsrc\u002Fai_hats_library\u002Fcore\u002Fskills\u002Fpredictive-accounting",1,"https:\u002F\u002Fgithub.com\u002Fmuratovv\u002Fai-hats","https:\u002F\u002Fgithub.com\u002Fmuratovv","2026-11-05 20:59:10",{"source":8,"skillName":5,"commands":50,"prompt":60,"zipAvailable":61},[51,54,57],{"tool":52,"command":53},"npx","npx skills add muratovv\u002Fai-hats --skill predictive-accounting",{"tool":55,"command":56},"bunx","bunx skills add muratovv\u002Fai-hats --skill predictive-accounting",{"tool":58,"command":59},"pnpm","pnpm dlx skills add muratovv\u002Fai-hats --skill predictive-accounting","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fmuratovv\u002Fai-hats\u002Fblob\u002Fmaster\u002Fpackages\u002Fai-hats-library\u002Fsrc\u002Fai_hats_library\u002Fcore\u002Fskills\u002Fpredictive-accounting\u002FSKILL.md",true,[],[64,89,114,137,160,174],{"skillNo":65,"name":66,"nameZh":6,"description":67,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":68,"categories":69,"keywords":70,"publishedAt":37},"01M6PVFB1SM738R2SRSRSF7CY6","tool-evaluation-protocol","Time-bounded protocol for evaluating new tools, libraries, or methodologies before adoption. Use when evaluating a candidate dependency for the project, researching a methodology (e.g. ML\u002FLLM frameworks, testing approaches), or following up on a hype-driven recommendation.","https:\u002F\u002Fgithub.com\u002Fmuratovv\u002Fai-hats\u002Fblob\u002Fmaster\u002Fpackages\u002Fai-hats-library\u002Fsrc\u002Fai_hats_library\u002Fexperimental\u002Fusage\u002Fskills\u002Ftool-evaluation-protocol\u002FSKILL.md",[],[71,72,73,74,75,76,77,78,79,80,81,30,82,83,84,85,86,36,87,88],"protocol","Evaluation","tool","tool evaluation protocol","testing","ml","libraries","adoption","methodology","Tools","use","up","frameworks","time","project","recommendation","bounded","candidate",{"skillNo":90,"name":91,"nameZh":6,"description":92,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":93,"categories":94,"keywords":95,"publishedAt":37},"01M6PVF7HATBEX1G7N50E2QT57","systematic-debugging","4-phase bug-fix protocol (evidence, pattern, hypothesis, verify). Use when investigating any error, failure, or unexpected behavior, handling bug reports from users or monitoring, or diagnosing test failures with non-obvious causes.","https:\u002F\u002Fgithub.com\u002Fmuratovv\u002Fai-hats\u002Fblob\u002Fmaster\u002Fpackages\u002Fai-hats-library\u002Fsrc\u002Fai_hats_library\u002Fexperimental\u002Fusage\u002Fskills\u002Fsystematic-debugging\u002FSKILL.md",[],[96,97,98,99,71,100,101,102,103,104,81,105,106,107,108,109,110,111,112,113],"systematic debugging","debugging","systematic","test","monitoring","hypothesis","verify","behavior","fix","evidence","bug","reports","pattern","users","error","with","bug-fix","phase",{"skillNo":115,"name":116,"nameZh":6,"description":117,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":118,"categories":119,"keywords":125,"publishedAt":37},"01M6PVF3MTQN3RPF73AN34856J","skill-template","Canonical template and validation guide for ai-hats skills. Use when creating a new skill, reviewing an existing one for structural compliance, or deciding which pattern fits a new behavior.","https:\u002F\u002Fgithub.com\u002Fmuratovv\u002Fai-hats\u002Fblob\u002Fmaster\u002Fpackages\u002Fai-hats-library\u002Fsrc\u002Fai_hats_library\u002Fexperimental\u002Fusage\u002Fskills\u002Fskill-template\u002FSKILL.md",[120],{"categoryNo":121,"categoryName":122,"taxonomyType":123,"taxonomyTypeDesc":124},"01JBSEEDCAT000000000000023","Skill与智能体开发","SCENARIO","使用场景",[126,127,128,129,130,103,131,81,132,108,133,134,135,36,136],"template","skill template","validation","compliance","hats","guide","new skill","structural","canonical","which","Existing",{"skillNo":138,"name":139,"nameZh":6,"description":140,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":141,"categories":142,"keywords":144,"publishedAt":37},"01M6PVF06SCV28QARM5MQPANC9","skill-optimization","Audit and refactor library components to eliminate redundancy and staleness. Use during periodic library maintenance, after adding multiple new skills or rules, when a role's token budget is too high, or after retrospectives identify component issues.","https:\u002F\u002Fgithub.com\u002Fmuratovv\u002Fai-hats\u002Fblob\u002Fmaster\u002Fpackages\u002Fai-hats-library\u002Fsrc\u002Fai_hats_library\u002Fexperimental\u002Fusage\u002Fskills\u002Fskill-optimization\u002FSKILL.md",[143],{"categoryNo":121,"categoryName":122,"taxonomyType":123,"taxonomyTypeDesc":124},[145,146,147,148,149,150,151,28,152,153,81,154,155,156,157,158,159],"Optimization","skill optimization","components","component","issues","library","audit","Budget","Rules","periodic","maintenance","token","token budget","role","high",{"skillNo":161,"name":162,"nameZh":6,"description":163,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":164,"categories":165,"keywords":166,"publishedAt":37},"01M6PVEXM9717016T9MW82HDCT","silent-fallback-gate","PreToolUse hook — refuses an Edit or Write that adds an inert broad except. Use when a Python edit was blocked for a silent fallback.","https:\u002F\u002Fgithub.com\u002Fmuratovv\u002Fai-hats\u002Fblob\u002Fmaster\u002Fpackages\u002Fai-hats-library\u002Fsrc\u002Fai_hats_library\u002Fexperimental\u002Fusage\u002Fskills\u002Fsilent-fallback-gate\u002FSKILL.md",[],[167,168,169,170,171,172,81,173,36],"gate","fallback","silent fallback gate","python","write","edit","hook",{"skillNo":175,"name":176,"nameZh":6,"description":177,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":178,"categories":179,"keywords":181,"publishedAt":37},"01M6PVESM49C5NT7SB7N3F76VS","retro-to-framework","Convert an observation about agent behavior — from a retrospective or from a single incident — into a framework-level change (hook, rule, skill, skill update). Use after a retrospective identifies problems that are not project-specific, after an incident where an agent misapplied a component it had read, when CLAUDE.md band-aids accumulate (more than 3 per-project rules that could be generic), or when the same problem recurs across multiple projects.","https:\u002F\u002Fgithub.com\u002Fmuratovv\u002Fai-hats\u002Fblob\u002Fmaster\u002Fpackages\u002Fai-hats-library\u002Fsrc\u002Fai_hats_library\u002Fexperimental\u002Fusage\u002Fskills\u002Fretro-to-framework\u002FSKILL.md",[180],{"categoryNo":121,"categoryName":122,"taxonomyType":123,"taxonomyTypeDesc":124},[182,183,184,185,148,186,187,188,153,103,81,189,190,85,191,192,193,194,195,196],"framework","retro","retro to framework","change","retrospective","projects","convert","incident","across","problem","about","more","skill update","single","generic"]