@cubis/foundry 0.3.70 → 0.3.72
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 +15 -0
- package/dist/cli/core.js +4 -18
- package/dist/cli/core.js.map +1 -1
- package/package.json +1 -1
- package/src/cli/core.ts +4 -18
- package/workflows/powers/accessibility/POWER.md +83 -94
- package/workflows/powers/accessibility/SKILL.md +82 -94
- package/workflows/powers/agent-design/POWER.md +201 -0
- package/workflows/powers/agent-design/SKILL.md +198 -0
- package/workflows/powers/agent-design/references/clarification-patterns.md +153 -0
- package/workflows/powers/agent-design/references/skill-testing.md +164 -0
- package/workflows/powers/agent-design/references/workflow-patterns.md +226 -0
- package/workflows/powers/agentic-eval/POWER.md +62 -0
- package/workflows/powers/agentic-eval/SKILL.md +59 -0
- package/workflows/powers/agentic-eval/references/rubric-and-regression-checklist.md +11 -0
- package/workflows/powers/api-designer/POWER.md +43 -71
- package/workflows/powers/api-designer/SKILL.md +43 -71
- package/workflows/powers/api-patterns/POWER.md +42 -56
- package/workflows/powers/api-patterns/SKILL.md +42 -57
- package/workflows/powers/architecture-designer/POWER.md +43 -60
- package/workflows/powers/architecture-designer/SKILL.md +43 -60
- package/workflows/powers/ask-questions-if-underspecified/POWER.md +51 -3
- package/workflows/powers/ask-questions-if-underspecified/SKILL.md +51 -3
- package/workflows/powers/auth-architect/POWER.md +69 -0
- package/workflows/powers/auth-architect/SKILL.md +66 -0
- package/workflows/powers/auth-architect/references/session-token-policy-checklist.md +45 -0
- package/workflows/powers/behavioral-modes/POWER.md +100 -9
- package/workflows/powers/behavioral-modes/SKILL.md +100 -9
- package/workflows/powers/c-pro/POWER.md +105 -0
- package/workflows/powers/c-pro/SKILL.md +102 -0
- package/workflows/powers/c-pro/references/build-systems-and-toolchains.md +148 -0
- package/workflows/powers/c-pro/references/common-ub-and-portability.md +166 -0
- package/workflows/powers/c-pro/references/debugging-with-sanitizers.md +205 -0
- package/workflows/powers/c-pro/references/memory-safety-and-build-checklist.md +60 -0
- package/workflows/powers/c-pro/references/posix-and-platform-apis.md +244 -0
- package/workflows/powers/changelog-generator/POWER.md +127 -63
- package/workflows/powers/changelog-generator/SKILL.md +126 -63
- package/workflows/powers/ci-cd-pipelines/POWER.md +156 -0
- package/workflows/powers/ci-cd-pipelines/SKILL.md +153 -0
- package/workflows/powers/ci-cd-pipelines/references/github-actions-patterns.md +160 -0
- package/workflows/powers/ci-cd-pipelines/references/pipeline-security-checklist.md +57 -0
- package/workflows/powers/cli-developer/POWER.md +152 -95
- package/workflows/powers/cli-developer/SKILL.md +152 -95
- package/workflows/powers/cpp-pro/POWER.md +111 -0
- package/workflows/powers/cpp-pro/SKILL.md +108 -0
- package/workflows/powers/cpp-pro/references/concurrency-primitives.md +266 -0
- package/workflows/powers/cpp-pro/references/move-semantics-and-value-types.md +149 -0
- package/workflows/powers/cpp-pro/references/performance-and-profiling.md +191 -0
- package/workflows/powers/cpp-pro/references/raii-and-modern-cpp-checklist.md +87 -0
- package/workflows/powers/cpp-pro/references/template-and-concepts-patterns.md +205 -0
- package/workflows/powers/csharp-pro/POWER.md +47 -22
- package/workflows/powers/csharp-pro/SKILL.md +47 -22
- package/workflows/powers/dart-pro/POWER.md +68 -0
- package/workflows/powers/dart-pro/SKILL.md +65 -0
- package/workflows/powers/dart-pro/references/isolate-and-concurrency.md +180 -0
- package/workflows/powers/dart-pro/references/null-safety-and-async-patterns.md +133 -0
- package/workflows/powers/dart-pro/references/package-structure-and-linting.md +193 -0
- package/workflows/powers/dart-pro/references/sealed-records-patterns.md +173 -0
- package/workflows/powers/dart-pro/references/testing-and-mocking.md +235 -0
- package/workflows/powers/database-design/POWER.md +47 -33
- package/workflows/powers/database-design/SKILL.md +47 -33
- package/workflows/powers/database-optimizer/POWER.md +43 -64
- package/workflows/powers/database-optimizer/SKILL.md +43 -64
- package/workflows/powers/database-skills/POWER.md +59 -93
- package/workflows/powers/database-skills/SKILL.md +59 -93
- package/workflows/powers/debugging-strategies/POWER.md +69 -0
- package/workflows/powers/debugging-strategies/SKILL.md +66 -0
- package/workflows/powers/debugging-strategies/references/reproduce-isolate-verify-checklist.md +42 -0
- package/workflows/powers/deep-research/POWER.md +67 -0
- package/workflows/powers/deep-research/SKILL.md +64 -0
- package/workflows/powers/deep-research/references/multi-round-research-loop.md +80 -0
- package/workflows/powers/design-system-builder/POWER.md +130 -116
- package/workflows/powers/design-system-builder/SKILL.md +130 -116
- package/workflows/powers/devops-engineer/POWER.md +120 -57
- package/workflows/powers/devops-engineer/SKILL.md +120 -57
- package/workflows/powers/docker-kubernetes/POWER.md +94 -0
- package/workflows/powers/docker-kubernetes/SKILL.md +91 -0
- package/workflows/powers/docker-kubernetes/references/dockerfile-optimization-checklist.md +35 -0
- package/workflows/powers/docker-kubernetes/references/kubernetes-deployment-patterns.md +59 -0
- package/workflows/powers/documentation-templates/POWER.md +158 -127
- package/workflows/powers/documentation-templates/SKILL.md +158 -127
- package/workflows/powers/drizzle-expert/POWER.md +66 -0
- package/workflows/powers/drizzle-expert/SKILL.md +63 -0
- package/workflows/powers/drizzle-expert/references/runtime-pairing-matrix.md +16 -0
- package/workflows/powers/drizzle-expert/references/schema-and-migration-playbook.md +18 -0
- package/workflows/powers/error-ux-observability/POWER.md +144 -131
- package/workflows/powers/error-ux-observability/SKILL.md +143 -131
- package/workflows/powers/fastapi-expert/POWER.md +46 -60
- package/workflows/powers/fastapi-expert/SKILL.md +46 -60
- package/workflows/powers/firebase/POWER.md +65 -0
- package/workflows/powers/firebase/SKILL.md +62 -0
- package/workflows/powers/firebase/references/platform-routing.md +16 -0
- package/workflows/powers/firebase/references/rules-and-indexes-checklist.md +11 -0
- package/workflows/powers/flutter-design-system/POWER.md +63 -0
- package/workflows/powers/flutter-design-system/SKILL.md +60 -0
- package/workflows/powers/flutter-design-system/references/shared-widgets.md +29 -0
- package/workflows/powers/flutter-design-system/references/tokens-and-theme.md +34 -0
- package/workflows/powers/flutter-drift/POWER.md +65 -0
- package/workflows/powers/flutter-drift/SKILL.md +62 -0
- package/workflows/powers/flutter-drift/references/migrations.md +22 -0
- package/workflows/powers/flutter-drift/references/query-patterns.md +26 -0
- package/workflows/powers/flutter-feature/POWER.md +65 -0
- package/workflows/powers/flutter-feature/SKILL.md +62 -0
- package/workflows/powers/flutter-feature/references/architecture-rules.md +85 -0
- package/workflows/powers/flutter-feature/references/composite-provider.md +58 -0
- package/workflows/powers/flutter-feature/references/outbox-pattern.md +87 -0
- package/workflows/powers/flutter-feature/references/testing-patterns.md +218 -0
- package/workflows/powers/flutter-go-router/POWER.md +64 -0
- package/workflows/powers/flutter-go-router/SKILL.md +61 -0
- package/workflows/powers/flutter-go-router/references/guards-and-deeplinks.md +20 -0
- package/workflows/powers/flutter-go-router/references/typed-routes.md +27 -0
- package/workflows/powers/flutter-offline-sync/POWER.md +62 -0
- package/workflows/powers/flutter-offline-sync/SKILL.md +59 -0
- package/workflows/powers/flutter-offline-sync/references/outbox-full.md +44 -0
- package/workflows/powers/flutter-repository/POWER.md +64 -0
- package/workflows/powers/flutter-repository/SKILL.md +61 -0
- package/workflows/powers/flutter-repository/references/drift-patterns.md +21 -0
- package/workflows/powers/flutter-repository/references/retrofit-patterns.md +20 -0
- package/workflows/powers/flutter-riverpod/POWER.md +70 -0
- package/workflows/powers/flutter-riverpod/SKILL.md +67 -0
- package/workflows/powers/flutter-riverpod/references/async-and-mutations.md +19 -0
- package/workflows/powers/flutter-riverpod/references/async-lifecycle.md +19 -0
- package/workflows/powers/flutter-riverpod/references/provider-selection.md +20 -0
- package/workflows/powers/flutter-riverpod/references/testing.md +21 -0
- package/workflows/powers/flutter-riverpod/references/version-matrix.md +24 -0
- package/workflows/powers/flutter-state-machine/POWER.md +62 -0
- package/workflows/powers/flutter-state-machine/SKILL.md +59 -0
- package/workflows/powers/flutter-state-machine/references/app-state-contract.md +23 -0
- package/workflows/powers/flutter-state-machine/references/ui-rendering.md +14 -0
- package/workflows/powers/flutter-testing/POWER.md +64 -0
- package/workflows/powers/flutter-testing/SKILL.md +61 -0
- package/workflows/powers/flutter-testing/references/offline-sync-tests.md +16 -0
- package/workflows/powers/flutter-testing/references/test-layers.md +33 -0
- package/workflows/powers/frontend-code-review/POWER.md +137 -0
- package/workflows/powers/frontend-code-review/SKILL.md +134 -0
- package/workflows/powers/frontend-code-review/references/common-antipatterns.md +86 -0
- package/workflows/powers/frontend-code-review/references/performance-budgets.md +56 -0
- package/workflows/powers/frontend-code-review/references/review-checklists.md +47 -0
- package/workflows/powers/frontend-design/POWER.md +163 -362
- package/workflows/powers/frontend-design/SKILL.md +163 -362
- package/workflows/powers/game-development/POWER.md +57 -140
- package/workflows/powers/game-development/SKILL.md +57 -140
- package/workflows/powers/geo-fundamentals/POWER.md +64 -126
- package/workflows/powers/geo-fundamentals/SKILL.md +64 -127
- package/workflows/powers/git-workflow/POWER.md +135 -0
- package/workflows/powers/git-workflow/SKILL.md +132 -0
- package/workflows/powers/git-workflow/references/pr-review-checklist.md +63 -0
- package/workflows/powers/golang-pro/POWER.md +46 -35
- package/workflows/powers/golang-pro/SKILL.md +46 -35
- package/workflows/powers/graphql-architect/POWER.md +44 -62
- package/workflows/powers/graphql-architect/SKILL.md +44 -62
- package/workflows/powers/i18n-localization/POWER.md +118 -103
- package/workflows/powers/i18n-localization/SKILL.md +118 -103
- package/workflows/powers/java-pro/POWER.md +47 -22
- package/workflows/powers/java-pro/SKILL.md +47 -22
- package/workflows/powers/javascript-pro/POWER.md +47 -34
- package/workflows/powers/javascript-pro/SKILL.md +47 -34
- package/workflows/powers/kotlin-pro/POWER.md +46 -23
- package/workflows/powers/kotlin-pro/SKILL.md +46 -23
- package/workflows/powers/legacy-modernizer/POWER.md +43 -60
- package/workflows/powers/legacy-modernizer/SKILL.md +43 -60
- package/workflows/powers/mcp-builder/POWER.md +65 -0
- package/workflows/powers/mcp-builder/SKILL.md +62 -0
- package/workflows/powers/mcp-builder/references/testing-and-evals.md +17 -0
- package/workflows/powers/mcp-builder/references/transport-and-tool-design.md +17 -0
- package/workflows/powers/microservices-architect/POWER.md +43 -70
- package/workflows/powers/microservices-architect/SKILL.md +43 -70
- package/workflows/powers/mobile-design/POWER.md +110 -345
- package/workflows/powers/mobile-design/SKILL.md +110 -345
- package/workflows/powers/mongodb/POWER.md +67 -0
- package/workflows/powers/mongodb/SKILL.md +64 -0
- package/workflows/powers/mongodb/references/mongodb-checklist.md +20 -0
- package/workflows/powers/mysql/POWER.md +67 -0
- package/workflows/powers/mysql/SKILL.md +64 -0
- package/workflows/powers/mysql/references/mysql-checklist.md +20 -0
- package/workflows/powers/neki/POWER.md +67 -0
- package/workflows/powers/neki/SKILL.md +64 -0
- package/workflows/powers/neki/references/neki-checklist.md +18 -0
- package/workflows/powers/nestjs-expert/POWER.md +45 -91
- package/workflows/powers/nestjs-expert/SKILL.md +45 -91
- package/workflows/powers/nextjs-developer/POWER.md +51 -44
- package/workflows/powers/nextjs-developer/SKILL.md +51 -44
- package/workflows/powers/nodejs-best-practices/POWER.md +48 -29
- package/workflows/powers/nodejs-best-practices/SKILL.md +48 -29
- package/workflows/powers/observability/POWER.md +109 -0
- package/workflows/powers/observability/SKILL.md +106 -0
- package/workflows/powers/observability/references/alerting-and-slo-checklist.md +87 -0
- package/workflows/powers/observability/references/opentelemetry-setup-guide.md +121 -0
- package/workflows/powers/openai-docs/POWER.md +61 -0
- package/workflows/powers/openai-docs/SKILL.md +58 -0
- package/workflows/powers/openai-docs/references/official-source-playbook.md +10 -0
- package/workflows/powers/performance-profiling/POWER.md +61 -114
- package/workflows/powers/performance-profiling/SKILL.md +61 -114
- package/workflows/powers/php-pro/POWER.md +116 -0
- package/workflows/powers/php-pro/SKILL.md +113 -0
- package/workflows/powers/php-pro/references/architecture-and-di.md +239 -0
- package/workflows/powers/php-pro/references/modern-php-features.md +189 -0
- package/workflows/powers/php-pro/references/performance-and-deployment.md +197 -0
- package/workflows/powers/php-pro/references/php84-strict-typing-checklist.md +161 -0
- package/workflows/powers/php-pro/references/testing-and-static-analysis.md +235 -0
- package/workflows/powers/playwright-e2e/POWER.md +85 -0
- package/workflows/powers/playwright-e2e/SKILL.md +82 -0
- package/workflows/powers/playwright-e2e/references/locator-trace-flake-checklist.md +80 -0
- package/workflows/powers/postgres/POWER.md +67 -0
- package/workflows/powers/postgres/SKILL.md +64 -0
- package/workflows/powers/postgres/references/postgres-checklist.md +20 -0
- package/workflows/powers/prompt-engineer/POWER.md +47 -30
- package/workflows/powers/prompt-engineer/SKILL.md +47 -30
- package/workflows/powers/python-pro/POWER.md +47 -36
- package/workflows/powers/python-pro/SKILL.md +47 -36
- package/workflows/powers/react-best-practices/POWER.md +56 -33
- package/workflows/powers/react-best-practices/SKILL.md +56 -33
- package/workflows/powers/react-expert/POWER.md +47 -37
- package/workflows/powers/react-expert/SKILL.md +47 -37
- package/workflows/powers/redis/POWER.md +67 -0
- package/workflows/powers/redis/SKILL.md +64 -0
- package/workflows/powers/redis/references/redis-checklist.md +19 -0
- package/workflows/powers/ruby-pro/POWER.md +118 -0
- package/workflows/powers/ruby-pro/SKILL.md +115 -0
- package/workflows/powers/ruby-pro/references/modern-ruby-features.md +189 -0
- package/workflows/powers/ruby-pro/references/object-design-patterns.md +220 -0
- package/workflows/powers/ruby-pro/references/performance-and-profiling.md +224 -0
- package/workflows/powers/ruby-pro/references/ruby-concurrency-and-testing.md +190 -0
- package/workflows/powers/ruby-pro/references/testing-and-rspec.md +236 -0
- package/workflows/powers/rust-pro/POWER.md +45 -31
- package/workflows/powers/rust-pro/SKILL.md +45 -31
- package/workflows/powers/security-engineer/POWER.md +129 -0
- package/workflows/powers/security-engineer/SKILL.md +126 -0
- package/workflows/powers/seo-fundamentals/POWER.md +59 -102
- package/workflows/powers/seo-fundamentals/SKILL.md +59 -102
- package/workflows/powers/serverless-patterns/POWER.md +171 -0
- package/workflows/powers/serverless-patterns/SKILL.md +168 -0
- package/workflows/powers/skill-creator/POWER.md +90 -0
- package/workflows/powers/skill-creator/SKILL.md +87 -0
- package/workflows/powers/skill-creator/references/platform-formats.md +181 -0
- package/workflows/powers/skill-creator/references/schemas.md +430 -0
- package/workflows/powers/spec-miner/POWER.md +49 -57
- package/workflows/powers/spec-miner/SKILL.md +49 -57
- package/workflows/powers/sqlite/POWER.md +67 -0
- package/workflows/powers/sqlite/SKILL.md +64 -0
- package/workflows/powers/sqlite/references/sqlite-checklist.md +19 -0
- package/workflows/powers/sre-engineer/POWER.md +123 -64
- package/workflows/powers/sre-engineer/SKILL.md +123 -64
- package/workflows/powers/static-analysis/POWER.md +121 -77
- package/workflows/powers/static-analysis/SKILL.md +121 -77
- package/workflows/powers/stripe-best-practices/POWER.md +140 -17
- package/workflows/powers/stripe-best-practices/SKILL.md +139 -17
- package/workflows/powers/supabase/POWER.md +67 -0
- package/workflows/powers/supabase/SKILL.md +64 -0
- package/workflows/powers/supabase/references/supabase-checklist.md +19 -0
- package/workflows/powers/swift-pro/POWER.md +118 -0
- package/workflows/powers/swift-pro/SKILL.md +115 -0
- package/workflows/powers/swift-pro/references/concurrency-patterns.md +165 -0
- package/workflows/powers/swift-pro/references/protocol-and-generics.md +172 -0
- package/workflows/powers/swift-pro/references/sendable-and-isolation.md +116 -0
- package/workflows/powers/swift-pro/references/swift-concurrency-and-protocols.md +260 -0
- package/workflows/powers/swift-pro/references/testing-and-packages.md +192 -0
- package/workflows/powers/tailwind-patterns/POWER.md +71 -240
- package/workflows/powers/tailwind-patterns/SKILL.md +71 -240
- package/workflows/powers/testing-patterns/POWER.md +155 -10
- package/workflows/powers/testing-patterns/SKILL.md +155 -10
- package/workflows/powers/typescript-pro/POWER.md +47 -38
- package/workflows/powers/typescript-pro/SKILL.md +47 -38
- package/workflows/powers/vitess/POWER.md +67 -0
- package/workflows/powers/vitess/SKILL.md +64 -0
- package/workflows/powers/vitess/references/vitess-checklist.md +19 -0
- package/workflows/powers/vulnerability-scanner/POWER.md +146 -10
- package/workflows/powers/vulnerability-scanner/SKILL.md +146 -10
- package/workflows/powers/web-perf/POWER.md +43 -170
- package/workflows/powers/web-perf/SKILL.md +43 -170
- package/workflows/powers/webapp-testing/POWER.md +43 -164
- package/workflows/powers/webapp-testing/SKILL.md +43 -164
- package/workflows/skills/agent-design/SKILL.md +198 -0
- package/workflows/skills/agent-design/references/clarification-patterns.md +153 -0
- package/workflows/skills/agent-design/references/skill-testing.md +164 -0
- package/workflows/skills/agent-design/references/workflow-patterns.md +226 -0
- package/workflows/skills/deep-research/SKILL.md +25 -20
- package/workflows/skills/deep-research/references/multi-round-research-loop.md +73 -8
- package/workflows/skills/frontend-design/SKILL.md +37 -32
- package/workflows/skills/frontend-design/commands/brand.md +167 -0
- package/workflows/skills/frontend-design/references/brand-presets.md +228 -0
- package/workflows/skills/generated/skill-audit.json +11 -2
- package/workflows/skills/generated/skill-catalog.json +37 -5
- package/workflows/skills/skills_index.json +1 -1
- package/workflows/workflows/agent-environment-setup/platforms/claude/skills/agent-design/SKILL.md +198 -0
- package/workflows/workflows/agent-environment-setup/platforms/claude/skills/agent-design/references/clarification-patterns.md +153 -0
- package/workflows/workflows/agent-environment-setup/platforms/claude/skills/agent-design/references/skill-testing.md +164 -0
- package/workflows/workflows/agent-environment-setup/platforms/claude/skills/agent-design/references/workflow-patterns.md +226 -0
- package/workflows/workflows/agent-environment-setup/platforms/claude/skills/deep-research/SKILL.md +25 -20
- package/workflows/workflows/agent-environment-setup/platforms/claude/skills/deep-research/references/multi-round-research-loop.md +73 -8
- package/workflows/workflows/agent-environment-setup/platforms/claude/skills/frontend-design/SKILL.md +37 -32
- package/workflows/workflows/agent-environment-setup/platforms/claude/skills/frontend-design/commands/brand.md +167 -0
- package/workflows/workflows/agent-environment-setup/platforms/claude/skills/frontend-design/references/brand-presets.md +228 -0
- package/workflows/workflows/agent-environment-setup/platforms/claude/skills/skills_index.json +1 -1
- package/workflows/workflows/agent-environment-setup/platforms/copilot/skills/agent-design/SKILL.md +197 -0
- package/workflows/workflows/agent-environment-setup/platforms/copilot/skills/agent-design/references/clarification-patterns.md +153 -0
- package/workflows/workflows/agent-environment-setup/platforms/copilot/skills/agent-design/references/skill-testing.md +164 -0
- package/workflows/workflows/agent-environment-setup/platforms/copilot/skills/agent-design/references/workflow-patterns.md +226 -0
- package/workflows/workflows/agent-environment-setup/platforms/copilot/skills/deep-research/SKILL.md +25 -20
- package/workflows/workflows/agent-environment-setup/platforms/copilot/skills/deep-research/references/multi-round-research-loop.md +73 -8
- package/workflows/workflows/agent-environment-setup/platforms/copilot/skills/frontend-design/SKILL.md +37 -32
- package/workflows/workflows/agent-environment-setup/platforms/copilot/skills/frontend-design/commands/brand.md +167 -0
- package/workflows/workflows/agent-environment-setup/platforms/copilot/skills/frontend-design/references/brand-presets.md +228 -0
- package/workflows/workflows/agent-environment-setup/platforms/copilot/skills/skills_index.json +1 -1
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
# Alerting and SLO Checklist
|
|
2
|
+
|
|
3
|
+
## SLO definition template
|
|
4
|
+
|
|
5
|
+
```yaml
|
|
6
|
+
slo:
|
|
7
|
+
name: "API request success rate"
|
|
8
|
+
service: my-service
|
|
9
|
+
sli:
|
|
10
|
+
type: availability
|
|
11
|
+
metric: "http_requests_total{status!~'5..'} / http_requests_total"
|
|
12
|
+
target: 99.9%
|
|
13
|
+
window: 30d
|
|
14
|
+
error_budget: 0.1% # ~43 minutes of downtime per 30 days
|
|
15
|
+
owner: platform-team
|
|
16
|
+
review_cadence: quarterly
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
## SLI types
|
|
20
|
+
|
|
21
|
+
| Type | Definition | Example metric |
|
|
22
|
+
| ------------ | --------------------------------------- | ------------------------------------------- |
|
|
23
|
+
| Availability | Proportion of successful requests | `successful_requests / total_requests` |
|
|
24
|
+
| Latency | Proportion of requests within threshold | `requests_under_200ms / total_requests` |
|
|
25
|
+
| Correctness | Proportion of correct results | `valid_responses / total_responses` |
|
|
26
|
+
| Freshness | Proportion of data within age threshold | `records_updated_within_1h / total_records` |
|
|
27
|
+
|
|
28
|
+
## Multi-window burn rate alerts
|
|
29
|
+
|
|
30
|
+
Use burn rate to detect SLO violations early without false positives.
|
|
31
|
+
|
|
32
|
+
| Alert severity | Burn rate | Short window | Long window | Response |
|
|
33
|
+
| -------------------------- | --------- | ------------ | ----------- | --------------------- |
|
|
34
|
+
| Page (immediate) | 14.4x | 5 min | 1 hour | Wake someone up |
|
|
35
|
+
| Page (urgent) | 6x | 30 min | 6 hours | Respond within 30 min |
|
|
36
|
+
| Ticket (next business day) | 3x | 2 hours | 1 day | Fix during work hours |
|
|
37
|
+
| Ticket (low priority) | 1x | 6 hours | 3 days | Schedule in sprint |
|
|
38
|
+
|
|
39
|
+
Formula: `burn_rate = error_rate_in_window / (1 - slo_target)`
|
|
40
|
+
|
|
41
|
+
Both short and long windows must exceed the burn rate threshold to fire.
|
|
42
|
+
|
|
43
|
+
## Alert specification template
|
|
44
|
+
|
|
45
|
+
```yaml
|
|
46
|
+
alert:
|
|
47
|
+
name: "High error rate - API"
|
|
48
|
+
severity: page
|
|
49
|
+
condition: "burn rate > 14.4x for 5m AND burn rate > 14.4x for 1h"
|
|
50
|
+
impact: "Users experiencing API failures above SLO budget"
|
|
51
|
+
runbook: "https://wiki.internal/runbooks/api-high-error-rate"
|
|
52
|
+
escalation:
|
|
53
|
+
- primary: on-call-engineer
|
|
54
|
+
- secondary: team-lead (after 15 min)
|
|
55
|
+
- tertiary: engineering-manager (after 30 min)
|
|
56
|
+
silence_during:
|
|
57
|
+
- maintenance windows
|
|
58
|
+
- planned deployments
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
## Alert review process (monthly)
|
|
62
|
+
|
|
63
|
+
- [ ] List all alerts that fired in the past 30 days
|
|
64
|
+
- [ ] For each alert: was it actionable? Did someone respond?
|
|
65
|
+
- [ ] Identify noisy alerts (fired >5 times without requiring action) — fix or remove
|
|
66
|
+
- [ ] Identify missing alerts (incidents not caught by alerts) — add coverage
|
|
67
|
+
- [ ] Verify all alerts have current runbook links
|
|
68
|
+
- [ ] Verify escalation paths are up to date
|
|
69
|
+
- [ ] Check that alert thresholds still match current SLO targets
|
|
70
|
+
|
|
71
|
+
## Runbook structure
|
|
72
|
+
|
|
73
|
+
Every alert must link to a runbook with:
|
|
74
|
+
|
|
75
|
+
1. **What is this alert?** — one-sentence description
|
|
76
|
+
2. **Why does it matter?** — user impact
|
|
77
|
+
3. **First response** — immediate triage steps (check dashboards, recent deploys, dependencies)
|
|
78
|
+
4. **Common causes** — ranked by frequency with fix instructions
|
|
79
|
+
5. **Escalation** — when and who to escalate to
|
|
80
|
+
6. **Post-incident** — link to post-mortem template
|
|
81
|
+
|
|
82
|
+
## Error budget policy
|
|
83
|
+
|
|
84
|
+
- **Budget remaining > 50%**: normal feature velocity
|
|
85
|
+
- **Budget remaining 25-50%**: reduce risky changes, add reliability work to sprint
|
|
86
|
+
- **Budget remaining < 25%**: freeze non-critical deploys, prioritize reliability
|
|
87
|
+
- **Budget exhausted**: stop feature work, all hands on reliability until budget recovers
|
|
@@ -0,0 +1,121 @@
|
|
|
1
|
+
# OpenTelemetry Setup Guide
|
|
2
|
+
|
|
3
|
+
## SDK initialization (Node.js)
|
|
4
|
+
|
|
5
|
+
```typescript
|
|
6
|
+
import { NodeSDK } from "@opentelemetry/sdk-node";
|
|
7
|
+
import { getNodeAutoInstrumentations } from "@opentelemetry/auto-instrumentations-node";
|
|
8
|
+
import { OTLPTraceExporter } from "@opentelemetry/exporter-trace-otlp-http";
|
|
9
|
+
import { OTLPMetricExporter } from "@opentelemetry/exporter-metrics-otlp-http";
|
|
10
|
+
import { PeriodicExportingMetricReader } from "@opentelemetry/sdk-metrics";
|
|
11
|
+
import { Resource } from "@opentelemetry/resources";
|
|
12
|
+
import {
|
|
13
|
+
ATTR_SERVICE_NAME,
|
|
14
|
+
ATTR_SERVICE_VERSION,
|
|
15
|
+
} from "@opentelemetry/semantic-conventions";
|
|
16
|
+
|
|
17
|
+
const sdk = new NodeSDK({
|
|
18
|
+
resource: new Resource({
|
|
19
|
+
[ATTR_SERVICE_NAME]: "my-service",
|
|
20
|
+
[ATTR_SERVICE_VERSION]: "1.0.0",
|
|
21
|
+
}),
|
|
22
|
+
traceExporter: new OTLPTraceExporter({
|
|
23
|
+
url: process.env.OTEL_EXPORTER_OTLP_ENDPOINT + "/v1/traces",
|
|
24
|
+
}),
|
|
25
|
+
metricReader: new PeriodicExportingMetricReader({
|
|
26
|
+
exporter: new OTLPMetricExporter({
|
|
27
|
+
url: process.env.OTEL_EXPORTER_OTLP_ENDPOINT + "/v1/metrics",
|
|
28
|
+
}),
|
|
29
|
+
exportIntervalMillis: 60_000,
|
|
30
|
+
}),
|
|
31
|
+
instrumentations: [getNodeAutoInstrumentations()],
|
|
32
|
+
});
|
|
33
|
+
|
|
34
|
+
sdk.start();
|
|
35
|
+
process.on("SIGTERM", () => sdk.shutdown());
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
- Initialize the SDK before any other imports that need instrumentation.
|
|
39
|
+
- Use environment variables for endpoint configuration — do not hardcode.
|
|
40
|
+
|
|
41
|
+
## SDK initialization (Python)
|
|
42
|
+
|
|
43
|
+
```python
|
|
44
|
+
from opentelemetry import trace
|
|
45
|
+
from opentelemetry.sdk.trace import TracerProvider
|
|
46
|
+
from opentelemetry.sdk.trace.export import BatchSpanProcessor
|
|
47
|
+
from opentelemetry.exporter.otlp.proto.grpc.trace_exporter import OTLPSpanExporter
|
|
48
|
+
from opentelemetry.sdk.resources import Resource
|
|
49
|
+
from opentelemetry.instrumentation.flask import FlaskInstrumentor
|
|
50
|
+
from opentelemetry.instrumentation.requests import RequestsInstrumentor
|
|
51
|
+
|
|
52
|
+
resource = Resource.create({"service.name": "my-service", "service.version": "1.0.0"})
|
|
53
|
+
provider = TracerProvider(resource=resource)
|
|
54
|
+
provider.add_span_processor(BatchSpanProcessor(OTLPSpanExporter()))
|
|
55
|
+
trace.set_tracer_provider(provider)
|
|
56
|
+
|
|
57
|
+
FlaskInstrumentor().instrument()
|
|
58
|
+
RequestsInstrumentor().instrument()
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
## Auto-instrumentation coverage
|
|
62
|
+
|
|
63
|
+
| Library | What it captures |
|
|
64
|
+
| ------------------------------------ | ------------------------------------------------------------ |
|
|
65
|
+
| HTTP server (Express, Flask, etc.) | Inbound request spans with method, route, status |
|
|
66
|
+
| HTTP client (fetch, axios, requests) | Outbound request spans with URL, status, duration |
|
|
67
|
+
| Database (pg, mysql2, pymongo) | Query spans with statement, parameters (sanitized), duration |
|
|
68
|
+
| Message queues (amqplib, kafkajs) | Produce/consume spans with topic, partition, offset |
|
|
69
|
+
| gRPC | Client and server call spans with method, status |
|
|
70
|
+
|
|
71
|
+
## Custom span creation
|
|
72
|
+
|
|
73
|
+
```typescript
|
|
74
|
+
import { trace } from "@opentelemetry/api";
|
|
75
|
+
|
|
76
|
+
const tracer = trace.getTracer("my-service");
|
|
77
|
+
|
|
78
|
+
async function processOrder(orderId: string) {
|
|
79
|
+
return tracer.startActiveSpan("process-order", async (span) => {
|
|
80
|
+
span.setAttribute("order.id", orderId);
|
|
81
|
+
try {
|
|
82
|
+
const result = await chargePayment(orderId);
|
|
83
|
+
span.setAttribute("order.status", "completed");
|
|
84
|
+
return result;
|
|
85
|
+
} catch (error) {
|
|
86
|
+
span.recordException(error as Error);
|
|
87
|
+
span.setStatus({ code: 2, message: (error as Error).message });
|
|
88
|
+
throw error;
|
|
89
|
+
} finally {
|
|
90
|
+
span.end();
|
|
91
|
+
}
|
|
92
|
+
});
|
|
93
|
+
}
|
|
94
|
+
```
|
|
95
|
+
|
|
96
|
+
## Sampling strategy
|
|
97
|
+
|
|
98
|
+
- **Development**: 100% sampling — capture everything.
|
|
99
|
+
- **Staging**: 100% sampling — reproduce production-like trace volume.
|
|
100
|
+
- **Production**:
|
|
101
|
+
- Always sample errors and slow requests (tail-based sampling).
|
|
102
|
+
- Sample 1-10% of successful requests depending on volume.
|
|
103
|
+
- Use parent-based sampling to preserve complete traces.
|
|
104
|
+
|
|
105
|
+
## Exporter configuration
|
|
106
|
+
|
|
107
|
+
| Backend | Protocol | Endpoint pattern |
|
|
108
|
+
| ------------- | --------- | ------------------------------ |
|
|
109
|
+
| Jaeger | OTLP/gRPC | `http://jaeger:4317` |
|
|
110
|
+
| Grafana Tempo | OTLP/HTTP | `http://tempo:4318/v1/traces` |
|
|
111
|
+
| Datadog | OTLP/gRPC | `http://datadog-agent:4317` |
|
|
112
|
+
| Honeycomb | OTLP/gRPC | `https://api.honeycomb.io:443` |
|
|
113
|
+
|
|
114
|
+
Set via `OTEL_EXPORTER_OTLP_ENDPOINT` environment variable for portability.
|
|
115
|
+
|
|
116
|
+
## Context propagation
|
|
117
|
+
|
|
118
|
+
- Use W3C Trace Context (`traceparent`, `tracestate` headers) — this is the default in OTel.
|
|
119
|
+
- Ensure all HTTP clients and servers propagate context headers.
|
|
120
|
+
- For message queues, inject trace context into message headers/attributes.
|
|
121
|
+
- For background jobs, pass trace parent as a job metadata field.
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
````markdown
|
|
2
|
+
---
|
|
3
|
+
inclusion: manual
|
|
4
|
+
name: openai-docs
|
|
5
|
+
description: "Use when the task depends on current OpenAI platform or product documentation: API usage, model behavior, tool features, SDK guidance, or version-sensitive OpenAI docs that should be verified from official sources."
|
|
6
|
+
license: MIT
|
|
7
|
+
metadata:
|
|
8
|
+
author: cubis-foundry
|
|
9
|
+
version: "1.0"
|
|
10
|
+
compatibility: Claude Code, Codex, GitHub Copilot
|
|
11
|
+
---
|
|
12
|
+
|
|
13
|
+
# OpenAI Docs
|
|
14
|
+
|
|
15
|
+
## Purpose
|
|
16
|
+
|
|
17
|
+
You are the specialist for current OpenAI documentation lookup and citation discipline.
|
|
18
|
+
|
|
19
|
+
Your job is to force official-source verification when OpenAI guidance may be stale, version-sensitive, or product-specific.
|
|
20
|
+
|
|
21
|
+
## When to Use
|
|
22
|
+
|
|
23
|
+
- The task depends on current OpenAI docs, product behavior, SDK guidance, or API surface.
|
|
24
|
+
- The user asks for latest OpenAI information, official docs, or source-backed answers.
|
|
25
|
+
- Version-sensitive or product-specific OpenAI behavior materially affects the answer.
|
|
26
|
+
|
|
27
|
+
## Instructions
|
|
28
|
+
|
|
29
|
+
### STANDARD OPERATING PROCEDURE (SOP)
|
|
30
|
+
|
|
31
|
+
1. Identify the exact OpenAI surface in question.
|
|
32
|
+
2. Prefer official OpenAI documentation and official OpenAI repos first.
|
|
33
|
+
3. Cite the current source rather than relying on recalled behavior.
|
|
34
|
+
4. Separate documented facts from inference.
|
|
35
|
+
5. State uncertainty if the docs do not fully answer the question.
|
|
36
|
+
|
|
37
|
+
### Constraints
|
|
38
|
+
|
|
39
|
+
- Do not answer OpenAI product questions from memory when current docs are needed.
|
|
40
|
+
- Do not use community summaries as primary sources when official docs exist.
|
|
41
|
+
- Do not broaden into general web research when the task is specifically OpenAI guidance.
|
|
42
|
+
|
|
43
|
+
## Output Format
|
|
44
|
+
|
|
45
|
+
Provide implementation guidance, code examples, and configuration as appropriate to the task.
|
|
46
|
+
|
|
47
|
+
## References
|
|
48
|
+
|
|
49
|
+
| File | Load when |
|
|
50
|
+
| ---------------------------------------- | ------------------------------------------------------------------------------- |
|
|
51
|
+
| `references/official-source-playbook.md` | You need the source-selection and citation rules for OpenAI documentation work. |
|
|
52
|
+
|
|
53
|
+
## Scripts
|
|
54
|
+
|
|
55
|
+
No helper scripts are required for this skill right now. Keep execution in `SKILL.md` and `references/` unless repeated automation becomes necessary.
|
|
56
|
+
|
|
57
|
+
## Examples
|
|
58
|
+
|
|
59
|
+
- "Help me with openai docs best practices in this project"
|
|
60
|
+
- "Review my openai docs implementation for issues"
|
|
61
|
+
````
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: openai-docs
|
|
3
|
+
description: "Use when the task depends on current OpenAI platform or product documentation: API usage, model behavior, tool features, SDK guidance, or version-sensitive OpenAI docs that should be verified from official sources."
|
|
4
|
+
license: MIT
|
|
5
|
+
metadata:
|
|
6
|
+
author: cubis-foundry
|
|
7
|
+
version: "1.0"
|
|
8
|
+
compatibility: Claude Code, Codex, GitHub Copilot
|
|
9
|
+
---
|
|
10
|
+
|
|
11
|
+
# OpenAI Docs
|
|
12
|
+
|
|
13
|
+
## Purpose
|
|
14
|
+
|
|
15
|
+
You are the specialist for current OpenAI documentation lookup and citation discipline.
|
|
16
|
+
|
|
17
|
+
Your job is to force official-source verification when OpenAI guidance may be stale, version-sensitive, or product-specific.
|
|
18
|
+
|
|
19
|
+
## When to Use
|
|
20
|
+
|
|
21
|
+
- The task depends on current OpenAI docs, product behavior, SDK guidance, or API surface.
|
|
22
|
+
- The user asks for latest OpenAI information, official docs, or source-backed answers.
|
|
23
|
+
- Version-sensitive or product-specific OpenAI behavior materially affects the answer.
|
|
24
|
+
|
|
25
|
+
## Instructions
|
|
26
|
+
|
|
27
|
+
### STANDARD OPERATING PROCEDURE (SOP)
|
|
28
|
+
|
|
29
|
+
1. Identify the exact OpenAI surface in question.
|
|
30
|
+
2. Prefer official OpenAI documentation and official OpenAI repos first.
|
|
31
|
+
3. Cite the current source rather than relying on recalled behavior.
|
|
32
|
+
4. Separate documented facts from inference.
|
|
33
|
+
5. State uncertainty if the docs do not fully answer the question.
|
|
34
|
+
|
|
35
|
+
### Constraints
|
|
36
|
+
|
|
37
|
+
- Do not answer OpenAI product questions from memory when current docs are needed.
|
|
38
|
+
- Do not use community summaries as primary sources when official docs exist.
|
|
39
|
+
- Do not broaden into general web research when the task is specifically OpenAI guidance.
|
|
40
|
+
|
|
41
|
+
## Output Format
|
|
42
|
+
|
|
43
|
+
Provide implementation guidance, code examples, and configuration as appropriate to the task.
|
|
44
|
+
|
|
45
|
+
## References
|
|
46
|
+
|
|
47
|
+
| File | Load when |
|
|
48
|
+
| ---------------------------------------- | ------------------------------------------------------------------------------- |
|
|
49
|
+
| `references/official-source-playbook.md` | You need the source-selection and citation rules for OpenAI documentation work. |
|
|
50
|
+
|
|
51
|
+
## Scripts
|
|
52
|
+
|
|
53
|
+
No helper scripts are required for this skill right now. Keep execution in `SKILL.md` and `references/` unless repeated automation becomes necessary.
|
|
54
|
+
|
|
55
|
+
## Examples
|
|
56
|
+
|
|
57
|
+
- "Help me with openai docs best practices in this project"
|
|
58
|
+
- "Review my openai docs implementation for issues"
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
# Official Source Playbook
|
|
2
|
+
|
|
3
|
+
Load this when answering OpenAI-specific questions or refreshing OpenAI-facing skills.
|
|
4
|
+
|
|
5
|
+
## Source Rules
|
|
6
|
+
|
|
7
|
+
- Prefer official OpenAI docs and official OpenAI repos first.
|
|
8
|
+
- Use community material only when it adds context the official docs do not cover.
|
|
9
|
+
- Mark inferences clearly when the source does not state something outright.
|
|
10
|
+
- If current product behavior may have changed, verify before answering.
|
|
@@ -2,145 +2,92 @@
|
|
|
2
2
|
---
|
|
3
3
|
inclusion: manual
|
|
4
4
|
name: performance-profiling
|
|
5
|
-
description:
|
|
6
|
-
|
|
5
|
+
description: "Use when measuring, analyzing, and optimizing application performance with Core Web Vitals, bundle analysis, runtime profiling, and lighthouse audits."
|
|
6
|
+
license: MIT
|
|
7
|
+
metadata:
|
|
8
|
+
author: cubis-foundry
|
|
9
|
+
version: "1.0"
|
|
10
|
+
compatibility: Claude Code, Codex, GitHub Copilot
|
|
7
11
|
---
|
|
8
12
|
|
|
9
13
|
# Performance Profiling
|
|
10
14
|
|
|
11
|
-
|
|
15
|
+
## Purpose
|
|
12
16
|
|
|
13
|
-
|
|
17
|
+
Use when measuring, analyzing, and optimizing application performance with Core Web Vitals, bundle analysis, runtime profiling, and lighthouse audits.
|
|
14
18
|
|
|
15
|
-
|
|
19
|
+
## When to Use
|
|
16
20
|
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
21
|
+
- Measuring and improving Core Web Vitals (LCP, INP, CLS).
|
|
22
|
+
- Analyzing bundle size, finding large dependencies, and code splitting.
|
|
23
|
+
- Profiling runtime performance in browser Performance or Memory tabs.
|
|
24
|
+
- Diagnosing performance bottlenecks (slow API, large payload, memory leak, layout thrash).
|
|
25
|
+
- Planning performance optimization with measurement-first discipline.
|
|
20
26
|
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
## 1. Core Web Vitals
|
|
24
|
-
|
|
25
|
-
### Targets
|
|
26
|
-
|
|
27
|
-
| Metric | Good | Poor | Measures |
|
|
28
|
-
|--------|------|------|----------|
|
|
29
|
-
| **LCP** | < 2.5s | > 4.0s | Loading |
|
|
30
|
-
| **INP** | < 200ms | > 500ms | Interactivity |
|
|
31
|
-
| **CLS** | < 0.1 | > 0.25 | Stability |
|
|
32
|
-
|
|
33
|
-
### When to Measure
|
|
34
|
-
|
|
35
|
-
| Stage | Tool |
|
|
36
|
-
|-------|------|
|
|
37
|
-
| Development | Local Lighthouse |
|
|
38
|
-
| CI/CD | Lighthouse CI |
|
|
39
|
-
| Production | RUM (Real User Monitoring) |
|
|
40
|
-
|
|
41
|
-
---
|
|
42
|
-
|
|
43
|
-
## 2. Profiling Workflow
|
|
44
|
-
|
|
45
|
-
### The 4-Step Process
|
|
46
|
-
|
|
47
|
-
```
|
|
48
|
-
1. BASELINE → Measure current state
|
|
49
|
-
2. IDENTIFY → Find the bottleneck
|
|
50
|
-
3. FIX → Make targeted change
|
|
51
|
-
4. VALIDATE → Confirm improvement
|
|
52
|
-
```
|
|
53
|
-
|
|
54
|
-
### Profiling Tool Selection
|
|
27
|
+
## Instructions
|
|
55
28
|
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
| Runtime | DevTools Performance |
|
|
61
|
-
| Memory | DevTools Memory |
|
|
62
|
-
| Network | DevTools Network |
|
|
29
|
+
1. Baseline — measure current performance with Lighthouse, WebPageTest, or browser DevTools.
|
|
30
|
+
2. Identify — find the biggest bottleneck using profiling data, not assumptions.
|
|
31
|
+
3. Fix — apply targeted optimization for the measured bottleneck.
|
|
32
|
+
4. Validate — re-measure to confirm improvement and check for regressions.
|
|
63
33
|
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
## 3. Bundle Analysis
|
|
67
|
-
|
|
68
|
-
### What to Look For
|
|
69
|
-
|
|
70
|
-
| Issue | Indicator |
|
|
71
|
-
|-------|-----------|
|
|
72
|
-
| Large dependencies | Top of bundle |
|
|
73
|
-
| Duplicate code | Multiple chunks |
|
|
74
|
-
| Unused code | Low coverage |
|
|
75
|
-
| Missing splits | Single large chunk |
|
|
76
|
-
|
|
77
|
-
### Optimization Actions
|
|
78
|
-
|
|
79
|
-
| Finding | Action |
|
|
80
|
-
|---------|--------|
|
|
81
|
-
| Big library | Import specific modules |
|
|
82
|
-
| Duplicate deps | Dedupe, update versions |
|
|
83
|
-
| Route in main | Code split |
|
|
84
|
-
| Unused exports | Tree shake |
|
|
34
|
+
### Core Web Vitals targets
|
|
85
35
|
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
36
|
+
| Metric | Good | Needs Improvement | Poor |
|
|
37
|
+
| ------ | ------- | ----------------- | ------- |
|
|
38
|
+
| LCP | < 2.5s | 2.5s – 4.0s | > 4.0s |
|
|
39
|
+
| INP | < 200ms | 200ms – 500ms | > 500ms |
|
|
40
|
+
| CLS | < 0.1 | 0.1 – 0.25 | > 0.25 |
|
|
89
41
|
|
|
90
|
-
###
|
|
42
|
+
### Baseline standards
|
|
91
43
|
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
| Script | JavaScript execution |
|
|
44
|
+
- Always measure before optimizing — intuition is unreliable for performance.
|
|
45
|
+
- Use real user metrics (RUM) alongside synthetic benchmarks.
|
|
46
|
+
- Profile on representative hardware, not just developer machines.
|
|
47
|
+
- Address the largest bottleneck first for maximum impact.
|
|
48
|
+
- Verify optimizations don't introduce regressions elsewhere.
|
|
98
49
|
|
|
99
|
-
###
|
|
50
|
+
### Quick wins priority
|
|
100
51
|
|
|
101
|
-
|
|
|
102
|
-
|
|
103
|
-
|
|
|
104
|
-
|
|
|
105
|
-
|
|
|
52
|
+
| Priority | Action | Typical Impact |
|
|
53
|
+
| -------- | -------------------------------- | ------------------------- |
|
|
54
|
+
| 1 | Enable compression (gzip/brotli) | 60-80% transfer reduction |
|
|
55
|
+
| 2 | Lazy load below-fold images | LCP improvement |
|
|
56
|
+
| 3 | Code split routes | Initial load reduction |
|
|
57
|
+
| 4 | Set proper cache headers | Repeat visit speed |
|
|
58
|
+
| 5 | Optimize images (WebP/AVIF) | Transfer size reduction |
|
|
106
59
|
|
|
107
|
-
|
|
60
|
+
### Common bottlenecks by symptom
|
|
108
61
|
|
|
109
|
-
|
|
62
|
+
| Symptom | Likely Cause | Investigation |
|
|
63
|
+
| ----------------- | --------------------------------------- | ---------------------------------- |
|
|
64
|
+
| Slow initial load | Large bundle, render-blocking resources | Bundle analysis, waterfall |
|
|
65
|
+
| Janky scrolling | Layout thrash, paint storms | Performance tab, layers panel |
|
|
66
|
+
| Memory growth | Detached DOM, event listener leaks | Memory tab, heap snapshots |
|
|
67
|
+
| Slow interaction | Long tasks, main thread blocking | Performance tab, long task markers |
|
|
110
68
|
|
|
111
|
-
###
|
|
69
|
+
### Constraints
|
|
112
70
|
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
| Jank during scroll | Layout thrashing |
|
|
118
|
-
| Growing memory | Leaks, retained refs |
|
|
71
|
+
- Never optimize without measuring first.
|
|
72
|
+
- Never assume a change improved performance — always validate with data.
|
|
73
|
+
- Never sacrifice correctness for performance.
|
|
74
|
+
- Avoid premature optimization of code paths that aren't bottlenecks.
|
|
119
75
|
|
|
120
|
-
|
|
76
|
+
## Output Format
|
|
121
77
|
|
|
122
|
-
|
|
78
|
+
Provide measurement data, identified bottlenecks with evidence, optimization recommendations, and before/after comparisons.
|
|
123
79
|
|
|
124
|
-
|
|
125
|
-
|----------|--------|--------|
|
|
126
|
-
| 1 | Enable compression | High |
|
|
127
|
-
| 2 | Lazy load images | High |
|
|
128
|
-
| 3 | Code split routes | High |
|
|
129
|
-
| 4 | Cache static assets | Medium |
|
|
130
|
-
| 5 | Optimize images | Medium |
|
|
80
|
+
## References
|
|
131
81
|
|
|
132
|
-
|
|
82
|
+
No reference files for this skill right now.
|
|
133
83
|
|
|
134
|
-
##
|
|
84
|
+
## Scripts
|
|
135
85
|
|
|
136
|
-
|
|
137
|
-
|----------|-------|
|
|
138
|
-
| Guess at problems | Profile first |
|
|
139
|
-
| Micro-optimize | Fix biggest issue |
|
|
140
|
-
| Optimize early | Optimize when needed |
|
|
141
|
-
| Ignore real users | Use RUM data |
|
|
86
|
+
No helper scripts are required for this skill right now.
|
|
142
87
|
|
|
143
|
-
|
|
88
|
+
## Examples
|
|
144
89
|
|
|
145
|
-
|
|
90
|
+
- "Profile and optimize the Core Web Vitals for our landing page"
|
|
91
|
+
- "Analyze our bundle and recommend code splitting strategy"
|
|
92
|
+
- "Find and fix the memory leak in our real-time dashboard"
|
|
146
93
|
````
|