[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M7D3H9MA7NWWHW857YGWH85E":3,"skill-same:01M7D3H9MA7NWWHW857YGWH85E":91},{"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":24,"commitSha":25,"skillDirectory":26,"forksCount":14,"repositoryHtmlUrl":27,"repositoryHomepageUrl":28,"ownerHtmlUrl":29,"ownerBlogUrl":30,"ownerDescription":31,"updatedAt":32,"install":33,"resources":46},"01M7D3H9MA7NWWHW857YGWH85E","clean-code",null,"Specific naming conventions, cohesion metrics, coupling detection, function responsibility, duplication patterns, dead code, side effects, mutation, API ergonomics","poppyTM\u002Faipo-lang","poppyTM","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F339400917?v=4","01M78F6YNKFR5S5JQR27X9F09Z","Poppy Team","01M7D3H3PCFF0AZSRPP5GTS76P",0,"MIT","https:\u002F\u002Fgithub.com\u002FpoppyTM\u002Faipo-lang\u002Fblob\u002Fmain\u002F.agents\u002Fskills\u002Fclean-code\u002FSKILL.md",[],[],"2026-11-15 14:19:17",false,"---\nname: clean-code\ndescription: Specific naming conventions, cohesion metrics, coupling detection, function responsibility, duplication patterns, dead code, side effects, mutation, API ergonomics\n---\n# Clean Code Engineering\n\n## 1. Naming Conventions\nNaming is the primary means of communicating intent. Variables should be nouns describing content. Functions should be verbs describing action. Avoid abbreviations. Booleans should indicate true\u002Ffalse context (is_valid, has_children). Names must be searchable and pronounceable.\n\n## 2. Cohesion Metrics\nCohesion measures how strongly related the responsibilities of a module are. Aim for high cohesion: a class should have one primary responsibility. Use LCOM (Lack of Cohesion of Methods) metrics to identify classes to split. All methods must operate on the class's state.\n\n## 3. Coupling Detection\nCoupling is the degree of interdependence between modules. Minimize coupling via dependency injection. Prefer interfaces over concrete implementations. Detect coupling by analyzing import statements, cross-module calls, and checking for tight temporal constraints between distinct services.\n\n## 4. Function Responsibility\nA function should do one thing, do it well, and do it only. Limit function size to fit on a single screen. Extract sub-tasks into separate, clearly named functions. Avoid mixing different levels of abstraction. The Single Responsibility Principle applies at the function level.\n\n## 5. Duplication Patterns\nIdentify and eliminate duplicated code using the Rule of Three. Extract common logic into helper functions or base classes. Use Strategy or Template Method patterns to abstract varying behaviors. Be careful not to prematurely abstract coincidental duplication that isn't true behavioral duplication.\n\n## 6. Dead Code Elimination\nRegularly audit and remove code that is no longer executed. Use coverage tools and static analysis to identify untouched code paths. Remove deprecated features once their grace period expires. Do not comment out code; rely on version control history.\n\n## 7. Side Effects Management\nMinimize and isolate side effects to improve predictability. Favor pure functions that rely only on inputs and return outputs. Explicitly document functions performing I\u002FO. Group side-effecting code at the boundaries of the application (e.g., Hexagonal Architecture).\n\n## 8. State Mutation\nControl how and when state changes occur. Prefer immutable data structures where possible. Restrict mutability to small, clearly defined scopes. Use explicit synchronization mechanisms if mutation is necessary in concurrent environments. Avoid global mutable state entirely.\n\n## 9. API Ergonomics\nDesign APIs that are easy to use correctly and hard to use incorrectly. Provide sensible defaults. Use strong typing and domain types rather than primitive obsession. Ensure consistent naming and behavior across the entire API surface. Follow the Principle of Least Astonishment.\n\n## 10. Code Smells Identification\nTrain yourself to spot common code smells: Long Method, Large Class, Primitive Obsession, Feature Envy, Data Clumps, Switch Statements, and Temporary Field. Addressing these early prevents systemic rot and keeps the codebase malleable over its lifetime.\n\n","# Clean Code Engineering\n\n## 1. Naming Conventions\nNaming is the primary means of communicating intent. Variables should be nouns describing content. Functions should be verbs describing action. Avoid abbreviations. Booleans should indicate true\u002Ffalse context (is_valid, has_children). Names must be searchable and pronounceable.\n\n## 2. Cohesion Metrics\nCohesion measures how strongly related the responsibilities of a module are. Aim for high cohesion: a class should have one primary responsibility. Use LCOM (Lack of Cohesion of Methods) metrics to identify classes to split. All methods must operate on the class's state.\n\n## 3. Coupling Detection\nCoupling is the degree of interdependence between modules. Minimize coupling via dependency injection. Prefer interfaces over concrete implementations. Detect coupling by analyzing import statements, cross-module calls, and checking for tight temporal constraints between distinct services.\n\n## 4. Function Responsibility\nA function should do one thing, do it well, and do it only. Limit function size to fit on a single screen. Extract sub-tasks into separate, clearly named functions. Avoid mixing different levels of abstraction. The Single Responsibility Principle applies at the function level.\n\n## 5. Duplication Patterns\nIdentify and eliminate duplicated code using the Rule of Three. Extract common logic into helper functions or base classes. Use Strategy or Template Method patterns to abstract varying behaviors. Be careful not to prematurely abstract coincidental duplication that isn't true behavioral duplication.\n\n## 6. Dead Code Elimination\nRegularly audit and remove code that is no longer executed. Use coverage tools and static analysis to identify untouched code paths. Remove deprecated features once their grace period expires. Do not comment out code; rely on version control history.\n\n## 7. Side Effects Management\nMinimize and isolate side effects to improve predictability. Favor pure functions that rely only on inputs and return outputs. Explicitly document functions performing I\u002FO. Group side-effecting code at the boundaries of the application (e.g., Hexagonal Architecture).\n\n## 8. State Mutation\nControl how and when state changes occur. Prefer immutable data structures where possible. Restrict mutability to small, clearly defined scopes. Use explicit synchronization mechanisms if mutation is necessary in concurrent environments. Avoid global mutable state entirely.\n\n## 9. API Ergonomics\nDesign APIs that are easy to use correctly and hard to use incorrectly. Provide sensible defaults. Use strong typing and domain types rather than primitive obsession. Ensure consistent naming and behavior across the entire API surface. Follow the Principle of Least Astonishment.\n\n## 10. Code Smells Identification\nTrain yourself to spot common code smells: Long Method, Large Class, Primitive Obsession, Feature Envy, Data Clumps, Switch Statements, and Temporary Field. Addressing these early prevents systemic rot and keeps the codebase malleable over its lifetime.\n\n",{"name":5,"description":7},"main","b2b8635798b0fab7a7c037608a616985cc1da742",".agents\u002Fskills\u002Fclean-code","https:\u002F\u002Fgithub.com\u002FpoppyTM\u002Faipo-lang","https:\u002F\u002Fwww.poppy.lat\u002Faipo\u002Fdocs\u002F","https:\u002F\u002Fgithub.com\u002FpoppyTM","https:\u002F\u002Fpoppy.lat","Construímos linguagens de programação e ferramentas para quem lê código com o mesmo cuidado com que escreve.","2026-11-02 17:30:11",{"source":8,"skillName":5,"commands":34,"prompt":44,"zipAvailable":45},[35,38,41],{"tool":36,"command":37},"npx","npx skills add poppyTM\u002Faipo-lang --skill clean-code",{"tool":39,"command":40},"bunx","bunx skills add poppyTM\u002Faipo-lang --skill clean-code",{"tool":42,"command":43},"pnpm","pnpm dlx skills add poppyTM\u002Faipo-lang --skill clean-code","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002FpoppyTM\u002Faipo-lang\u002Fblob\u002Fmain\u002F.agents\u002Fskills\u002Fclean-code\u002FSKILL.md",true,[47,53,57,61,65,69,73,77,83,87],{"path":48,"resourceType":49,"resourceTypeDesc":50,"sizeBytes":51,"sourceHtmlUrl":52},"checks\u002Fcleanliness-checklist.md","REFERENCE","参考文档",418,"https:\u002F\u002Fgithub.com\u002FpoppyTM\u002Faipo-lang\u002Fblob\u002Fmain\u002F.agents\u002Fskills\u002Fclean-code\u002Fchecks\u002Fcleanliness-checklist.md",{"path":54,"resourceType":49,"resourceTypeDesc":50,"sizeBytes":55,"sourceHtmlUrl":56},"examples\u002Fbad-naming.md",107,"https:\u002F\u002Fgithub.com\u002FpoppyTM\u002Faipo-lang\u002Fblob\u002Fmain\u002F.agents\u002Fskills\u002Fclean-code\u002Fexamples\u002Fbad-naming.md",{"path":58,"resourceType":49,"resourceTypeDesc":50,"sizeBytes":59,"sourceHtmlUrl":60},"examples\u002Fbefore_after_clean_code.md",1535,"https:\u002F\u002Fgithub.com\u002FpoppyTM\u002Faipo-lang\u002Fblob\u002Fmain\u002F.agents\u002Fskills\u002Fclean-code\u002Fexamples\u002Fbefore_after_clean_code.md",{"path":62,"resourceType":49,"resourceTypeDesc":50,"sizeBytes":63,"sourceHtmlUrl":64},"examples\u002Fgood-naming.md",129,"https:\u002F\u002Fgithub.com\u002FpoppyTM\u002Faipo-lang\u002Fblob\u002Fmain\u002F.agents\u002Fskills\u002Fclean-code\u002Fexamples\u002Fgood-naming.md",{"path":66,"resourceType":49,"resourceTypeDesc":50,"sizeBytes":67,"sourceHtmlUrl":68},"manifest.json",1255,"https:\u002F\u002Fgithub.com\u002FpoppyTM\u002Faipo-lang\u002Fblob\u002Fmain\u002F.agents\u002Fskills\u002Fclean-code\u002Fmanifest.json",{"path":70,"resourceType":49,"resourceTypeDesc":50,"sizeBytes":71,"sourceHtmlUrl":72},"references\u002Fclean-code-principles.md",1838,"https:\u002F\u002Fgithub.com\u002FpoppyTM\u002Faipo-lang\u002Fblob\u002Fmain\u002F.agents\u002Fskills\u002Fclean-code\u002Freferences\u002Fclean-code-principles.md",{"path":74,"resourceType":49,"resourceTypeDesc":50,"sizeBytes":75,"sourceHtmlUrl":76},"references\u002Fmartin-fowler-refactoring.md",134,"https:\u002F\u002Fgithub.com\u002FpoppyTM\u002Faipo-lang\u002Fblob\u002Fmain\u002F.agents\u002Fskills\u002Fclean-code\u002Freferences\u002Fmartin-fowler-refactoring.md",{"path":78,"resourceType":79,"resourceTypeDesc":80,"sizeBytes":81,"sourceHtmlUrl":82},"scripts\u002Fanalyze_complexity.sh","SCRIPT","脚本",63,"https:\u002F\u002Fgithub.com\u002FpoppyTM\u002Faipo-lang\u002Fblob\u002Fmain\u002F.agents\u002Fskills\u002Fclean-code\u002Fscripts\u002Fanalyze_complexity.sh",{"path":84,"resourceType":79,"resourceTypeDesc":80,"sizeBytes":85,"sourceHtmlUrl":86},"scripts\u002Fanalyze-cohesion.sh",160,"https:\u002F\u002Fgithub.com\u002FpoppyTM\u002Faipo-lang\u002Fblob\u002Fmain\u002F.agents\u002Fskills\u002Fclean-code\u002Fscripts\u002Fanalyze-cohesion.sh",{"path":88,"resourceType":49,"resourceTypeDesc":50,"sizeBytes":89,"sourceHtmlUrl":90},"templates\u002Fclean-code-review.md",280,"https:\u002F\u002Fgithub.com\u002FpoppyTM\u002Faipo-lang\u002Fblob\u002Fmain\u002F.agents\u002Fskills\u002Fclean-code\u002Ftemplates\u002Fclean-code-review.md",[92,99,105,111,117,124],{"skillNo":93,"name":94,"nameZh":6,"description":95,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":96,"categories":97,"keywords":98,"publishedAt":19},"01M7D3JYBW82B2Q8XH75TKWBT7","lang-aipo","Aipo V1 canonical engineering, ADR-001 syntax conformance, braces blocks, Tipo:nome method bindings, structural interfaces, transactional failure handling, and anti-hallucination guardrails for LLMs.","https:\u002F\u002Fgithub.com\u002FpoppyTM\u002Faipo-lang\u002Fblob\u002Fmain\u002Fskills\u002Flang-aipo\u002FSKILL.md",[],[],{"skillNo":100,"name":101,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":102,"categories":103,"keywords":104,"publishedAt":19},"01M7D3JWY6HS47F1TRVX14SZ5F","goal-management","https:\u002F\u002Fgithub.com\u002FpoppyTM\u002Faipo-lang\u002Fblob\u002Fmain\u002F.opencode\u002Fskills\u002Fgoal-management\u002FSKILL.md",[],[],{"skillNo":106,"name":107,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":108,"categories":109,"keywords":110,"publishedAt":19},"01M7D3JV6D1SPD1WNS14634CGV","evidence-collection","https:\u002F\u002Fgithub.com\u002FpoppyTM\u002Faipo-lang\u002Fblob\u002Fmain\u002F.opencode\u002Fskills\u002Fevidence-collection\u002FSKILL.md",[],[],{"skillNo":112,"name":113,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":114,"categories":115,"keywords":116,"publishedAt":19},"01M7D3JSSDVRNC7W42KAFA65MH","code-review","https:\u002F\u002Fgithub.com\u002FpoppyTM\u002Faipo-lang\u002Fblob\u002Fmain\u002F.opencode\u002Fskills\u002Fcode-review\u002FSKILL.md",[],[],{"skillNo":118,"name":119,"nameZh":6,"description":120,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":121,"categories":122,"keywords":123,"publishedAt":19},"01M7D3JPEZSE144W9T31QKB9XP","testing-quality","Testing pyramid, deterministic tests, regression tests, behavior assertions, test isolation, flaky detection, representative fixtures","https:\u002F\u002Fgithub.com\u002FpoppyTM\u002Faipo-lang\u002Fblob\u002Fmain\u002F.ai\u002Fskills\u002Ftesting-quality\u002FSKILL.md",[],[],{"skillNo":125,"name":126,"nameZh":6,"description":127,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":128,"categories":129,"keywords":130,"publishedAt":19},"01M7D3JJES8J9K0HXG45H27BRF","cognitive-clarity","Unambiguous communication, single-decision focus, visual structuring, and rationale-first explanation tailored for neurodivergent collaboration","https:\u002F\u002Fgithub.com\u002FpoppyTM\u002Faipo-lang\u002Fblob\u002Fmain\u002F.ai\u002Fskills\u002Fcognitive-clarity\u002FSKILL.md",[],[]]