@aryaminus/controlkeel-opencode 0.3.1 → 0.3.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.
@@ -0,0 +1,67 @@
1
+ ---
2
+ name: align
3
+ description: "Interview the user about their goal before any plan or code. Reach shared understanding of what, why, which layers, success criteria, and unknowns. Feed the result into plan-slice or ck_review_submit."
4
+ when_to_use: "Activate at the very start of any new feature, fix, or project — before writing a PRD, submitting a plan, or touching any code. Also activate when a brief or Slack message arrives and the intent is not yet fully clear."
5
+ argument-hint: "[goal description or raw brief]"
6
+ license: Apache-2.0
7
+ compatibility:
8
+ - codex
9
+ - claude-standalone
10
+ - claude-plugin
11
+ - copilot-plugin
12
+ - github-repo
13
+ - open-standard
14
+ metadata:
15
+ author: controlkeel
16
+ version: "1.0"
17
+ category: planning
18
+ ck_mcp_tools:
19
+ - ck_context
20
+ - ck_goal
21
+ - ck_memory_record
22
+ - ck_memory_search
23
+ ---
24
+
25
+ # Align Skill
26
+
27
+ Reach a **shared design concept** with the user before any plan or code is written. The most expensive misalignment is the one caught after implementation — catch it here instead.
28
+
29
+ ## Protocol
30
+
31
+ 1. Call `ck_context` to load current session state, domain pack, and any prior goals or decisions already recorded.
32
+ 2. Call `ck_memory_search` with the user's stated goal to surface prior aligned work on the same area before asking redundant questions.
33
+ 3. Ask the user **one question at a time**. For each question, provide your recommended answer so the user can confirm, adjust, or replace it — never leave them staring at a blank.
34
+ 4. Work through the alignment tree in this order:
35
+
36
+ **What** — What is the exact outcome? What is explicitly out of scope?
37
+ **Why** — What problem does this solve? What is the success signal?
38
+ **Who** — Who uses the result? Which roles, systems, or integrations are affected?
39
+ **Layers** — Which system layers does this touch? (schema, services, APIs, UI, infra, third-party) Record each touched layer explicitly — this drives vertical slice decomposition later.
40
+ **Acceptance criteria** — What does "done" look like? What would a failing test catch?
41
+ **Edge cases** — What breaks if inputs are invalid, empty, or unexpected?
42
+ **Constraints** — Budget, timeline, tech stack limits, compliance requirements, or must-not-change areas.
43
+ **Unknowns** — What do you not know yet? What needs a spike or research before implementation starts?
44
+
45
+ 5. After each resolved decision, call `ck_memory_record` with type `decision` to persist it. Future agents resuming this work will recover these without asking again.
46
+ 6. When alignment is complete, call `ck_goal` (mode: `record`, horizon: `session`) to record the aligned goal with its acceptance criteria and touched layers.
47
+ 7. Tell the user the alignment is complete and recommend the next step:
48
+ - If the work is multi-layer and will need decomposition → activate `plan-slice`.
49
+ - If the work is a single small change that fits in one task → proceed to `ck_review_submit` (plan_phase: `narrowed_decision`).
50
+
51
+ ## Non-negotiable rules
52
+
53
+ - Never skip alignment and go straight to planning or code, even for "small" tasks. A missed constraint at this stage compounds into blocked findings or rework later.
54
+ - Do not produce a plan, PRD, or code during this skill. The output is a recorded goal and a set of decisions — nothing else.
55
+ - If the user says "just do it," record what you know so far, note the unknowns explicitly, and move forward — but surface the open questions as warnings so they can surface as findings if they bite later.
56
+ - Planning is always human-in-the-loop. The agent asks; the human decides. Never answer your own alignment questions and continue as if the human agreed.
57
+
58
+ ## What you produce
59
+
60
+ At the end of this skill:
61
+ - A `ck_goal` record with: objective, acceptance criteria, touched layers, known constraints, open unknowns.
62
+ - One or more `ck_memory_record` entries (type: `decision`) for each resolved design choice.
63
+ - A clear recommendation on whether to proceed to `plan-slice` or directly to `ck_review_submit`.
64
+
65
+ ## Additional resources
66
+
67
+ - For the full governed workflow, see [references/workflow.md](references/workflow.md)
@@ -51,6 +51,10 @@ metadata:
51
51
 
52
52
  You are operating inside a **ControlKeel-governed session**. Start here whenever you need the base CK operating protocol.
53
53
 
54
+ ## Before new work
55
+
56
+ For any new feature, fix, or project — before writing plans or code — use the `align` skill to reach shared understanding of the goal, layers, and acceptance criteria. Once aligned, use `plan-slice` to decompose the goal into vertical slices with explicit blocking relationships before any implementation begins. Planning is always human-in-the-loop; implementation of an approved slice can be AFK.
57
+
54
58
  ## Core loop
55
59
 
56
60
  1. Call `ck_context` at task start to load mission, risk, budget, proof, active findings, workspace context, context reacquisition, instruction hierarchy, and recent transcript state.
@@ -94,6 +98,8 @@ You are operating inside a **ControlKeel-governed session**. Start here whenever
94
98
  - `ck_deployment_advisor` — repo stack detection, CI/Docker generation, DNS/SSL guide
95
99
  - `ck_outcome_tracker` — record and review session outcomes/agent scores
96
100
  - `ck_skill_list`, `ck_skill_load` — specialized workflow activation
101
+ - `align` skill — pre-work alignment interview before any plan or code
102
+ - `plan-slice` skill — vertical slice decomposition with blocking relationships and autonomy labels
97
103
 
98
104
  ## Additional resources
99
105
 
@@ -0,0 +1,80 @@
1
+ ---
2
+ name: handoff
3
+ description: "Persist session state and hand off in-progress work to a background agent or delegated execution. Use when work outgrows the current session, context is near limit, or a task needs to continue unattended."
4
+ when_to_use: "Activate when the user says 'hand off', 'delegate this', 'continue in background', 'pass this off', or when context pressure is high and significant work remains. Also activate when ck_route recommends a different agent for the remaining work."
5
+ argument-hint: "[optional: specific task or remaining work to hand off]"
6
+ license: Apache-2.0
7
+ compatibility:
8
+ - codex
9
+ - claude-standalone
10
+ - claude-plugin
11
+ - copilot-plugin
12
+ - github-repo
13
+ - open-standard
14
+ metadata:
15
+ author: controlkeel
16
+ version: "1.0"
17
+ category: execution
18
+ ck_mcp_tools:
19
+ - ck_context
20
+ - ck_memory_record
21
+ - ck_memory_search
22
+ - ck_route
23
+ - ck_delegate
24
+ - ck_goal
25
+ ---
26
+
27
+ # Handoff Skill
28
+
29
+ Transfer in-progress work to another agent or execution context with full state preservation, so work continues seamlessly after the current session ends or context runs out.
30
+
31
+ ## When to use this skill
32
+
33
+ - Context window is approaching its limit and substantial work remains
34
+ - The user wants work to continue unattended (background execution)
35
+ - `ck_route` recommends a different agent or runtime for the remaining task
36
+ - The user explicitly asks to delegate, hand off, or pass work to a background agent
37
+
38
+ ## Protocol
39
+
40
+ 1. Call `ck_context` to load current session state, open findings, active goal, and proof summary.
41
+
42
+ 2. Call `ck_memory_search` with the current task description to surface any prior decisions, constraints, or context that the receiving agent will need.
43
+
44
+ 3. Build the **handoff packet** — record it with `ck_memory_record` (type: `decision`, scope: `session`) containing:
45
+ - **What was accomplished** this session (bullet list of completed work with file paths)
46
+ - **What remains** (ordered list of next steps, from most to least critical)
47
+ - **Open findings** — any blocked or warning-level issues the receiving agent must address first
48
+ - **Constraints** — must-not-change areas, budget limits, compliance requirements discovered this session
49
+ - **Assumptions** — decisions made without explicit human confirmation that the receiving agent should be aware of
50
+ - **Resume hint** — the single most important thing the next agent should do first
51
+
52
+ 4. Call `ck_goal` (mode: `read`) to confirm the goal record is current. If it has drifted from what was actually worked on, update it with `ck_goal` (mode: `record`) before handing off.
53
+
54
+ 5. Call `ck_route` to determine the best agent or execution mode for the remaining work. Provide the remaining task list and any constraints.
55
+
56
+ 6. Call `ck_delegate` with the handoff packet as context and the routing recommendation from step 5. Use mode `handoff` for human-mediated transfer or mode `runtime` for automated background execution.
57
+
58
+ 7. Confirm to the user:
59
+ - What was preserved (memory record ID)
60
+ - Where the work is going (agent / mode)
61
+ - The single next action for the receiving agent
62
+ - How to resume: what to tell the next agent to pick up seamlessly
63
+
64
+ ## Non-negotiable rules
65
+
66
+ - Never hand off with open **blocked** findings. Resolve or escalate them first — a blocked finding handed off unresolved will stall the receiving agent immediately.
67
+ - The handoff packet must be complete enough that the receiving agent can continue **without** reading this session's conversation history.
68
+ - If `ck_route` returns no suitable agent, tell the user explicitly rather than handing off to a mismatched executor.
69
+
70
+ ## What you produce
71
+
72
+ At the end of this skill:
73
+ - A `ck_memory_record` entry (type: `decision`) containing the full handoff packet
74
+ - A `ck_delegate` call that initiates the transfer
75
+ - A clear user-facing summary: what was saved, where work is going, and what the next agent will do first
76
+
77
+ ## Additional resources
78
+
79
+ - For proof preservation before handoff, run the `proof-memory` skill first
80
+ - For routing decisions, see `ck_route` tool documentation
@@ -0,0 +1,130 @@
1
+ ---
2
+ name: plan-slice
3
+ description: "Decompose an aligned goal into independently executable vertical slices with explicit blocking relationships. Each slice must cross all touched system layers — not a single layer. Submit for human approval before any implementation begins."
4
+ when_to_use: "Activate after the align skill has produced a recorded goal, and before any code or delegation begins. Also activate when a goal has more than one system layer or more than two sequential tasks."
5
+ argument-hint: "[aligned goal or ck_goal record ID]"
6
+ license: Apache-2.0
7
+ compatibility:
8
+ - codex
9
+ - claude-standalone
10
+ - claude-plugin
11
+ - copilot-plugin
12
+ - github-repo
13
+ - open-standard
14
+ metadata:
15
+ author: controlkeel
16
+ version: "1.0"
17
+ category: planning
18
+ ck_mcp_tools:
19
+ - ck_context
20
+ - ck_goal
21
+ - ck_memory_record
22
+ - ck_memory_search
23
+ - ck_review_submit
24
+ - ck_review_status
25
+ - ck_route
26
+ ---
27
+
28
+ # Plan Slice Skill
29
+
30
+ Turn an aligned goal into a **directed acyclic graph of vertical slices** that agents can execute independently. Vertical slices give you working software at the end of each slice and feedback across all layers immediately — not at the end of phase 3 when three layers have already diverged.
31
+
32
+ ## Why vertical slices matter
33
+
34
+ Agents default to horizontal work: all schema changes in phase 1, all API changes in phase 2, all UI in phase 3. This delays feedback on whether layers actually fit together until late in the work. A vertical slice crosses schema + service + UI (or whichever layers are touched) in one shot, so each slice is demonstrably working software — not a half-built layer.
35
+
36
+ ## Protocol
37
+
38
+ ### 1. Load context
39
+ Call `ck_context` and `ck_memory_search` to retrieve the aligned goal, recorded decisions, and touched layers from the `align` step.
40
+
41
+ ### 2. Map system layers
42
+ List every layer the goal touches. Common layers in order (innermost first):
43
+ - **schema** — database tables, migrations, indexes
44
+ - **service** — business logic, background jobs, domain rules
45
+ - **api** — HTTP handlers, resolvers, RPC endpoints
46
+ - **ui** — components, pages, forms, interactions
47
+ - **infra** — CI/CD, environment config, feature flags, third-party credentials
48
+
49
+ Not every goal touches all layers. Record which ones are in scope.
50
+
51
+ ### 3. Draft vertical slices
52
+
53
+ Each slice must:
54
+ - Touch **at least two adjacent layers** from the list above (one-layer slices are horizontal — flag them and expand or merge).
55
+ - Deliver something observable or testable at its boundary (a working endpoint, a rendered component, a passing integration test).
56
+ - Be **independently grabbable**: another agent or developer can pick it up given only the slice description and the outputs of its blocking slices.
57
+
58
+ Start with the **thinnest possible vertical slice first** — often called the tracer bullet. This is the minimal path through all touched layers: one user story, one schema column, one endpoint, one UI element. It proves the layers fit together before you build breadth.
59
+
60
+ Structure:
61
+ ```
62
+ Slice 1 (tracer): <minimal cross-layer path> — AFK
63
+ Slice 2: <next user story, depends on slice 1> — AFK
64
+ Slice 3: <requires a design decision> — HiTL
65
+ Slice 4: <final integration / edge cases, depends on 2 and 3> — AFK
66
+ ```
67
+
68
+ ### 4. Validate each slice
69
+
70
+ For every proposed slice, check:
71
+ - Does it touch only one layer? → **Horizontal slice — expand or merge.**
72
+ - Does it produce something testable by the end? → If not, split differently.
73
+ - Could another agent start it in isolation given its inputs? → If not, clarify the interface contract.
74
+ - Does it contain unresolved design decisions? → Label it **HiTL** (supervised_execute or human_gate); clear decisions → label **AFK** (guarded_autonomy).
75
+
76
+ ### 5. Define blocking relationships
77
+
78
+ Produce an explicit dependency list:
79
+ ```
80
+ Slice 2 blocked by: Slice 1
81
+ Slice 3 blocked by: Slice 1
82
+ Slice 4 blocked by: Slice 2, Slice 3
83
+ ```
84
+
85
+ Slices with no dependencies can run in parallel via `ck_route` + `ck_delegate`. Document which slices are parallelizable.
86
+
87
+ ### 6. Label autonomy mode per slice
88
+
89
+ Map each slice to a CK autonomy profile:
90
+ - **AFK** → `guarded_autonomy`: well-defined inputs/outputs, no open design questions, validation loop is deterministic.
91
+ - **HiTL** → `supervised_execute`: contains a design decision, requires human judgment, or touches a critical path (auth, payments, schema migration, compliance-sensitive data).
92
+
93
+ Never label a slice AFK if it contains an unresolved unknown from the `align` step.
94
+
95
+ ### 7. Record the plan
96
+ Call `ck_memory_record` (type: `decision`) with the full slice plan: slice titles, layer coverage, blocking relationships, and autonomy labels.
97
+
98
+ Update the `ck_goal` record (mode: `update_status`) with `active` and a progress note pointing to the slice plan.
99
+
100
+ ### 8. Submit for human approval
101
+
102
+ Call `ck_review_submit` with:
103
+ - `review_type`: `plan`
104
+ - `plan_phase`: `implementation_plan`
105
+ - `implementation_steps`: the slice list with blocking relationships and autonomy labels
106
+ - `validation_plan`: which tests or observables prove each slice is done
107
+ - `alignment_context`: the accepted goal from the `align` step
108
+ - `scope_estimate`: number of slices, estimated touch points per layer
109
+
110
+ Then call `ck_review_status` to check for `grill_questions`. Surface every grill question back to the user and resolve them before implementation begins. This is still human-in-the-loop — do not start coding until the review is approved.
111
+
112
+ ## Non-negotiable rules
113
+
114
+ - Never begin implementation before the review is approved.
115
+ - A slice that touches only one layer is not a vertical slice — it is a horizontal slice. Reject it.
116
+ - AFK slices must have zero open design questions. If you find one, promote the slice to HiTL.
117
+ - Parallelism is only valid between slices with no blocking relationship. Never run blocking slices in parallel.
118
+ - The first slice must always be the thinnest viable cross-layer path. Do not start with setup or scaffolding that produces no observable output.
119
+
120
+ ## What you produce
121
+
122
+ At the end of this skill:
123
+ - A reviewed and approved slice plan (via `ck_review_submit`).
124
+ - A `ck_memory_record` containing the DAG: slice titles, layers, dependencies, autonomy labels.
125
+ - A `ck_goal` update marking the plan as active.
126
+ - A clear first slice ready for handoff to implementation (via `ck_delegate` or direct agent work under the governance skill).
127
+
128
+ ## Additional resources
129
+
130
+ - For the full governed workflow, see [references/workflow.md](references/workflow.md)
package/package.json CHANGED
@@ -35,5 +35,5 @@
35
35
  "url": "git+https://github.com/aryaminus/controlkeel.git"
36
36
  },
37
37
  "type": "module",
38
- "version": "0.3.1"
38
+ "version": "0.3.2"
39
39
  }