codymaster 4.1.3 → 4.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +22 -2
- package/README.md +54 -84
- package/dist/index.js +589 -510
- package/dist/ui/box.js +49 -0
- package/install.sh +2 -2
- package/package.json +3 -9
- package/skills/AGENTS.md +61 -0
- package/skills/CLAUDE.md +158 -0
- package/skills/boxme-git-config/SKILL.md +56 -0
- package/skills/boxme-local-dev/SKILL.md +66 -0
- package/skills/build.sh +30 -0
- package/skills/cf +314 -0
- package/skills/cf 2 +313 -0
- package/skills/cm-ads-tracker/SKILL.md +364 -69
- package/skills/cm-auto-publisher/SKILL.md +81 -0
- package/skills/cm-booking-calendar/SKILL.md +521 -0
- package/skills/cm-booking-calendar/references/industry-patterns.md +527 -0
- package/skills/cm-booking-calendar/templates/booking-form.css +626 -0
- package/skills/cm-booking-calendar/templates/booking-form.html +477 -0
- package/skills/cm-booking-calendar/templates/calendar-engine.js +419 -0
- package/skills/cm-booking-calendar/templates/calendar-export.js +395 -0
- package/skills/cm-booking-calendar/templates/reminder-config.js +629 -0
- package/skills/cm-brainstorm-idea/SKILL.md +15 -24
- package/skills/cm-clean-code/SKILL.md +300 -0
- package/skills/cm-code-review/SKILL.md +0 -27
- package/skills/cm-codeintell/SKILL.md +598 -0
- package/skills/cm-content-factory/.content-factory-state.json +132 -0
- package/skills/cm-content-factory/.git 2/logs/refs/heads/main +1 -0
- package/skills/cm-content-factory/.git 2/logs/refs/remotes/origin/main +1 -0
- package/skills/cm-content-factory/.git 2/objects/02/fb0956734b5f8ba3f918b7defd04a89cfe0076 +0 -0
- package/skills/cm-content-factory/.git 2/objects/08/1e129d75dc6feac6c02037272e6bd1a04e3324 +0 -0
- package/skills/cm-content-factory/.git 2/objects/0c/5393416f3c5e01c9a655a802bff0dd52f76f0a +0 -0
- package/skills/cm-content-factory/.git 2/objects/10/0b9be46978a946a77188f68be725098a122001 +0 -0
- package/skills/cm-content-factory/.git 2/objects/10/cf041167fc9843610eb3d90259ef3396315fdc +0 -0
- package/skills/cm-content-factory/.git 2/objects/12/5e19538dd6e1338ffe74f6c4c165b00435bf48 +0 -0
- package/skills/cm-content-factory/.git 2/objects/16/a9b9d0088d5c1347628b45a2620b479d8ad57c +0 -0
- package/skills/cm-content-factory/.git 2/objects/17/8c2a9ef93c33ae4eec9d58e82321f9229843a1 +0 -0
- package/skills/cm-content-factory/.git 2/objects/25/397ae41d09104d763bdcac2695209d85cdea89 +0 -0
- package/skills/cm-content-factory/.git 2/objects/2f/a836b7947f2d458e1f639788bf4bb0983a3305 +0 -0
- package/skills/cm-content-factory/.git 2/objects/3a/baaaf0a1c0909c0828335791557125fba911e0 +0 -0
- package/skills/cm-content-factory/.git 2/objects/42/2924221b81f5ce3c4e4daac9a64a24f9b01f9a +0 -0
- package/skills/cm-content-factory/.git 2/objects/42/ec0ce707447dc11446a34c9995fb8533801731 +0 -0
- package/skills/cm-content-factory/.git 2/objects/46/e43ce92866d56ce74b1d750db307cfe6154a15 +0 -0
- package/skills/cm-content-factory/.git 2/objects/48/5e41b633c63f55b8277bcc59f44f67681f671a +0 -0
- package/skills/cm-content-factory/.git 2/objects/49/49c596a3a89fa240642acd95dd3258e261eb09 +0 -0
- package/skills/cm-content-factory/.git 2/objects/50/9d42d8412ef8eaf7f7e138476bac2e4d10ce60 +0 -0
- package/skills/cm-content-factory/.git 2/objects/55/0c8c389d981b463ef849aeb792d8be3ccb6ec8 +0 -0
- package/skills/cm-content-factory/.git 2/objects/5d/82d3b18410cdda3ace3677436f0cb599dbe2d2 +0 -0
- package/skills/cm-content-factory/.git 2/objects/60/0617c58e871a38b33bf29e282d132bb3c381ad +0 -0
- package/skills/cm-content-factory/.git 2/objects/6a/8369a99c687b7245c92ffaf0e0f0dab9014504 +0 -0
- package/skills/cm-content-factory/.git 2/objects/79/bea435d40ab531c1aaf6be0432c6a5b7aaed21 +0 -0
- package/skills/cm-content-factory/.git 2/objects/7e/5ebd79251c2f14e4aceb86c74b6b6daae6b500 +0 -0
- package/skills/cm-content-factory/.git 2/objects/81/98a822a60178d6d5023ddb3e222cddf048742e +0 -0
- package/skills/cm-content-factory/.git 2/objects/86/0a0e1943dfe53411d2e499a1f16f46a96ef758 +0 -0
- package/skills/cm-content-factory/.git 2/objects/86/971fb55fdc081fdbae52376f0f13e57a4e9b04 +0 -0
- package/skills/cm-content-factory/.git 2/objects/88/b89dd609a0a03f8d4fe8bfde20d5b8fc1d326d +0 -0
- package/skills/cm-content-factory/.git 2/objects/90/8737edb6b7809e32cc01590b4e08ba42a9d40d +0 -0
- package/skills/cm-content-factory/.git 2/objects/93/d5a8a9a7d4fb7f11491cb596a6880528725118 +0 -0
- package/skills/cm-content-factory/.git 2/objects/98/46a2ab81d0c3b3eb00ef88fc56989aa7e9f316 +0 -0
- package/skills/cm-content-factory/.git 2/objects/9b/d8dd1e49cf274eaf9c555f3ab39dce7af5715e +0 -0
- package/skills/cm-content-factory/.git 2/objects/a1/13329fb0cec96ae78b222d33a24c3b5bc7fa1f +0 -0
- package/skills/cm-content-factory/.git 2/objects/a9/e6effe626e8a3aea3a8fc3364b492191c6e7d0 +0 -0
- package/skills/cm-content-factory/.git 2/objects/ad/6de7e48d9782cca9353d1ff0aa1aab7fe1df85 +0 -0
- package/skills/cm-content-factory/.git 2/objects/af/54ae316f771ff692e299ffcd8bf2f06b413b59 +0 -0
- package/skills/cm-content-factory/.git 2/objects/b0/4cb8b0b00dad633e731c1472161419e738d674 +0 -0
- package/skills/cm-content-factory/.git 2/objects/b3/094abb0b9ed46419b269e4a4e36a459690e3b0 +0 -0
- package/skills/cm-content-factory/.git 2/objects/b9/435c5d4baac2cfc5c83009ddd27b46b60db5f1 +0 -0
- package/skills/cm-content-factory/.git 2/objects/ba/5da17dbaec5ec2dcfdfd126aead518d1171d5c +0 -0
- package/skills/cm-content-factory/.git 2/objects/c0/bf58703aa258ba5dd63083bebaec8f223d844c +0 -0
- package/skills/cm-content-factory/.git 2/objects/c4/701a34edf1fc1bad58ccc57bd03f9426acb59a +0 -0
- package/skills/cm-content-factory/.git 2/objects/c7/5ccce9a4e5cc74d9b3174550cf6d993ca43638 +0 -0
- package/skills/cm-content-factory/.git 2/objects/c7/710d59b5a35b0f1f0a0399386643a0bd94c929 +0 -0
- package/skills/cm-content-factory/.git 2/objects/d1/fe58237112e953e5fec52da22cf38e08be3df9 +5 -0
- package/skills/cm-content-factory/.git 2/objects/d2/2bbe9fd2f74c95bc5583e803f5e435f1e2cd86 +0 -0
- package/skills/cm-content-factory/.git 2/objects/d7/e72852ea2bff74581dbf247d400120086229f4 +0 -0
- package/skills/cm-content-factory/.git 2/objects/d8/d4c3b5553e4fd72807e1d4b49ef07d9ef3ac35 +0 -0
- package/skills/cm-content-factory/.git 2/objects/dc/75050c2876f6a02ae2a53a3c886f395b622977 +0 -0
- package/skills/cm-content-factory/.git 2/objects/ee/e8546f95acec500187c08a28a8b9ee02db0dec +0 -0
- package/skills/cm-content-factory/.git 2/objects/ef/263c059208b416c2146434f10cb2b9fabcba16 +0 -0
- package/skills/cm-content-factory/.git 2/objects/f3/ae597e84d9a59b88acd21c99bde2eaf686d785 +0 -0
- package/skills/cm-content-factory/.git 2/objects/f3/f6f5673c821d3d8e76fa267a9e882e7a5387ea +0 -0
- package/skills/cm-content-factory/.git 2/objects/f9/6e6d0ad02624dd11d5848594d056caef7a5e8b +0 -0
- package/skills/cm-content-factory/.git 2/objects/ff/278988fc1edf0db3abcf18de795f4cc0b4f3e1 +0 -0
- package/skills/cm-content-factory/.git 2/refs/heads/main +1 -0
- package/skills/cm-content-factory/.git 2/refs/remotes/origin/main +1 -0
- package/skills/cm-content-factory/.pytest_cache 2/v/cache/nodeids +76 -0
- package/skills/cm-content-factory/.pytest_cache 2/v/cache/stepwise +1 -0
- package/skills/cm-content-factory/AGENTS.md +61 -0
- package/skills/cm-content-factory/CLAUDE.md +63 -0
- package/skills/cm-content-factory/CURSOR.md +43 -0
- package/skills/cm-content-factory/Content Factory.zip +0 -0
- package/skills/cm-content-factory/cf +313 -0
- package/skills/cm-content-factory/config.schema.json +397 -0
- package/skills/cm-content-factory/dashboard/app.js +556 -0
- package/skills/cm-content-factory/dashboard/index.html +397 -0
- package/skills/cm-content-factory/dashboard/style.css +1211 -0
- package/skills/cm-content-factory/examples/01-real-estate.config.json +146 -0
- package/skills/cm-content-factory/examples/02-personal-finance.config.json +146 -0
- package/skills/cm-content-factory/examples/03-health-wellness.config.json +147 -0
- package/skills/cm-content-factory/examples/04-saas-software.config.json +147 -0
- package/skills/cm-content-factory/examples/05-legal-services.config.json +147 -0
- package/skills/cm-content-factory/examples/06-insurance.config.json +146 -0
- package/skills/cm-content-factory/examples/07-ecommerce-dropship.config.json +146 -0
- package/skills/cm-content-factory/examples/08-online-education.config.json +147 -0
- package/skills/cm-content-factory/examples/09-crypto-defi.config.json +147 -0
- package/skills/cm-content-factory/examples/10-beauty-skincare.config.json +147 -0
- package/skills/cm-content-factory/examples/11-home-services.config.json +146 -0
- package/skills/cm-content-factory/examples/12-dental-clinic.config.json +147 -0
- package/skills/cm-content-factory/examples/13-pet-care.config.json +147 -0
- package/skills/cm-content-factory/examples/14-travel-hospitality.config.json +147 -0
- package/skills/cm-content-factory/examples/15-ai-automation.config.json +147 -0
- package/skills/cm-content-factory/examples/16-wedding-events.config.json +147 -0
- package/skills/cm-content-factory/examples/17-fitness-coaching.config.json +148 -0
- package/skills/cm-content-factory/examples/18-cybersecurity.config.json +147 -0
- package/skills/cm-content-factory/examples/19-food-restaurant.config.json +148 -0
- package/skills/cm-content-factory/examples/20-solar-energy.config.json +147 -0
- package/skills/cm-content-factory/examples/fitness-blog.config.json +116 -0
- package/skills/cm-content-factory/examples/tech-blog.config.json +107 -0
- package/skills/cm-content-factory/extensions/EXTENSION_GUIDE.md +72 -0
- package/skills/cm-content-factory/extensions/hooks.py +126 -0
- package/skills/cm-content-factory/extensions/openclaw_adapter.py +132 -0
- package/skills/cm-content-factory/landing/index.html +680 -0
- package/skills/cm-content-factory/landing/script.js +101 -0
- package/skills/cm-content-factory/landing/style.css +1216 -0
- package/skills/cm-content-factory/landing/translations.js +508 -0
- package/skills/cm-content-factory/logs/events.jsonl +11 -0
- package/skills/cm-content-factory/profiles/_template.profile.json +231 -0
- package/skills/cm-content-factory/profiles/finance.profile.json +278 -0
- package/skills/cm-content-factory/profiles/legal.profile.json +263 -0
- package/skills/cm-content-factory/profiles/medical-research.profile.json +321 -0
- package/skills/cm-content-factory/profiles/technology.profile.json +275 -0
- package/skills/cm-content-factory/scripts/agent_dispatcher.py +266 -0
- package/skills/cm-content-factory/scripts/audit.py +106 -0
- package/skills/cm-content-factory/scripts/dashboard_server.py +225 -0
- package/skills/cm-content-factory/scripts/deploy.py +146 -0
- package/skills/cm-content-factory/scripts/extract.py +132 -0
- package/skills/cm-content-factory/scripts/landing_generator.py +459 -0
- package/skills/cm-content-factory/scripts/memory.py +521 -0
- package/skills/cm-content-factory/scripts/monetize.py +239 -0
- package/skills/cm-content-factory/scripts/pipeline.py +357 -0
- package/skills/cm-content-factory/scripts/plan.py +163 -0
- package/skills/cm-content-factory/scripts/publish.py +145 -0
- package/skills/cm-content-factory/scripts/research.py +337 -0
- package/skills/cm-content-factory/scripts/scaffold.py +464 -0
- package/skills/cm-content-factory/scripts/scoreboard.py +336 -0
- package/skills/cm-content-factory/scripts/seo.py +90 -0
- package/skills/cm-content-factory/scripts/state_manager.py +320 -0
- package/skills/cm-content-factory/scripts/token_manager.py +268 -0
- package/skills/cm-content-factory/scripts/validate.py +221 -0
- package/skills/cm-content-factory/scripts/wizard.py +329 -0
- package/skills/cm-content-factory/scripts/write.py +93 -0
- package/skills/cm-content-factory/sites/docs-site/src/assets/houston.webp +0 -0
- package/skills/cm-content-factory/sites/docs-site/src/content/docs/architecture.md +90 -0
- package/skills/cm-content-factory/sites/docs-site/src/content/docs/data-flow.md +54 -0
- package/skills/cm-content-factory/sites/docs-site/src/content/docs/deployment.md +38 -0
- package/skills/cm-content-factory/sites/docs-site/src/content/docs/flows/index.md +65 -0
- package/skills/cm-content-factory/sites/docs-site/src/content/docs/flows/lc-content-lifecycle.md +48 -0
- package/skills/cm-content-factory/sites/docs-site/src/content/docs/flows/seq-write-mode.md +39 -0
- package/skills/cm-content-factory/sites/docs-site/src/content/docs/flows/uj-first-batch.md +42 -0
- package/skills/cm-content-factory/sites/docs-site/src/content/docs/flows/wf-content-pipeline.md +51 -0
- package/skills/cm-content-factory/sites/docs-site/src/content/docs/flows/wf-learning-cycle.md +52 -0
- package/skills/cm-content-factory/sites/docs-site/src/content/docs/getting-started/configuration.md +86 -0
- package/skills/cm-content-factory/sites/docs-site/src/content/docs/getting-started/installation.md +80 -0
- package/skills/cm-content-factory/sites/docs-site/src/content/docs/getting-started/intro.md +58 -0
- package/skills/cm-content-factory/sites/docs-site/src/content/docs/index.md +102 -0
- package/skills/cm-content-factory/sites/docs-site/src/content/docs/jtbd/index.md +45 -0
- package/skills/cm-content-factory/sites/docs-site/src/content/docs/jtbd/optimize-seo.md +29 -0
- package/skills/cm-content-factory/sites/docs-site/src/content/docs/jtbd/scale-content-production.md +55 -0
- package/skills/cm-content-factory/sites/docs-site/src/content/docs/jtbd/standardize-quality.md +29 -0
- package/skills/cm-content-factory/sites/docs-site/src/content/docs/personas/buyer-cmo-huong.md +41 -0
- package/skills/cm-content-factory/sites/docs-site/src/content/docs/personas/buyer-content-lead-khoa.md +40 -0
- package/skills/cm-content-factory/sites/docs-site/src/content/docs/personas/index.md +56 -0
- package/skills/cm-content-factory/sites/docs-site/src/content/docs/personas/user-content-manager-lan.md +46 -0
- package/skills/cm-content-factory/sites/docs-site/src/content/docs/personas/user-seo-minh.md +45 -0
- package/skills/cm-content-factory/sites/docs-site/src/content/docs/personas/user-writer-tu.md +45 -0
- package/skills/cm-content-factory/sites/docs-site/src/content/docs/sop/content-pipeline.md +108 -0
- package/skills/cm-content-factory/sites/docs-site/src/content/docs/sop/index.md +22 -0
- package/skills/cm-content-factory/sites/docs-site/src/content/docs/sop/memory-system.md +52 -0
- package/skills/cm-content-factory/sites/docs-site/src/content/docs/sop/seo-optimization.md +58 -0
- package/skills/cm-content-factory/sites/docs-site/src/content/docs/sop/troubleshooting-guide.md +92 -0
- package/skills/cm-content-factory/sites/docs-site/src/styles/custom.css +575 -0
- package/skills/cm-content-factory/tests/conftest.py +66 -0
- package/skills/cm-content-factory/tests/test_agent_dispatcher.py +125 -0
- package/skills/cm-content-factory/tests/test_memory.py +128 -0
- package/skills/cm-content-factory/tests/test_pipeline.py +107 -0
- package/skills/cm-content-factory/tests/test_research.py +56 -0
- package/skills/cm-content-factory/tests/test_state_manager.py +131 -0
- package/skills/cm-content-factory/tests/test_token_manager.py +110 -0
- package/skills/cm-content-factory/tests/test_wizard.py +121 -0
- package/skills/cm-continuity/SKILL.md +7 -0
- package/skills/cm-cro-methodology/SKILL.md +290 -0
- package/skills/cm-dashboard/SKILL.md +7 -525
- package/skills/cm-debugging/SKILL.md +7 -116
- package/skills/cm-deep-search/SKILL.md +5 -1
- package/skills/cm-dockit/README.md +6 -15
- package/skills/cm-dockit/SKILL.md +20 -37
- package/skills/cm-execution/SKILL.md +6 -1
- package/skills/cm-frappe-agent/SKILL.md +134 -0
- package/skills/cm-frappe-agent/agents/doctype-architect.md +596 -0
- package/skills/cm-frappe-agent/agents/erpnext-customizer.md +643 -0
- package/skills/cm-frappe-agent/agents/frappe-backend.md +814 -0
- package/skills/cm-frappe-agent/agents/frappe-custom-frontend.md +557 -0
- package/skills/cm-frappe-agent/agents/frappe-debugger.md +625 -0
- package/skills/cm-frappe-agent/agents/frappe-fixer.md +275 -0
- package/skills/cm-frappe-agent/agents/frappe-frontend.md +660 -0
- package/skills/cm-frappe-agent/agents/frappe-installer.md +158 -0
- package/skills/cm-frappe-agent/agents/frappe-performance.md +307 -0
- package/skills/cm-frappe-agent/agents/frappe-planner.md +419 -0
- package/skills/cm-frappe-agent/agents/frappe-remote-ops.md +153 -0
- package/skills/cm-frappe-agent/agents/github-workflow.md +286 -0
- package/skills/cm-frappe-agent/commands/frappe-app.md +351 -0
- package/skills/cm-frappe-agent/commands/frappe-backend.md +162 -0
- package/skills/cm-frappe-agent/commands/frappe-bench.md +254 -0
- package/skills/cm-frappe-agent/commands/frappe-debug.md +263 -0
- package/skills/cm-frappe-agent/commands/frappe-doctype-create.md +272 -0
- package/skills/cm-frappe-agent/commands/frappe-doctype-field.md +310 -0
- package/skills/cm-frappe-agent/commands/frappe-erpnext.md +210 -0
- package/skills/cm-frappe-agent/commands/frappe-fix.md +59 -0
- package/skills/cm-frappe-agent/commands/frappe-frontend.md +210 -0
- package/skills/cm-frappe-agent/commands/frappe-fullstack.md +243 -0
- package/skills/cm-frappe-agent/commands/frappe-github.md +57 -0
- package/skills/cm-frappe-agent/commands/frappe-install.md +52 -0
- package/skills/cm-frappe-agent/commands/frappe-plan.md +442 -0
- package/skills/cm-frappe-agent/commands/frappe-remote.md +58 -0
- package/skills/cm-frappe-agent/commands/frappe-test.md +356 -0
- package/skills/cm-frappe-agent/docs/README.md +51 -0
- package/skills/cm-frappe-agent/docs/agents-catalog.md +113 -0
- package/skills/cm-frappe-agent/docs/architecture.md +149 -0
- package/skills/cm-frappe-agent/docs/commands-catalog.md +82 -0
- package/skills/cm-frappe-agent/docs/resources-catalog.md +66 -0
- package/skills/cm-frappe-agent/docs/sitemap-urls.txt +52 -0
- package/skills/cm-frappe-agent/docs/sitemap.md +81 -0
- package/skills/cm-frappe-agent/docs/sop/user-guide.md +178 -0
- package/skills/cm-frappe-agent/docs/sop/vibe-coding-guide.md +122 -0
- package/skills/cm-frappe-agent/resources/7-layer-architecture.md +985 -0
- package/skills/cm-frappe-agent/resources/bench_commands.md +73 -0
- package/skills/cm-frappe-agent/resources/code-patterns-guide.md +948 -0
- package/skills/cm-frappe-agent/resources/common_pitfalls.md +266 -0
- package/skills/cm-frappe-agent/resources/doctype-registry.md +158 -0
- package/skills/cm-frappe-agent/resources/installation-guide.md +289 -0
- package/skills/cm-frappe-agent/resources/rest-api-patterns.md +182 -0
- package/skills/cm-frappe-agent/resources/scaffold_checklist.md +82 -0
- package/skills/cm-frappe-agent/resources/upgrade_patterns.md +113 -0
- package/skills/cm-frappe-agent/resources/web-form-patterns.md +252 -0
- package/skills/cm-frappe-agent/skills/bench-commands/SKILL.md +621 -0
- package/skills/cm-frappe-agent/skills/client-scripts/SKILL.md +642 -0
- package/skills/cm-frappe-agent/skills/doctype-patterns/SKILL.md +576 -0
- package/skills/cm-frappe-agent/skills/frappe-api/SKILL.md +740 -0
- package/skills/cm-frappe-agent/skills/remote-operations/SKILL.md +47 -0
- package/skills/cm-frappe-agent/skills/server-scripts/SKILL.md +608 -0
- package/skills/cm-frappe-agent/skills/web-forms/SKILL.md +46 -0
- package/skills/cm-git-worktrees/SKILL.md +0 -7
- package/skills/cm-google-form/SKILL.md +266 -0
- package/skills/cm-google-form/templates/apps-script.js +55 -0
- package/skills/cm-google-form/templates/form-markup.html +110 -0
- package/skills/cm-google-form/templates/form-submit.js +201 -0
- package/skills/cm-google-form/templates/toast.css +152 -0
- package/skills/cm-growth-hacking/SKILL.md +293 -0
- package/skills/cm-growth-hacking/bottom-sheet-engine.md +261 -0
- package/skills/cm-growth-hacking/calendar-integration.md +264 -0
- package/skills/cm-growth-hacking/references/engagement-patterns.md +346 -0
- package/skills/cm-growth-hacking/templates/bottom-sheet.css +528 -0
- package/skills/cm-growth-hacking/templates/bottom-sheet.js +269 -0
- package/skills/cm-growth-hacking/templates/calendar-cta.js +213 -0
- package/skills/cm-growth-hacking/templates/tracking-events.js +211 -0
- package/skills/cm-growth-hacking/templates/trigger-manager.js +254 -0
- package/skills/cm-growth-hacking/tracking-events.md +246 -0
- package/skills/cm-growth-hacking/trigger-system.md +342 -0
- package/skills/cm-how-it-work/SKILL.md +20 -4
- package/skills/cm-identity-guard/SKILL.md +0 -11
- package/skills/cm-jtbd/SKILL.md +1 -1
- package/skills/cm-notebooklm/SKILL.md +172 -0
- package/skills/cm-notebooklm/references/command_reference.md +94 -0
- package/skills/cm-notebooklm/references/workflows.md +60 -0
- package/skills/cm-notebooklm/resources/knowledge_sources.md +106 -0
- package/skills/cm-notebooklm/scripts/brain-sync.sh +453 -0
- package/skills/cm-notebooklm/scripts/graduate_wisdom.py +101 -0
- package/skills/cm-planning/SKILL.md +39 -52
- package/skills/cm-project-bootstrap/SKILL.md +1307 -99
- package/skills/cm-quality-gate/SKILL.md +13 -106
- package/skills/cm-reactor/SKILL.md +274 -0
- package/skills/cm-safe-deploy/SKILL.md +415 -52
- package/skills/cm-safe-i18n/SKILL.md +1 -22
- package/skills/cm-secret-shield/SKILL.md +2 -2
- package/skills/cm-security-gate/SKILL.md +114 -0
- package/skills/cm-skill-chain/SKILL.md +2 -2
- package/skills/cm-skill-index/SKILL.md +9 -6
- package/skills/cm-skill-mastery/SKILL.md +2 -15
- package/skills/cm-start/SKILL.md +9 -0
- package/skills/cm-tdd/SKILL.md +8 -41
- package/skills/cm-ui-preview/SKILL.md +35 -173
- package/skills/cm-ux-master/FEATURES-v4.md +305 -0
- package/skills/cm-ux-master/README-ru.md +135 -0
- package/skills/cm-ux-master/README-vi.md +135 -0
- package/skills/cm-ux-master/README-zh.md +135 -0
- package/skills/cm-ux-master/README.md +489 -0
- package/skills/cm-ux-master/SKILL.md +773 -62
- package/skills/cm-ux-master/cli/README.md +180 -0
- package/skills/cm-ux-master/cli/pyproject.toml +106 -0
- package/skills/cm-ux-master/cli/requirements.txt +21 -0
- package/skills/cm-ux-master/cli/templates/base/skill-core.md +262 -0
- package/skills/cm-ux-master/cli/templates/platforms/claude.yaml +21 -0
- package/skills/cm-ux-master/cli/templates/platforms/cursor.yaml +21 -0
- package/skills/cm-ux-master/cli/templates/platforms/figma.yaml +24 -0
- package/skills/cm-ux-master/cli/templates/platforms/vscode-mcp.yaml +28 -0
- package/skills/cm-ux-master/cli/templates/platforms/windsurf.yaml +21 -0
- package/skills/cm-ux-master/cli/uxmaster/__init__.py +10 -0
- package/skills/cm-ux-master/cli/uxmaster/__main__.py +19 -0
- package/skills/cm-ux-master/cli/uxmaster/cli.py +349 -0
- package/skills/cm-ux-master/cli/uxmaster/commands/__init__.py +8 -0
- package/skills/cm-ux-master/cli/uxmaster/commands/extract.py +18 -0
- package/skills/cm-ux-master/cli/uxmaster/commands/init.py +58 -0
- package/skills/cm-ux-master/cli/uxmaster/commands/mcp.py +194 -0
- package/skills/cm-ux-master/cli/uxmaster/commands/search.py +23 -0
- package/skills/cm-ux-master/cli/uxmaster/commands/validate.py +270 -0
- package/skills/cm-ux-master/cli/uxmaster/search_engine.py +532 -0
- package/skills/cm-ux-master/cli/uxmaster/template_engine.py +458 -0
- package/skills/cm-ux-master/cli/uxmaster/utils/__init__.py +9 -0
- package/skills/cm-ux-master/cli/uxmaster/utils/console.py +42 -0
- package/skills/cm-ux-master/cli/uxmaster/utils/detect.py +83 -0
- package/skills/cm-ux-master/data/accessibility-advanced.csv +26 -0
- package/skills/cm-ux-master/data/animation.csv +31 -0
- package/skills/cm-ux-master/data/charts.csv +26 -0
- package/skills/cm-ux-master/data/colors.csv +97 -0
- package/skills/cm-ux-master/data/design-tests.csv +37 -0
- package/skills/cm-ux-master/data/devices.csv +21 -0
- package/skills/cm-ux-master/data/icons.csv +101 -0
- package/skills/cm-ux-master/data/landing.csv +31 -0
- package/skills/cm-ux-master/data/products.csv +97 -0
- package/skills/cm-ux-master/data/react-performance.csv +45 -0
- package/skills/cm-ux-master/data/responsive.csv +26 -0
- package/skills/cm-ux-master/data/semi-tokens.csv +52 -0
- package/skills/cm-ux-master/data/stacks/angular.csv +34 -0
- package/skills/cm-ux-master/data/stacks/astro.csv +54 -0
- package/skills/cm-ux-master/data/stacks/electron.csv +32 -0
- package/skills/cm-ux-master/data/stacks/flutter.csv +53 -0
- package/skills/cm-ux-master/data/stacks/html-tailwind.csv +56 -0
- package/skills/cm-ux-master/data/stacks/htmx.csv +28 -0
- package/skills/cm-ux-master/data/stacks/jetpack-compose.csv +53 -0
- package/skills/cm-ux-master/data/stacks/nextjs.csv +53 -0
- package/skills/cm-ux-master/data/stacks/nuxt-ui.csv +51 -0
- package/skills/cm-ux-master/data/stacks/nuxtjs.csv +59 -0
- package/skills/cm-ux-master/data/stacks/react-native.csv +52 -0
- package/skills/cm-ux-master/data/stacks/react.csv +54 -0
- package/skills/cm-ux-master/data/stacks/shadcn.csv +61 -0
- package/skills/cm-ux-master/data/stacks/svelte.csv +54 -0
- package/skills/cm-ux-master/data/stacks/swiftui.csv +51 -0
- package/skills/cm-ux-master/data/stacks/tauri.csv +29 -0
- package/skills/cm-ux-master/data/stacks/vue.csv +50 -0
- package/skills/cm-ux-master/data/styles.csv +68 -0
- package/skills/cm-ux-master/data/typography.csv +58 -0
- package/skills/cm-ux-master/data/ui-reasoning.csv +101 -0
- package/skills/cm-ux-master/data/ux-guidelines.csv +100 -0
- package/skills/cm-ux-master/data/ux-laws.csv +49 -0
- package/skills/cm-ux-master/data/web-interface.csv +31 -0
- package/skills/cm-ux-master/docs/LANDING-PAGE.html +377 -0
- package/skills/cm-ux-master/docs/README.md +108 -0
- package/skills/cm-ux-master/docs/css/styles.css +573 -0
- package/skills/cm-ux-master/docs/examples/demo-script.md +319 -0
- package/skills/cm-ux-master/docs/guides/for-designers.md +692 -0
- package/skills/cm-ux-master/docs/guides/for-developers.md +778 -0
- package/skills/cm-ux-master/docs/guides/for-product-managers.md +693 -0
- package/skills/cm-ux-master/docs/guides/react-guide-vi.md +50 -0
- package/skills/cm-ux-master/docs/index.html +1062 -0
- package/skills/cm-ux-master/docs/js/i18n.js +84 -0
- package/skills/cm-ux-master/docs/js/lang/de.js +145 -0
- package/skills/cm-ux-master/docs/js/lang/en.js +145 -0
- package/skills/cm-ux-master/docs/js/lang/fr.js +145 -0
- package/skills/cm-ux-master/docs/js/lang/hi.js +145 -0
- package/skills/cm-ux-master/docs/js/lang/id.js +145 -0
- package/skills/cm-ux-master/docs/js/lang/ja.js +145 -0
- package/skills/cm-ux-master/docs/js/lang/ko.js +145 -0
- package/skills/cm-ux-master/docs/js/lang/ru.js +145 -0
- package/skills/cm-ux-master/docs/js/lang/vi.js +145 -0
- package/skills/cm-ux-master/docs/js/lang/zh.js +145 -0
- package/skills/cm-ux-master/docs/js/main.js +117 -0
- package/skills/cm-ux-master/docs/plan/PHASE1-COMPLETION.md +217 -0
- package/skills/cm-ux-master/docs/plan/PHASE2-COMPLETION.md +199 -0
- package/skills/cm-ux-master/docs/plan/PHASE2-ENHANCED-COMPLETION.md +352 -0
- package/skills/cm-ux-master/docs/plan/PHASE3-VALIDATION-COMPLETION.md +499 -0
- package/skills/cm-ux-master/docs/plan/PHASE4-TESTING-POLISH-COMPLETION.md +483 -0
- package/skills/cm-ux-master/docs/plan/UXM-2.0-ROADMAP.md +681 -0
- package/skills/cm-ux-master/docs/plan/WOW-PITCH.md +410 -0
- package/skills/cm-ux-master/docs/technical/api-reference.md +824 -0
- package/skills/cm-ux-master/docs/technical/harvester-v4.md +328 -0
- package/skills/cm-ux-master/docs/technical/how-it-works.md +1128 -0
- package/skills/cm-ux-master/docs/tutorials/quickstart.md +339 -0
- package/skills/cm-ux-master/docs/tutorials/tutorials.md +939 -0
- package/skills/cm-ux-master/docs/tutorials/user-guide.md +716 -0
- package/skills/cm-ux-master/examples/README.md +63 -0
- package/skills/cm-ux-master/mcp/__init__.py +3 -0
- package/skills/cm-ux-master/mcp/integrations/__init__.py +11 -0
- package/skills/cm-ux-master/mcp/integrations/figma/__init__.py +6 -0
- package/skills/cm-ux-master/mcp/integrations/figma/client.py +293 -0
- package/skills/cm-ux-master/mcp/integrations/figma/plugin/code.js +561 -0
- package/skills/cm-ux-master/mcp/integrations/figma/plugin/ui.html +334 -0
- package/skills/cm-ux-master/mcp/integrations/stitch/__init__.py +5 -0
- package/skills/cm-ux-master/mcp/integrations/stitch/client.py +410 -0
- package/skills/cm-ux-master/mcp/integrations/vscode/package.json +167 -0
- package/skills/cm-ux-master/mcp/integrations/vscode/src/extension.ts +81 -0
- package/skills/cm-ux-master/mcp/mcp-config.json +274 -0
- package/skills/cm-ux-master/mcp/server.py +771 -0
- package/skills/cm-ux-master/mcp/tools/__init__.py +13 -0
- package/skills/cm-ux-master/mcp-server/server.py +595 -0
- package/skills/cm-ux-master/output/fila/FilaDashboard.tsx +47 -0
- package/skills/cm-ux-master/output/fila/components/badge/component.tsx +35 -0
- package/skills/cm-ux-master/output/fila/components/badge/index.ts +1 -0
- package/skills/cm-ux-master/output/fila/components/button/component.tsx +53 -0
- package/skills/cm-ux-master/output/fila/components/button/index.ts +1 -0
- package/skills/cm-ux-master/output/fila/components/card/component.tsx +35 -0
- package/skills/cm-ux-master/output/fila/components/card/index.ts +1 -0
- package/skills/cm-ux-master/output/fila/components/input/component.tsx +41 -0
- package/skills/cm-ux-master/output/fila/components/input/index.ts +1 -0
- package/skills/cm-ux-master/output/fila/design-system.css +151 -0
- package/skills/cm-ux-master/output/fila/design-system.html +1596 -0
- package/skills/cm-ux-master/output/fila/design-system.json +168 -0
- package/skills/cm-ux-master/output/fila/figma-tokens.json +523 -0
- package/skills/cm-ux-master/output/fila/harvest-v4-raw.json +406 -0
- package/skills/cm-ux-master/output/fila/semi-theme-override.css +95 -0
- package/skills/cm-ux-master/output/haravan/HaravanDashboard.tsx +103 -0
- package/skills/cm-ux-master/output/haravan/design-system-v3-live.html +2716 -0
- package/skills/cm-ux-master/output/haravan/design-system-v3.html +1770 -0
- package/skills/cm-ux-master/output/haravan/design-system.html +914 -0
- package/skills/cm-ux-master/output/haravan/figma-tokens.json +84 -0
- package/skills/cm-ux-master/output/haravan/haravan-harvest.json +33 -0
- package/skills/cm-ux-master/output/haravan/harvest-v3-raw.json +167 -0
- package/skills/cm-ux-master/output/haravan/semi-theme-override.css +39 -0
- package/skills/cm-ux-master/references/audit-template.md +257 -0
- package/skills/cm-ux-master/references/cultural-ux.md +346 -0
- package/skills/cm-ux-master/references/dark-patterns.md +362 -0
- package/skills/cm-ux-master/references/heuristic-conflicts.md +296 -0
- package/skills/cm-ux-master/references/krug-principles.md +289 -0
- package/skills/cm-ux-master/references/nielsen-heuristics.md +360 -0
- package/skills/cm-ux-master/references/wcag-checklist.md +306 -0
- package/skills/cm-ux-master/scripts/component_generator.py +631 -0
- package/skills/cm-ux-master/scripts/core.py +305 -0
- package/skills/cm-ux-master/scripts/demo_validation.py +452 -0
- package/skills/cm-ux-master/scripts/design_doc_generator.py +1325 -0
- package/skills/cm-ux-master/scripts/design_system.py +1141 -0
- package/skills/cm-ux-master/scripts/design_system_indexer.py +889 -0
- package/skills/cm-ux-master/scripts/extract_i18n.py +251 -0
- package/skills/cm-ux-master/scripts/extractor.py +1437 -0
- package/skills/cm-ux-master/scripts/figma_bridge.py +406 -0
- package/skills/cm-ux-master/scripts/generate.py +147 -0
- package/skills/cm-ux-master/scripts/harvest_session.py +207 -0
- package/skills/cm-ux-master/scripts/harvester.js +240 -0
- package/skills/cm-ux-master/scripts/harvester_browser.py +717 -0
- package/skills/cm-ux-master/scripts/harvester_cli.py +431 -0
- package/skills/cm-ux-master/scripts/harvester_v1.js +275 -0
- package/skills/cm-ux-master/scripts/harvester_v3.js +620 -0
- package/skills/cm-ux-master/scripts/harvester_v4.js +1003 -0
- package/skills/cm-ux-master/scripts/install.py +528 -0
- package/skills/cm-ux-master/scripts/license.py +81 -0
- package/skills/cm-ux-master/scripts/media/qrpayment.png +0 -0
- package/skills/cm-ux-master/scripts/pro_stubs.py +120 -0
- package/skills/cm-ux-master/scripts/project_registry.py +217 -0
- package/skills/cm-ux-master/scripts/search.py +114 -0
- package/skills/cm-ux-master/scripts/semi_mcp_bridge.py +425 -0
- package/skills/cm-ux-master/scripts/stitch_integration.py +583 -0
- package/skills/cm-ux-master/scripts/test_harvester_v4.py +335 -0
- package/skills/cm-ux-master/scripts/token_mapper.py +626 -0
- package/skills/cm-ux-master/scripts/validation_engine.py +1571 -0
- package/skills/cm-ux-master/scripts/wizard.py +653 -0
- package/skills/cm-ux-master/setup.py +93 -0
- package/skills/cm-ux-master/templates/base/flutter-widget.dart +69 -0
- package/skills/cm-ux-master/templates/base/html-page.html +152 -0
- package/skills/cm-ux-master/templates/base/react-component.tsx +47 -0
- package/skills/cm-ux-master/templates/base/swiftui-view.swift +62 -0
- package/skills/cm-ux-master/templates/quick-start.sh +176 -0
- package/skills/cm-ux-master/tests/automation/batch-validate.sh +250 -0
- package/skills/cm-ux-master/tests/automation/generate-test-projects.sh +561 -0
- package/skills/cm-ux-master/tests/automation/run-all-tests.sh +315 -0
- package/skills/cm-ux-master/tests/test_design_doc.py +145 -0
- package/skills/cm-ux-master/tests/test_devices.py +74 -0
- package/skills/cm-ux-master/tests/test_generator.py +116 -0
- package/skills/cm-ux-master/tests/test_harvest_session.py +131 -0
- package/skills/cm-ux-master/tests/test_harvester.py +127 -0
- package/skills/cm-ux-master/tests/test_harvester_v3.py +324 -0
- package/skills/cm-ux-master/tests/test_mcp_server.py +496 -0
- package/skills/cm-ux-master/tests/test_new_domains.py +108 -0
- package/skills/cm-ux-master/tests/test_new_stacks.py +103 -0
- package/skills/cm-ux-master/tests/test_project_registry.py +146 -0
- package/skills/cm-ux-master/tests/test_semi_mcp_bridge.py +207 -0
- package/skills/cm-ux-master/tests/test_token_mapper.py +247 -0
- package/skills/cm-ux-master/tests/test_validation_engine.py +617 -0
- package/skills/config.schema.json +397 -0
- package/skills/frappe-app-builder.zip +0 -0
- package/skills/jobs-to-be-done/SKILL.md +266 -0
- package/skills/jobs-to-be-done/references/case-studies.md +154 -0
- package/skills/jobs-to-be-done/references/competitive-strategy.md +280 -0
- package/skills/jobs-to-be-done/references/diagnostics.md +158 -0
- package/skills/jobs-to-be-done/references/innovation-process.md +392 -0
- package/skills/jobs-to-be-done/references/organizational-change.md +328 -0
- package/skills/marketplace-report-crawler/SKILL.md +176 -0
- package/skills/marketplace-report-crawler/config/accounts.json +41 -0
- package/skills/marketplace-report-crawler/config/report-types.json +422 -0
- package/skills/marketplace-report-crawler/config/sessions.json +3 -0
- package/skills/marketplace-report-crawler/scripts/ab-wrapper.sh +102 -0
- package/skills/marketplace-report-crawler/scripts/browser-actions/lazada/lazada-actions.js +114 -0
- package/skills/marketplace-report-crawler/scripts/browser-actions/shopee/shopee-actions.js +94 -0
- package/skills/marketplace-report-crawler/scripts/browser-actions/tiktok/tiktok-actions.js +272 -0
- package/skills/marketplace-report-crawler/scripts/crawl-runner.js +281 -0
- package/skills/marketplace-report-crawler/scripts/session-check.sh +72 -0
- package/skills/marketplace-report-crawler/scripts/session-manager.sh +349 -0
- package/skills/marketplace-report-crawler/scripts/setup-folders.sh +83 -0
- package/skills/medical-research/SKILL.md +194 -0
- package/skills/medical-research/scripts/evidence_checker.py +288 -0
- package/skills/mom-test/SKILL.md +267 -0
- package/skills/mom-test/references/avoiding-bad-data.md +221 -0
- package/skills/mom-test/references/case-studies.md +306 -0
- package/skills/mom-test/references/commitment-advancement.md +219 -0
- package/skills/mom-test/references/finding-conversations.md +251 -0
- package/skills/mom-test/references/processing-learning.md +256 -0
- package/skills/mom-test/references/question-patterns.md +198 -0
- package/skills/pandasai-analytics/SKILL.md +251 -0
- package/skills/release-it/SKILL.md +235 -0
- package/skills/release-it/references/anti-patterns.md +279 -0
- package/skills/release-it/references/capacity-planning.md +285 -0
- package/skills/release-it/references/chaos-engineering.md +325 -0
- package/skills/release-it/references/deployment-strategies.md +331 -0
- package/skills/release-it/references/observability.md +301 -0
- package/skills/release-it/references/stability-patterns.md +355 -0
- package/skills/scripts/sync-ide-skills.sh +61 -0
- package/skills/skill-creator-ultra/.agents/workflows/skill-audit.md +37 -0
- package/skills/skill-creator-ultra/.agents/workflows/skill-compare.md +34 -0
- package/skills/skill-creator-ultra/.agents/workflows/skill-export.md +51 -0
- package/skills/skill-creator-ultra/.agents/workflows/skill-generate.md +39 -0
- package/skills/skill-creator-ultra/.agents/workflows/skill-scaffold.md +52 -0
- package/skills/skill-creator-ultra/.agents/workflows/skill-simulate.md +25 -0
- package/skills/skill-creator-ultra/.agents/workflows/skill-stats.md +31 -0
- package/skills/skill-creator-ultra/.agents/workflows/skill-validate.md +25 -0
- package/skills/skill-creator-ultra/README.md +1242 -0
- package/skills/skill-creator-ultra/SKILL.md +388 -0
- package/skills/skill-creator-ultra/agents/analyzer.md +274 -0
- package/skills/skill-creator-ultra/agents/comparator.md +202 -0
- package/skills/skill-creator-ultra/agents/grader.md +223 -0
- package/skills/skill-creator-ultra/assets/eval_review.html +146 -0
- package/skills/skill-creator-ultra/eval-viewer/generate_review.py +471 -0
- package/skills/skill-creator-ultra/eval-viewer/viewer.html +1325 -0
- package/skills/skill-creator-ultra/examples/example_anthropic_frontend.md +109 -0
- package/skills/skill-creator-ultra/examples/example_anthropic_pdf.md +116 -0
- package/skills/skill-creator-ultra/examples/example_api_docs.md +189 -0
- package/skills/skill-creator-ultra/examples/example_db_migration.md +253 -0
- package/skills/skill-creator-ultra/examples/example_git_commit.md +111 -0
- package/skills/skill-creator-ultra/install.ps1 +289 -0
- package/skills/skill-creator-ultra/install.sh +313 -0
- package/skills/skill-creator-ultra/phases/phase1_interview.md +202 -0
- package/skills/skill-creator-ultra/phases/phase2_extract.md +55 -0
- package/skills/skill-creator-ultra/phases/phase3_detect.md +57 -0
- package/skills/skill-creator-ultra/phases/phase4_generate.md +543 -0
- package/skills/skill-creator-ultra/phases/phase5_test.md +319 -0
- package/skills/skill-creator-ultra/phases/phase6_eval.md +301 -0
- package/skills/skill-creator-ultra/phases/phase7_iterate.md +103 -0
- package/skills/skill-creator-ultra/phases/phase8_optimize.md +113 -0
- package/skills/skill-creator-ultra/resources/advanced_patterns.md +499 -0
- package/skills/skill-creator-ultra/resources/anti_patterns.md +376 -0
- package/skills/skill-creator-ultra/resources/blueprints.md +498 -0
- package/skills/skill-creator-ultra/resources/checklist.md +243 -0
- package/skills/skill-creator-ultra/resources/composition_cookbook.md +291 -0
- package/skills/skill-creator-ultra/resources/description_optimization.md +90 -0
- package/skills/skill-creator-ultra/resources/eval_guide.md +133 -0
- package/skills/skill-creator-ultra/resources/industry_questions.md +189 -0
- package/skills/skill-creator-ultra/resources/interview_questions.md +200 -0
- package/skills/skill-creator-ultra/resources/pattern_detection.md +200 -0
- package/skills/skill-creator-ultra/resources/prompt_engineering.md +531 -0
- package/skills/skill-creator-ultra/resources/schemas.md +430 -0
- package/skills/skill-creator-ultra/resources/script_integration.md +593 -0
- package/skills/skill-creator-ultra/resources/scripts_guide.md +339 -0
- package/skills/skill-creator-ultra/resources/skill_template.md +124 -0
- package/skills/skill-creator-ultra/resources/skill_writing_guide.md +634 -0
- package/skills/skill-creator-ultra/resources/versioning_guide.md +193 -0
- package/skills/skill-creator-ultra/scripts/ci_eval.py +200 -0
- package/skills/skill-creator-ultra/scripts/package_skill.py +165 -0
- package/skills/skill-creator-ultra/scripts/simulate_skill.py +398 -0
- package/skills/skill-creator-ultra/scripts/skill_audit.py +611 -0
- package/skills/skill-creator-ultra/scripts/skill_compare.py +265 -0
- package/skills/skill-creator-ultra/scripts/skill_export.py +334 -0
- package/skills/skill-creator-ultra/scripts/skill_scaffold.py +403 -0
- package/skills/skill-creator-ultra/scripts/skill_stats.py +339 -0
- package/skills/skill-creator-ultra/scripts/validate_skill.py +411 -0
- package/skills/tailwind-mastery/SKILL.md +229 -0
- package/skills/vercel-react-best-practices/AGENTS.md +3373 -0
- package/skills/vercel-react-best-practices/README.md +123 -0
- package/skills/vercel-react-best-practices/SKILL.md +143 -0
- package/skills/vercel-react-best-practices/rules/_sections.md +46 -0
- package/skills/vercel-react-best-practices/rules/_template.md +28 -0
- package/skills/vercel-react-best-practices/rules/advanced-event-handler-refs.md +55 -0
- package/skills/vercel-react-best-practices/rules/advanced-init-once.md +42 -0
- package/skills/vercel-react-best-practices/rules/advanced-use-latest.md +39 -0
- package/skills/vercel-react-best-practices/rules/async-api-routes.md +38 -0
- package/skills/vercel-react-best-practices/rules/async-defer-await.md +80 -0
- package/skills/vercel-react-best-practices/rules/async-dependencies.md +51 -0
- package/skills/vercel-react-best-practices/rules/async-parallel.md +28 -0
- package/skills/vercel-react-best-practices/rules/async-suspense-boundaries.md +99 -0
- package/skills/vercel-react-best-practices/rules/bundle-barrel-imports.md +59 -0
- package/skills/vercel-react-best-practices/rules/bundle-conditional.md +31 -0
- package/skills/vercel-react-best-practices/rules/bundle-defer-third-party.md +49 -0
- package/skills/vercel-react-best-practices/rules/bundle-dynamic-imports.md +35 -0
- package/skills/vercel-react-best-practices/rules/bundle-preload.md +50 -0
- package/skills/vercel-react-best-practices/rules/client-event-listeners.md +74 -0
- package/skills/vercel-react-best-practices/rules/client-localstorage-schema.md +71 -0
- package/skills/vercel-react-best-practices/rules/client-passive-event-listeners.md +48 -0
- package/skills/vercel-react-best-practices/rules/client-swr-dedup.md +56 -0
- package/skills/vercel-react-best-practices/rules/js-batch-dom-css.md +107 -0
- package/skills/vercel-react-best-practices/rules/js-cache-function-results.md +80 -0
- package/skills/vercel-react-best-practices/rules/js-cache-property-access.md +28 -0
- package/skills/vercel-react-best-practices/rules/js-cache-storage.md +70 -0
- package/skills/vercel-react-best-practices/rules/js-combine-iterations.md +32 -0
- package/skills/vercel-react-best-practices/rules/js-early-exit.md +50 -0
- package/skills/vercel-react-best-practices/rules/js-flatmap-filter.md +60 -0
- package/skills/vercel-react-best-practices/rules/js-hoist-regexp.md +45 -0
- package/skills/vercel-react-best-practices/rules/js-index-maps.md +37 -0
- package/skills/vercel-react-best-practices/rules/js-length-check-first.md +49 -0
- package/skills/vercel-react-best-practices/rules/js-min-max-loop.md +82 -0
- package/skills/vercel-react-best-practices/rules/js-set-map-lookups.md +24 -0
- package/skills/vercel-react-best-practices/rules/js-tosorted-immutable.md +57 -0
- package/skills/vercel-react-best-practices/rules/rendering-activity.md +26 -0
- package/skills/vercel-react-best-practices/rules/rendering-animate-svg-wrapper.md +47 -0
- package/skills/vercel-react-best-practices/rules/rendering-conditional-render.md +40 -0
- package/skills/vercel-react-best-practices/rules/rendering-content-visibility.md +38 -0
- package/skills/vercel-react-best-practices/rules/rendering-hoist-jsx.md +46 -0
- package/skills/vercel-react-best-practices/rules/rendering-hydration-no-flicker.md +82 -0
- package/skills/vercel-react-best-practices/rules/rendering-hydration-suppress-warning.md +30 -0
- package/skills/vercel-react-best-practices/rules/rendering-resource-hints.md +85 -0
- package/skills/vercel-react-best-practices/rules/rendering-script-defer-async.md +68 -0
- package/skills/vercel-react-best-practices/rules/rendering-svg-precision.md +28 -0
- package/skills/vercel-react-best-practices/rules/rendering-usetransition-loading.md +75 -0
- package/skills/vercel-react-best-practices/rules/rerender-defer-reads.md +39 -0
- package/skills/vercel-react-best-practices/rules/rerender-dependencies.md +45 -0
- package/skills/vercel-react-best-practices/rules/rerender-derived-state-no-effect.md +40 -0
- package/skills/vercel-react-best-practices/rules/rerender-derived-state.md +29 -0
- package/skills/vercel-react-best-practices/rules/rerender-functional-setstate.md +74 -0
- package/skills/vercel-react-best-practices/rules/rerender-lazy-state-init.md +58 -0
- package/skills/vercel-react-best-practices/rules/rerender-memo-with-default-value.md +38 -0
- package/skills/vercel-react-best-practices/rules/rerender-memo.md +44 -0
- package/skills/vercel-react-best-practices/rules/rerender-move-effect-to-event.md +45 -0
- package/skills/vercel-react-best-practices/rules/rerender-no-inline-components.md +82 -0
- package/skills/vercel-react-best-practices/rules/rerender-simple-expression-in-memo.md +35 -0
- package/skills/vercel-react-best-practices/rules/rerender-split-combined-hooks.md +64 -0
- package/skills/vercel-react-best-practices/rules/rerender-transitions.md +40 -0
- package/skills/vercel-react-best-practices/rules/rerender-use-deferred-value.md +59 -0
- package/skills/vercel-react-best-practices/rules/rerender-use-ref-transient-values.md +73 -0
- package/skills/vercel-react-best-practices/rules/server-after-nonblocking.md +73 -0
- package/skills/vercel-react-best-practices/rules/server-auth-actions.md +96 -0
- package/skills/vercel-react-best-practices/rules/server-cache-lru.md +41 -0
- package/skills/vercel-react-best-practices/rules/server-cache-react.md +76 -0
- package/skills/vercel-react-best-practices/rules/server-dedup-props.md +65 -0
- package/skills/vercel-react-best-practices/rules/server-hoist-static-io.md +142 -0
- package/skills/vercel-react-best-practices/rules/server-parallel-fetching.md +83 -0
- package/skills/vercel-react-best-practices/rules/server-serialization.md +38 -0
- package/skills/web-design-guidelines/SKILL.md +39 -0
- package/skills/cro-methodology/SKILL.md +0 -98
- /package/skills/{cro-methodology → cm-cro-methodology}/references/COPYWRITING.md +0 -0
- /package/skills/{cro-methodology → cm-cro-methodology}/references/OBJECTIONS.md +0 -0
- /package/skills/{cro-methodology → cm-cro-methodology}/references/PERSUASION.md +0 -0
- /package/skills/{cro-methodology → cm-cro-methodology}/references/RESEARCH.md +0 -0
- /package/skills/{cro-methodology → cm-cro-methodology}/references/funnel-analysis.md +0 -0
- /package/skills/{cro-methodology → cm-cro-methodology}/references/testing-methodology.md +0 -0
|
@@ -0,0 +1,331 @@
|
|
|
1
|
+
# Deployment Strategies
|
|
2
|
+
|
|
3
|
+
The distinction between deployment (placing code on infrastructure) and release (exposing code to users) is fundamental. Conflating the two means every deployment is a high-risk event. Separating them gives you the ability to deploy with confidence, test in production, and release when ready.
|
|
4
|
+
|
|
5
|
+
Most production outages are caused by changes. Deployment strategies exist to make changes safe.
|
|
6
|
+
|
|
7
|
+
## Zero-Downtime Deployment
|
|
8
|
+
|
|
9
|
+
Zero-downtime deployment is not optional for any system with users. Users should never see an error page because you are deploying code.
|
|
10
|
+
|
|
11
|
+
### Prerequisites for Zero-Downtime Deployment
|
|
12
|
+
|
|
13
|
+
| Requirement | Why |
|
|
14
|
+
|-------------|-----|
|
|
15
|
+
| **Backward-compatible changes** | Old code and new code run simultaneously during deployment |
|
|
16
|
+
| **Graceful shutdown** | In-flight requests must complete before an instance is terminated |
|
|
17
|
+
| **Health checks** | Load balancer must know when a new instance is ready to receive traffic |
|
|
18
|
+
| **Session independence** | Requests from the same user can be routed to any instance |
|
|
19
|
+
| **Database compatibility** | Schema changes must work with both old and new application code |
|
|
20
|
+
|
|
21
|
+
---
|
|
22
|
+
|
|
23
|
+
## Rolling Deployment
|
|
24
|
+
|
|
25
|
+
The simplest zero-downtime strategy. Replace instances one at a time (or in small batches), verifying health after each replacement.
|
|
26
|
+
|
|
27
|
+
### How It Works
|
|
28
|
+
|
|
29
|
+
```
|
|
30
|
+
Cluster: [v1] [v1] [v1] [v1] [v1]
|
|
31
|
+
|
|
32
|
+
Step 1: [v2] [v1] [v1] [v1] [v1] ← Deploy to instance 1, verify health
|
|
33
|
+
Step 2: [v2] [v2] [v1] [v1] [v1] ← Deploy to instance 2, verify health
|
|
34
|
+
Step 3: [v2] [v2] [v2] [v1] [v1] ← Deploy to instance 3, verify health
|
|
35
|
+
Step 4: [v2] [v2] [v2] [v2] [v1] ← Deploy to instance 4, verify health
|
|
36
|
+
Step 5: [v2] [v2] [v2] [v2] [v2] ← Deploy to instance 5, verify health
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
### Configuration Parameters
|
|
40
|
+
|
|
41
|
+
| Parameter | Description | Typical Value |
|
|
42
|
+
|-----------|-------------|---------------|
|
|
43
|
+
| **Max unavailable** | Maximum instances being replaced simultaneously | 1 or 25% |
|
|
44
|
+
| **Max surge** | Extra instances during deployment | 1 or 25% |
|
|
45
|
+
| **Readiness probe** | Health check before receiving traffic | HTTP 200 on `/ready` |
|
|
46
|
+
| **Min ready seconds** | How long instance must be healthy before proceeding | 30-60 seconds |
|
|
47
|
+
|
|
48
|
+
### Advantages and Limitations
|
|
49
|
+
|
|
50
|
+
| Advantage | Limitation |
|
|
51
|
+
|-----------|-----------|
|
|
52
|
+
| Simple to implement | Both versions run simultaneously (must be compatible) |
|
|
53
|
+
| Gradual rollout | Rollback requires re-deploying old version |
|
|
54
|
+
| No extra infrastructure | Reduced capacity during deployment |
|
|
55
|
+
| Built into Kubernetes | Slow for large clusters |
|
|
56
|
+
|
|
57
|
+
---
|
|
58
|
+
|
|
59
|
+
## Blue-Green Deployment
|
|
60
|
+
|
|
61
|
+
Maintain two identical production environments. One (blue) serves live traffic. Deploy to the other (green), verify, and switch the router.
|
|
62
|
+
|
|
63
|
+
### How It Works
|
|
64
|
+
|
|
65
|
+
```
|
|
66
|
+
┌──────────────┐
|
|
67
|
+
Users → Router ────→│ Blue (v1) │ ← Currently live
|
|
68
|
+
└──────────────┘
|
|
69
|
+
┌──────────────┐
|
|
70
|
+
│ Green (v2) │ ← Deploy here, test
|
|
71
|
+
└──────────────┘
|
|
72
|
+
|
|
73
|
+
After verification:
|
|
74
|
+
|
|
75
|
+
┌──────────────┐
|
|
76
|
+
│ Blue (v1) │ ← Standby (instant rollback)
|
|
77
|
+
└──────────────┘
|
|
78
|
+
┌──────────────┐
|
|
79
|
+
Users → Router ────→│ Green (v2) │ ← Now live
|
|
80
|
+
└──────────────┘
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
### Implementation Steps
|
|
84
|
+
|
|
85
|
+
1. Deploy new version to green environment
|
|
86
|
+
2. Run automated smoke tests against green
|
|
87
|
+
3. Optionally, route internal/test traffic to green for manual verification
|
|
88
|
+
4. Switch the router (load balancer, DNS, or service mesh) to green
|
|
89
|
+
5. Monitor for errors -- if problems arise, switch back to blue immediately
|
|
90
|
+
6. Keep blue running as the rollback target until the next deployment
|
|
91
|
+
|
|
92
|
+
### Advantages and Limitations
|
|
93
|
+
|
|
94
|
+
| Advantage | Limitation |
|
|
95
|
+
|-----------|-----------|
|
|
96
|
+
| Instant rollback (switch router back) | Requires double the infrastructure |
|
|
97
|
+
| Full testing in production-like environment | Database changes must be compatible with both versions |
|
|
98
|
+
| Zero capacity reduction during deployment | Stateful applications need careful session handling |
|
|
99
|
+
| Clear separation of deploy and release | Cost of maintaining two full environments |
|
|
100
|
+
|
|
101
|
+
---
|
|
102
|
+
|
|
103
|
+
## Canary Releases
|
|
104
|
+
|
|
105
|
+
Route a small percentage of production traffic to the new version. Monitor for errors. Gradually increase the percentage if healthy.
|
|
106
|
+
|
|
107
|
+
### How It Works
|
|
108
|
+
|
|
109
|
+
```
|
|
110
|
+
Phase 1: 5% → canary (v2), 95% → stable (v1)
|
|
111
|
+
Phase 2: 25% → canary (v2), 75% → stable (v1)
|
|
112
|
+
Phase 3: 50% → canary (v2), 50% → stable (v1)
|
|
113
|
+
Phase 4: 100% → canary (v2), 0% → stable (v1)
|
|
114
|
+
```
|
|
115
|
+
|
|
116
|
+
### Canary Evaluation Criteria
|
|
117
|
+
|
|
118
|
+
At each phase, evaluate before proceeding:
|
|
119
|
+
|
|
120
|
+
| Metric | Threshold | Action if Exceeded |
|
|
121
|
+
|--------|-----------|-------------------|
|
|
122
|
+
| **Error rate** | > 1% above baseline | Automatic rollback |
|
|
123
|
+
| **p99 latency** | > 2x baseline | Pause and investigate |
|
|
124
|
+
| **CPU usage** | > 80% sustained | Pause and investigate |
|
|
125
|
+
| **Memory usage** | Growing trend (potential leak) | Rollback |
|
|
126
|
+
| **Business metrics** | Conversion rate drops > 5% | Rollback |
|
|
127
|
+
|
|
128
|
+
### Automated Canary Analysis
|
|
129
|
+
|
|
130
|
+
Progressive delivery tools can automate canary evaluation:
|
|
131
|
+
|
|
132
|
+
1. Deploy canary with 5% traffic
|
|
133
|
+
2. Collect metrics for evaluation window (10-30 minutes)
|
|
134
|
+
3. Compare canary metrics against baseline (stable version) using statistical analysis
|
|
135
|
+
4. If pass: increase traffic percentage and repeat
|
|
136
|
+
5. If fail: automatic rollback and alert the team
|
|
137
|
+
|
|
138
|
+
### Canary vs. Blue-Green
|
|
139
|
+
|
|
140
|
+
| Aspect | Canary | Blue-Green |
|
|
141
|
+
|--------|--------|-----------|
|
|
142
|
+
| **Risk exposure** | Minimal (small % of traffic) | All-or-nothing switch |
|
|
143
|
+
| **Rollback speed** | Instant (route away from canary) | Instant (switch router) |
|
|
144
|
+
| **Infrastructure cost** | Minimal extra (small canary fleet) | Double infrastructure |
|
|
145
|
+
| **Verification depth** | Real user traffic at scale | Synthetic tests + internal traffic |
|
|
146
|
+
| **Complexity** | Higher (traffic splitting, metric comparison) | Lower (router switch) |
|
|
147
|
+
|
|
148
|
+
---
|
|
149
|
+
|
|
150
|
+
## Feature Flags
|
|
151
|
+
|
|
152
|
+
Feature flags (also called feature toggles) decouple deployment from release. Code is deployed but not activated until the flag is enabled.
|
|
153
|
+
|
|
154
|
+
### Types of Feature Flags
|
|
155
|
+
|
|
156
|
+
| Type | Lifetime | Purpose | Example |
|
|
157
|
+
|------|----------|---------|---------|
|
|
158
|
+
| **Release flag** | Days to weeks | Gate incomplete or untested features | `new_checkout_flow` |
|
|
159
|
+
| **Experiment flag** | Weeks to months | A/B testing and gradual rollout | `show_recommendations_v2` |
|
|
160
|
+
| **Ops flag** | Permanent | Runtime control over system behavior | `enable_expensive_query_cache` |
|
|
161
|
+
| **Kill switch** | Permanent | Disable features during incidents | `disable_search_suggestions` |
|
|
162
|
+
|
|
163
|
+
### Feature Flag Best Practices
|
|
164
|
+
|
|
165
|
+
**Do:**
|
|
166
|
+
- Use a centralized flag management system (not config files or environment variables)
|
|
167
|
+
- Set a default value for every flag (what happens if the flag service is down?)
|
|
168
|
+
- Clean up release flags after full rollout (flag debt is real technical debt)
|
|
169
|
+
- Log flag evaluations for debugging ("User X saw feature Y because flag Z was true")
|
|
170
|
+
- Test both flag states in your test suite
|
|
171
|
+
|
|
172
|
+
**Do not:**
|
|
173
|
+
- Use feature flags for long-lived branching (creates combinatorial testing nightmare)
|
|
174
|
+
- Nest feature flags (flag A enables feature which checks flag B -- unmaintainable)
|
|
175
|
+
- Deploy code that only works with the flag enabled (always support both states)
|
|
176
|
+
- Forget to remove old flags (accumulation makes the code unreadable)
|
|
177
|
+
|
|
178
|
+
### Feature Flag and Deployment Pipeline
|
|
179
|
+
|
|
180
|
+
```
|
|
181
|
+
1. Developer merges code with feature flag (default: off)
|
|
182
|
+
2. Code deploys to production (flag off -- no user impact)
|
|
183
|
+
3. QA enables flag for internal users and tests
|
|
184
|
+
4. Product enables flag for 5% of users (canary)
|
|
185
|
+
5. Monitor metrics for 24-48 hours
|
|
186
|
+
6. Ramp to 25%, 50%, 100% with monitoring at each stage
|
|
187
|
+
7. When 100% and stable, remove the flag and the old code path
|
|
188
|
+
```
|
|
189
|
+
|
|
190
|
+
---
|
|
191
|
+
|
|
192
|
+
## Database Migrations Without Downtime
|
|
193
|
+
|
|
194
|
+
Database schema changes are the most dangerous part of deployment because they are difficult to roll back and must be compatible with both old and new application code during the deployment window.
|
|
195
|
+
|
|
196
|
+
### The Expand-Contract Pattern
|
|
197
|
+
|
|
198
|
+
Never make a breaking schema change in a single step. Instead, expand (add), migrate data, then contract (remove).
|
|
199
|
+
|
|
200
|
+
### Example: Renaming a Column
|
|
201
|
+
|
|
202
|
+
**Wrong (causes downtime):**
|
|
203
|
+
```sql
|
|
204
|
+
ALTER TABLE users RENAME COLUMN name TO full_name;
|
|
205
|
+
-- Old code looking for "name" column fails immediately
|
|
206
|
+
```
|
|
207
|
+
|
|
208
|
+
**Right (zero-downtime expand-contract):**
|
|
209
|
+
|
|
210
|
+
| Step | Migration | Application Code |
|
|
211
|
+
|------|-----------|-----------------|
|
|
212
|
+
| 1. Expand | `ALTER TABLE users ADD COLUMN full_name VARCHAR(255);` | Writes to both `name` and `full_name` |
|
|
213
|
+
| 2. Backfill | `UPDATE users SET full_name = name WHERE full_name IS NULL;` | Reads from `full_name`, falls back to `name` |
|
|
214
|
+
| 3. Switch | No schema change | Reads and writes only `full_name` |
|
|
215
|
+
| 4. Contract | `ALTER TABLE users DROP COLUMN name;` | Only uses `full_name` |
|
|
216
|
+
|
|
217
|
+
Each step is a separate deployment. Each step is individually rollback-safe.
|
|
218
|
+
|
|
219
|
+
### Example: Adding a NOT NULL Column
|
|
220
|
+
|
|
221
|
+
**Wrong (locks table, breaks old code):**
|
|
222
|
+
```sql
|
|
223
|
+
ALTER TABLE orders ADD COLUMN status VARCHAR(20) NOT NULL DEFAULT 'pending';
|
|
224
|
+
-- On large tables, this locks the table for minutes/hours
|
|
225
|
+
```
|
|
226
|
+
|
|
227
|
+
**Right (phased approach):**
|
|
228
|
+
|
|
229
|
+
| Step | Action |
|
|
230
|
+
|------|--------|
|
|
231
|
+
| 1 | Add column as nullable: `ALTER TABLE orders ADD COLUMN status VARCHAR(20);` |
|
|
232
|
+
| 2 | Deploy code that writes `status` on all new rows |
|
|
233
|
+
| 3 | Backfill existing rows: `UPDATE orders SET status = 'pending' WHERE status IS NULL;` (in batches) |
|
|
234
|
+
| 4 | Add NOT NULL constraint: `ALTER TABLE orders ALTER COLUMN status SET NOT NULL;` |
|
|
235
|
+
|
|
236
|
+
### Migration Safety Checklist
|
|
237
|
+
|
|
238
|
+
- [ ] Can the old code work with the new schema?
|
|
239
|
+
- [ ] Can the new code work with the old schema (for rollback)?
|
|
240
|
+
- [ ] Are large data migrations batched (not one giant UPDATE)?
|
|
241
|
+
- [ ] Is the migration tested against production-volume data?
|
|
242
|
+
- [ ] Is the migration reversible?
|
|
243
|
+
- [ ] Are table locks avoided (no ALTER TABLE on large tables without online DDL)?
|
|
244
|
+
|
|
245
|
+
---
|
|
246
|
+
|
|
247
|
+
## Immutable Infrastructure
|
|
248
|
+
|
|
249
|
+
Never patch, update, or modify a running server. Instead, build a new image with the changes, deploy it, and destroy the old one.
|
|
250
|
+
|
|
251
|
+
### Why Immutable
|
|
252
|
+
|
|
253
|
+
| Mutable Infrastructure | Immutable Infrastructure |
|
|
254
|
+
|----------------------|-------------------------|
|
|
255
|
+
| SSH into servers, apply patches | Build new image with patches baked in |
|
|
256
|
+
| Configuration drift over time | Every instance is identical |
|
|
257
|
+
| "Snowflake" servers that are irreplaceable | Instances are disposable and replaceable |
|
|
258
|
+
| "It works on that server" debugging | Consistent behavior across all instances |
|
|
259
|
+
| Manual changes accumulate and are undocumented | All changes are in version control |
|
|
260
|
+
|
|
261
|
+
### Immutable Infrastructure Pipeline
|
|
262
|
+
|
|
263
|
+
```
|
|
264
|
+
1. Code change committed to version control
|
|
265
|
+
2. CI builds application artifact (binary, JAR, bundle)
|
|
266
|
+
3. CI builds infrastructure image (Docker image, AMI, VM image)
|
|
267
|
+
4. Image is tagged with version and stored in registry
|
|
268
|
+
5. Deployment tool replaces old instances with new image
|
|
269
|
+
6. Old instances are terminated (not modified, not reused)
|
|
270
|
+
```
|
|
271
|
+
|
|
272
|
+
### Implementation Patterns
|
|
273
|
+
|
|
274
|
+
| Pattern | Technology | Use Case |
|
|
275
|
+
|---------|-----------|----------|
|
|
276
|
+
| **Container images** | Docker, OCI | Microservices, cloud-native applications |
|
|
277
|
+
| **Machine images** | AMI, GCE image | VM-based workloads |
|
|
278
|
+
| **Serverless packages** | Lambda ZIP, Cloud Function | Event-driven workloads |
|
|
279
|
+
| **Helm charts** | Kubernetes + Helm | Kubernetes-native applications |
|
|
280
|
+
|
|
281
|
+
---
|
|
282
|
+
|
|
283
|
+
## Infrastructure as Code
|
|
284
|
+
|
|
285
|
+
All infrastructure -- servers, networks, databases, load balancers, DNS entries -- is defined in version-controlled code, not manually configured through web consoles or SSH sessions.
|
|
286
|
+
|
|
287
|
+
### Principles
|
|
288
|
+
|
|
289
|
+
| Principle | Practice |
|
|
290
|
+
|-----------|----------|
|
|
291
|
+
| **Everything in code** | No manual changes; all config in Terraform, CloudFormation, Pulumi, or similar |
|
|
292
|
+
| **Version controlled** | Infrastructure code lives in git alongside application code |
|
|
293
|
+
| **Reviewed** | Infrastructure changes go through code review like application changes |
|
|
294
|
+
| **Tested** | Infrastructure changes are validated in staging before production |
|
|
295
|
+
| **Reproducible** | Any environment can be recreated from code in minutes |
|
|
296
|
+
| **Idempotent** | Applying the same code twice produces the same result |
|
|
297
|
+
|
|
298
|
+
### Anti-Patterns
|
|
299
|
+
|
|
300
|
+
| Anti-Pattern | Problem | Fix |
|
|
301
|
+
|-------------|---------|-----|
|
|
302
|
+
| **ClickOps** | Changes made through web console are undocumented and unreproducible | Define all infrastructure in code |
|
|
303
|
+
| **SSH and modify** | Manual changes create drift between instances | Use immutable infrastructure |
|
|
304
|
+
| **Shared credentials** | No audit trail of who changed what | Individual credentials with role-based access |
|
|
305
|
+
| **No staging** | Infrastructure changes tested directly in production | Maintain a staging environment that mirrors production topology |
|
|
306
|
+
| **Monolithic templates** | One giant infrastructure file that is impossible to review | Modularize infrastructure into composable components |
|
|
307
|
+
|
|
308
|
+
---
|
|
309
|
+
|
|
310
|
+
## Rollback Strategy
|
|
311
|
+
|
|
312
|
+
Rollback must be faster and simpler than rolling forward. If rolling back takes 30 minutes of manual steps, teams will hesitate to deploy -- and when they do deploy, they will hesitate to roll back when things go wrong.
|
|
313
|
+
|
|
314
|
+
### Rollback Approaches
|
|
315
|
+
|
|
316
|
+
| Approach | Speed | Complexity | Limitation |
|
|
317
|
+
|----------|-------|-----------|-----------|
|
|
318
|
+
| **Traffic switch** (blue-green) | Seconds | Low | Requires both versions running |
|
|
319
|
+
| **Revert canary** | Seconds | Low | Only for canary percentage |
|
|
320
|
+
| **Redeploy previous version** | Minutes | Medium | Requires previous artifact available |
|
|
321
|
+
| **Feature flag disable** | Seconds | Low | Only for flag-gated features |
|
|
322
|
+
| **Database rollback** | Minutes to hours | High | May require data migration reversal |
|
|
323
|
+
|
|
324
|
+
### Rollback Checklist
|
|
325
|
+
|
|
326
|
+
- [ ] Is the previous version's artifact still available in the registry?
|
|
327
|
+
- [ ] Can the previous version work with the current database schema?
|
|
328
|
+
- [ ] Are feature flags in a state that supports rollback?
|
|
329
|
+
- [ ] Has the rollback procedure been tested (not just documented)?
|
|
330
|
+
- [ ] Can rollback be executed by the on-call engineer without escalation?
|
|
331
|
+
- [ ] Is the rollback time under 5 minutes?
|
|
@@ -0,0 +1,301 @@
|
|
|
1
|
+
# Observability
|
|
2
|
+
|
|
3
|
+
You cannot operate what you cannot observe. Observability is the ability to understand the internal state of a system by examining its external outputs. It is not an afterthought or a nice-to-have -- it is a first-class design concern that must be built into every service from day one.
|
|
4
|
+
|
|
5
|
+
A well-observed system lets you answer questions you did not anticipate at design time. A poorly observed system forces you to deploy new instrumentation during an outage -- exactly when you can least afford the risk.
|
|
6
|
+
|
|
7
|
+
## The Three Pillars of Observability
|
|
8
|
+
|
|
9
|
+
### 1. Structured Logs
|
|
10
|
+
|
|
11
|
+
Logs answer the question: "What happened?"
|
|
12
|
+
|
|
13
|
+
**Structured logging** means emitting logs as key-value pairs (JSON), not free-form text. Structured logs are searchable, filterable, and aggregatable. Free-form text logs require regex parsing and break when the format changes.
|
|
14
|
+
|
|
15
|
+
**Essential log fields:**
|
|
16
|
+
|
|
17
|
+
| Field | Purpose | Example |
|
|
18
|
+
|-------|---------|---------|
|
|
19
|
+
| `timestamp` | When the event occurred | `2024-01-15T14:23:45.123Z` |
|
|
20
|
+
| `level` | Severity (DEBUG, INFO, WARN, ERROR) | `ERROR` |
|
|
21
|
+
| `service` | Which service emitted the log | `payment-service` |
|
|
22
|
+
| `trace_id` | Correlation ID across services | `abc123def456` |
|
|
23
|
+
| `span_id` | Specific operation within the trace | `span789` |
|
|
24
|
+
| `user_id` | Which user was affected (if applicable) | `user_42` |
|
|
25
|
+
| `message` | Human-readable description | `Payment processing failed` |
|
|
26
|
+
| `error` | Error type and stack trace | `TimeoutException: read timed out` |
|
|
27
|
+
| `duration_ms` | How long the operation took | `5230` |
|
|
28
|
+
| `request_id` | Unique identifier for the request | `req_abc123` |
|
|
29
|
+
|
|
30
|
+
**Logging best practices:**
|
|
31
|
+
- Log at service boundaries (incoming request, outgoing call, response)
|
|
32
|
+
- Include enough context to understand the event without reading code
|
|
33
|
+
- Use consistent field names across all services
|
|
34
|
+
- Do not log sensitive data (passwords, tokens, PII) -- use redaction
|
|
35
|
+
- Log errors with full context, not just the exception message
|
|
36
|
+
- Use sampling for high-volume debug logs in production
|
|
37
|
+
- Emit logs asynchronously to avoid blocking application threads
|
|
38
|
+
|
|
39
|
+
### 2. Metrics
|
|
40
|
+
|
|
41
|
+
Metrics answer the question: "How much?"
|
|
42
|
+
|
|
43
|
+
Metrics are numeric measurements collected over time. They are cheap to store, fast to query, and essential for dashboards and alerts.
|
|
44
|
+
|
|
45
|
+
**Metric types:**
|
|
46
|
+
|
|
47
|
+
| Type | What It Measures | Example |
|
|
48
|
+
|------|-----------------|---------|
|
|
49
|
+
| **Counter** | Cumulative count of events | `http_requests_total`, `errors_total` |
|
|
50
|
+
| **Gauge** | Current value that can go up or down | `active_connections`, `queue_depth`, `cpu_usage` |
|
|
51
|
+
| **Histogram** | Distribution of values | `request_duration_seconds` (with buckets for p50, p95, p99) |
|
|
52
|
+
| **Summary** | Pre-calculated percentiles | `request_duration_seconds{quantile="0.99"}` |
|
|
53
|
+
|
|
54
|
+
**Metric naming conventions:**
|
|
55
|
+
- Use snake_case: `http_request_duration_seconds`
|
|
56
|
+
- Include the unit in the name: `_seconds`, `_bytes`, `_total`
|
|
57
|
+
- Use labels for dimensions: `http_requests_total{method="GET", status="200", endpoint="/api/users"}`
|
|
58
|
+
- Do not use high-cardinality labels (user IDs, request IDs) -- these explode metric storage
|
|
59
|
+
|
|
60
|
+
### 3. Distributed Traces
|
|
61
|
+
|
|
62
|
+
Traces answer the question: "Where did the time go?"
|
|
63
|
+
|
|
64
|
+
A distributed trace follows a single request across multiple services, showing the sequence of operations, their durations, and their relationships.
|
|
65
|
+
|
|
66
|
+
**Trace anatomy:**
|
|
67
|
+
|
|
68
|
+
```
|
|
69
|
+
Trace: user request to checkout
|
|
70
|
+
├── Span: API Gateway (2ms)
|
|
71
|
+
│ ├── Span: Auth Service - validate token (15ms)
|
|
72
|
+
│ ├── Span: Cart Service - get cart (45ms)
|
|
73
|
+
│ │ └── Span: Database - SELECT cart items (12ms)
|
|
74
|
+
│ ├── Span: Inventory Service - check stock (120ms) ← Bottleneck
|
|
75
|
+
│ │ └── Span: Database - SELECT inventory (95ms)
|
|
76
|
+
│ └── Span: Payment Service - charge card (230ms)
|
|
77
|
+
│ └── Span: Stripe API - create charge (180ms)
|
|
78
|
+
Total: 412ms
|
|
79
|
+
```
|
|
80
|
+
|
|
81
|
+
**Trace implementation:**
|
|
82
|
+
- Inject trace context (trace ID, span ID) into all outgoing requests (HTTP headers, message metadata)
|
|
83
|
+
- Extract trace context from all incoming requests
|
|
84
|
+
- Create a new span for each significant operation (service call, database query, cache lookup)
|
|
85
|
+
- Annotate spans with relevant metadata (query, parameters, result count)
|
|
86
|
+
- Use sampling in production (1-10% of requests) to manage cost and volume
|
|
87
|
+
- Always trace errors at 100% (do not sample error traces)
|
|
88
|
+
|
|
89
|
+
---
|
|
90
|
+
|
|
91
|
+
## Health Check Patterns
|
|
92
|
+
|
|
93
|
+
Health checks tell load balancers, orchestrators, and monitoring systems whether an instance is able to serve traffic.
|
|
94
|
+
|
|
95
|
+
### Shallow Health Check
|
|
96
|
+
|
|
97
|
+
A shallow health check verifies that the process is running and can respond to HTTP requests. It does not verify dependencies.
|
|
98
|
+
|
|
99
|
+
```
|
|
100
|
+
GET /health
|
|
101
|
+
200 OK {"status": "up"}
|
|
102
|
+
```
|
|
103
|
+
|
|
104
|
+
**Use for:** Liveness probes (is the process alive?). If this fails, the orchestrator should restart the process.
|
|
105
|
+
|
|
106
|
+
### Deep Health Check
|
|
107
|
+
|
|
108
|
+
A deep health check verifies that the instance can actually serve requests by checking connectivity to all critical dependencies.
|
|
109
|
+
|
|
110
|
+
```
|
|
111
|
+
GET /health/ready
|
|
112
|
+
200 OK {
|
|
113
|
+
"status": "ready",
|
|
114
|
+
"checks": {
|
|
115
|
+
"database": {"status": "up", "latency_ms": 3},
|
|
116
|
+
"cache": {"status": "up", "latency_ms": 1},
|
|
117
|
+
"queue": {"status": "up", "latency_ms": 5},
|
|
118
|
+
"disk": {"status": "up", "free_gb": 42}
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
503 Service Unavailable {
|
|
123
|
+
"status": "not_ready",
|
|
124
|
+
"checks": {
|
|
125
|
+
"database": {"status": "down", "error": "connection refused"},
|
|
126
|
+
"cache": {"status": "up", "latency_ms": 1},
|
|
127
|
+
"queue": {"status": "up", "latency_ms": 5},
|
|
128
|
+
"disk": {"status": "up", "free_gb": 42}
|
|
129
|
+
}
|
|
130
|
+
}
|
|
131
|
+
```
|
|
132
|
+
|
|
133
|
+
**Use for:** Readiness probes (can this instance serve traffic?). If this fails, the load balancer should stop routing traffic to this instance -- but should not restart it (the problem might be a downstream dependency, not this process).
|
|
134
|
+
|
|
135
|
+
### Health Check Design Rules
|
|
136
|
+
|
|
137
|
+
| Rule | Rationale |
|
|
138
|
+
|------|-----------|
|
|
139
|
+
| **Shallow checks should be fast (<100ms)** | Frequent liveness checks should not consume significant resources |
|
|
140
|
+
| **Deep checks should have their own timeout** | A hanging dependency check should not make the health endpoint hang |
|
|
141
|
+
| **Do not cache health check results** | Health checks must reflect current state, not cached state |
|
|
142
|
+
| **Separate liveness from readiness** | A process can be alive but not ready (warming up, dependency down) |
|
|
143
|
+
| **Include version information** | Helps verify deployment status: `"version": "2.3.1", "commit": "abc123"` |
|
|
144
|
+
| **Rate-limit deep checks** | Running deep checks every second can stress dependencies |
|
|
145
|
+
|
|
146
|
+
---
|
|
147
|
+
|
|
148
|
+
## The RED Method
|
|
149
|
+
|
|
150
|
+
The RED method is a monitoring framework for request-driven services (APIs, web applications).
|
|
151
|
+
|
|
152
|
+
### RED Metrics
|
|
153
|
+
|
|
154
|
+
| Metric | What It Measures | Why It Matters |
|
|
155
|
+
|--------|-----------------|---------------|
|
|
156
|
+
| **Rate** | Requests per second | Is traffic normal? Dropping? Spiking? |
|
|
157
|
+
| **Errors** | Error rate (errors / total requests) | Are users experiencing failures? |
|
|
158
|
+
| **Duration** | Latency distribution (p50, p95, p99) | Are users experiencing slowness? |
|
|
159
|
+
|
|
160
|
+
### Implementation
|
|
161
|
+
|
|
162
|
+
For every service endpoint, instrument:
|
|
163
|
+
|
|
164
|
+
```
|
|
165
|
+
# Rate
|
|
166
|
+
http_requests_total{service, method, endpoint, status}
|
|
167
|
+
|
|
168
|
+
# Errors
|
|
169
|
+
http_errors_total{service, method, endpoint, error_type}
|
|
170
|
+
# Error rate = http_errors_total / http_requests_total
|
|
171
|
+
|
|
172
|
+
# Duration
|
|
173
|
+
http_request_duration_seconds{service, method, endpoint}
|
|
174
|
+
# Report as histogram with p50, p95, p99 percentiles
|
|
175
|
+
```
|
|
176
|
+
|
|
177
|
+
### RED Dashboard
|
|
178
|
+
|
|
179
|
+
A RED dashboard for each service should answer three questions at a glance:
|
|
180
|
+
1. **Is traffic arriving?** (Rate graph -- sudden drops indicate upstream problems or DNS issues)
|
|
181
|
+
2. **Are requests succeeding?** (Error rate graph -- spikes indicate bugs or dependency failures)
|
|
182
|
+
3. **Are requests fast?** (Duration graph -- p99 latency increasing indicates saturation)
|
|
183
|
+
|
|
184
|
+
---
|
|
185
|
+
|
|
186
|
+
## The USE Method
|
|
187
|
+
|
|
188
|
+
The USE method is a monitoring framework for infrastructure resources (CPU, memory, disk, network).
|
|
189
|
+
|
|
190
|
+
### USE Metrics
|
|
191
|
+
|
|
192
|
+
| Metric | What It Measures | Why It Matters |
|
|
193
|
+
|--------|-----------------|---------------|
|
|
194
|
+
| **Utilization** | Percentage of resource currently in use | High utilization means approaching capacity |
|
|
195
|
+
| **Saturation** | Amount of work waiting (queue depth) | Saturation means demand exceeds capacity |
|
|
196
|
+
| **Errors** | Count of error events for this resource | Hardware errors, packet drops, OOM kills |
|
|
197
|
+
|
|
198
|
+
### USE by Resource
|
|
199
|
+
|
|
200
|
+
| Resource | Utilization | Saturation | Errors |
|
|
201
|
+
|----------|------------|------------|--------|
|
|
202
|
+
| **CPU** | % time busy | Run queue length | Machine check exceptions |
|
|
203
|
+
| **Memory** | % used | Swap usage, OOM events | ECC errors, OOM kills |
|
|
204
|
+
| **Disk** | % capacity used, IOPS utilization | I/O queue depth | Read/write errors |
|
|
205
|
+
| **Network** | Bandwidth utilization | TCP retransmit queue, dropped packets | Interface errors, CRC errors |
|
|
206
|
+
| **Thread pool** | Active threads / max threads | Queued tasks | Rejected tasks |
|
|
207
|
+
| **Connection pool** | Active connections / max connections | Wait count | Timeout errors |
|
|
208
|
+
|
|
209
|
+
---
|
|
210
|
+
|
|
211
|
+
## SLIs, SLOs, and SLAs
|
|
212
|
+
|
|
213
|
+
### Definitions
|
|
214
|
+
|
|
215
|
+
| Term | Definition | Example |
|
|
216
|
+
|------|-----------|---------|
|
|
217
|
+
| **SLI** (Service Level Indicator) | A quantitative measure of a specific aspect of service quality | 99.2% of requests complete in < 200ms |
|
|
218
|
+
| **SLO** (Service Level Objective) | A target value for an SLI | 99.5% of requests should complete in < 200ms |
|
|
219
|
+
| **SLA** (Service Level Agreement) | A contractual commitment with consequences for violation | 99.9% availability; credit issued if breached |
|
|
220
|
+
|
|
221
|
+
### Choosing SLIs
|
|
222
|
+
|
|
223
|
+
Good SLIs measure what users actually experience:
|
|
224
|
+
|
|
225
|
+
| SLI Type | What It Measures | Measurement Point |
|
|
226
|
+
|----------|-----------------|-------------------|
|
|
227
|
+
| **Availability** | Proportion of successful requests | Load balancer or edge proxy |
|
|
228
|
+
| **Latency** | Proportion of requests faster than threshold | Application instrumentation |
|
|
229
|
+
| **Correctness** | Proportion of requests returning correct results | End-to-end tests or data validation |
|
|
230
|
+
| **Freshness** | Proportion of data updated within threshold | Data pipeline monitoring |
|
|
231
|
+
|
|
232
|
+
### Error Budget
|
|
233
|
+
|
|
234
|
+
The error budget is the allowed amount of unreliability: `error_budget = 1 - SLO`.
|
|
235
|
+
|
|
236
|
+
For a 99.9% availability SLO:
|
|
237
|
+
- Error budget = 0.1% = 43.8 minutes/month of downtime
|
|
238
|
+
- If you have consumed 30 minutes of budget, you have 13.8 minutes remaining
|
|
239
|
+
- If the budget is exhausted, freeze deployments and focus on reliability
|
|
240
|
+
|
|
241
|
+
**Error budget policy:**
|
|
242
|
+
- Budget remaining > 50%: deploy freely, run experiments
|
|
243
|
+
- Budget remaining 20-50%: deploy with caution, increase monitoring
|
|
244
|
+
- Budget remaining < 20%: freeze non-critical deploys, prioritize reliability work
|
|
245
|
+
- Budget exhausted: halt all feature deploys until budget replenishes
|
|
246
|
+
|
|
247
|
+
---
|
|
248
|
+
|
|
249
|
+
## Alerting Strategy
|
|
250
|
+
|
|
251
|
+
### Alert on Symptoms, Not Causes
|
|
252
|
+
|
|
253
|
+
| Cause-Based Alert (Avoid) | Symptom-Based Alert (Prefer) |
|
|
254
|
+
|--------------------------|------------------------------|
|
|
255
|
+
| CPU > 80% | p99 latency > 500ms |
|
|
256
|
+
| Memory > 90% | Error rate > 1% |
|
|
257
|
+
| Disk > 85% | Availability < 99.9% |
|
|
258
|
+
| Queue depth > 1000 | User-facing errors increasing |
|
|
259
|
+
|
|
260
|
+
Cause-based alerts generate noise. CPU can be at 90% and users are fine. CPU can be at 50% and users are seeing errors because of a deadlock.
|
|
261
|
+
|
|
262
|
+
### Alert Severity Levels
|
|
263
|
+
|
|
264
|
+
| Level | Criteria | Response | Example |
|
|
265
|
+
|-------|----------|----------|---------|
|
|
266
|
+
| **Critical** | Users actively impacted; error budget burning fast | Page on-call immediately | Error rate > 5% for 5 minutes |
|
|
267
|
+
| **Warning** | Approaching threshold; action needed soon | Notify team during business hours | Error budget burn rate 2x normal |
|
|
268
|
+
| **Info** | Notable but not actionable | Log and dashboard only | Deployment completed; circuit breaker tripped and recovered |
|
|
269
|
+
|
|
270
|
+
### Alerting Anti-Patterns
|
|
271
|
+
|
|
272
|
+
| Anti-Pattern | Problem | Fix |
|
|
273
|
+
|-------------|---------|-----|
|
|
274
|
+
| **Alert on every metric** | Alert fatigue; team ignores pages | Only alert on user-facing symptoms |
|
|
275
|
+
| **No alert grouping** | 50 alerts fire for one incident | Group related alerts; alert on the root symptom |
|
|
276
|
+
| **No runbook** | On-call does not know what to do | Every alert links to a runbook with diagnostic steps |
|
|
277
|
+
| **Stale alerts** | Alerts for services that no longer exist | Review and prune alerts quarterly |
|
|
278
|
+
| **Missing alerts** | Critical failures go unnoticed | Regularly audit: "If X fails, would we know?" |
|
|
279
|
+
|
|
280
|
+
---
|
|
281
|
+
|
|
282
|
+
## Dashboards That Matter
|
|
283
|
+
|
|
284
|
+
A dashboard should answer "Is the system healthy right now?" within 5 seconds of looking at it.
|
|
285
|
+
|
|
286
|
+
### Dashboard Hierarchy
|
|
287
|
+
|
|
288
|
+
| Level | Audience | Content |
|
|
289
|
+
|-------|----------|---------|
|
|
290
|
+
| **Executive** | Leadership | SLO status (green/red), error budget remaining, incident count |
|
|
291
|
+
| **Service overview** | On-call engineer | RED metrics per service, dependency status |
|
|
292
|
+
| **Service deep-dive** | Service owner | Detailed metrics, resource utilization, deployment markers |
|
|
293
|
+
| **Debug** | Investigating engineer | Traces, log queries, specific metric breakdowns |
|
|
294
|
+
|
|
295
|
+
### Dashboard Design Rules
|
|
296
|
+
|
|
297
|
+
- **USE traffic lights:** Green (healthy), yellow (degraded), red (critical) at the top of every dashboard
|
|
298
|
+
- **Show trends, not just current values:** A metric at 70% is fine if it has been at 70% for a week; it is alarming if it was at 30% an hour ago
|
|
299
|
+
- **Mark deployments:** Overlay deployment events on metric graphs to correlate changes with behavior
|
|
300
|
+
- **Time range matters:** Default to 6 hours for operational dashboards; allow quick switching to 1h, 24h, 7d
|
|
301
|
+
- **Less is more:** A dashboard with 50 graphs is useless; a dashboard with 4 graphs that answer the right questions is invaluable
|