cognitive-core 0.2.1 → 0.2.2
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/dist/atlas.d.ts +10 -0
- package/dist/atlas.d.ts.map +1 -1
- package/dist/atlas.js +65 -0
- package/dist/atlas.js.map +1 -1
- package/dist/learning/pipeline.d.ts +4 -31
- package/dist/learning/pipeline.d.ts.map +1 -1
- package/dist/learning/pipeline.js +12 -64
- package/dist/learning/pipeline.js.map +1 -1
- package/dist/memory/curated-loader.d.ts +21 -4
- package/dist/memory/curated-loader.d.ts.map +1 -1
- package/dist/memory/curated-loader.js +53 -16
- package/dist/memory/curated-loader.js.map +1 -1
- package/dist/memory/index.d.ts +2 -1
- package/dist/memory/index.d.ts.map +1 -1
- package/dist/memory/index.js +3 -1
- package/dist/memory/index.js.map +1 -1
- package/dist/memory/playbook.d.ts +6 -0
- package/dist/memory/playbook.d.ts.map +1 -1
- package/dist/memory/playbook.js +15 -0
- package/dist/memory/playbook.js.map +1 -1
- package/dist/memory/source-resolver.d.ts +120 -0
- package/dist/memory/source-resolver.d.ts.map +1 -0
- package/dist/memory/source-resolver.js +300 -0
- package/dist/memory/source-resolver.js.map +1 -0
- package/dist/types/config.d.ts +141 -0
- package/dist/types/config.d.ts.map +1 -1
- package/dist/types/config.js +40 -0
- package/dist/types/config.js.map +1 -1
- package/dist/types/index.d.ts +1 -1
- package/dist/types/index.d.ts.map +1 -1
- package/dist/types/index.js +1 -1
- package/dist/types/index.js.map +1 -1
- package/dist/workspace/types.d.ts +12 -54
- package/dist/workspace/types.d.ts.map +1 -1
- package/dist/workspace/types.js.map +1 -1
- package/package.json +2 -2
- package/playbooks/compound-engineering/adversarial-review.json +51 -0
- package/playbooks/compound-engineering/agent-native-architecture.json +59 -0
- package/playbooks/compound-engineering/agent-native-review.json +54 -0
- package/playbooks/compound-engineering/api-contract-review.json +52 -0
- package/playbooks/compound-engineering/brainstorm-requirements.json +55 -0
- package/playbooks/compound-engineering/bug-reproduction.json +62 -0
- package/playbooks/compound-engineering/confidence-calibration.json +49 -0
- package/playbooks/compound-engineering/correctness-review.json +49 -0
- package/playbooks/compound-engineering/data-migration-safety.json +59 -0
- package/playbooks/compound-engineering/deployment-verification.json +63 -0
- package/playbooks/compound-engineering/error-recovery-patterns.json +53 -0
- package/playbooks/compound-engineering/implementation-planning.json +64 -0
- package/playbooks/compound-engineering/issue-pattern-analysis.json +53 -0
- package/playbooks/compound-engineering/knowledge-compounding.json +63 -0
- package/playbooks/compound-engineering/learnings-research.json +54 -0
- package/playbooks/compound-engineering/maintainability-review.json +49 -0
- package/playbooks/compound-engineering/performance-review.json +54 -0
- package/playbooks/compound-engineering/plan-adversarial-review.json +56 -0
- package/playbooks/compound-engineering/plan-feasibility-review.json +56 -0
- package/playbooks/compound-engineering/project-standards-review.json +52 -0
- package/playbooks/compound-engineering/reliability-review.json +53 -0
- package/playbooks/compound-engineering/review-orchestration.json +64 -0
- package/playbooks/compound-engineering/security-review.json +54 -0
- package/playbooks/compound-engineering/systematic-execution.json +64 -0
- package/playbooks/compound-engineering/testing-review.json +50 -0
- package/src/atlas.ts +96 -0
- package/src/memory/curated-loader.ts +69 -16
- package/src/memory/index.ts +16 -0
- package/src/memory/playbook.ts +19 -0
- package/src/memory/source-resolver.ts +422 -0
- package/src/types/config.ts +46 -0
- package/src/types/index.ts +4 -0
- package/src/workspace/types.ts +22 -78
- package/tests/integration/curated-sources-e2e.test.ts +502 -0
- package/tests/memory/compound-engineering-seed.test.ts +338 -0
- package/tests/memory/curated-loader-extended.test.ts +225 -0
- package/tests/memory/playbook-quality-validation.test.ts +430 -0
- package/tests/memory/source-resolver.test.ts +700 -0
- package/.claude/settings.local.json +0 -11
- package/dist/learning/llm-extractor.d.ts +0 -88
- package/dist/learning/llm-extractor.d.ts.map +0 -1
- package/dist/learning/llm-extractor.js +0 -372
- package/dist/learning/llm-extractor.js.map +0 -1
- package/dist/learning/loop-coordinator.d.ts +0 -61
- package/dist/learning/loop-coordinator.d.ts.map +0 -1
- package/dist/learning/loop-coordinator.js +0 -96
- package/dist/learning/loop-coordinator.js.map +0 -1
- package/references/agent-workspace/CLAUDE.md +0 -74
- package/references/agent-workspace/README.md +0 -587
- package/references/agent-workspace/media/banner.png +0 -0
- package/references/agent-workspace/package-lock.json +0 -2061
- package/references/agent-workspace/package.json +0 -54
- package/references/agent-workspace/src/handle.ts +0 -122
- package/references/agent-workspace/src/index.ts +0 -32
- package/references/agent-workspace/src/manager.ts +0 -102
- package/references/agent-workspace/src/readers/json.ts +0 -71
- package/references/agent-workspace/src/readers/markdown.ts +0 -37
- package/references/agent-workspace/src/readers/raw.ts +0 -27
- package/references/agent-workspace/src/types.ts +0 -68
- package/references/agent-workspace/src/validation.ts +0 -93
- package/references/agent-workspace/src/writers/json.ts +0 -17
- package/references/agent-workspace/src/writers/markdown.ts +0 -27
- package/references/agent-workspace/src/writers/raw.ts +0 -22
- package/references/agent-workspace/tests/errors.test.ts +0 -652
- package/references/agent-workspace/tests/handle.test.ts +0 -144
- package/references/agent-workspace/tests/manager.test.ts +0 -124
- package/references/agent-workspace/tests/readers.test.ts +0 -205
- package/references/agent-workspace/tests/validation.test.ts +0 -196
- package/references/agent-workspace/tests/writers.test.ts +0 -108
- package/references/agent-workspace/tsconfig.json +0 -20
- package/references/agent-workspace/tsup.config.ts +0 -9
- package/references/minimem/.claude/settings.json +0 -7
- package/references/minimem/.sudocode/issues.jsonl +0 -18
- package/references/minimem/.sudocode/specs.jsonl +0 -1
- package/references/minimem/CLAUDE.md +0 -310
- package/references/minimem/README.md +0 -556
- package/references/minimem/claude-plugin/.claude-plugin/plugin.json +0 -10
- package/references/minimem/claude-plugin/.mcp.json +0 -7
- package/references/minimem/claude-plugin/README.md +0 -158
- package/references/minimem/claude-plugin/commands/recall.md +0 -47
- package/references/minimem/claude-plugin/commands/remember.md +0 -41
- package/references/minimem/claude-plugin/hooks/__tests__/hooks.test.ts +0 -272
- package/references/minimem/claude-plugin/hooks/hooks.json +0 -27
- package/references/minimem/claude-plugin/hooks/session-end.sh +0 -86
- package/references/minimem/claude-plugin/hooks/session-start.sh +0 -85
- package/references/minimem/claude-plugin/skills/memory/SKILL.md +0 -108
- package/references/minimem/package-lock.json +0 -5373
- package/references/minimem/package.json +0 -60
- package/references/minimem/scripts/postbuild.js +0 -35
- package/references/minimem/src/__tests__/edge-cases.test.ts +0 -371
- package/references/minimem/src/__tests__/errors.test.ts +0 -265
- package/references/minimem/src/__tests__/helpers.ts +0 -199
- package/references/minimem/src/__tests__/internal.test.ts +0 -407
- package/references/minimem/src/__tests__/knowledge.test.ts +0 -287
- package/references/minimem/src/__tests__/minimem.integration.test.ts +0 -1127
- package/references/minimem/src/__tests__/session.test.ts +0 -190
- package/references/minimem/src/cli/__tests__/commands.test.ts +0 -759
- package/references/minimem/src/cli/commands/__tests__/conflicts.test.ts +0 -141
- package/references/minimem/src/cli/commands/append.ts +0 -76
- package/references/minimem/src/cli/commands/config.ts +0 -262
- package/references/minimem/src/cli/commands/conflicts.ts +0 -413
- package/references/minimem/src/cli/commands/daemon.ts +0 -169
- package/references/minimem/src/cli/commands/index.ts +0 -12
- package/references/minimem/src/cli/commands/init.ts +0 -88
- package/references/minimem/src/cli/commands/mcp.ts +0 -177
- package/references/minimem/src/cli/commands/push-pull.ts +0 -213
- package/references/minimem/src/cli/commands/search.ts +0 -158
- package/references/minimem/src/cli/commands/status.ts +0 -84
- package/references/minimem/src/cli/commands/sync-init.ts +0 -290
- package/references/minimem/src/cli/commands/sync.ts +0 -70
- package/references/minimem/src/cli/commands/upsert.ts +0 -197
- package/references/minimem/src/cli/config.ts +0 -584
- package/references/minimem/src/cli/index.ts +0 -264
- package/references/minimem/src/cli/shared.ts +0 -161
- package/references/minimem/src/cli/sync/__tests__/central.test.ts +0 -152
- package/references/minimem/src/cli/sync/__tests__/conflicts.test.ts +0 -209
- package/references/minimem/src/cli/sync/__tests__/daemon.test.ts +0 -118
- package/references/minimem/src/cli/sync/__tests__/detection.test.ts +0 -207
- package/references/minimem/src/cli/sync/__tests__/integration.test.ts +0 -476
- package/references/minimem/src/cli/sync/__tests__/registry.test.ts +0 -363
- package/references/minimem/src/cli/sync/__tests__/state.test.ts +0 -255
- package/references/minimem/src/cli/sync/__tests__/validation.test.ts +0 -193
- package/references/minimem/src/cli/sync/__tests__/watcher.test.ts +0 -178
- package/references/minimem/src/cli/sync/central.ts +0 -292
- package/references/minimem/src/cli/sync/conflicts.ts +0 -204
- package/references/minimem/src/cli/sync/daemon.ts +0 -407
- package/references/minimem/src/cli/sync/detection.ts +0 -138
- package/references/minimem/src/cli/sync/index.ts +0 -107
- package/references/minimem/src/cli/sync/operations.ts +0 -373
- package/references/minimem/src/cli/sync/registry.ts +0 -279
- package/references/minimem/src/cli/sync/state.ts +0 -355
- package/references/minimem/src/cli/sync/validation.ts +0 -206
- package/references/minimem/src/cli/sync/watcher.ts +0 -234
- package/references/minimem/src/cli/version.ts +0 -34
- package/references/minimem/src/core/index.ts +0 -9
- package/references/minimem/src/core/indexer.ts +0 -628
- package/references/minimem/src/core/searcher.ts +0 -221
- package/references/minimem/src/db/schema.ts +0 -183
- package/references/minimem/src/db/sqlite-vec.ts +0 -24
- package/references/minimem/src/embeddings/__tests__/embeddings.test.ts +0 -431
- package/references/minimem/src/embeddings/batch-gemini.ts +0 -392
- package/references/minimem/src/embeddings/batch-openai.ts +0 -409
- package/references/minimem/src/embeddings/embeddings.ts +0 -434
- package/references/minimem/src/index.ts +0 -109
- package/references/minimem/src/internal.ts +0 -299
- package/references/minimem/src/minimem.ts +0 -1276
- package/references/minimem/src/search/__tests__/hybrid.test.ts +0 -247
- package/references/minimem/src/search/graph.ts +0 -234
- package/references/minimem/src/search/hybrid.ts +0 -151
- package/references/minimem/src/search/search.ts +0 -256
- package/references/minimem/src/server/__tests__/mcp.test.ts +0 -341
- package/references/minimem/src/server/__tests__/tools.test.ts +0 -364
- package/references/minimem/src/server/mcp.ts +0 -326
- package/references/minimem/src/server/tools.ts +0 -720
- package/references/minimem/src/session.ts +0 -460
- package/references/minimem/tsconfig.json +0 -19
- package/references/minimem/tsup.config.ts +0 -26
- package/references/minimem/vitest.config.ts +0 -24
- package/references/sessionlog/.husky/pre-commit +0 -1
- package/references/sessionlog/.lintstagedrc.json +0 -4
- package/references/sessionlog/.prettierignore +0 -4
- package/references/sessionlog/.prettierrc.json +0 -11
- package/references/sessionlog/LICENSE +0 -21
- package/references/sessionlog/README.md +0 -453
- package/references/sessionlog/eslint.config.js +0 -58
- package/references/sessionlog/package-lock.json +0 -3672
- package/references/sessionlog/package.json +0 -65
- package/references/sessionlog/src/__tests__/agent-hooks.test.ts +0 -570
- package/references/sessionlog/src/__tests__/agent-registry.test.ts +0 -127
- package/references/sessionlog/src/__tests__/claude-code-hooks.test.ts +0 -225
- package/references/sessionlog/src/__tests__/claude-generator.test.ts +0 -46
- package/references/sessionlog/src/__tests__/commit-msg.test.ts +0 -86
- package/references/sessionlog/src/__tests__/cursor-agent.test.ts +0 -224
- package/references/sessionlog/src/__tests__/e2e-live.test.ts +0 -890
- package/references/sessionlog/src/__tests__/event-log.test.ts +0 -183
- package/references/sessionlog/src/__tests__/flush-sentinel.test.ts +0 -105
- package/references/sessionlog/src/__tests__/gemini-agent.test.ts +0 -375
- package/references/sessionlog/src/__tests__/git-hooks.test.ts +0 -78
- package/references/sessionlog/src/__tests__/hook-managers.test.ts +0 -121
- package/references/sessionlog/src/__tests__/lifecycle-tasks.test.ts +0 -759
- package/references/sessionlog/src/__tests__/opencode-agent.test.ts +0 -338
- package/references/sessionlog/src/__tests__/redaction.test.ts +0 -136
- package/references/sessionlog/src/__tests__/session-repo.test.ts +0 -353
- package/references/sessionlog/src/__tests__/session-store.test.ts +0 -166
- package/references/sessionlog/src/__tests__/setup-ccweb.test.ts +0 -466
- package/references/sessionlog/src/__tests__/skill-live.test.ts +0 -461
- package/references/sessionlog/src/__tests__/summarize.test.ts +0 -348
- package/references/sessionlog/src/__tests__/task-plan-e2e.test.ts +0 -610
- package/references/sessionlog/src/__tests__/task-plan-live.test.ts +0 -632
- package/references/sessionlog/src/__tests__/transcript-timestamp.test.ts +0 -121
- package/references/sessionlog/src/__tests__/types.test.ts +0 -166
- package/references/sessionlog/src/__tests__/utils.test.ts +0 -333
- package/references/sessionlog/src/__tests__/validation.test.ts +0 -103
- package/references/sessionlog/src/__tests__/worktree.test.ts +0 -57
- package/references/sessionlog/src/agent/agents/claude-code.ts +0 -1089
- package/references/sessionlog/src/agent/agents/cursor.ts +0 -361
- package/references/sessionlog/src/agent/agents/gemini-cli.ts +0 -632
- package/references/sessionlog/src/agent/agents/opencode.ts +0 -540
- package/references/sessionlog/src/agent/registry.ts +0 -143
- package/references/sessionlog/src/agent/session-types.ts +0 -113
- package/references/sessionlog/src/agent/types.ts +0 -220
- package/references/sessionlog/src/cli.ts +0 -597
- package/references/sessionlog/src/commands/clean.ts +0 -133
- package/references/sessionlog/src/commands/disable.ts +0 -84
- package/references/sessionlog/src/commands/doctor.ts +0 -145
- package/references/sessionlog/src/commands/enable.ts +0 -202
- package/references/sessionlog/src/commands/explain.ts +0 -261
- package/references/sessionlog/src/commands/reset.ts +0 -105
- package/references/sessionlog/src/commands/resume.ts +0 -180
- package/references/sessionlog/src/commands/rewind.ts +0 -195
- package/references/sessionlog/src/commands/setup-ccweb.ts +0 -275
- package/references/sessionlog/src/commands/status.ts +0 -172
- package/references/sessionlog/src/config.ts +0 -165
- package/references/sessionlog/src/events/event-log.ts +0 -126
- package/references/sessionlog/src/git-operations.ts +0 -558
- package/references/sessionlog/src/hooks/git-hooks.ts +0 -165
- package/references/sessionlog/src/hooks/lifecycle.ts +0 -391
- package/references/sessionlog/src/index.ts +0 -650
- package/references/sessionlog/src/security/redaction.ts +0 -283
- package/references/sessionlog/src/session/state-machine.ts +0 -452
- package/references/sessionlog/src/store/checkpoint-store.ts +0 -509
- package/references/sessionlog/src/store/native-store.ts +0 -173
- package/references/sessionlog/src/store/provider-types.ts +0 -99
- package/references/sessionlog/src/store/session-store.ts +0 -266
- package/references/sessionlog/src/strategy/attribution.ts +0 -296
- package/references/sessionlog/src/strategy/common.ts +0 -207
- package/references/sessionlog/src/strategy/content-overlap.ts +0 -228
- package/references/sessionlog/src/strategy/manual-commit.ts +0 -988
- package/references/sessionlog/src/strategy/types.ts +0 -279
- package/references/sessionlog/src/summarize/claude-generator.ts +0 -115
- package/references/sessionlog/src/summarize/summarize.ts +0 -432
- package/references/sessionlog/src/types.ts +0 -508
- package/references/sessionlog/src/utils/chunk-files.ts +0 -49
- package/references/sessionlog/src/utils/commit-message.ts +0 -65
- package/references/sessionlog/src/utils/detect-agent.ts +0 -36
- package/references/sessionlog/src/utils/hook-managers.ts +0 -125
- package/references/sessionlog/src/utils/ide-tags.ts +0 -32
- package/references/sessionlog/src/utils/paths.ts +0 -79
- package/references/sessionlog/src/utils/preview-rewind.ts +0 -80
- package/references/sessionlog/src/utils/rewind-conflict.ts +0 -121
- package/references/sessionlog/src/utils/shadow-branch.ts +0 -109
- package/references/sessionlog/src/utils/string-utils.ts +0 -46
- package/references/sessionlog/src/utils/todo-extract.ts +0 -188
- package/references/sessionlog/src/utils/trailers.ts +0 -187
- package/references/sessionlog/src/utils/transcript-parse.ts +0 -177
- package/references/sessionlog/src/utils/transcript-timestamp.ts +0 -59
- package/references/sessionlog/src/utils/tree-ops.ts +0 -219
- package/references/sessionlog/src/utils/tty.ts +0 -72
- package/references/sessionlog/src/utils/validation.ts +0 -65
- package/references/sessionlog/src/utils/worktree.ts +0 -58
- package/references/sessionlog/src/wire-types.ts +0 -59
- package/references/sessionlog/templates/setup-env.sh +0 -153
- package/references/sessionlog/tsconfig.json +0 -18
- package/references/sessionlog/vitest.config.ts +0 -12
- package/references/skill-tree/.claude/settings.json +0 -6
- package/references/skill-tree/.sudocode/issues.jsonl +0 -19
- package/references/skill-tree/.sudocode/specs.jsonl +0 -3
- package/references/skill-tree/CLAUDE.md +0 -126
- package/references/skill-tree/README.md +0 -372
- package/references/skill-tree/docs/GAPS_v1.md +0 -221
- package/references/skill-tree/docs/INTEGRATION_PLAN.md +0 -467
- package/references/skill-tree/docs/TODOS.md +0 -91
- package/references/skill-tree/docs/anthropic_skill_guide.md +0 -1364
- package/references/skill-tree/docs/design/federated-skill-trees.md +0 -524
- package/references/skill-tree/docs/design/multi-agent-sync.md +0 -759
- package/references/skill-tree/docs/scraper/BRAINSTORM.md +0 -583
- package/references/skill-tree/docs/scraper/POC_PLAN.md +0 -420
- package/references/skill-tree/docs/scraper/README.md +0 -170
- package/references/skill-tree/examples/basic-usage.ts +0 -164
- package/references/skill-tree/package-lock.json +0 -1852
- package/references/skill-tree/package.json +0 -66
- package/references/skill-tree/scraper/README.md +0 -123
- package/references/skill-tree/scraper/docs/DESIGN.md +0 -683
- package/references/skill-tree/scraper/docs/PLAN.md +0 -336
- package/references/skill-tree/scraper/drizzle.config.ts +0 -10
- package/references/skill-tree/scraper/package-lock.json +0 -6329
- package/references/skill-tree/scraper/package.json +0 -68
- package/references/skill-tree/scraper/test/fixtures/invalid-skill/missing-description.md +0 -7
- package/references/skill-tree/scraper/test/fixtures/invalid-skill/missing-name.md +0 -7
- package/references/skill-tree/scraper/test/fixtures/minimal-skill/SKILL.md +0 -27
- package/references/skill-tree/scraper/test/fixtures/skill-json/SKILL.json +0 -21
- package/references/skill-tree/scraper/test/fixtures/skill-with-meta/SKILL.md +0 -54
- package/references/skill-tree/scraper/test/fixtures/skill-with-meta/_meta.json +0 -24
- package/references/skill-tree/scraper/test/fixtures/valid-skill/SKILL.md +0 -93
- package/references/skill-tree/scraper/test/fixtures/valid-skill/_meta.json +0 -22
- package/references/skill-tree/scraper/tsup.config.ts +0 -14
- package/references/skill-tree/scraper/vitest.config.ts +0 -17
- package/references/skill-tree/scripts/convert-to-vitest.ts +0 -166
- package/references/skill-tree/skills/skill-writer/SKILL.md +0 -339
- package/references/skill-tree/skills/skill-writer/references/examples.md +0 -326
- package/references/skill-tree/skills/skill-writer/references/patterns.md +0 -210
- package/references/skill-tree/skills/skill-writer/references/quality-checklist.md +0 -123
- package/references/skill-tree/test/run-all.ts +0 -106
- package/references/skill-tree/test/utils.ts +0 -128
- package/references/skill-tree/vitest.config.ts +0 -16
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "bug-reproduction",
|
|
3
|
+
"curatedBy": "compound-engineering",
|
|
4
|
+
"confidence": 0.8,
|
|
5
|
+
"complexity": "moderate",
|
|
6
|
+
"estimatedEffort": 5,
|
|
7
|
+
"applicability": {
|
|
8
|
+
"situations": [
|
|
9
|
+
"Investigating a reported bug to find root cause and reproduction steps",
|
|
10
|
+
"Debugging issues with unclear or incomplete reproduction information",
|
|
11
|
+
"Systematically narrowing down failure conditions through hypothesis-driven investigation"
|
|
12
|
+
],
|
|
13
|
+
"triggers": [
|
|
14
|
+
"reproduce bug",
|
|
15
|
+
"investigate issue",
|
|
16
|
+
"debug",
|
|
17
|
+
"root cause",
|
|
18
|
+
"bug report"
|
|
19
|
+
],
|
|
20
|
+
"antiPatterns": [
|
|
21
|
+
"Starting investigation without forming hypotheses first",
|
|
22
|
+
"Trying all possible paths without ranking by likelihood",
|
|
23
|
+
"Making code changes before confirming root cause"
|
|
24
|
+
],
|
|
25
|
+
"domains": ["debugging", "investigation", "software-engineering"]
|
|
26
|
+
},
|
|
27
|
+
"guidance": {
|
|
28
|
+
"strategy": "Hypothesis-driven investigation: understand the report, form ranked hypotheses, reproduce via the most efficient route (test, browser, or manual), trace the code path, and document everything before proposing a fix.",
|
|
29
|
+
"tactics": [
|
|
30
|
+
"Phase 1 — Understand: extract reported symptoms, expected behavior, reproduction steps, environment clues, and frequency from the issue/report",
|
|
31
|
+
"Phase 2 — Hypothesize: search for relevant code (error messages, feature names, route paths, model/service names), form 2-3 hypotheses about what might be wrong and where in the codebase, rank by likelihood",
|
|
32
|
+
"Phase 3 — Reproduce: choose the most efficient route: (A) test-based — find existing tests, run them, write a failing test if needed; (B) browser-based — follow reported steps in the UI; (C) manual — document conditions and guide through steps. Prefer test-based for fastest feedback",
|
|
33
|
+
"Phase 4 — Investigate: check logs, error tracking, database state, request/response cycle; trace the code path from entry point; check recent changes with git log on affected files",
|
|
34
|
+
"Phase 5 — Document: record root cause (file:line), confirmed reproduction steps, evidence collected, suggested fix approach, and open questions. Present findings before taking action",
|
|
35
|
+
"Always confirm root cause before proposing or implementing a fix",
|
|
36
|
+
"Use native search tools (not shell pipes) for code exploration"
|
|
37
|
+
],
|
|
38
|
+
"steps": [
|
|
39
|
+
"1. Read the bug report — extract symptoms, expected behavior, steps, environment, frequency",
|
|
40
|
+
"2. Search codebase for relevant code paths (error messages, feature names, routes)",
|
|
41
|
+
"3. Form 2-3 hypotheses, ranked by likelihood",
|
|
42
|
+
"4. Attempt reproduction via most efficient route (test > browser > manual)",
|
|
43
|
+
"5. Trace code path from entry point, check logs and recent git changes",
|
|
44
|
+
"6. Document: root cause, reproduction steps, evidence, suggested fix, open questions",
|
|
45
|
+
"7. Present findings before taking any action"
|
|
46
|
+
]
|
|
47
|
+
},
|
|
48
|
+
"verification": {
|
|
49
|
+
"successIndicators": [
|
|
50
|
+
"Root cause identified with specific file and line reference",
|
|
51
|
+
"Reproduction is confirmed and steps are documented",
|
|
52
|
+
"Hypotheses were formed before investigation, not after",
|
|
53
|
+
"Findings documented before proposing a fix"
|
|
54
|
+
],
|
|
55
|
+
"failureIndicators": [
|
|
56
|
+
"Investigation started without structured hypotheses",
|
|
57
|
+
"Code changes proposed before root cause confirmed",
|
|
58
|
+
"Reproduction steps are vague or unconfirmed",
|
|
59
|
+
"Only one hypothesis considered without exploring alternatives"
|
|
60
|
+
]
|
|
61
|
+
}
|
|
62
|
+
}
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "confidence-calibration",
|
|
3
|
+
"curatedBy": "compound-engineering",
|
|
4
|
+
"confidence": 0.9,
|
|
5
|
+
"complexity": "simple",
|
|
6
|
+
"estimatedEffort": 1,
|
|
7
|
+
"applicability": {
|
|
8
|
+
"situations": [
|
|
9
|
+
"Any task producing findings, recommendations, or assessments that need confidence scoring",
|
|
10
|
+
"Code review findings that could be false positives",
|
|
11
|
+
"Analysis results where certainty varies across findings"
|
|
12
|
+
],
|
|
13
|
+
"triggers": [
|
|
14
|
+
"confidence score",
|
|
15
|
+
"how sure",
|
|
16
|
+
"false positive",
|
|
17
|
+
"suppress low confidence"
|
|
18
|
+
],
|
|
19
|
+
"antiPatterns": [
|
|
20
|
+
"Binary pass/fail assessments where confidence doesn't apply",
|
|
21
|
+
"Objective facts that are either true or false (syntax errors, type mismatches)"
|
|
22
|
+
],
|
|
23
|
+
"domains": ["quality-assurance", "code-review", "analysis"]
|
|
24
|
+
},
|
|
25
|
+
"guidance": {
|
|
26
|
+
"strategy": "Apply a three-tier confidence model to all findings. Suppress anything below 0.60 to prevent noise. Be transparent about what tier each finding falls into.",
|
|
27
|
+
"tactics": [
|
|
28
|
+
"HIGH confidence (0.80+): Finding is provable from available evidence alone; full execution/reasoning path is visible; no external context needed to confirm",
|
|
29
|
+
"MODERATE confidence (0.60-0.79): Finding likely but depends on conditions not directly visible; needs context from calling code, runtime state, or configuration to fully confirm",
|
|
30
|
+
"LOW confidence (below 0.60): Finding requires runtime observation, specific input shapes, or environmental conditions to confirm — SUPPRESS these findings entirely",
|
|
31
|
+
"When in doubt about tier, choose the lower one — false negatives (missing a real issue) are less damaging than false positives (noise that erodes trust)",
|
|
32
|
+
"Report suppressed count so reviewers know what was filtered and can request expansion if needed",
|
|
33
|
+
"Severity and confidence are independent axes: a P0 at 0.55 confidence should still be suppressed"
|
|
34
|
+
]
|
|
35
|
+
},
|
|
36
|
+
"verification": {
|
|
37
|
+
"successIndicators": [
|
|
38
|
+
"All findings include explicit confidence scores",
|
|
39
|
+
"No findings below 0.60 confidence in final output",
|
|
40
|
+
"Suppressed count reported for transparency",
|
|
41
|
+
"High-confidence findings are all provable without runtime context"
|
|
42
|
+
],
|
|
43
|
+
"failureIndicators": [
|
|
44
|
+
"Findings with 'might', 'could', 'possibly' language but no confidence score",
|
|
45
|
+
"Low-confidence findings not suppressed, adding noise",
|
|
46
|
+
"Confidence score inflated to avoid suppression"
|
|
47
|
+
]
|
|
48
|
+
}
|
|
49
|
+
}
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "correctness-review",
|
|
3
|
+
"curatedBy": "compound-engineering",
|
|
4
|
+
"confidence": 0.85,
|
|
5
|
+
"complexity": "moderate",
|
|
6
|
+
"estimatedEffort": 3,
|
|
7
|
+
"applicability": {
|
|
8
|
+
"situations": [
|
|
9
|
+
"Reviewing code changes for logical correctness",
|
|
10
|
+
"Hunting for runtime bugs before they reach production",
|
|
11
|
+
"Verifying behavioral correctness of new or changed code paths"
|
|
12
|
+
],
|
|
13
|
+
"triggers": [
|
|
14
|
+
"code review",
|
|
15
|
+
"logic error",
|
|
16
|
+
"bug hunt",
|
|
17
|
+
"correctness check"
|
|
18
|
+
],
|
|
19
|
+
"antiPatterns": [
|
|
20
|
+
"Style or formatting reviews — use maintainability review instead",
|
|
21
|
+
"Test coverage analysis — use testing review instead",
|
|
22
|
+
"Performance optimization — use performance review instead"
|
|
23
|
+
],
|
|
24
|
+
"domains": ["code-review", "debugging", "quality-assurance"]
|
|
25
|
+
},
|
|
26
|
+
"guidance": {
|
|
27
|
+
"strategy": "Mentally execute code with concrete values. Trace inputs through every branch. Ask 'what happens when X is null/empty/zero/negative/concurrent'. Focus exclusively on behavioral correctness, not style.",
|
|
28
|
+
"tactics": [
|
|
29
|
+
"Hunt for: off-by-one errors, null/undefined propagation, race conditions, ordering assumptions, incorrect state transitions, broken error propagation, TOCTOU gaps",
|
|
30
|
+
"Mental execution discipline: follow state changes step by step, check loop bounds with boundary values (0, 1, N-1, N, N+1), trace async completion ordering",
|
|
31
|
+
"For each finding, trace the full execution path from input to bug — it must be reproducible from code alone",
|
|
32
|
+
"Confidence calibration: HIGH (0.80+) when full execution path is visible and bug is reproducible from code alone; MODERATE (0.60-0.79) when bug depends on conditions in calling code not visible in diff; suppress below 0.60",
|
|
33
|
+
"Never flag defensive coding that isn't needed — only flag actual bugs with concrete trigger conditions",
|
|
34
|
+
"Focus on semantic issues that linters cannot catch"
|
|
35
|
+
]
|
|
36
|
+
},
|
|
37
|
+
"verification": {
|
|
38
|
+
"successIndicators": [
|
|
39
|
+
"Finding traces specific input through specific branch to specific wrong output",
|
|
40
|
+
"Bug is reproducible by reading the code alone without runtime context",
|
|
41
|
+
"No false positives from style, naming, or lint-catchable issues"
|
|
42
|
+
],
|
|
43
|
+
"failureIndicators": [
|
|
44
|
+
"Finding requires runtime conditions or specific input shapes that aren't provable from code",
|
|
45
|
+
"Finding is actually a style preference disguised as a correctness issue",
|
|
46
|
+
"Confidence is below 0.60 but finding was not suppressed"
|
|
47
|
+
]
|
|
48
|
+
}
|
|
49
|
+
}
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "data-migration-safety",
|
|
3
|
+
"curatedBy": "compound-engineering",
|
|
4
|
+
"confidence": 0.85,
|
|
5
|
+
"complexity": "complex",
|
|
6
|
+
"estimatedEffort": 6,
|
|
7
|
+
"applicability": {
|
|
8
|
+
"situations": [
|
|
9
|
+
"Reviewing database migrations, schema changes, or data backfills",
|
|
10
|
+
"Validating data transformation correctness against production data",
|
|
11
|
+
"Ensuring rollback safety and referential integrity during migrations"
|
|
12
|
+
],
|
|
13
|
+
"triggers": [
|
|
14
|
+
"migration",
|
|
15
|
+
"schema change",
|
|
16
|
+
"backfill",
|
|
17
|
+
"column drop",
|
|
18
|
+
"data transform",
|
|
19
|
+
"ALTER TABLE"
|
|
20
|
+
],
|
|
21
|
+
"antiPatterns": [
|
|
22
|
+
"Adding nullable columns (safe by definition)",
|
|
23
|
+
"Adding indexes on small or low-traffic tables",
|
|
24
|
+
"Test database changes (fixtures, test setup, seed files)",
|
|
25
|
+
"Purely additive schema changes (new tables, new columns with defaults)"
|
|
26
|
+
],
|
|
27
|
+
"domains": ["code-review", "database", "data-safety", "quality-assurance"]
|
|
28
|
+
},
|
|
29
|
+
"guidance": {
|
|
30
|
+
"strategy": "Verify mappings against production data, never fixtures. The single most common migration bug is swapped/inverted ID mappings. Every migration needs a rollback plan and post-deploy verification SQL queries.",
|
|
31
|
+
"tactics": [
|
|
32
|
+
"Swapped mappings (THE most common bug): verify CASE/IF branches map IDs correctly — check that '1 => TypeA, 2 => TypeB' in code matches production, not the reverse. Flag hard-coded mapping constants without verification against live data",
|
|
33
|
+
"Irreversible migrations: flag column drops, type changes losing precision (float→integer), string length reductions (text→varchar(255)), constraint additions that may violate existing data — require explicit rollback plan or acknowledgment",
|
|
34
|
+
"Missing backfill: flag NOT NULL columns added without defaults or backfill plan; flag renamed columns still referenced by old code, serializers, API responses, or background jobs",
|
|
35
|
+
"Deploy-window safety: detect schema changes that break running code during deployment (column removed before code deployed, constraint added while violating rows exist)",
|
|
36
|
+
"Transaction boundaries: flag multi-table updates without transaction wrapping; verify atomic operations on related tables",
|
|
37
|
+
"Index locking: flag index creation on large frequently-written tables without concurrent/online option",
|
|
38
|
+
"Referential integrity: check for orphaned references after column/table drops; verify cascade behavior; flag polymorphic associations lacking integrity checks",
|
|
39
|
+
"Dual-write validation: during transition periods verify both old and new columns are written for all code paths (not just new records)",
|
|
40
|
+
"Privacy/compliance: identify PII in new columns, verify encryption for sensitive fields, check GDPR retention policies",
|
|
41
|
+
"Post-deploy verification: require concrete SQL queries to verify data invariants remain true after migration",
|
|
42
|
+
"Confidence calibration: HIGH (0.80+) when migration DDL is directly in diff; MODERATE (0.60-0.79) when inferring data impact from application code; suppress below 0.60"
|
|
43
|
+
]
|
|
44
|
+
},
|
|
45
|
+
"verification": {
|
|
46
|
+
"successIndicators": [
|
|
47
|
+
"Mapping correctness verified against production data, not fixtures",
|
|
48
|
+
"Rollback plan exists for every destructive operation",
|
|
49
|
+
"Post-deploy verification SQL queries are concrete and runnable",
|
|
50
|
+
"Transaction boundaries cover all multi-step transforms"
|
|
51
|
+
],
|
|
52
|
+
"failureIndicators": [
|
|
53
|
+
"Mappings trusted from fixtures or hardcoded constants without production verification",
|
|
54
|
+
"Irreversible migration without explicit acknowledgment or rollback plan",
|
|
55
|
+
"Missing post-deploy verification queries",
|
|
56
|
+
"Index creation on hot table without concurrent option"
|
|
57
|
+
]
|
|
58
|
+
}
|
|
59
|
+
}
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "deployment-verification",
|
|
3
|
+
"curatedBy": "compound-engineering",
|
|
4
|
+
"confidence": 0.8,
|
|
5
|
+
"complexity": "moderate",
|
|
6
|
+
"estimatedEffort": 4,
|
|
7
|
+
"applicability": {
|
|
8
|
+
"situations": [
|
|
9
|
+
"Preparing Go/No-Go checklists for risky deployments",
|
|
10
|
+
"Creating pre-deploy and post-deploy verification SQL queries",
|
|
11
|
+
"Planning rollback procedures and monitoring for data-affecting changes"
|
|
12
|
+
],
|
|
13
|
+
"triggers": [
|
|
14
|
+
"deployment checklist",
|
|
15
|
+
"go/no-go",
|
|
16
|
+
"deploy verification",
|
|
17
|
+
"pre-deploy",
|
|
18
|
+
"post-deploy monitoring"
|
|
19
|
+
],
|
|
20
|
+
"antiPatterns": [
|
|
21
|
+
"Routine deployments with no data or schema changes",
|
|
22
|
+
"Feature flag rollouts that are trivially reversible",
|
|
23
|
+
"Documentation-only or test-only changes"
|
|
24
|
+
],
|
|
25
|
+
"domains": ["deployment", "operations", "data-safety"]
|
|
26
|
+
},
|
|
27
|
+
"guidance": {
|
|
28
|
+
"strategy": "Transform abstract 'be careful with data' into executable checklists with concrete SQL verification queries, rollback procedures, and monitoring plans. Every risky deployment gets a Go/No-Go checklist.",
|
|
29
|
+
"tactics": [
|
|
30
|
+
"Define data invariants: document specific properties that must remain true (e.g., 'every order has exactly one payment record', 'no user has null email')",
|
|
31
|
+
"Pre-deploy baseline: write read-only SQL queries that capture current state of invariants — save results for post-deploy comparison",
|
|
32
|
+
"Destructive steps: document each step with runtime estimate, batching requirements (batch size, sleep between batches), and explicit rollback procedure",
|
|
33
|
+
"Index locking: assess lock time for index creation on large tables; use concurrent/online options where available",
|
|
34
|
+
"Post-deploy verification: SQL queries to run within 5 minutes of deployment confirming invariants still hold and new data is correct",
|
|
35
|
+
"Rollback plan: for each migration step, document whether rollback is full/partial/impossible with explicit steps (not vague 'restore from backup')",
|
|
36
|
+
"Post-deploy monitoring (24 hours): define specific metrics to watch, dashboard links, healthy signal baselines, alert thresholds, and failure triggers",
|
|
37
|
+
"Console verification: include spot-check commands (Rails console, SQL queries) for manual verification"
|
|
38
|
+
],
|
|
39
|
+
"steps": [
|
|
40
|
+
"1. Identify data invariants that must remain true",
|
|
41
|
+
"2. Write pre-deploy baseline SQL queries (read-only)",
|
|
42
|
+
"3. Document each destructive step with runtime estimate and batching",
|
|
43
|
+
"4. Write rollback procedure for each step (full/partial/impossible)",
|
|
44
|
+
"5. Write post-deploy verification SQL queries (run within 5 minutes)",
|
|
45
|
+
"6. Define monitoring plan: metrics, dashboards, thresholds, failure triggers (24 hours)",
|
|
46
|
+
"7. Compile Go/No-Go checklist for deployment day"
|
|
47
|
+
]
|
|
48
|
+
},
|
|
49
|
+
"verification": {
|
|
50
|
+
"successIndicators": [
|
|
51
|
+
"Data invariants explicitly documented with SQL verification queries",
|
|
52
|
+
"Pre-deploy baselines captured for post-deploy comparison",
|
|
53
|
+
"Rollback procedures are concrete and tested, not vague",
|
|
54
|
+
"Monitoring plan has specific metrics, thresholds, and 24-hour window"
|
|
55
|
+
],
|
|
56
|
+
"failureIndicators": [
|
|
57
|
+
"No data invariants defined — deploying blind",
|
|
58
|
+
"Rollback plan says 'restore from backup' without concrete steps",
|
|
59
|
+
"Post-deploy verification missing or scheduled for 'later'",
|
|
60
|
+
"Monitoring plan lacks specific alert thresholds"
|
|
61
|
+
]
|
|
62
|
+
}
|
|
63
|
+
}
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "error-recovery-patterns",
|
|
3
|
+
"curatedBy": "compound-engineering",
|
|
4
|
+
"confidence": 0.75,
|
|
5
|
+
"complexity": "moderate",
|
|
6
|
+
"estimatedEffort": 3,
|
|
7
|
+
"applicability": {
|
|
8
|
+
"situations": [
|
|
9
|
+
"Diagnosing and recovering from common error categories in agent task execution",
|
|
10
|
+
"Applying structured error classification to choose the right recovery strategy",
|
|
11
|
+
"Learning from failure→recovery trajectories to build causal knowledge"
|
|
12
|
+
],
|
|
13
|
+
"triggers": [
|
|
14
|
+
"error recovery",
|
|
15
|
+
"task failure",
|
|
16
|
+
"retry strategy",
|
|
17
|
+
"error classification",
|
|
18
|
+
"recovery pattern"
|
|
19
|
+
],
|
|
20
|
+
"antiPatterns": [
|
|
21
|
+
"Retrying the identical action without diagnosing the root cause",
|
|
22
|
+
"Classifying errors locally instead of using the shared error classifier",
|
|
23
|
+
"Ignoring the causal store when a similar failure→recovery pattern already exists"
|
|
24
|
+
],
|
|
25
|
+
"domains": ["debugging", "error-handling", "agent-execution"]
|
|
26
|
+
},
|
|
27
|
+
"guidance": {
|
|
28
|
+
"strategy": "Classify the error using the canonical error taxonomy, check the causal store for known recovery patterns, then apply the appropriate recovery strategy. Every failure→recovery pair becomes a causal edge for future learning.",
|
|
29
|
+
"tactics": [
|
|
30
|
+
"Error classification: use the canonical types — syntax-error, type-error, runtime-error, logic-error, environment-error, dependency-error, configuration-error, timeout-error, permission-error, resource-error, unknown-error",
|
|
31
|
+
"Before retrying: check the causal store for existing failure→recovery edges matching this error type and context; reuse known recovery patterns rather than rediscovering them",
|
|
32
|
+
"Recovery strategies by class: syntax/type errors → fix the specific code; runtime/logic errors → trace the execution path, add assertions; environment/dependency/config errors → verify setup before retrying; timeout/resource errors → adjust limits or batch size; permission errors → check and request access",
|
|
33
|
+
"Avoid repeated actions: if the same action has been tried 3+ times without progress, escalate to a different strategy rather than retrying",
|
|
34
|
+
"Extract tool names and action patterns from the trajectory to detect loops early",
|
|
35
|
+
"After successful recovery: record the failure→recovery pair as a causal edge so future encounters can shortcut to the solution",
|
|
36
|
+
"Reflexion: generate a reflexion episode capturing what went wrong, what the recovery was, and what to do differently next time"
|
|
37
|
+
]
|
|
38
|
+
},
|
|
39
|
+
"verification": {
|
|
40
|
+
"successIndicators": [
|
|
41
|
+
"Error classified using canonical taxonomy, not ad-hoc categories",
|
|
42
|
+
"Causal store checked before attempting recovery",
|
|
43
|
+
"Recovery strategy matches the error class",
|
|
44
|
+
"Failure→recovery pair recorded as causal edge after successful resolution"
|
|
45
|
+
],
|
|
46
|
+
"failureIndicators": [
|
|
47
|
+
"Same action retried 3+ times without changing strategy",
|
|
48
|
+
"Error classified with local ad-hoc logic instead of shared classifier",
|
|
49
|
+
"Known recovery pattern in causal store was ignored",
|
|
50
|
+
"Successful recovery not recorded — knowledge lost"
|
|
51
|
+
]
|
|
52
|
+
}
|
|
53
|
+
}
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "implementation-planning",
|
|
3
|
+
"curatedBy": "compound-engineering",
|
|
4
|
+
"confidence": 0.8,
|
|
5
|
+
"complexity": "complex",
|
|
6
|
+
"estimatedEffort": 8,
|
|
7
|
+
"applicability": {
|
|
8
|
+
"situations": [
|
|
9
|
+
"Creating a structured implementation plan from requirements",
|
|
10
|
+
"Technical planning before code execution",
|
|
11
|
+
"Establishing architecture, patterns, and test strategy before work starts"
|
|
12
|
+
],
|
|
13
|
+
"triggers": [
|
|
14
|
+
"create plan",
|
|
15
|
+
"implementation plan",
|
|
16
|
+
"plan this feature",
|
|
17
|
+
"how to implement",
|
|
18
|
+
"technical plan"
|
|
19
|
+
],
|
|
20
|
+
"antiPatterns": [
|
|
21
|
+
"Requirements are unclear — brainstorm first",
|
|
22
|
+
"Trivial change that doesn't need a plan (single file, obvious fix)",
|
|
23
|
+
"Runtime discovery needed — some things must be learned by doing, not planned"
|
|
24
|
+
],
|
|
25
|
+
"domains": ["planning", "architecture", "software-engineering"]
|
|
26
|
+
},
|
|
27
|
+
"guidance": {
|
|
28
|
+
"strategy": "Research-then-structure: parallel research (repo patterns + institutional knowledge + external best practices) before structuring the plan. Plans are decision artifacts, not instruction scripts — they document what and why, not line-by-line how.",
|
|
29
|
+
"tactics": [
|
|
30
|
+
"Research phase: run repo-research (patterns, conventions, existing code) and learnings-research (past solutions, known gotchas) in parallel; conditionally add external research for security, payments, APIs, migrations, compliance",
|
|
31
|
+
"Requirements traceability: carry forward all decisions from requirements; preserve blocked vs deferred questions",
|
|
32
|
+
"Decompose into implementation units: logical clusters (not micro-steps); each unit has Goal, Patterns to follow, Approach, Files, Test scenarios, Verification, Dependencies",
|
|
33
|
+
"Test scenario specificity: name exact inputs and expected outcomes, not generic 'validates correctly'",
|
|
34
|
+
"Execution posture signals: annotate units with test-first, characterization-first, or external-delegate when signals are clear",
|
|
35
|
+
"Reference actual files in the repo for patterns to follow — don't invent from scratch",
|
|
36
|
+
"Depth classification: lightweight (brief, <1hr), standard (structured, 1-3hrs), deep (full research + options analysis, 3hrs+)",
|
|
37
|
+
"Plans must contain decisions with rationale, not just task lists"
|
|
38
|
+
],
|
|
39
|
+
"steps": [
|
|
40
|
+
"1. Assess scope and depth classification (lightweight/standard/deep)",
|
|
41
|
+
"2. Research: repo patterns + institutional knowledge + external guidance (in parallel)",
|
|
42
|
+
"3. Resolve planning questions — separate 'resolve now' from 'deferred to implementation'",
|
|
43
|
+
"4. Structure plan into implementation units with dependencies",
|
|
44
|
+
"5. Deep-dive each unit: concrete file paths, test file paths, exact test scenarios",
|
|
45
|
+
"6. Confidence check: verify sequencing, risk mitigation, unknown handling",
|
|
46
|
+
"7. Finalize with explicit ordering and execution posture signals"
|
|
47
|
+
]
|
|
48
|
+
},
|
|
49
|
+
"verification": {
|
|
50
|
+
"successIndicators": [
|
|
51
|
+
"All requirements traced to implementation units",
|
|
52
|
+
"Each unit has concrete file paths and exact test scenarios (not generic)",
|
|
53
|
+
"Decisions documented with rationale",
|
|
54
|
+
"Dependencies explicitly ordered",
|
|
55
|
+
"Pattern references point to actual files in the repo"
|
|
56
|
+
],
|
|
57
|
+
"failureIndicators": [
|
|
58
|
+
"Plan contains pre-written implementation code (should be decisions, not code)",
|
|
59
|
+
"Test scenarios say 'validates correctly' without naming inputs and expected outputs",
|
|
60
|
+
"Pattern references are invented, not sourced from existing codebase",
|
|
61
|
+
"Requirements not traceable to implementation units"
|
|
62
|
+
]
|
|
63
|
+
}
|
|
64
|
+
}
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "issue-pattern-analysis",
|
|
3
|
+
"curatedBy": "compound-engineering",
|
|
4
|
+
"confidence": 0.8,
|
|
5
|
+
"complexity": "moderate",
|
|
6
|
+
"estimatedEffort": 4,
|
|
7
|
+
"applicability": {
|
|
8
|
+
"situations": [
|
|
9
|
+
"Analyzing GitHub issues to identify systemic themes rather than individual bugs",
|
|
10
|
+
"Understanding user pain patterns for planning and prioritization",
|
|
11
|
+
"Detecting recurring problems that indicate architectural weaknesses"
|
|
12
|
+
],
|
|
13
|
+
"triggers": [
|
|
14
|
+
"issue analysis",
|
|
15
|
+
"bug patterns",
|
|
16
|
+
"systemic issues",
|
|
17
|
+
"issue themes",
|
|
18
|
+
"user pain"
|
|
19
|
+
],
|
|
20
|
+
"antiPatterns": [
|
|
21
|
+
"Analyzing issues one by one instead of clustering into themes",
|
|
22
|
+
"Creating themes from closed-only issues with zero open support",
|
|
23
|
+
"Over-granular clustering (more than 8 themes obscures signal)"
|
|
24
|
+
],
|
|
25
|
+
"domains": ["planning", "analysis", "project-management"]
|
|
26
|
+
},
|
|
27
|
+
"guidance": {
|
|
28
|
+
"strategy": "Cluster issues by root cause or system area, not by symptom. Distinguish open from recently-closed issues to detect recurrence. Produce 3-8 themes with quantified impact and trend direction.",
|
|
29
|
+
"tactics": [
|
|
30
|
+
"Token-efficient fetching: scan labels first, fetch high-priority issues, backfill remaining, fetch recently closed (last 30 days) for recurrence signal, deduplicate",
|
|
31
|
+
"Cluster by theme: group by root cause or system area, not surface symptom; use labels as hints but don't over-rely; separate bugs from enhancements",
|
|
32
|
+
"Recurrence detection: check recently closed issues for themes that keep coming back — recurrence is a stronger signal than open count alone",
|
|
33
|
+
"Theme structure: for each theme provide title, description, why it matters, issue count, source mix (open vs closed), trend direction (growing/stable/declining), representative issues, and confidence",
|
|
34
|
+
"Target 3-8 themes: fewer than 3 means clustering is too coarse; more than 8 means too granular for strategic signal",
|
|
35
|
+
"Data integrity: never fabricate statistics not computed from actual data; all counts and trends must be derivable from the issues analyzed",
|
|
36
|
+
"Do not let closed-only issues create new themes — they must have open issue support"
|
|
37
|
+
]
|
|
38
|
+
},
|
|
39
|
+
"verification": {
|
|
40
|
+
"successIndicators": [
|
|
41
|
+
"3-8 themes identified with quantified impact",
|
|
42
|
+
"Themes clustered by root cause, not symptom",
|
|
43
|
+
"Recurrence patterns detected from recently-closed issues",
|
|
44
|
+
"All statistics derivable from actual issue data"
|
|
45
|
+
],
|
|
46
|
+
"failureIndicators": [
|
|
47
|
+
"Issues listed individually instead of clustered into themes",
|
|
48
|
+
"Themes based on closed-only issues with no open support",
|
|
49
|
+
"More than 8 themes (too granular for strategic planning)",
|
|
50
|
+
"Fabricated or estimated statistics not computed from data"
|
|
51
|
+
]
|
|
52
|
+
}
|
|
53
|
+
}
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "knowledge-compounding",
|
|
3
|
+
"curatedBy": "compound-engineering",
|
|
4
|
+
"confidence": 0.8,
|
|
5
|
+
"complexity": "moderate",
|
|
6
|
+
"estimatedEffort": 5,
|
|
7
|
+
"applicability": {
|
|
8
|
+
"situations": [
|
|
9
|
+
"Documenting a solved problem while context is fresh",
|
|
10
|
+
"Extracting reusable knowledge from debugging sessions",
|
|
11
|
+
"Preventing repeated mistakes by compounding institutional knowledge"
|
|
12
|
+
],
|
|
13
|
+
"triggers": [
|
|
14
|
+
"problem solved",
|
|
15
|
+
"that worked",
|
|
16
|
+
"it's fixed",
|
|
17
|
+
"document solution",
|
|
18
|
+
"compound knowledge"
|
|
19
|
+
],
|
|
20
|
+
"antiPatterns": [
|
|
21
|
+
"Problem is not fully solved and verified — don't document partial solutions",
|
|
22
|
+
"Trivial fix that doesn't generalize (typo, missing import)",
|
|
23
|
+
"Solution is identical to an existing documented solution"
|
|
24
|
+
],
|
|
25
|
+
"domains": ["knowledge-management", "documentation", "learning"]
|
|
26
|
+
},
|
|
27
|
+
"guidance": {
|
|
28
|
+
"strategy": "Use parallel extraction agents (Context Analyzer + Solution Extractor) to capture the problem and solution, then check for overlap with existing knowledge before writing. Update existing docs when overlap is high rather than creating duplicates.",
|
|
29
|
+
"tactics": [
|
|
30
|
+
"Phase 0.5: Scan existing knowledge for related entries using grep-first filtering on frontmatter fields (title, tags, module, component)",
|
|
31
|
+
"Phase 1: Run Context Analyzer (extract problem, symptoms, category, affected files) and Solution Extractor (root cause, solution steps, prevention rules, test cases) in parallel — they return text only, no file writes",
|
|
32
|
+
"Phase 2: Assess overlap with existing docs on 5 dimensions: problem statement, root cause, solution approach, referenced files, prevention rules",
|
|
33
|
+
"High overlap (4-5 dimensions match): update existing document instead of creating new one",
|
|
34
|
+
"Moderate overlap (2-3 dimensions): create new document but flag for later consolidation",
|
|
35
|
+
"Low/no overlap: create new document",
|
|
36
|
+
"Single file write guarantee: only the orchestrator writes output, subagents return text",
|
|
37
|
+
"Include all required sections: Problem, Symptoms, What Didn't Work, Solution, Why This Works, Prevention (with code examples)"
|
|
38
|
+
],
|
|
39
|
+
"steps": [
|
|
40
|
+
"1. Grep existing knowledge for related entries by keywords, tags, and module",
|
|
41
|
+
"2. Extract context (problem, symptoms, category) and solution (root cause, fix, prevention) in parallel",
|
|
42
|
+
"3. Score overlap with found entries on 5 dimensions",
|
|
43
|
+
"4. If high overlap, update existing entry with new information",
|
|
44
|
+
"5. If low overlap, create new entry with YAML frontmatter (category, problem_type, tags, severity, module)",
|
|
45
|
+
"6. Add cross-links to related entries"
|
|
46
|
+
]
|
|
47
|
+
},
|
|
48
|
+
"verification": {
|
|
49
|
+
"successIndicators": [
|
|
50
|
+
"Knowledge entry created/updated with valid frontmatter",
|
|
51
|
+
"All required sections present with specific details (not generic text)",
|
|
52
|
+
"Overlap assessment performed — no unnecessary duplicates",
|
|
53
|
+
"Prevention section includes concrete, actionable rules",
|
|
54
|
+
"Cross-links connect to related existing entries"
|
|
55
|
+
],
|
|
56
|
+
"failureIndicators": [
|
|
57
|
+
"Duplicate of existing entry created without overlap check",
|
|
58
|
+
"Solution section is vague or lacks root cause explanation",
|
|
59
|
+
"Missing prevention rules — knowledge won't prevent future recurrence",
|
|
60
|
+
"Problem wasn't actually solved before documenting"
|
|
61
|
+
]
|
|
62
|
+
}
|
|
63
|
+
}
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "learnings-research",
|
|
3
|
+
"curatedBy": "compound-engineering",
|
|
4
|
+
"confidence": 0.85,
|
|
5
|
+
"complexity": "moderate",
|
|
6
|
+
"estimatedEffort": 3,
|
|
7
|
+
"applicability": {
|
|
8
|
+
"situations": [
|
|
9
|
+
"Looking up institutional knowledge before starting work",
|
|
10
|
+
"Finding past solutions for similar problems during debugging",
|
|
11
|
+
"Preventing repeated mistakes by surfacing known patterns and gotchas"
|
|
12
|
+
],
|
|
13
|
+
"triggers": [
|
|
14
|
+
"search knowledge",
|
|
15
|
+
"past solutions",
|
|
16
|
+
"known issues",
|
|
17
|
+
"institutional knowledge",
|
|
18
|
+
"what do we know about"
|
|
19
|
+
],
|
|
20
|
+
"antiPatterns": [
|
|
21
|
+
"Searching for information that doesn't exist in the knowledge base yet",
|
|
22
|
+
"Using full-text search as the first step instead of grep-first filtering",
|
|
23
|
+
"Reading all files sequentially instead of parallel keyword search"
|
|
24
|
+
],
|
|
25
|
+
"domains": ["knowledge-management", "research", "debugging"]
|
|
26
|
+
},
|
|
27
|
+
"guidance": {
|
|
28
|
+
"strategy": "Grep-first filtering: extract keywords, narrow by category, run parallel content searches on frontmatter fields, then read only strong/moderate matches. Never read all files — always pre-filter.",
|
|
29
|
+
"tactics": [
|
|
30
|
+
"Extract keywords from the current task/problem description",
|
|
31
|
+
"Category narrowing (if clear): focus on the relevant knowledge subdirectory first",
|
|
32
|
+
"Parallel content-search: search on frontmatter fields (title, tags, module, component) using multiple keywords in parallel; use case-insensitive matching; use OR for synonyms",
|
|
33
|
+
"Score matches into four categories: Strong (module + tags match), Moderate (problem_type relevant + tags), Weak (tangential), None — only read Strong and Moderate",
|
|
34
|
+
"Always check critical-patterns document regardless of grep results — it contains must-know patterns for all work",
|
|
35
|
+
"Distill summaries from matched documents — surface actionable insights, not raw content",
|
|
36
|
+
"Assess overlap on 5 dimensions: problem statement, root cause, solution, referenced files, prevention rules",
|
|
37
|
+
"Run multiple searches in parallel — never sequentially"
|
|
38
|
+
]
|
|
39
|
+
},
|
|
40
|
+
"verification": {
|
|
41
|
+
"successIndicators": [
|
|
42
|
+
"Relevant documents found and ranked by relevance strength",
|
|
43
|
+
"Critical patterns checked and incorporated",
|
|
44
|
+
"Summaries are distilled and actionable (not raw file dumps)",
|
|
45
|
+
"Search used grep-first filtering, not sequential file reading"
|
|
46
|
+
],
|
|
47
|
+
"failureIndicators": [
|
|
48
|
+
"All files read sequentially instead of pre-filtered",
|
|
49
|
+
"Tangentially related entries included, adding noise",
|
|
50
|
+
"Critical patterns document skipped",
|
|
51
|
+
"Searches run sequentially instead of in parallel"
|
|
52
|
+
]
|
|
53
|
+
}
|
|
54
|
+
}
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "maintainability-review",
|
|
3
|
+
"curatedBy": "compound-engineering",
|
|
4
|
+
"confidence": 0.85,
|
|
5
|
+
"complexity": "moderate",
|
|
6
|
+
"estimatedEffort": 3,
|
|
7
|
+
"applicability": {
|
|
8
|
+
"situations": [
|
|
9
|
+
"Reviewing code for long-term carrying cost and maintainability",
|
|
10
|
+
"Evaluating abstractions, indirection, and naming clarity",
|
|
11
|
+
"Checking for dead code, unnecessary coupling, and premature complexity"
|
|
12
|
+
],
|
|
13
|
+
"triggers": [
|
|
14
|
+
"code review",
|
|
15
|
+
"maintainability",
|
|
16
|
+
"complexity",
|
|
17
|
+
"refactoring"
|
|
18
|
+
],
|
|
19
|
+
"antiPatterns": [
|
|
20
|
+
"Reviewing for correctness bugs — use correctness review instead",
|
|
21
|
+
"Style preferences that don't affect comprehension",
|
|
22
|
+
"Debating naming conventions already established in the codebase"
|
|
23
|
+
],
|
|
24
|
+
"domains": ["code-review", "maintainability", "quality-assurance"]
|
|
25
|
+
},
|
|
26
|
+
"guidance": {
|
|
27
|
+
"strategy": "Apply the future developer lens: will the next person who touches this in 6 months understand it quickly? Every abstraction must earn its keep with 3+ implementations or proven variation.",
|
|
28
|
+
"tactics": [
|
|
29
|
+
"Hunt for: premature abstraction (interface/factory with one user), unnecessary indirection (>2 delegation levels), dead code (commented, unused exports, unreachable), unrelated module coupling, naming that obscures intent",
|
|
30
|
+
"Anti-pattern catalog: generic solution for specific problem, wrapper with no added value, config for unchanging values, unused extension points, circular dependencies, shared mutable state",
|
|
31
|
+
"Abstractions must earn their keep: 3+ implementations or proven variation axis — otherwise inline",
|
|
32
|
+
"Indirection must add clear value: if a function just delegates to another without transformation, it's overhead",
|
|
33
|
+
"Naming describes what, not how: booleans have is/has/should prefixes; functions describe outcome not mechanism",
|
|
34
|
+
"Confidence calibration: HIGH (0.80+) when objectively provable (abstraction has 1 user visible in codebase); MODERATE (0.60-0.79) for naming/abstraction boundary judgments; suppress below 0.60 for style preferences"
|
|
35
|
+
]
|
|
36
|
+
},
|
|
37
|
+
"verification": {
|
|
38
|
+
"successIndicators": [
|
|
39
|
+
"All flagged abstractions are objectively underused (provable from codebase search)",
|
|
40
|
+
"Indirection findings show concrete delegation chain with no value-add",
|
|
41
|
+
"Dead code findings are verifiable via search (no callers/importers)"
|
|
42
|
+
],
|
|
43
|
+
"failureIndicators": [
|
|
44
|
+
"Finding is really a style preference, not a maintainability concern",
|
|
45
|
+
"Abstraction flagged as premature but actually has 3+ users",
|
|
46
|
+
"Naming critique is subjective rather than clarity-impacting"
|
|
47
|
+
]
|
|
48
|
+
}
|
|
49
|
+
}
|