@jeiemgi/cckit 0.2.0 → 0.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.claude-plugin/plugin.json +1 -1
- package/AGENTS.md +21 -8
- package/README.md +119 -20
- package/bin/cckit +42 -16
- package/cckit.config.json +1 -1
- package/commands/kit-doctor.md +3 -1
- package/commands/kit-update.md +9 -4
- package/kit.config.schema.json +25 -0
- package/package.json +1 -1
- package/scripts/annotate-setup.sh +7 -2
- package/scripts/capture-project-ids.sh +23 -10
- package/scripts/init-upgrade-test.sh +35 -1
- package/scripts/init.sh +43 -7
- package/scripts/kit-doctor.sh +185 -7
- package/scripts/kit-version-check-test.sh +36 -0
- package/scripts/kit-version-check.sh +19 -4
- package/scripts/kit-wire.sh +4 -1
- package/scripts/knowledge-lint.sh +4 -1
- package/scripts/lib/board-view-test.sh +54 -0
- package/scripts/lib/board-view.sh +80 -0
- package/scripts/lib/captain-test.sh +18 -0
- package/scripts/lib/captain.sh +92 -5
- package/scripts/lib/config-path-test.sh +47 -0
- package/scripts/lib/config-path.sh +29 -0
- package/scripts/lib/copilot.sh +9 -9
- package/scripts/lib/effort-dispatch-test.sh +25 -0
- package/scripts/lib/effort-flows-test.sh +55 -0
- package/scripts/lib/effort-metrics-test.sh +57 -0
- package/scripts/lib/effort-metrics.sh +19 -5
- package/scripts/lib/effort-ops-test.sh +110 -3
- package/scripts/lib/effort-ops.sh +480 -50
- package/scripts/lib/effort-parity-test.sh +128 -0
- package/scripts/lib/effort-slug-test.sh +87 -0
- package/scripts/lib/effort-slug.sh +104 -0
- package/scripts/lib/effort.sh +91 -1
- package/scripts/lib/gh-project-test.sh +95 -0
- package/scripts/lib/gh-project.sh +22 -7
- package/scripts/lib/git-remote-test.sh +57 -0
- package/scripts/lib/git-remote.sh +21 -0
- package/scripts/lib/kit-config-test.sh +37 -0
- package/scripts/lib/kit-config.sh +38 -13
- package/scripts/lib/kit-engine-test.sh +9 -0
- package/scripts/lib/kit-events.sh +5 -3
- package/scripts/lib/kit-gc-test.sh +88 -0
- package/scripts/lib/kit-gc.sh +136 -19
- package/scripts/lib/kit-local.sh +8 -1
- package/scripts/lib/kit-operate.sh +17 -2
- package/scripts/lib/next.sh +3 -3
- package/scripts/lib/plan-next-test.sh +87 -0
- package/scripts/lib/plan-next.sh +212 -0
- package/scripts/lib/project-scan.sh +7 -1
- package/scripts/lib/worktree-start.sh +12 -3
- package/scripts/lib/zsh-safety-test.sh +73 -0
- package/scripts/portable-test.sh +62 -20
- package/scripts/setup-labels.sh +13 -2
- package/scripts/showcase.sh +13 -4
- package/scripts/status-test.sh +63 -0
- package/scripts/status.sh +12 -4
- package/scripts/task-sync.sh +79 -10
- package/skills/kit-autopilot/SKILL.md +5 -0
- package/skills/{docs-writer → kit-docs-writer}/SKILL.md +2 -2
- package/skills/kit-effort-close/SKILL.md +52 -104
- package/skills/kit-effort-new/SKILL.md +40 -112
- package/skills/kit-effort-pr/SKILL.md +6 -2
- package/skills/kit-effort-start/SKILL.md +44 -46
- package/skills/kit-next/SKILL.md +4 -0
- package/skills/kit-plan-next/SKILL.md +82 -0
- package/skills/kit-task-start/SKILL.md +44 -55
- package/templates/CLAUDE.md.tmpl +1 -1
- package/templates/agents/auto-dev.md +1 -1
- package/templates/hooks/mempal_session_start.sh.tmpl +36 -2
- package/templates/rules/effort-model.md +43 -6
- package/templates/rules/mempalace.md +1 -0
- package/templates/rules/plan-next.md +58 -0
- package/templates/rules/task-management.md +1 -1
|
@@ -56,6 +56,14 @@ The parent ref is mandatory; `N` is a plain number so subs sort and read predict
|
|
|
56
56
|
applies both formats when it creates the parent + native sub-issues, so a sub is identifiable by
|
|
57
57
|
name alone in any flat list.
|
|
58
58
|
|
|
59
|
+
**One creation core (no drift).** Both ways to create an effort — the `cckit effort new` verb and
|
|
60
|
+
the `/kit-effort-new` skill — call the **same** shared function `effort_new` (`scripts/lib/effort-ops.sh`).
|
|
61
|
+
That single core fills the four body sections, applies the `ctx/kind/priority/role/flow` label set
|
|
62
|
+
(`ctx:*` via `effort_ctx_bucket`), lints the parent **and every sub** title up front, links the
|
|
63
|
+
native sub-issues, and adds everything to the board. Change the core and both move together; there
|
|
64
|
+
is no second implementation. `scripts/setup-labels.sh` provisions every label family the core
|
|
65
|
+
applies (`ctx:* flow:* kind:* priority:* role:*`) so creation never fails on a missing label.
|
|
66
|
+
|
|
59
67
|
### Title rule, flow tags, relations, session-fit
|
|
60
68
|
|
|
61
69
|
The board should be **legible at a glance** — a title says *what* an effort delivers and *which
|
|
@@ -68,8 +76,9 @@ plain-language **outcome** with an optional leading `[Flow]` tag:
|
|
|
68
76
|
- **Banned in the name:** glyphs (`— ▾ ▸ → ✓ ✗ … •`), parentheses, ` — ` / ` · ` / ` / ` sub-clauses,
|
|
69
77
|
code identifiers (file names, paths, `snake_case`), internal jargon (`chrome`, `seam`, `contract`,
|
|
70
78
|
`rescue stash`, `refactor`, `wiring`, …), and **> 6 words**. Detail goes in the body.
|
|
71
|
-
- **`effort_title_lint`** (`scripts/lib/effort.sh`) is the check; `effort-new`
|
|
72
|
-
|
|
79
|
+
- **`effort_title_lint`** (`scripts/lib/effort.sh`) is the check; `effort-new` lints the parent **and
|
|
80
|
+
every sub** title up front and refuses to create anything if one fails. Bad→good:
|
|
81
|
+
`operator chrome — Settings ▾ dropdown + fixes` → **`[UI] operator navigation`**.
|
|
73
82
|
|
|
74
83
|
**Flow tag (`[Flow]` + `flow:<flow>` label).** A **flow** is a named thread of efforts toward one
|
|
75
84
|
outcome. Controlled vocabulary (`EFFORT_FLOWS` in `effort.sh`; a project overrides it). The title
|
|
@@ -99,15 +108,43 @@ The parent carries the rich narrative; the **PR** carries the human-facing revie
|
|
|
99
108
|
|
|
100
109
|
| Step | What |
|
|
101
110
|
|------|------|
|
|
102
|
-
| `effort-new` | parent issue (
|
|
103
|
-
| `effort-start <N>` | `effort/<N>` branch + worktree; board → In Progress |
|
|
111
|
+
| `effort-new` | parent issue (4-section body **filled** + `ctx/kind/priority/role/flow` labels) + native sub-issues, every title linted; optional `--slug` sets the handle |
|
|
112
|
+
| `effort-start <slug\|N>` | `effort/<N>` branch + worktree; board → In Progress |
|
|
104
113
|
| orchestrate | sub-issues in own worktrees (file-disjoint) → merge into `effort/<N>`; each closes + board Done as it lands |
|
|
105
|
-
| `effort-pr <N>` | ONE PR `effort/<N>` → main (rich body + `## For agents`) |
|
|
106
|
-
| `effort-close <N>` | **snapshot sub-diffs pre-squash** → merge → close parent + subs → board Done(all) → GC prune → kit-sync drift check |
|
|
114
|
+
| `effort-pr <slug\|N>` | ONE PR `effort/<N>` → main (rich body + `## For agents`) |
|
|
115
|
+
| `effort-close <slug\|N>` | **snapshot sub-diffs pre-squash** → merge → close parent + subs → board Done(all) → GC prune → kit-sync drift check |
|
|
107
116
|
|
|
108
117
|
Board + record state are correct **by construction** — the close op owns them. Never rely on a
|
|
109
118
|
separate, skippable "mark done" step.
|
|
110
119
|
|
|
120
|
+
## Wave close — the final sub of every effort
|
|
121
|
+
|
|
122
|
+
When efforts are planned as an **arc** (a chain of `blocked_by` efforts toward one outcome), the
|
|
123
|
+
downstream efforts start as **thin placeholders** — a parent with a Goal + a one-line scope, *not*
|
|
124
|
+
yet decomposed. Every effort's **last sub-issue is a wave-close task** that keeps the arc moving:
|
|
125
|
+
|
|
126
|
+
1. **Fill the next effort's sub-issues** — decompose the next placeholder into its real deliverables
|
|
127
|
+
on the now-clean base, so each plan is scoped **just-in-time** with an accurate `## For agents`
|
|
128
|
+
retrieval context, never guessed up front. (Speculative sub-issues rot; stale sub-issues hide
|
|
129
|
+
unfinished work.)
|
|
130
|
+
2. **Compact the wave** — write a compact summary of what shipped (to the knowledge base + a memory
|
|
131
|
+
drawer) and run `/compact`, so the next wave starts on clean context.
|
|
132
|
+
|
|
133
|
+
This makes the arc **self-propelling**: finishing wave N produces wave N+1's issues. The final effort
|
|
134
|
+
in an arc has nothing to fill next — its wave-close task is compact-and-close only. A single,
|
|
135
|
+
standalone effort needs no wave-close sub.
|
|
136
|
+
|
|
137
|
+
## Slug handles (number stays canonical)
|
|
138
|
+
|
|
139
|
+
The issue **number** is the single source of truth — sub-issue links, PRs, labels, and `blocked_by`
|
|
140
|
+
all reference it. The **slug** is a *derived* human handle (the one in `effort/<N>-<slug>`), never a
|
|
141
|
+
parallel ID space. `effort-start`/`pr`/`close` accept `<slug|N>`: a pure-digits arg is the number,
|
|
142
|
+
anything else is resolved to the canonical number by matching `effort/*` branches (local + remote),
|
|
143
|
+
then the `slug:<slug>` label, then open effort titles. Unknown/ambiguous → structured error, no
|
|
144
|
+
guess. `effort-new --slug <s>` stores the handle as a `slug:<slug>` label; without it the slug is
|
|
145
|
+
derived from the title (with the `[Effort] N ·` prefix and `[Flow]` tag peeled, so the number is not
|
|
146
|
+
doubled into the slug). Efforts render as `slug #N`.
|
|
147
|
+
|
|
111
148
|
## Plans are issues, not files
|
|
112
149
|
|
|
113
150
|
The parent issue **is** the plan. Strategy / roadmap narrative lives in your knowledge base; the
|
|
@@ -100,6 +100,7 @@ Correct-option notes:
|
|
|
100
100
|
## Hooks (scaffolded into `.claude/settings.local.json`)
|
|
101
101
|
|
|
102
102
|
- **SessionStart** → `mempalace wake-up --wing {{WING}}` — injects palace context at session start. Uses `wake-up --wing` (explicit) rather than `mempalace hook run --hook session-start`, which derives the wing implicitly and could file into the wrong wing.
|
|
103
|
+
- **Per-wing header:** `wake-up` scopes the L1 *body* to `{{WING}}`, but its L0 identity *header* comes from the single global `~/.mempalace/identity.txt` and ignores the wing. So this project has its own, `cckit init` seeded **`.claude/mempal-identity.{{WING}}.txt`** (and `cckit doctor` re-seeds it if it goes missing); the hook swaps it in for the global L0 block. **Edit its `Stack:` line** to describe this project — it shows on every session wake-up. Delete the file to fall back to the global identity unchanged.
|
|
103
104
|
- **Stop** → files the finished session into `wing={{WING}}` (`mempalace mine … --mode convos`).
|
|
104
105
|
- **PreCompact** → safety-net sweep before context compression.
|
|
105
106
|
- **SessionEnd** → `mempal_followup.sh`: if the current branch has **unsynced work** (dirty tree or
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
# Plan-next — forward planning from the current state
|
|
2
|
+
|
|
3
|
+
cckit plans **forward from what already ships**. `cckit plan-next` (and the `/kit-plan-next` skill)
|
|
4
|
+
introspect the kit's CURRENT capability surface at runtime — skills, verbs/commands, rules, docs —
|
|
5
|
+
and propose what to build next, grounded in that inventory. This is the productized form of the
|
|
6
|
+
manual "given where we are, here is what to build next" triage.
|
|
7
|
+
|
|
8
|
+
> Two planners coexist, and they answer different questions. `cckit plan` / `/kit-next` order the
|
|
9
|
+
> issues that **already exist** (deps-ordered, file-disjoint waves). `cckit plan-next` proposes the
|
|
10
|
+
> issues that **don't exist yet**, derived from gaps in the current capability surface. Use plan-next
|
|
11
|
+
> to decide *what* to create; use plan / next to decide *in what order* to do the created work.
|
|
12
|
+
|
|
13
|
+
## Where it sits in the workflow
|
|
14
|
+
|
|
15
|
+
```
|
|
16
|
+
cckit plan-next → propose next efforts (grounded in current skills/verbs/rules/docs)
|
|
17
|
+
└─ /kit-plan-next → choose one with the human, hand off to:
|
|
18
|
+
└─ /kit-effort-new → scope it into a parent issue + sub-issues (effort-model.md)
|
|
19
|
+
└─ cckit plan / cckit next → order + drive the now-existing work
|
|
20
|
+
```
|
|
21
|
+
|
|
22
|
+
It is the front of the funnel: it feeds [`/kit-effort-new`](effort-model.md), which produces the
|
|
23
|
+
unit of work the rest of the lifecycle drives.
|
|
24
|
+
|
|
25
|
+
## The mandatory docs + README step (docs-always)
|
|
26
|
+
|
|
27
|
+
**Every plan plan-next emits carries a docs + README update step as rank 1 — non-negotiable, never
|
|
28
|
+
dropped, even for a tiny change.** Docs are part of "done," not a follow-up. When you scope a chosen
|
|
29
|
+
proposal into an effort, that effort MUST keep a docs + README sub-issue. The planner surfaces this
|
|
30
|
+
on every plan precisely so it cannot be forgotten; `/kit-effort-new` must preserve it.
|
|
31
|
+
|
|
32
|
+
## Grounded, not generative
|
|
33
|
+
|
|
34
|
+
The proposals are deterministic and derived from the inventory, not invented:
|
|
35
|
+
|
|
36
|
+
- **Coverage gaps** — skills or verbs that ship but are not referenced in any doc page become
|
|
37
|
+
"document X" proposals.
|
|
38
|
+
- **Thinnest area** — the capability area with the fewest entries becomes a "deepen X" proposal, so
|
|
39
|
+
there is always at least one concrete next effort beyond docs.
|
|
40
|
+
|
|
41
|
+
Run it from the cckit repo for a full inventory, or from a host project where the kit is installed —
|
|
42
|
+
there it degrades gracefully to whatever capability dirs exist (host docs only) and never crashes.
|
|
43
|
+
|
|
44
|
+
## Critical — context-anxiety rule
|
|
45
|
+
|
|
46
|
+
**The plan-next output is HUMAN / orchestrator-facing ONLY.** It must NEVER be injected into a
|
|
47
|
+
monitored model's prompt or context, and it is never wired into any agent's context automatically.
|
|
48
|
+
|
|
49
|
+
The thesis is the opposite of context-stuffing: planning that is *pre-grounded* in the current
|
|
50
|
+
docs/skills/rules means the EXECUTING agent burns fewer tokens rediscovering what the kit can do —
|
|
51
|
+
the plan informs the human/orchestrator's decision, then only the CHOSEN, scoped effort reaches an
|
|
52
|
+
agent. The plan itself is not agent-context fuel. The verb states this in its output footer; the
|
|
53
|
+
skill states it up front; both honor it.
|
|
54
|
+
|
|
55
|
+
## See also
|
|
56
|
+
|
|
57
|
+
- [effort-model.md](effort-model.md) — the unit of work a chosen proposal becomes.
|
|
58
|
+
- [plan-output-format.md](plan-output-format.md) — the format for any written "plan" deliverable.
|
|
@@ -27,7 +27,7 @@ The role determines which agent owns the work. Spawn that agent for the actual e
|
|
|
27
27
|
## The loop
|
|
28
28
|
|
|
29
29
|
1. `/kit-task-sync` — see the board, pick an unblocked issue
|
|
30
|
-
2. `/kit-task-start <N>` — branch from
|
|
30
|
+
2. `/kit-task-start <N>` — isolated worktree + branch from the base, mark In Progress
|
|
31
31
|
3. Do the work (spawn the owning agent)
|
|
32
32
|
4. `/kit-task-pr <N>` — commit, push, open PR
|
|
33
33
|
5. `/kit-task-pr-merge` — squash-merge, back to main
|