{
  "policy": {
    "version": 5,
    "patterns": {
      "version": 1,
      "method": "CURATED_PRACTICE_TOPIC",
      "notice": "Pattern topics identify design choices to practice. Read the ticket's acceptance criteria and justify the simplest suitable approach. Tags are not capability or ownership evidence; an untagged ticket has no curated pattern topic assigned."
    },
    "fieldMix": {
      "version": 1,
      "method": "CURATED_ESTIMATE",
      "notice": "Field percentages are editorial estimates of the ticket's engineering focus. They total 100%; they are not measured time, proficiency scores, or ownership evidence."
    },
    "contentStatus": "PRACTICE_BRIEF",
    "assessmentStatus": "NOT_QUALIFIED",
    "evidenceUse": "NONE",
    "aiPolicy": "AI tools are welcome during implementation. Record assumptions, review the result, and verify its behavior.",
    "notice": "Fictional engineering practice briefs. Starter repositories, fixtures, automated grading, and verified ownership are not included.",
    "outcomeEvidence": "Tests, patches, and runbooks are requested deliverables. They become Outcome Evidence only through a qualified Mission and immutable Evidence IDs.",
    "ownershipEvidence": "Independent adaptation must be observed under a declared verification policy and cite immutable Evidence IDs. Completing a planning ticket establishes no Ownership Evidence."
  },
  "patternTopics": [
    {
      "id": "factory-method",
      "label": "Factory Method",
      "group": "Creational"
    },
    {
      "id": "abstract-factory",
      "label": "Abstract Factory",
      "group": "Creational"
    },
    {
      "id": "builder",
      "label": "Builder",
      "group": "Creational"
    },
    {
      "id": "prototype",
      "label": "Prototype",
      "group": "Creational"
    },
    {
      "id": "singleton",
      "label": "Singleton",
      "group": "Creational"
    },
    {
      "id": "adapter",
      "label": "Adapter",
      "group": "Structural"
    },
    {
      "id": "bridge",
      "label": "Bridge",
      "group": "Structural"
    },
    {
      "id": "composite",
      "label": "Composite",
      "group": "Structural"
    },
    {
      "id": "decorator",
      "label": "Decorator",
      "group": "Structural"
    },
    {
      "id": "facade",
      "label": "Facade",
      "group": "Structural"
    },
    {
      "id": "flyweight",
      "label": "Flyweight",
      "group": "Structural"
    },
    {
      "id": "proxy",
      "label": "Proxy",
      "group": "Structural"
    },
    {
      "id": "chain-of-responsibility",
      "label": "Chain of Responsibility",
      "group": "Behavioral"
    },
    {
      "id": "command",
      "label": "Command",
      "group": "Behavioral"
    },
    {
      "id": "interpreter",
      "label": "Interpreter",
      "group": "Behavioral"
    },
    {
      "id": "iterator",
      "label": "Iterator",
      "group": "Behavioral"
    },
    {
      "id": "mediator",
      "label": "Mediator",
      "group": "Behavioral"
    },
    {
      "id": "memento",
      "label": "Memento",
      "group": "Behavioral"
    },
    {
      "id": "observer",
      "label": "Observer",
      "group": "Behavioral"
    },
    {
      "id": "state",
      "label": "State",
      "group": "Behavioral"
    },
    {
      "id": "strategy",
      "label": "Strategy",
      "group": "Behavioral"
    },
    {
      "id": "template-method",
      "label": "Template Method",
      "group": "Behavioral"
    },
    {
      "id": "visitor",
      "label": "Visitor",
      "group": "Behavioral"
    },
    {
      "id": "ports-and-adapters",
      "label": "Ports and Adapters",
      "group": "Architectural"
    },
    {
      "id": "cqrs",
      "label": "CQRS",
      "group": "Architectural"
    },
    {
      "id": "strangler-fig",
      "label": "Strangler Fig",
      "group": "Architectural"
    },
    {
      "id": "saga",
      "label": "Saga",
      "group": "Distributed and reliability"
    },
    {
      "id": "transactional-outbox",
      "label": "Transactional Outbox",
      "group": "Distributed and reliability"
    },
    {
      "id": "circuit-breaker",
      "label": "Circuit Breaker",
      "group": "Distributed and reliability"
    },
    {
      "id": "bulkhead",
      "label": "Bulkhead",
      "group": "Distributed and reliability"
    }
  ],
  "projects": [
    {
      "id": "ebc48eea-e9e0-4933-b542-cfb020847b73",
      "key": "BMONO",
      "title": "Monorepo change planner",
      "field": "Developer tooling",
      "summary": "Make selective CI trustworthy when packages, lockfiles, and generated inputs change.",
      "context": "A fictional internal tools team maintains eighteen packages. Engineers currently run everything because the affected-package script occasionally misses downstream consumers.",
      "stack": [
        "TypeScript",
        "pnpm",
        "Git"
      ],
      "prerequisites": [
        "Create a local six-package fixture with a dependency cycle, shared compiler configuration, and two example changes."
      ],
      "developerValue": "Practice graph analysis, reproducible commands, and safe developer-tool failure modes.",
      "companyValue": "Produce an inspectable CI selection plan that avoids unnecessary work without silently skipping consumers.",
      "delivery": "Deliver a local planning CLI, regression fixtures, and an adoption note; hosted CI integration is optional.",
      "phases": [
        {
          "id": "map",
          "title": "Map the inputs",
          "goal": "Define which repository changes affect which commands."
        },
        {
          "id": "plan",
          "title": "Build the planner",
          "goal": "Produce deterministic affected sets with conservative fallbacks."
        },
        {
          "id": "adopt",
          "title": "Adopt safely",
          "goal": "Compare selective runs against full runs before enforcement."
        }
      ],
      "tickets": [
        {
          "id": "e928f5ea-1a8b-4849-90cd-ca0f9c8b2764",
          "key": "BMONO-101",
          "title": "Document task inputs beyond package dependencies",
          "type": "TASK",
          "priority": "MEDIUM",
          "difficulty": "FOUNDATIONAL",
          "estimateMinutes": 60,
          "phaseId": "map",
          "dependsOn": [],
          "scenario": "A root compiler change passed CI although an unchanged package no longer compiled. Inventory inputs the planner must treat as shared.",
          "acceptanceCriteria": [
            "List compiler, lockfile, environment, and generator inputs separately.",
            "Assign an owner and invalidation rule to each input.",
            "Include one change that legitimately affects every package."
          ],
          "implementationNotes": [
            "Use the local fixture; do not inspect private repositories."
          ],
          "verification": [
            "Trace a package-only edit to its expected tasks.",
            "Trace an unknown root input to conservative full selection."
          ],
          "deliverables": [
            "Input ownership matrix."
          ],
          "rollout": "Review the matrix before enabling selection; retain full CI as fallback.",
          "skills": [
            "Dependency analysis",
            "Build systems"
          ],
          "fieldMix": [
            {
              "field": "Developer tooling",
              "percentage": 100
            }
          ],
          "patterns": []
        },
        {
          "id": "fd02c7e7-8f72-4ea0-851a-91ae3ee35a59",
          "key": "BMONO-102",
          "title": "Parse workspace manifests without executing package scripts",
          "type": "TASK",
          "priority": "HIGH",
          "difficulty": "INTERMEDIATE",
          "estimateMinutes": 150,
          "phaseId": "map",
          "dependsOn": [
            "BMONO-101"
          ],
          "scenario": "The planner must inspect an unfamiliar checkout without triggering install hooks or repository commands.",
          "acceptanceCriteria": [
            "Resolve workspace package names and paths from manifests.",
            "Reject duplicate names and paths outside the checkout.",
            "Report malformed JSON with file and safe location."
          ],
          "implementationNotes": [
            "Treat manifests as data; never evaluate imported configuration."
          ],
          "verification": [
            "Load valid nested workspace fixtures.",
            "Reject traversal, duplicate identity, and invalid JSON fixtures."
          ],
          "deliverables": [
            "Manifest parser and fixture tests."
          ],
          "rollout": "Use read-only inventory mode first; fall back to full CI on parser errors.",
          "skills": [
            "TypeScript",
            "Input validation"
          ],
          "fieldMix": [
            {
              "field": "Developer tooling",
              "percentage": 70
            },
            {
              "field": "Security",
              "percentage": 30
            }
          ],
          "patterns": []
        },
        {
          "id": "5f091b07-d974-4c0b-893f-4bbd3f18048d",
          "key": "BMONO-103",
          "title": "Handle cycles in the downstream impact graph",
          "type": "BUG",
          "priority": "HIGH",
          "difficulty": "ADVANCED",
          "estimateMinutes": 210,
          "phaseId": "plan",
          "dependsOn": [
            "BMONO-102"
          ],
          "scenario": "Two shared packages depend on each other through development tooling, and recursive traversal never finishes.",
          "acceptanceCriteria": [
            "Collapse or explicitly track cycles without dropping members.",
            "Include transitive dependents once each.",
            "Sort output stably regardless of manifest enumeration order."
          ],
          "implementationNotes": [
            "Distinguish runtime and development edges in the plan explanation."
          ],
          "verification": [
            "Resolve a diamond graph with one cycle.",
            "Verify a disconnected package stays excluded and traversal terminates."
          ],
          "deliverables": [
            "Cycle-safe graph traversal."
          ],
          "rollout": "Compare results with full package selection; disable selective mode if membership differs.",
          "skills": [
            "Graph algorithms",
            "Dependency analysis"
          ],
          "fieldMix": [
            {
              "field": "Developer tooling",
              "percentage": 100
            }
          ],
          "patterns": []
        },
        {
          "id": "12dcc0b4-6c0b-4607-9235-dca5418c901e",
          "key": "BMONO-104",
          "title": "Resolve renamed and deleted files against both revisions",
          "type": "BUG",
          "priority": "HIGH",
          "difficulty": "ADVANCED",
          "estimateMinutes": 180,
          "phaseId": "plan",
          "dependsOn": [
            "BMONO-102"
          ],
          "scenario": "A package deletion disappears from the current workspace map and incorrectly produces an empty plan.",
          "acceptanceCriteria": [
            "Read changed paths from a declared base and head.",
            "Account for both source and destination of renames.",
            "Select former dependents when a package is removed."
          ],
          "implementationNotes": [
            "Do not assume a remote branch exists in a shallow checkout."
          ],
          "verification": [
            "Plan a package move with unchanged contents.",
            "Exercise missing base and deleted-manifest cases with explicit fallback."
          ],
          "deliverables": [
            "Revision-aware path ownership logic."
          ],
          "rollout": "Ship behind diagnostic output; preserve full CI for unresolved history.",
          "skills": [
            "Git",
            "Change analysis"
          ],
          "fieldMix": [
            {
              "field": "Developer tooling",
              "percentage": 100
            }
          ],
          "patterns": []
        },
        {
          "id": "d7ff818b-da54-4781-bd12-3e53a8fddb06",
          "key": "BMONO-105",
          "title": "Explain why each selected command is necessary",
          "type": "STORY",
          "priority": "MEDIUM",
          "difficulty": "INTERMEDIATE",
          "estimateMinutes": 120,
          "phaseId": "plan",
          "dependsOn": [
            "BMONO-103",
            "BMONO-104"
          ],
          "scenario": "Maintainers cannot review a large affected set because the tool prints only package names.",
          "acceptanceCriteria": [
            "Attach at least one changed input to each selected task.",
            "Represent transitive paths without unbounded recursion.",
            "Emit stable JSON and readable plain-text output."
          ],
          "implementationNotes": [
            "Keep absolute workstation paths out of exported plans."
          ],
          "verification": [
            "Snapshot a direct and a transitive explanation.",
            "Verify cyclic and missing-owner explanations remain bounded."
          ],
          "deliverables": [
            "Plan explanation renderer."
          ],
          "rollout": "Enable explanation output immediately; keep command execution opt-in.",
          "skills": [
            "CLI design",
            "Developer experience"
          ],
          "fieldMix": [
            {
              "field": "Developer tooling",
              "percentage": 100
            }
          ],
          "patterns": []
        },
        {
          "id": "169d0729-89ea-44be-ae99-c1eaa63c8174",
          "key": "BMONO-106",
          "title": "Make cache keys include generator versions and relevant environment",
          "type": "BUG",
          "priority": "HIGH",
          "difficulty": "ADVANCED",
          "estimateMinutes": 210,
          "phaseId": "plan",
          "dependsOn": [
            "BMONO-101",
            "BMONO-103"
          ],
          "scenario": "Generated client code changed after a tool upgrade while the cache reused an old successful result.",
          "acceptanceCriteria": [
            "Hash declared inputs using stable ordering.",
            "Include generator version and allowlisted environment names.",
            "Exclude secrets and unrelated environment values from key material."
          ],
          "implementationNotes": [
            "A cache hit must never authorize skipping an undeclared dependency."
          ],
          "verification": [
            "Change each declared input and observe key changes.",
            "Verify secret values are absent from keys and diagnostic output."
          ],
          "deliverables": [
            "Cache-key contract and regression checks."
          ],
          "rollout": "Invalidate old keys on adoption; revert to uncached commands if key provenance is missing.",
          "skills": [
            "Caching",
            "Reproducibility"
          ],
          "fieldMix": [
            {
              "field": "Developer tooling",
              "percentage": 70
            },
            {
              "field": "Storage systems",
              "percentage": 30
            }
          ],
          "patterns": []
        },
        {
          "id": "b78f2c9d-7bae-416c-b22c-57840b89c31f",
          "key": "BMONO-107",
          "title": "Detect stale plan execution after the worktree changes",
          "type": "TASK",
          "priority": "HIGH",
          "difficulty": "INTERMEDIATE",
          "estimateMinutes": 150,
          "phaseId": "plan",
          "dependsOn": [
            "BMONO-105",
            "BMONO-106"
          ],
          "scenario": "A developer reviews a plan, edits another package, then executes commands from the earlier plan.",
          "acceptanceCriteria": [
            "Bind plans to revision and relevant working-tree digests.",
            "Check the binding immediately before execution.",
            "Return a distinct stale-plan error with regeneration guidance."
          ],
          "implementationNotes": [
            "Do not discard or reset local edits."
          ],
          "verification": [
            "Execute an unchanged reviewed plan successfully.",
            "Modify a tracked input and reject the stale plan before spawning commands."
          ],
          "deliverables": [
            "Plan freshness guard."
          ],
          "rollout": "Require freshness for execution; allow explicit regeneration without modifying the checkout.",
          "skills": [
            "Integrity checks",
            "CLI design"
          ],
          "fieldMix": [
            {
              "field": "Developer tooling",
              "percentage": 100
            }
          ],
          "patterns": []
        },
        {
          "id": "ea67aaf9-4e02-46c6-a3d0-c1eaa2877b04",
          "key": "BMONO-108",
          "title": "Bound parallel commands and stop cleanly on cancellation",
          "type": "TASK",
          "priority": "MEDIUM",
          "difficulty": "ADVANCED",
          "estimateMinutes": 210,
          "phaseId": "adopt",
          "dependsOn": [
            "BMONO-107"
          ],
          "scenario": "Selective tasks saturate a laptop and leave child processes alive when the parent command is interrupted.",
          "acceptanceCriteria": [
            "Enforce configured parallelism between one and the fixture package count.",
            "Stop scheduling new work after cancellation.",
            "Report completed, failed, and cancelled tasks separately."
          ],
          "implementationNotes": [
            "Execute only trusted fixture commands in this exercise."
          ],
          "verification": [
            "Observe the concurrency ceiling with delayed fixtures.",
            "Cancel mid-run and verify owned child processes terminate."
          ],
          "deliverables": [
            "Bounded command scheduler."
          ],
          "rollout": "Default to conservative parallelism; provide serial mode for recovery.",
          "skills": [
            "Process management",
            "Concurrency"
          ],
          "fieldMix": [
            {
              "field": "Developer tooling",
              "percentage": 100
            }
          ],
          "patterns": []
        },
        {
          "id": "8bda1001-eaec-41e1-86cc-cdfb8d5e8d58",
          "key": "BMONO-109",
          "title": "Compare selective and full plans over a recorded change corpus",
          "type": "TASK",
          "priority": "HIGH",
          "difficulty": "EXPERT",
          "estimateMinutes": 360,
          "phaseId": "adopt",
          "dependsOn": [
            "BMONO-103",
            "BMONO-104",
            "BMONO-106",
            "BMONO-108"
          ],
          "scenario": "Before making selection mandatory, the team needs a defensible way to find false negatives rather than celebrate shorter CI runs.",
          "acceptanceCriteria": [
            "Define a corpus covering root, package, rename, and deletion changes.",
            "Compare selected task outcomes with full-run outcomes under identical inputs.",
            "Block adoption on an unexplained excluded failure and record uncertainty."
          ],
          "implementationNotes": [
            "Report workload and machine limits; do not promise general speedups from local measurements."
          ],
          "verification": [
            "Detect an intentionally omitted shared input.",
            "Show a safe exclusion and publish reproducible comparison commands."
          ],
          "deliverables": [
            "Adoption assessment and mismatch report."
          ],
          "rollout": "Run in shadow mode for the corpus; retain a one-command full-run override.",
          "skills": [
            "Experimental design",
            "CI engineering"
          ],
          "fieldMix": [
            {
              "field": "Quality engineering",
              "percentage": 50
            },
            {
              "field": "Developer tooling",
              "percentage": 50
            }
          ],
          "patterns": []
        },
        {
          "id": "59ffcde3-cf51-460c-b434-68e76a2ae336",
          "key": "BMONO-110",
          "title": "Write a maintainer playbook for adding a new task input",
          "type": "CHORE",
          "priority": "LOW",
          "difficulty": "FOUNDATIONAL",
          "estimateMinutes": 60,
          "phaseId": "adopt",
          "dependsOn": [
            "BMONO-109"
          ],
          "scenario": "New generators will appear after launch, and ownership of the invalidation map is currently undocumented.",
          "acceptanceCriteria": [
            "Show how to declare one generator input and its owner.",
            "Include the regression case required before selective execution.",
            "Document diagnosis of unexpected full and empty plans."
          ],
          "implementationNotes": [
            "Use examples from the implemented planner rather than future capabilities."
          ],
          "verification": [
            "Follow the guide to add a synthetic generator input.",
            "Verify omission is detected by the comparison procedure."
          ],
          "deliverables": [
            "Maintainer guide with worked example."
          ],
          "rollout": "Link the guide from CLI help; withdraw selective defaults if ownership becomes unclear.",
          "skills": [
            "Technical writing",
            "Build systems"
          ],
          "fieldMix": [
            {
              "field": "Developer tooling",
              "percentage": 100
            }
          ],
          "patterns": []
        }
      ]
    }
  ]
}
