@ngockhoale/ukit 3.4.75 → 3.4.77

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -2,6 +2,23 @@
2
2
 
3
3
  All notable changes to UKit are documented here.
4
4
 
5
+ ## 3.4.77 - 2026-11-06
6
+
7
+ - Packaging: the 1.0.0–2.0.7 changelog entries moved verbatim to `docs/archive/CHANGELOG-1.0.0-2.0.7.md` (repository only) so the npm artifact stays inside the unchanged size budget; no runtime or safety code was removed and the size limits were not raised.
8
+ - P0 acceptance: a Claude Code scheduled wakeup (`scheduled_task_fire` in the current delivery window) is recognized as host provenance, never owner authorization; commit/push + script deploy keeps a separate git goal; a milestone with no attempted operation hands back instead of demanding operation verification; an unchanged-state Stop gives a single finite handback.
9
+ - P0 continuation: a pending host background job yields a WAIT Stop (no budget, no edit demand, one release per job); an explicit owner continue/authorization adopts the predecessor task's content-current evidence via a single-hop link; scoped (conditional/purpose/other-subject/quoted) bans no longer prohibit an authorized deploy; non-npm native deploys are proven by deploy + post-deploy receipts; unproven-exit messages name the runner. Replay/unit evidence only.
10
+
11
+ ## 3.4.76 - 2026-11-03
12
+
13
+ **P0 follow-up: UNKNOWN-stop marker store, explicit STOP publication and negation-aware state classification. Isolated process/replay evidence only; not live-host certification.**
14
+
15
+ - `ukit marker-store migrate`: plan by default; `--apply --writers-stopped` refuses unless the owner attests every OMP/bridge session is closed, no process uses the project, no writer temp file exists and the store is unchanged across an observation window. It never kills processes, keeps releases byte-for-byte, turns blocks into sticky releases under the same hashed names, quarantines (never deletes) the old store, and resumes after interruption.
16
+ - Bridge: a fenced or unavailable store fails open (`degraded:storage`) without crash or repeated calls; release-only saturation keeps every release.
17
+ - Explicit owner STOP survives pending route publication and never expires by TTL.
18
+ - Classifier: a negated verb ("do not stop the job") no longer mints a state-verification debt; `khong sua ledger/gate/receipts` stays READ_ONLY.
19
+ - Consumers: close related OMP/bridge sessions, `ukit update`, `ukit marker-store migrate`, then `--apply --writers-stopped`, verify, reopen. STOP stays in effect; legacy cursors are adopted only via explicit `--adopt-legacy-run`.
20
+ - Artifact budget: packed < 3,500,000 and unpacked < 11,300,000 bytes (limits unchanged). To stay under the unpacked limit, about 92 verbose bullets in historical entries (mostly older than 2.7) were shortened in this file, saving about 22 KB; no release was removed, and the full original text is in git history at 46b48d11.
21
+
5
22
  ## 3.4.75 - 2026-11-01
6
23
 
7
24
  - Publish receipts bind to artifact integrity.
@@ -2038,7 +2055,7 @@ pulls from npm, so an install on 2.3.19 (or older) needs an update to receive th
2038
2055
 
2039
2056
  C14 bug-fix release record — one correctness fix is shipped; this release adds no new features.
2040
2057
 
2041
- - **Completion gate no longer silently releases a reentrant stop.** `templates/.claude/ukit/runtime/execution-ledger.mjs` (`--evaluate-stop`) had a `stop_hook_active` valve: when Claude Code re-fired `Stop` after the gate had already blocked once, the valve emitted only a `systemMessage` with no `decision` while completion evidence was still missing, so the turn ended and the session idled until the human typed "tiếp". The valve is removed — a reentrant stop is now evaluated like any other stop, blocking again with the actionable missing-evidence reason (produce the evidence or report a blocker), and the loop stays bounded by the existing visible continuation cap and the verification-loop blocker, so a finished task is never trapped.
2058
+ - **Completion gate no longer silently releases a reentrant stop.** `templates/.claude/ukit/runtime/execution-ledger.mjs` (`--evaluate-stop`) had a `stop_hook_active` valve:
2042
2059
 
2043
2060
  ## 2.3.18 - 2026-09-12
2044
2061
 
@@ -3068,7 +3085,7 @@ Follow-up to the user's report that UKit had become too heavy-handed: too many h
3068
3085
  ### Changed
3069
3086
 
3070
3087
  - **`PreToolUse:Bash` now runs 4 hook scripts instead of 6.** `verification-guard.sh` was removed from the default Bash chain (both `.claude/settings.json` copies, the omp bridge's `HOOK_EVENT_MAP`/`FAIL_CLOSED_SCRIPTS`, and `hook-chain-runner.mjs`'s own classification). Its hard-block path is gated behind `UKIT_VERIFICATION_GUARD_ENFORCE=1`, unset by default, so it was pure per-call overhead (a full `node` spawn) for zero present safety value. The script and its standalone tests are untouched — still shippable, opt-in.
3071
- - **`PreToolUse:Read|Grep|Glob` no longer runs `skill-router.sh`.** Automatic skill activation still runs on `UserPromptSubmit` and `Edit|Write`, where a skill choice actually matters; it no longer re-evaluates on every read-only tool call. Traded away: skill-router no longer sees "which files were Read/Grep'd" as mid-task evidence — only the original prompt and Edit/Write targets.
3088
+ - **`PreToolUse:Read|Grep|Glob` no longer runs `skill-router.sh`.** Automatic skill activation still runs on `UserPromptSubmit` and `Edit|Write`, where a skill choice actually matters;
3072
3089
 
3073
3090
  ### Fixed
3074
3091
 
@@ -3086,7 +3103,7 @@ Follow-up to 2.2.3's hook-chain collapse: a real omp session on a CloudMounter/F
3086
3103
  ### Fixed
3087
3104
 
3088
3105
  - **Outer transport failures no longer impersonate a specific safety gate.** `runScriptChain` in `ukit-bridge.js` treated a killed/timed-out `pi.exec`, empty stdout, or malformed JSON from `hook-chain-runner.mjs` as proof that the chain's first fail-closed script (e.g. `protect-files.sh`) had failed — without verifying that script ever ran. It now distinguishes "the runner returned a verifiable per-script result" from "the runner itself failed before producing one," and on the latter reports the real failure (killed/code/elapsedMs/runtime) instead of a fabricated gate name. Diagnostics are appended to `.ukit/storage/cache/hook-errors/<session>.jsonl`.
3089
- - **Bash and Read/Grep/Glob no longer fail closed on a bridge/runner outage.** Only `Edit`/`Write` chains still block when the runner can't produce a verdict, since those guard file mutation. Ordinary shell commands and read-only tools now fail open (with a logged warning), so a runner-level hiccup can no longer brick command execution or diagnosis tools.
3106
+ - **Bash and Read/Grep/Glob no longer fail closed on a bridge/runner outage.** Only `Edit`/`Write` chains still block when the runner can't produce a verdict, since those guard file mutation.
3090
3107
  - **`process.execPath` is no longer trusted blindly for the runner subprocess.** The bridge resolves `process.env.UKIT_NODE_PATH || process.execPath` and records the resolved runtime in the failure diagnostic, so a Bun-hosted omp launching the Node-only runner under the wrong binary is now visible instead of silently assumed.
3091
3108
 
3092
3109
  ### Added
@@ -3099,17 +3116,17 @@ Sessions were stalling mid-task — the model would read source, then simply sto
3099
3116
 
3100
3117
  ### Fixed
3101
3118
 
3102
- - **Silent stalls were unenforceable, because nothing measured them.** A stop after a read-only pass was indistinguishable from a stop after finished work: both were just the model ending its turn. UKit now keeps a session-scoped execution ledger (`.ukit/storage/cache/exec-ledger/<session>.json`) recording source reads, write attempts and outcomes, and verification commands with their exit codes. A new `Stop` hook (`completion-gate.sh`, and omp's `session_stop`) reads it against the routed contract's `completionEvidence` and blocks a premature stop with the specific missing evidence and a recovery instruction matched to the actual state — no source yet, failed write, no write, failed verification, or no verification each get different guidance. Recovery is capped at 6 continuations, then degrades to a warning, so the gate can never loop.
3119
+ - **Silent stalls were unenforceable, because nothing measured them.** A stop after a read-only pass was indistinguishable from a stop after finished work:
3103
3120
  - **The omp bridge could exceed omp's own handler budget and freeze the session.** A single `Edit` fired 7 hook scripts as 7 serial `pi.exec` subprocesses at up to 8s each — worst case well past omp's ~30s outer timeout, which surfaces to the user as the session simply hanging. They now run in one bounded `hook-chain-runner.mjs` process: 4s per script, 10s total budget, under a 12s outer timeout. Per-event latency is appended to `.ukit/storage/cache/hook-latency/<session>.jsonl` so hook cost stops being invisible.
3104
- - **omp writes bypassed the safety gates entirely.** omp's `normalizeToolEventInput` emits `path` / `paths`; every UKit hook script reads `file_path`. So `protect-files.sh` and `stale-spec-guard.sh` saw no target on an omp edit and waved it through. The bridge now normalizes `path` / `paths[0]` → `file_path` at the host boundary, without mutating the caller's event.
3121
+ - **omp writes bypassed the safety gates entirely.** omp's `normalizeToolEventInput` emits `path` / `paths`;
3105
3122
  - **An unmapped mutation-capable tool failed open and silently.** `mapToolName` returned `null` for any tool not in its table, and the bridge ran an empty script chain — so a host tool that writes files but is not yet mapped skipped every guard with no signal. Such tools are now blocked with a message naming the tool; unmapped read-only tools still pass through.
3106
- - **The ledger CLI silently did nothing under a symlinked project root.** Its main-guard compared `fileURLToPath(import.meta.url)` against `path.resolve(process.argv[1])`. Under macOS `/tmp` → `/private/tmp`, or any symlinked work directory, those differ — so `--record` and `--evaluate-stop` returned exit 0 having done nothing: no receipts, no gate. The whole unit suite stayed green; only a scratch install under `/tmp` exposed it. Both paths are now compared by realpath, covered by `tests/hooks/executionLedgerCli.test.js`.
3107
- - **`.omp/config.yml` documented the model aliases backwards**, calling the UNIC names "LITERAL model names, not aliases". They are stable provider-neutral aliases whose hidden backends change during development — which is precisely why orchestration must not branch on vendor names.
3123
+ - **The ledger CLI silently did nothing under a symlinked project root.** Its main-guard compared `fileURLToPath(import.meta.url)` against `path.resolve(process.argv[1])`.
3124
+ - **`.omp/config.yml` documented the model aliases backwards**, calling the UNIC names "LITERAL model names, not aliases".
3108
3125
 
3109
3126
  ### Added
3110
3127
 
3111
- - **`tests/hooks/executionLedgerCli.test.js`** (4 tests) — drives the real CLI through a symlinked root: receipts get written, a premature stop is blocked, a stop with write + passing verification is allowed, and the continuation cap engages at exactly 6. Verified RED against the pre-fix guard (3 of 4 fail).
3112
- - **Manifest entries and dev-mirror parity for the four new files** — `record-execution.sh`, `completion-gate.sh`, `execution-ledger.mjs`, `hook-chain-runner.mjs`. `templates/.claude/` is gitignored and existing template files were force-added, so new ones are invisible to both git and `npm pack` unless added the same way; verified present in the packed tarball, with hook scripts executable after a real `ukit install`.
3128
+ - **`tests/hooks/executionLedgerCli.test.js`** (4 tests) — drives the real CLI through a symlinked root:
3129
+ - **Manifest entries and dev-mirror parity for the four new files** — `record-execution.sh`, `completion-gate.sh`, `execution-ledger.mjs`, `hook-chain-runner.mjs`.
3113
3130
 
3114
3131
  ## 2.2.2 - 2026-08-22
3115
3132
 
@@ -3119,20 +3136,20 @@ It also settles the three `TODO(verify)` items 2.2.1 shipped with. Those were pl
3119
3136
 
3120
3137
  ### Fixed
3121
3138
 
3122
- - **Auto-compact was never actually configured on omp.** `.omp/config.yml` set `compact.autoCompactWindow: 180000`, a key omp does not have — `omp config get compact.autoCompactWindow` answers "Unknown setting", so the value was inert and omp stayed on its own default. The real key is `compaction.thresholdTokens` ("Fixed token limit for context maintenance; overrides percentage if set", omp's default `-1`). Verified end-to-end against a scratch project: the nested form now reads back as `180000`, which is below `compact.hardCapTokens` (220000) as intended, so auto-compact fires before `context-hardcap-gate.sh` starts blocking tool calls.
3123
- - **Post-compact hooks never ran on omp.** The bridge assumed omp re-emitted `session_start` after a compaction, the way Claude Code's matcher-less `SessionStart` hook fires with `source: "compact"`. It does not — it has a dedicated event instead (`session_before_compact` → `session.compacting` → `session_compact`, the last firing once compaction settles). So on omp the entire post-compact chain was lost: the run cursor stayed un-surfaced, compact pressure was never reset, and a mid-cycle handoff silently failed to resume after a compaction. `ukit-bridge.js` now maps `session_compact` onto the same script chain, keeping `hook_event_name: 'SessionStart'` in the payload so the scripts stay shared with Claude Code rather than forked.
3124
- - **Two UNIC gateway probes could never have fired.** `unic-gateway.mjs` probed an `OMP_BASE_URL` env var and a `baseUrl` key in `.omp/config.yml`. Neither exists: omp's anthropic provider reads `ANTHROPIC_BASE_URL` (falling back to `https://api.anthropic.com`), and its settings schema declares no `baseUrl` at any level. Both probes are removed rather than left returning a permanent `false` — a probe that can never fire is worse than no probe, because it reads as coverage. Detection is unchanged in behaviour and now literally matches what the docs already claimed: routing is decided only by `ANTHROPIC_BASE_URL`, on omp for the same reason as on Claude Code.
3139
+ - **Auto-compact was never actually configured on omp.** `.omp/config.yml` set `compact.autoCompactWindow:
3140
+ - **Post-compact hooks never ran on omp.** The bridge assumed omp re-emitted `session_start` after a compaction, the way Claude Code's matcher-less `SessionStart` hook fires with `source:
3141
+ - **Two UNIC gateway probes could never have fired.** `unic-gateway.mjs` probed an `OMP_BASE_URL` env var and a `baseUrl` key in `.omp/config.yml`.
3125
3142
  - **omp behaved as if UKit only had one model, because it was never told otherwise.** `templates/AGENTS.md` — the context doc omp, Codex and OpenCode read — was missing the entire `3-Tier Model Routing` block, plus `Post-Edit Sidecar Review` and `Skill Quality`, and still announced itself as `UKit v1.5.1`. `.omp/config.yml` declared `modelRoles` for all four lanes, but nothing in omp's context ever said *when* to use a tier, so everything ran inline on the session model.
3126
3143
  - **Five section pairs had been renamed apart** — `Core Rule`/`Core UKit Rule`, `Fast Classification`/`Fast Task Classification`, `Internal Helper Policy`/`Internal Helper Routing`, `Selective Subagent Policy`/`Subagent Policy`, `Project Snapshot`/`Environment Snapshot`. This is what let the drift hide: once the headings differ, no diff lines up and the gap is invisible. Headings are now shared, and the two docs carry byte-identical bodies for every shared section.
3127
- - **Every session opened by being told to resume a finished cycle.** `docs/AI_HANDOFF/RUN.md` was left at `Phase: R4` after 2.2.1 shipped, so `handoff-resume.sh` — which runs in the `session_start` chain of *both* Claude Code and the omp bridge — fired a "CONTINUATION — resume immediately" banner at the start of every new, unrelated session. The cursor now reads `Phase: done`.
3128
- - **`/ukit:*` commands re-pasted the user's whole problem statement up to seven times per file.** Only one `$ARGUMENTS` site per command is a real interpolation (the `## Problem / feature` body); the other six were *references* that expanded to the entire paragraph again mid-sentence. They now say "the **Problem / feature** section above".
3129
- - **Eight fallback lines told the model to do something only a human can do.** `> Other tools without subagent support: manually switch to the strong model` reads, to a running model, as an instruction to itself — which it cannot follow, so it improvises. Each is now explicitly addressed: `> **For the human operator, on a tool with no agent support (Codex, OpenCode) — not an instruction to the model:**`.
3144
+ - **Every session opened by being told to resume a finished cycle.** `docs/AI_HANDOFF/RUN.md` was left at `Phase:
3145
+ - **`/ukit:*` commands re-pasted the user's whole problem statement up to seven times per file.** Only one `$ARGUMENTS` site per command is a real interpolation (the `## Problem / feature` body);
3146
+ - **Eight fallback lines told the model to do something only a human can do.** `> Other tools without subagent support:
3130
3147
 
3131
3148
  ### Added
3132
3149
 
3133
- - **`### How a tier is actually bound`** in both context docs. The main session model never changes mid-turn; a tier only takes effect when work is handed to an agent whose own definition binds that model. The section carries a harness table (Claude Code `.claude/agents/*.md` + `subagent_type`, omp `.omp/agents/*.md` + `task-agent`) and states the consequence plainly: doing everything inline is exactly what makes UKit behave as if it had one model.
3150
+ - **`### How a tier is actually bound`** in both context docs. The main session model never changes mid-turn;
3134
3151
  - **`tests/consistency/contextDocsParity.test.js`** (29 tests) — every `## ` section must exist in both `templates/CLAUDE.md` and `templates/AGENTS.md` with byte-identical bodies, unless allowlisted with a stated reason (currently one entry: `Session Start — OpenCode`, which exists because OpenCode does not auto-load `.claude/skills/`). Also asserts neither doc hardcodes a version, and that both manifest items declare the same variable set.
3135
- - **`.omp/RULES.md` grew from 4 rules to 7**, targeting direct chat specifically — direct chat is steered only by static context, so what is missing there is simply never applied. New: `Classify first, then act` (Trivial / Simple / Non-trivial lanes, decided *before* the first tool call), `Auto-activate skills`, and `Delegate to bind a model tier`. It stays short on purpose: it is re-attached near every turn.
3152
+ - **`.omp/RULES.md` grew from 4 rules to 7**, targeting direct chat specifically — direct chat is steered only by static context, so what is missing there is simply never applied.
3136
3153
  - **The three `/ukit:*` sites that named only Claude Code now name omp too** — `handoff-fullstack.md`'s Model Split note, and the small-task-maintainer lines in `handoff-clear.md` and `handoff-status.md`.
3137
3154
 
3138
3155
  ### Changed
@@ -3146,27 +3163,27 @@ UKit gains a fourth runtime and loses one. omp (Oh My Pi) reaches full parity wi
3146
3163
 
3147
3164
  ### Added
3148
3165
 
3149
- - **omp (Oh My Pi) adapter — `ukit install --tools=omp`** (alias `--tools=oh-my-pi`). Installs 11 files: `.omp/AGENTS.md` (a thin `@../AGENTS.md` import rather than a copy, so the shared instructions have exactly one home), `.omp/RULES.md` (sticky hard rules), `.omp/config.yml`, `.omp/README.md`, `.omp/hooks/pre/ukit-bridge.js`, and the six agents under `.omp/agents/`. **No symlinks are created.** omp's discovery providers already rank its `claude` provider above nothing at all for skills and commands, so `.claude/skills/` and `.claude/commands/` are read directly — an `.omp/skills` symlink would shadow the canonical tree for no benefit. `.omp/agents/` must be real files because omp explicitly skips `.claude/agents/*.md`.
3150
- - **All six shared agents ported to omp's task-agent contract**: `bug-debugger`, `code-reviewer`, `feature-implementer`, `handoff-planner`, `ukit-small-task-maintainer`, `ukit-vision-analyst`. The differences between each agent's Claude Code and omp form — and why each one is or is not a faithful port — are recorded in [`docs/research/2026-08-22_omp-agent-parity.md`](docs/research/2026-08-22_omp-agent-parity.md).
3151
- - **UNIC model names survive the port.** `.omp/config.yml` ships `modelRoles` with all four lanes intact: `lite: unic-lite`, `code: unic-code`, `smart: unic-smart`, `vision: unic-vision`. The vision lane stays a capability lane, not a fourth cost tier.
3166
+ - **omp (Oh My Pi) adapter — `ukit install --tools=omp`** (alias `--tools=oh-my-pi`).
3167
+ - **All six shared agents ported to omp's task-agent contract**: `bug-debugger`, `code-reviewer`, `feature-implementer`, `handoff-planner`, `ukit-small-task-maintainer`, `ukit-vision-analyst`.
3168
+ - **UNIC model names survive the port.** `.omp/config.yml` ships `modelRoles` with all four lanes intact:
3152
3169
  - **Hook bridge — one source of truth, two runtimes.** `.omp/hooks/pre/ukit-bridge.js` is an omp hook factory (`export default function hook(pi)`) that translates omp's events into the Claude Code hook JSON shape and then executes the **existing** `.claude/hooks/*.sh` scripts. The 20 shell hooks are not duplicated, forked, or rewritten for omp; a fix to one fixes both runtimes.
3153
- - **Auto-compact parity.** `compact.agentContext.targets` gains an `omp` entry using `mode: 'precompact-reinject'` — the same strategy as `claude`, not Codex's `soft-handoff`. omp exposes real pre-compaction hook events, so there is nothing to work around with a state file.
3154
- - **`agent-code-reviewer` manifest item.** `templates/.claude/agents/code-reviewer.md` had shipped as a template with no manifest item since it was introduced, and `autoDiscoverTemplates: false` meant it was therefore **silently never installed** — UKit was installing five of its six Claude agents. Both the handoff Phase 4 reviewer and the Post-Edit Sidecar Review added in 2.1.5 instruct the model to spawn an agent that was not present in any installed project. Found by the omp parity work, because the new adapter would otherwise have shipped a strictly better agent set than the one it was porting from.
3170
+ - **Auto-compact parity.** `compact.agentContext.targets` gains an `omp` entry using `mode:
3171
+ - **`agent-code-reviewer` manifest item.** `templates/.claude/agents/code-reviewer.md` had shipped as a template with no manifest item since it was introduced, and `autoDiscoverTemplates:
3155
3172
 
3156
3173
  ### Changed
3157
3174
 
3158
- - **`/ukit:*` commands are phrased for whichever runtime is reading them.** The command bodies no longer assume Claude Code's spawn mechanics; each names its model tier and its delegation step in runtime-neutral terms, so the same file drives the same pipeline under Claude Code and under omp.
3175
+ - **`/ukit:*` commands are phrased for whichever runtime is reading them.** The command bodies no longer assume Claude Code's spawn mechanics;
3159
3176
  - **`ukit status` reports `Oh My Pi (omp)`** and checks `.omp/config.yml`; the Antigravity row is gone.
3160
3177
  - **`.omp/` is TCC-protected** (`applyPlan.js`) and **git-ignored** by the managed `.gitignore` block, alongside `.claude/` and `.codex/`.
3161
3178
 
3162
3179
  ### Removed
3163
3180
 
3164
3181
  - **The Antigravity adapter.** `templates/.antigravity/`, `templates/adapter-presets/antigravity/`, the five `multi-antigravity-*` manifest items, its entry in `src/cli/adapters.js`, and every user-facing mention — in `README.md`, `QUICK_START.md`, `docs/PROJECT.md`, and in the installed workspace itself: `AGENTS.md`, `.codex/README.md` and the four `/ukit:handoff-*` command files all named Antigravity as a tool you could use. `--tools=antigravity` now fails fast with `Antigravity has been removed as a UKit adapter.` plus the list of adapters that do exist, rather than silently installing nothing.
3165
- - **Legacy cleanup is retained, not removed.** `ukit uninstall` still cleans `.antigravity/`, and `.antigravity/` keeps its TCC protection, because a stale pre-2.2.0 install still has the directory. Install-time pruning now covers it too: `.antigravity/` joined `AUTO_PRUNE_OBSOLETE_PREFIXES`, so a re-install removes the stale symlinks a pre-2.2.0 install left behind. Without it those links would dangle forever — pruning is the only pass that ever revisits them, and removing the adapter took them out of the manifest that uninstall reads. Only paths UKit itself recorded in `install.json` are considered, and a path the user has replaced with a real directory is skipped with a warning instead of being silently left behind.
3182
+ - **Legacy cleanup is retained, not removed.** `ukit uninstall` still cleans `.antigravity/`, and `.antigravity/` keeps its TCC protection, because a stale pre-2.2.0 install still has the directory.
3166
3183
 
3167
3184
  ### Fixed
3168
3185
 
3169
- - **Deselecting omp no longer orphans its agents.** `OPTIONAL_ADAPTERS`' `managedPaths` listed `.omp/agents` as a single entry, copying the shape of Codex's `.codex/agents`. Codex's is a symlink; omp's is a real directory of six real files. `removeFileOrLinkOnly` refuses real directories, so re-running `ukit install` without `omp` and confirming removal deleted nothing — while the metadata pass still dropped all six from `install.json`, leaving them on disk and untracked forever. The six paths are now listed individually, matching `uninstall.js`'s own list. Full `ukit uninstall` was never affected.
3186
+ - **Deselecting omp no longer orphans its agents.** `OPTIONAL_ADAPTERS`' `managedPaths` listed `.omp/agents` as a single entry, copying the shape of Codex's `.codex/agents`.
3170
3187
  - **The `--tools=antigravity` regression test was passing vacuously.** It asserted on a directory the install pipeline had never been pointed at, so the "no partial write" half would have held even if the error path did write. It now runs the real `bin/ukit`, and checks the exit code, the stderr text, the absence of a stack frame, and that not even the always-on `.claude/` adapter was written.
3171
3188
 
3172
3189
  **Known gap:** omp was not installed on the machine this release was built on. Every omp assertion in the test suite is against the generated `.omp/` tree and the bridge module's shape — the packed-tarball test confirms `templates/.omp/**` actually publishes, but nothing here observes omp's runtime behaviour. The three open verification items (does omp emit `session_start` on a post-compact continuation; omp's real base-URL key; omp's real auto-compact-window key) are recorded in `docs/AI_HANDOFF/tasks/TASK-008.md`.
@@ -3177,7 +3194,7 @@ UKit gains a fourth runtime and loses one. omp (Oh My Pi) reaches full parity wi
3177
3194
 
3178
3195
  ### Changed
3179
3196
 
3180
- - **`local-build` now requires verification evidence, not just write evidence, before claiming done.** `orchestration.contracts['local-build'].completionRule` was `require-write`; every other multi-step contract (`shared-edit`, `find-cause`, `map-impact`) already required verification too, so `local-build` was the odd one out — the exact lane where a weaker executor model producing "silly bugs" that pass a glance but fail a real check would go unnoticed. `completionEvidence` now includes `verification-evidence` alongside `write-evidence` in `src/index/taskRouting.js`, mirrored in `src/core/runtimeConfig.js` and both `config.json` copies. `tests/index/taskRouting.test.js` and `tests/core/runtimeConfig.test.js` lock the new requirement.
3197
+ - **`local-build` now requires verification evidence, not just write evidence, before claiming done.** `orchestration.contracts['local-build'].completionRule` was `require-write`;
3181
3198
 
3182
3199
  ### Added
3183
3200
 
@@ -3200,8 +3217,8 @@ More room before compaction, the handoff hooks stop taxing every call they were
3200
3217
 
3201
3218
  ### Added
3202
3219
 
3203
- - **`.claude/ukit/index/provision-worktree.mjs`** — deterministic worktree provisioning for handoff waves, packaged via `manifests/platform.full.yaml`. It hides the worktree's `node_modules` symlink through the worktree's own `.git/info/exclude` (a symlink never matched `.gitignore`'s `node_modules/`, so an orchestrator `git add -A` would have committed a machine-local absolute path), and skips git-tracked files when copying `.claude/` so it cannot clobber `.claude/commands/ukit/handoff-fullstack.md`. **Shipped but not yet wired into `handoff-implement`** — the wiring is queued for a later release.
3204
- - **Test-selection policy in `docs/AI_HANDOFF/RULES.md`** — per-task related tests are the floor, and a full suite at the wave/cycle boundary is mandatory, not optional. This is the compensating net that makes narrowed per-task scope safe; the agent definitions already cited it before it existed.
3220
+ - **`.claude/ukit/index/provision-worktree.mjs`** — deterministic worktree provisioning for handoff waves, packaged via `manifests/platform.full.yaml`.
3221
+ - **Test-selection policy in `docs/AI_HANDOFF/RULES.md`** — per-task related tests are the floor, and a full suite at the wave/cycle boundary is mandatory, not optional.
3205
3222
  - **`scripts/bench/parallel-agents.mjs`** — harness for measuring concurrent test-process contention at several parallelism levels, recording `slowdownFactor` / `perRunCost` / a `recommended` value plus the load averages the run happened under. It measures test-process contention, not LLM agents.
3206
3223
  - **`handoff.maxParallelAgents`: 10 → 12.** Chosen, not measured — the benchmark above was never run on a quiet enough machine, so this is the middle of the ~10-15 safe band the config's own `_help` has always documented. Lower it to 3-5 if your tasks produce long verification output or you see compaction firing repeatedly.
3207
3224
 
@@ -3233,12 +3250,12 @@ Follow-up to 2.1.0, which fixed the wrong hook. Runs were still freezing mid-tas
3233
3250
 
3234
3251
  ### Added
3235
3252
 
3236
- - **`compact.hardCapGraceCalls`** (default `10`). Budget is per over-cap episode, not per wave: it resets only when the token estimate actually falls (a real compaction happened), so a long run cannot mint itself unlimited grace by advancing its cursor. With no unfinished run the gate's behavior is unchanged.
3237
- - **`tests/hooks/contextHardcapGate.test.js`** — 12 cases covering under-cap pass-through, blocking with no run in flight, `Phase: done` treated as no run, grace grant/exhaustion, no top-up on cursor advance, budget restored after a real compaction, `hardCapBlock=false` escape hatch, non-gated tools, fail-open on malformed input, template/mirror parity, and manifest+settings wiring.
3253
+ - **`compact.hardCapGraceCalls`** (default `10`). Budget is per over-cap episode, not per wave:
3254
+ - **`tests/hooks/contextHardcapGate.test.js`** — 12 cases covering under-cap pass-through, blocking with no run in flight, `Phase:
3238
3255
 
3239
3256
  ### Notes
3240
3257
 
3241
- - **No hook can call `/compact`** — it is a client-only command, so UKit cannot auto-compact on your behalf. The supported path is: land inside the grace window → user runs `/compact` (or Claude Code's own auto-compact fires) → the `handoff-resume.sh` SessionStart hook replays the cursor → the run continues. Enabling auto-compact in Claude Code's `/config` makes that middle step automatic.
3258
+ - **No hook can call `/compact`** — it is a client-only command, so UKit cannot auto-compact on your behalf.
3242
3259
 
3243
3260
  ## 2.1.0 - 2026-08-16
3244
3261
 
@@ -3247,659 +3264,23 @@ Handoff autonomy wave: `/ukit:handoff-fullstack` runs a whole goal end-to-end wi
3247
3264
  ### Added
3248
3265
 
3249
3266
  - **Autonomy Contract in all four handoff commands.** `handoff-create` owns the single question window — one batched `AskUserQuestion` (max 4, recommended option first) before planning starts, covering scope, conflicting interpretations, subsystem choice and acceptance criteria only. `handoff-fullstack`, `handoff-implement` and `handoff-review` ask nothing between that window and the Final Report; each command carries a table mapping every former STOP to its required automatic behavior.
3250
- - **Run cursor + resume protocol (`docs/AI_HANDOFF/RUN.md`).** Every phase transition writes `Phase`/`Cursor`/`Next`. A `Phase:` other than `done` means the next session is a continuation: no re-plan, no re-scope, no questions. New config `handoff.autonomy.resumeFromCursor` / `runCursorFile`.
3267
+ - **Run cursor + resume protocol (`docs/AI_HANDOFF/RUN.md`).** Every phase transition writes `Phase`/`Cursor`/`Next`.
3251
3268
  - **`handoff-resume.sh` SessionStart hook** (manifest id `hook-handoff-resume`). Reads the run cursor and prints a resume banner with Goal/Base/Phase/Cursor/Next, plus two extra lines when the session started from `source: compact`. Advisory only, always exits 0, silent when there is no unfinished run.
3252
- - **Auto-fix loop after review (max 2 rounds).** Non-approved tasks are re-waved and re-implemented in parallel — agents read their own `## Reviewer Verdict` from disk — then committed and re-reviewed. After round 2 the stuck tasks stay `blocked` and the rest of the pipeline proceeds instead of halting. Config: `handoff.autonomy.autoFixRounds`.
3269
+ - **Auto-fix loop after review (max 2 rounds).** Non-approved tasks are re-waved and re-implemented in parallel — agents read their own `## Reviewer Verdict` from disk — then committed and re-reviewed.
3253
3270
  - **Planner Grounding + 12-point Self-Audit.** `handoff-planner` must verify that every Target File exists (or is marked `(new)`), that every Verification Command is a real `package.json` script, and that test file paths match the neighbouring test layout; then run a 12-point self-audit (coverage / correctness / test quality, including "could every listed test pass against an empty implementation?") and report the result. Compensates for dropping plan review from 3 rounds to 2.
3254
- - **Wave-boundary commit + context checkpoint.** Each wave ends with `git add -A && git commit -m "handoff: wave <N> — TASK-00x, ..."`, a cursor update, and a collapse of that wave to one line per task in working memory. Config: `handoff.autonomy.commitPerWave`.
3271
+ - **Wave-boundary commit + context checkpoint.** Each wave ends with `git add -A && git commit -m "handoff:
3255
3272
 
3256
3273
  ### Changed
3257
3274
 
3258
- - **`git push` moved from the `ask` list to `allow`** in default settings, alongside `git add`, `git commit` and `git worktree`. Runs no longer stop at the final step for a confirmation. `git push --force` and `--force-with-lease` remain in `deny`, which still wins over `allow`.
3259
- - **Subagent return contracts are now capped.** Executors return ≤10 lines (`TASK`/`STATUS`/`EXECUTOR_MODEL`/`FILES`/`RED`/`VERIFY`/`NOTE`), reviewers ≤6. Verbose agent reports injected back into the orchestrator were the main cause of context exhaustion on long fullstack runs; this addresses it structurally rather than by raising caps.
3260
- - **`context-window-guard.sh` is now run-cursor aware.** With an unfinished run it emits shed-context-and-continue instructions instead of the stop-and-`/compact` directive. Asking the user to `/compact` is permitted only at a cycle boundary, in the Final Report — never mid-task. Config: `handoff.autonomy.compactAtCycleBoundaryOnly`.
3261
- - **Same-wave file conflicts auto-serialize** instead of marking both tasks `needs_breakdown`: the higher-numbered task gains a `Dependencies: TASK-<lower>` line and moves to the next wave. Config: `handoff.autonomy.autoSerializeFileConflicts`.
3275
+ - **`git push` moved from the `ask` list to `allow`** in default settings, alongside `git add`, `git commit` and `git worktree`.
3276
+ - **Subagent return contracts are now capped.** Executors return ≤10 lines (`TASK`/`STATUS`/`EXECUTOR_MODEL`/`FILES`/`RED`/`VERIFY`/`NOTE`), reviewers ≤6.
3277
+ - **`context-window-guard.sh` is now run-cursor aware.** With an unfinished run it emits shed-context-and-continue instructions instead of the stop-and-`/compact` directive.
3278
+ - **Same-wave file conflicts auto-serialize** instead of marking both tasks `needs_breakdown`:
3262
3279
  - **A dirty working tree no longer blocks Phase 3.** It is committed as `handoff: checkpoint before implement` and the run continues.
3263
3280
  - **Plan review loop cap: 3 rounds → 2**, then findings are applied and the run proceeds (logged as `### Round <N> — findings applied without re-review`). Config: `handoff.autonomy.planReviewRounds`.
3264
3281
  - **Review diff range is now anchored to the plan commit** (`git log --grep='^handoff: plan' -n 1`) rather than the working tree, since waves are committed as they finish.
3265
3282
  - **`handoff-planner` maximizes wave width.** `Dependencies: none` unless task B genuinely cannot be written without A's output — ordering preference, same code area and review order are explicitly not dependencies.
3266
- - **`feature-implementer` and `code-reviewer` run unattended in handoff mode.** Ambiguity resolves through task file → PLAN.md → surrounding code → recommended choice, recorded in `## Discussion`; reviewer findings must be actionable defects (`file:line` + concrete failure + what correct looks like), never questions. Daily (non-handoff) behavior is unchanged.
3267
- - **`handoff-model-guard.sh` gained a bash fast path** that skips the node spawn when the payload contains neither `AI_HANDOFF` nor `git push`. Behavior-identical (verified against the previous version across a 6-payload sweep); measured 67ms → 38ms per ordinary Bash/Edit/Write call, paid on every call in every parallel subagent.
3268
-
3269
- ## 2.0.7 - 2026-08-15
3270
-
3271
- ### Added
3272
-
3273
- - **`/ukit:handoff-create` and `/ukit:handoff-fullstack` gain a P2.5 independent plan review gate.** After the planner writes `PLAN.md` and before it's committed, a separate `code-reviewer` agent invocation (`REVIEW_TARGET_TYPE=plan`, fresh context — not the planner reviewing its own work) checks Completeness/Consistency/Clarity/Scope/YAGNI. `Issues Found` routes back to the planner to revise and resubmit; `Approved` unlocks the commit. Each round is logged to PLAN.md's new `## Plan Review Log` section, and the loop is capped at 3 `Issues Found` rounds — past that it escalates to the human instead of looping indefinitely.
3274
- - **Same-wave file-conflict precheck in Phase 3.** Before spawning any implementation wave, `handoff-implement.md`/`handoff-fullstack.md` now compare `Target Files` across every task in that wave; any overlap stops the wave and marks both tasks `needs_breakdown` instead of risking a mid-wave merge conflict. Code-level backstop for the planner's existing "no shared files in one wave" scope constraint.
3275
- - **TDD RED-state now requires real evidence.** The Executor Report template adds a mandatory `RED_OUTPUT` field — the actual failing-test output pasted before implementation, not a bare "confirmed" claim. `code-reviewer` checks this field during Test Plan adherence review and requests changes if it's missing or vague.
3276
- - **`handoff.plan.requireLintOrTypecheckInVerification`** (default `true`): when the project has a lint/typecheck script, task Verification Commands must run it, not just tests; the planner must state an explicit N/A if the project has none. Enforced by `code-reviewer` as review-order step 0.
3277
-
3278
- ### Changed
3279
-
3280
- - **`handoff.maxParallelAgents`**: 3 → 10, raising the default cap on concurrent background agents per wave (config comments still warn against exceeding ~10-15 — each agent's report gets injected back into the orchestrator's own context on completion).
3281
- - **Phase 4 (Review) is now parallelized**, batched by `maxParallelAgents` the same way Phase 3 (Implement) already was — reviewer agents only read a diff and append a verdict to their own task file, so parallel review carries none of Phase 3's shared-worktree conflict risk.
3282
- - **`handoff.plan.minTestsEdgeCase`**: 1 → 2, and the two edge cases must now be of different kinds (e.g. null/empty **and** boundary/concurrent) — two near-duplicate cases no longer satisfy the requirement. Wired through `handoff-planner`, `code-reviewer`, `feature-implementer`'s inline-test-plan fallback, `RULES.md`, and both handoff pipeline commands.
3283
-
3284
- ## 2.0.6 - 2026-08-12
3285
-
3286
- ### Changed
3287
-
3288
- - **`context-window-guard.sh` now issues an actionable directive instead of a passive notice.** At 80%+ of `compact.hardCapTokens` it previously only printed an FYI warning that nothing acted on, so it kept re-firing every prompt with no remedy. It now instructs the agent, in the same turn: persist progress to `docs/STATUS.md` (update-status skill), split remaining multi-phase work (e.g. a `handoff-fullstack` run) into bounded `docs/AI_HANDOFF` tasks instead of continuing in one long thread, or tell the user plainly to `/compact`/start a fresh session. The full directive is debounced (3 min at hard phase, 8 min at soft) so it does not repeat in full every prompt — a short reminder line stands in until the phase changes or the cooldown lapses. `/compact` itself still cannot be invoked from a hook (client-only command), so this closes the gap by making the advisory self-actionable rather than attempting to fake a call the hook has no access to.
3289
-
3290
- ## 2.0.5 - 2026-08-11
3291
-
3292
- ### Changed
3293
-
3294
- - **Model IDs refreshed to the Claude 5 family**: `claude-sonnet-4-6` → `claude-sonnet-5`, `claude-opus-4-6` → `claude-opus-5`, across the `code`/`smart` tiers, `orchestration.modelTiers.vision.fallbackModel`, `handoff.defaultModel`/`advisorModel`/`orchestratorModel`, the Codex adapter settings, the `handoff-planner` agent example, and the config's own Vietnamese documentation strings. `claude-haiku-4-5` is unchanged — Haiku 4.5 is still current, so the `lite` tier was already correct. 54 references in live config, source and tests; historical records (`docs/AI_HANDOFF/archive/`, `docs/plans/`, `docs/WORKLOG.md`, `.ukit/storage/backups/`) are deliberately left alone, since rewriting what a past cycle actually ran on would be falsifying the record.
3295
-
3296
- ## 2.0.4 - 2026-08-11
3297
-
3298
- ### Added
3299
-
3300
- - **`context-window-guard.sh`** (UserPromptSubmit) — measures the session's real context by reading the transcript, and warns at 80% of `compact.hardCapTokens` / raises an ALERT at 100%. It counts only the messages *after* the last `compact_boundary`, so it tracks live context rather than the file's lifetime size (on a real 5.8 MB transcript: 1,444,439 tokens whole-file vs 145,510 measured — the whole-file number is off by 10x and useless). Subagent entries (`isSidechain`) are counted separately, since each carries its own window. **Advisory only — it always exits 0.** A hook that blocked here would strand the user at exactly the moment they can no longer type their way out.
3301
- - **`handoff.maxParallelAgents`** (default `3`) — caps how many implementer agents a handoff wave spawns at once. `handoff-implement` and `handoff-fullstack` now batch each wave against it instead of launching every independent task simultaneously.
3302
- - **`ukit update` now refreshes the current project**, replacing the `ukit update && ukit install` two-step. `--no-install` keeps the old CLI-only behaviour. The refresh is spawned as a **child process** running the newly installed global `bin/ukit`: after `npm install -g`, the running process still holds the old module graph, so an in-process install would redeploy the *old* templates and silently defeat the update. It also refuses to scaffold a directory with no UKit markers (install writes `.claude/`, `CLAUDE.md` and edits `.gitignore` — an unwelcome surprise in a home directory), and never reports an install that did not actually happen.
3303
-
3304
- ### Changed
3305
-
3306
- - **`compact.hardCapTokens` default lowered from `220000` to `160000`.** The old default sat *above* a 200k model window, so the gate it guards could never fire in the one situation it exists to prevent — it was dead code shipped as a safety feature. Measured live on a real session, the new guard read 157,952 tokens against this 160k cap, matching the point where the API actually starts rejecting input. The separate 50k/80k advisory phases are unchanged.
3307
- - **The index now covers the whole project instead of a fixed list of directory names.** Discovery scanned `src`/`tests`/`test`/`specs`/`spec`/`__tests__`/`manifests` and fell back to the project root only when *none* of them existed. A partial match was the trap: a repo with a top-level `tests/` but its code in `packages/` or `app/` indexed `tests/` and silently nothing else. Scope now comes from the project's own ignore rules — git's tracked plus untracked-not-ignored files — which is self-tuning per layout and needs no configuration. Non-git projects fall back to walking the root. This also removes noise the old name-based walk could not see: build output a project gitignores, and `.claude/`/`.ukit/`, which `ukit install` writes into every project.
3308
- - **Shell scripts are indexed.** `.sh` joins `.md`/`.json`/`.yaml` as tracked-but-not-parsed, matched by path. Every hook UKit ships was previously invisible to its own index.
3309
-
3310
- ### Fixed
3311
-
3312
- - **One pasted screenshot could brick `Edit`/`Write` for an entire session on every non-UNIC project.** The vision gate hard-blocks edits until a `ukit-vision-analyst` receipt exists, and it accepted a receipt only if the reported model matched a hardcoded, by-then-stale model ID. That acceptance path is unsatisfiable in practice: an honest agent reports the model it *actually* ran on, so the gate could never be cleared and the only escape was deleting a gitignored marker file by hand. The gate now stands down entirely when the session is off the UNIC gateway — where Claude reads images natively and there is nothing to enforce — and matches `unic-vision` by capability instead of by a pinned version string. Detection failure (`null`) still enforces, so breaking one gitignored file is not a bypass. `tests/handoff/cycle4/vision-gate.test.mjs` gains cases 21b/21c pinning "off-gateway + no receipt is allowed, never a deadlock" and "no fallback model needs to be configured"; the UNIC enforcement cases are untouched and still pass.
3313
- - **The v2.0.2 hard cap could not stop what it was built to stop.** `context-hardcap-gate.sh` is `PreToolUse`, but a context-window rejection happens when the request is *sent* — before any tool call exists to gate. `UserPromptSubmit` is the only event that runs early enough, hence the new guard above. Related: only three modules ever advance `estimatedTotalTokens`, and none of them observe `Read` results, images, or returned subagent reports, so the tracked figure drifts far below reality on exactly the sessions that overflow.
3314
- - **UKit's index could not see what UKit ships — the root cause of three releases' worth of dead features.** Because `src`, `tests` and `manifests` all exist in this repo, `templates/` was never scanned: 0 of 303 shipped files indexed, while the hand-maintained `.claude/` dev mirror sat in plain view. CLAUDE.md mandates an index-first loop, so the AI was routed to `src/` and the mirror, and never learned that `templates/.claude/` is the copy that reaches users. Querying a shipped skill by its own name returned only `src/` files, with no signal that anything was out of scope. Coverage in this repo goes from 136 files to 442, including the 185 `templates/.claude` files and all 17 shipped hooks; the three assets behind the 2.0.0 and 2.0.2 bugs now rank first for their own names.
3315
- - `tests/index/scanScope.test.js` guards the class: code outside the old allowlist is indexed even when a listed directory exists, ignore rules define scope, the non-git fallback still covers the whole project, and the shipped `index-core.mjs` bundle must carry the same discovery logic as `src/` — that bundle is what installed projects actually run, so a fix landing only in `src/` reaches nobody.
3316
-
3317
- ## 2.0.3 - 2026-08-11
3318
-
3319
- ### Added
3320
-
3321
- - **`ukit memory propose "<text>" [--category <name>] [--project <id>]`** — the missing first step of the Project Pattern Learning loop. Wires the existing `proposePatternCandidate()` to the CLI so a candidate can actually be created; duplicate proposals of the same text return the existing pending entry instead of stacking.
3322
-
3323
- ### Fixed
3324
-
3325
- - **Project Pattern Learning was unreachable in every real install.** v2.0.0 shipped `ukit memory list --pending` / `approve` / `reject`, but nothing could create a candidate: `proposePatternCandidate()` had zero production callers, and the `project-learning` skill told the AI to import it from `src/core/memory/store.js` — a path that only exists inside the UKit repo, never in an installed project. The skill now points at the new CLI subcommand, and `tests/cli/memoryCommand.test.js` drives the loop through the CLI only, so a fix that works solely via a direct function import cannot make those tests pass.
3326
- - **The v2.0.0 handoff Interfaces block never shipped.** `Consumes`/`Produces` were added to the repo's own `docs/AI_HANDOFF/RULES.md` and `tasks/_TEMPLATE.md` but not to the `templates/docs/AI_HANDOFF/` copies that `ukit install` actually delivers, so installed projects got handoff docs without the feature the 2.0.0 changelog claims. Same dev-mirror divergence class as the 2.0.2 hard-cap hooks.
3327
-
3328
- ## 2.0.2 - 2026-08-11
3329
-
3330
- ### Added
3331
-
3332
- - **Absolute context hard cap** — new `compact.hardCapTokens` (default `220000`) and `compact.hardCapBlock` (default `true`). Crossing the cap makes `context-hardcap-gate.sh` refuse `Edit`/`Write`/`Bash` outright until real compaction happens, instead of only printing a suggestion. `Read`/`Grep`/`Glob` stay open so the agent can still explain the block — only a human can invoke compaction. This is a new, separate ceiling: the existing soft/hard advisory phases (`compact.tokenThreshold` 50k, derived hard 80k) are unchanged.
3333
- - **`reset-compact-pressure.sh`** (SessionStart) — zeroes the compact pressure tracker at session start, so the cap measures the current session rather than accumulating over a project's lifetime.
3334
-
3335
- ### Fixed
3336
-
3337
- - **The hard cap would have shipped dead.** Both new hooks were wired into `settings.json` but had no entry in `manifests/platform.full.yaml`, so `ukit install` never copied them: real installs got `settings.json` pointing at scripts that do not exist. Found by a scratch-project install, not by the test suite. Added a `tests/manifest/settingsHookCoverage.test.js` regression guard that fails whenever a hook is wired without a manifest entry, or a manifest hook's `sourceTemplate` is missing, or the dev mirror and template `settings.json` disagree.
3338
- - **Permanent-block deadlock.** `compact-pressure.json` accumulated forever, so the cap would eventually block `Edit`/`Write`/`Bash` in every future session even with tiny context — and because the gate covers `Bash`, the documented remedies could not run. Fixed by the SessionStart reset plus a PreCompact reset.
3339
- - **Reset skipped on cache hit.** The PreCompact reset sat after `reinject-context.mjs`'s prompt-cache early return, so a cache hit left the gate tripped permanently. Moved ahead of the return.
3340
- - **Gate bypass via `NotebookEdit`/`MultiEdit`.** The gate compared `tool_name` exactly while the `settings.json` matcher is a regex (`Edit|Write` also matches both), so those tools fired the hook and passed through it. Now matched against an explicit tool set.
3341
- - Prompt cache in `reinject-context.mjs` no longer keys on the live pressure value when the threshold plan is inactive (where it cannot affect output), which had turned every run into a cache miss.
3342
- - `compact.hardCapTokens` reads straight from config instead of deriving from the advisory hard threshold, so raising `tokenThreshold` can never silently raise the ceiling.
3343
-
3344
- ## 2.0.1 - 2026-08-10
3345
-
3346
- ### Fixed
3347
-
3348
- - `ukit memory approve` / `reject` accept an optional `--project <id>` flag, so a pattern candidate belonging to a non-current project (surfaced by `list --pending`'s cross-project scan) can actually be resolved instead of failing "not found".
3349
- - `ukit memory list` reports a conventions count alongside decisions, so an approval's effect is visible.
3350
-
3351
- ## 2.0.0 - 2026-08-10
3352
-
3353
- ### Added
3354
-
3355
- - **`skill-quality` skill** (maintainer-only) — adversarial pressure-testing process for template skills/agents before shipping changes, with `pressure-scenario-template.md`, `rationalization-table-template.md`, and `trigger-accuracy-template.md` companion files, plus `scripts/skill/audit-skill.mjs` (`yarn skill:audit`) for scaffolding scenario files and recording results. Not a `ukit` CLI command — a maintainer dev-tool, same tier as `yarn bug:triage`.
3356
- - **`executing-plans` Preflight checklist + Blocker Classifier** — structured pre-execution checks and a formal blocker taxonomy, replacing an unstructured "When to Stop" bullet list.
3357
- - **`handoff-planner` Scope Explosion Detector + Right-Sizing rule** — flags oversized multi-subsystem handoff requests and enforces task-granularity limits, on top of the existing wave-dependency logic.
3358
- - **`RULES.md` / task template Interfaces block** — `Consumes`/`Produces` fields for explicit task-to-task data contracts in handoff cycles.
3359
- - **`code-reviewer` agent generalized** with a `REVIEW_TARGET_TYPE` branch (`code` / `spec`), so it can review non-diff artifacts (e.g. specs) in addition to code diffs.
3360
- - **`skillProfile.js` + `ukit doctor --skills`** — word-count budget report for every `templates/.claude/skills/*/SKILL.md`, flagging files over a 500-word default threshold.
3361
- - **Project Pattern Learning** — schema + `ukit memory list --pending` / `approve` / `reject` CLI surface for proposing and confirming project-local conventions, gated on human approval (never auto-applied, project-local scope only).
3362
- - **`project-learning` skill** — guides proposing/confirming project conventions through the new pattern-learning CLI.
3363
- - Wired the previously dead `runHygiene()` (decision-superseding + session consolidation) into the live memory flow instead of leaving it uncalled.
3364
-
3365
- ### Changed
3366
-
3367
- - Trimmed `templates/.claude/skills/**/SKILL.md` word count 31,227 → 25,900 words (17%) via companion-file extraction and in-place deduplication, with zero behavior loss (content relocated to companion `.md` files, never deleted, except one verbatim-duplicate line removed from `duraone`). See `docs/WORKLOG.md` Task 13 entry for the full per-skill breakdown.
3368
- - Deleted 3 orphaned barrel `index.js` re-export files (`src/core/router/index.js`, `src/core/validation/index.js`, `src/core/memory/index.js`) with zero importers anywhere in the repo.
3369
- - Raised the packed-artifact size budget in `tests/integration/packageArtifact.test.js` (`1,680,000` → `1,684,000` bytes packed, `5,283,000` → `5,291,000` bytes unpacked) — the artifact is dominated by binary assets (canvas fonts, OOXML XSD schemas) that skill-text trimming can't reduce.
3370
-
3371
- ## 1.6.8 - 2026-08-09
3372
-
3373
- ### Fixed
3374
-
3375
- - **`extract-image.mjs`** no longer re-arms `pending-<sha>.json` for an image that already has an `analyzed-<sha>.json` receipt. `selectImages()` always returns the most recent N images from the whole transcript, so a fully-analyzed image never fell out of that window on its own; since `vision-router.sh` calls `--mark-pending` on every prompt, this re-triggered the vision hint/gate on the same closed-out image forever, even on unrelated prompts. Both `--detect` and `--mark-pending` now skip any sha with an existing analyzed receipt.
3376
-
3377
- ## 1.6.7 - 2026-08-09
3378
-
3379
- ### Fixed
3380
-
3381
- - **`unic-gateway.mjs` `detectUnicGateway()`** is now scoped to Claude Code's own outbound endpoint only (`process.env.ANTHROPIC_BASE_URL`, and the `env.ANTHROPIC_BASE_URL` key in project/home `.claude/settings.json`). It no longer probes Codex `config.toml`, Kilo `secrets.json`, or `OPENAI_BASE_URL` — those describe a different tool's endpoint and were producing permanent false positives (`unicMode: true` for a plain Claude Code session whenever some other tool on the machine happened to be pointed at the UNIC gateway), which would deadlock Edit/Write on any image-mentioning turn under the vision gate.
3382
- - **`vision-router.sh`** no longer always tells the caller to invoke `Agent(subagent_type: "ukit-vision-analyst") [model: unic-vision]`. `unic-vision` is only an invokable model when the UNIC gateway is actually active for this session; the remedy message now branches on `detectUnicGateway()`'s `unicMode`: gateway active keeps today's `unic-vision` text, gateway inactive with a readable `orchestration.modelTiers.vision.fallbackModel` (read from `.ukit/storage/config.json`, the same path `vision-gate.sh` uses) tells the caller to override the model to that fallback and to self-report it in the analyst's receipt, and any missing/broken detection falls back to the strict `unic-vision` text as before. The hook's fail-open contract (never blocks the prompt, always exit 0) is unchanged.
3383
- - **`handoff-model-guard.sh`** no longer re-blocks `git push` forever over a closed, human-approved model-tier exception (a documented `## Model-Tier Guard Override` section with `OVERRIDE_APPROVED_BY: human` now exempts that task from the push-time reviewer/executor tier scan).
3384
-
3385
- ## 1.6.6 - 2026-08-03
3386
-
3387
- ### Fixed
3388
-
3389
- - **`ensureGitignore`** no longer silently no-ops on a damaged UKit block (missing/duplicate end marker). Marker detection is now a single source of truth (`parseGitignore` + `locateBlock`, exact-line matching, shared with `removeGitignoreBlock`), fixing data loss on substring-collision lines, content between two legitimate blocks, and CRLF round-tripping, while staying idempotent.
3390
- - **Install summary counts** no longer go negative or misattribute a skip. `applyDiffResults` now tracks skips per planned action (`create`/`update`), and `runInstallPipeline` subtracts each skip from its own bucket instead of always assuming `update`.
3391
- - **Runtime config default version** is now read from `package.json` instead of a hardcoded, drifting literal (was stuck at `1.5.2`).
3392
- - **`mergeObjects` (runtime config)** now refuses `__proto__`, `constructor`, and `prototype` keys at every merge depth, closing a prototype-pollution path via a hand-edited `.ukit/storage/config.json`.
3393
- - **`buildInstallPlan`** no longer aborts the entire install when a template is missing for a *non-selected/excluded* item — it skips quietly. A missing template for a *selected* item still fails loudly with a clear error.
3394
- - **`uninstallUkit`** now reports out-of-scope/forged tracked paths on real runs, not only `--dry-run`, while routine link-child paths stay silent.
3395
-
3396
- ## 1.6.5 - 2026-08-02
3397
-
3398
- ### Added
3399
-
3400
- - **Enforced `unic-vision` image lane.** Images are now mechanically routed to a vision-capable model instead of being guessed at by `unic-code`/`unic-smart`, which cannot read images on the UNIC gateway.
3401
- - `.claude/ukit/index/extract-image.mjs` — decodes pasted images out of the session transcript to disk (a spawned subagent receives text only and does not inherit image blocks), and writes content-addressed `pending-<sha>.json` markers. Single owner of the sha256; both the marker and the image filename come from the same hash.
3402
- - `.claude/hooks/vision-router.sh` (`UserPromptSubmit`) — detects all three input forms (pasted, local path, image URL) and arms a marker for each. Fails OPEN: a failure here degrades to no hint and no markers, never a wedged prompt.
3403
- - `.claude/hooks/vision-gate.sh` (`PreToolUse`, `Edit|Write` only) — hard-blocks the write (exit 2) until an `analyzed-<sha>.json` receipt exists whose self-reported model is vision-capable. A receipt from `unic-code`, `unic-smart`, `sonnet`, or `opus` is treated as ABSENT and still blocks. Fails CLOSED, and gateway detection that is missing or broken DENIES the fallback-model exception rather than granting it. `Read`/`Grep`/`Glob`/`Bash` are never gated — the vision analyst needs them to clear the gate.
3404
- - `ukit-vision-analyst` agent — pinned to `unic-vision`, the only lane permitted to interpret images. Reports findings only; it has no `Edit`/`Write`.
3405
- - `.claude/ukit/index/unic-gateway.mjs` — detects a `unicjsc.com` gateway across Claude Code env, Codex config, Kilo config, and `OPENAI_BASE_URL`. Only ever tests for substring presence; never reads credential file contents into output.
3406
-
3407
- ### Changed
3408
-
3409
- - `orchestration.escalation` now has real consumers. `route-task.mjs` reads `debugLoopThreshold`, `tierOrder`, and `cap` from config instead of hardcoded literals, and emits `escalatedTier` alongside `modelTier` — one rung up, capped at `smart`. The same literals remain as fallbacks, so projects that never opted in behave identically.
3410
- - `orchestration.modelTiers` documents all four UNIC models. `vision` is a capability lane orthogonal to the lite/code/smart cost tiers, never a fourth tier, and is stripped from any configured `tierOrder`.
3411
- - `handoff-model-guard.sh`: `tierOf()` hardened against vision/unknown model names.
3412
-
3413
- ## 1.6.4 - 2026-07-27
3414
-
3415
- ### Added
3416
-
3417
- - Hard enforcement of the handoff model-tier contract via a new `PreToolUse` hook (`.claude/hooks/handoff-model-guard.sh`), registered for both `Edit|Write` and `Bash`. Previously the plan=opus / implement=sonnet / review=opus split was only a prompt convention the orchestrating model could silently skip.
3418
- - Blocks writing `docs/AI_HANDOFF/PLAN.md` unless it declares a smart-tier `PLANNER_MODEL` in a new mandatory `## Planner Report` footer.
3419
- - Blocks creating a fresh `TASK-xxx.md` until `PLAN.md` has a valid smart-tier `PLANNER_MODEL`.
3420
- - Blocks writing `## Executor Report` unless `EXECUTOR_MODEL` is present and not lite-tier.
3421
- - Blocks writing `## Reviewer Verdict` unless `REVIEWER_MODEL` is smart-tier and differs from `EXECUTOR_MODEL`.
3422
- - Blocks `git push` when any reviewed task in the active cycle violates the contract.
3423
- - Applies identically to the standalone `/ukit:handoff-create`, `/ukit:handoff-implement`, `/ukit:handoff-review` commands and the combined `/ukit:handoff-fullstack` pipeline, since the gate is keyed on file content, not on which command ran.
3424
- - `/ukit:handoff-create`, `/ukit:handoff-implement`, `/ukit:handoff-review`, `/ukit:handoff-fullstack`: each phase now carries a mandatory Agent-tool-spawn directive (`ukit-small-task-maintainer`, `handoff-planner`, `feature-implementer`, `code-reviewer`) so the correct model tier is actually invoked, not just suggested.
3425
- - `handoff-planner` agent and `PLAN.md` now require a `## Planner Report` / `PLANNER_MODEL` self-report, mirroring the existing `EXECUTOR_MODEL` / `REVIEWER_MODEL` self-report contract on task files.
3426
-
3427
- ## 1.6.2 - 2026-07-26
3428
-
3429
- ### Added
3430
-
3431
- - `ukit update` — new command that upgrades the globally installed UKit CLI to the latest published version (equivalent to `npm install -g @ngockhoale/ukit`).
3432
-
3433
- ### Changed
3434
-
3435
- - Downgraded `find-cause` and `map-impact` orchestration contracts from `modelTier: smart` (opus) to `modelTier: code` (sonnet); `review-release` stays on `smart`. Reduces unnecessary Opus usage for routine debugging/impact-mapping work.
3436
-
3437
- ### Fixed
3438
-
3439
- - Auto-compact context-pressure state is now surfaced to the model as a warning (`[ukit-skill-router] Context pressure: soft/hard ...`) once token usage crosses the soft/hard threshold, instead of being silently tracked and only reinjected after Claude Code's native compaction already began. Users previously had to compact manually because nothing ever prompted proactive `/compact` suggestions.
3440
-
3441
- ## 1.5.24 - 2026-06-10
3442
-
3443
- ### Fixed
3444
-
3445
- - Register `command-handoff-fullstack` in `manifests/platform.full.yaml` so `ukit install` now copies `handoff-fullstack.md` to target projects. Previously the template existed but was missing from the manifest.
3446
-
3447
- ## 1.5.23 - 2026-06-10
3448
-
3449
- ### Added
3450
-
3451
- - `handoff-fullstack`: new all-in-one slash command combining `handoff-create` + `handoff-implement` + `handoff-review` into a single pipeline. Per-step model split (haiku/unic-lite for light work, sonnet/unic-code for implementation, opus/unic-smart for planning + review), plan auto-commit, conditional push on full approval, always-on worktree/branch cleanup, guaranteed clean git state at cycle end.
3452
-
3453
- ## 1.5.22 - 2026-06-09
3454
-
3455
- ### Changed
3456
-
3457
- - Internal: bumped version for release.
3458
-
3459
- ## 1.5.21 - 2026-06-09
3460
-
3461
- ### Changed
3462
-
3463
- - Renamed handoff slash commands from `*-handoff` to `handoff-*` convention: `handoff-status`, `handoff-create`, `handoff-implement`, `handoff-review`, `handoff-clear`. Old `*-handoff.md` files removed; manifests and skill routing updated.
3464
- - Auto-prune now targets `handoff-abort.md` (new name) instead of `clear-handoff.md`.
3465
-
3466
- ## 1.5.16 - 2026-06-06
3467
-
3468
- ### Changed
3469
-
3470
- - `handoff-clear`: added Step 2 — stage `docs/AI_HANDOFF/`, commit planning artifacts, merge `handoff/integration → $BASE`, push, delete integration branch. This is the **only** git commit+push in the entire handoff flow.
3471
- - `handoff-review`: removed all merge/push instructions from Step 3. Reviewer now stops at "Run /ukit:handoff-clear" after all tasks approved.
3472
- - Rule enforced: `handoff-create`, `handoff-implement`, `handoff-review` may only change files inside `docs/AI_HANDOFF/`. No commits to main, no pushes.
3473
-
3474
- ## 1.5.15 - 2026-06-06
3475
-
3476
- ### Changed
3477
-
3478
- - `handoff-review`: removed automatic `git merge handoff/integration → $BASE`. Reviewer now stops after all tasks are approved and instructs the human to merge manually. Only the end user (or an explicit human prompt) may commit to the base branch.
3479
-
3480
- ## 1.5.14 - 2026-06-05
3481
-
3482
- ### Added
3483
-
3484
- - Added 6 handoff slash commands to OpenCode template (`ukit-handoff-status`, `ukit-handoff-create`, `ukit-handoff-implement`, `ukit-handoff-review`, `ukit-handoff-clear`, `ukit-handoff-abort`). These now appear as Workflows in Kilo Code and slash commands in OpenCode after `ukit install`.
3485
-
3486
- ### Fixed
3487
-
3488
- - `templates/ukit/storage/config.json`: version was hardcoded as `"1.5.7"` instead of `"{{ukit.version}}"` — fixed so install always writes the current package version.
3489
-
3490
- ## 1.5.7 - 2026-06-02
3491
-
3492
- ### Fixed
3493
-
3494
- - Fixed `compact-threshold.mjs` never being deployed by `ukit install` — the file existed in `templates/` since v1.1.2 but was missing from `manifests/platform.full.yaml`. Every Bash PostToolUse hook (`compress-output.sh`) and PreCompact hook (`reinject-context.sh`) crashed with `ERR_MODULE_NOT_FOUND`, causing the agent to silently stop mid-task.
3495
- - Added `ukit-runtime-compact-threshold-script` manifest entry with correct `requires` chain. Updated `requires` for `ukit-runtime-reinject-context-script`, `ukit-runtime-output-compression-script`, and `hook-skill-router` to declare the dependency.
3496
- - Changed default `safePatch.advisoryOnly` from `false` to `true` in `src/core/runtimeConfig.js`. Previously, `stale-spec-guard.sh` exited code 2 on any Edit to a shared/risky file with a stale `old_string`, causing Claude Code to block the tool call and halt the agent loop silently from the user's perspective. Advisory mode downgrades exit 2 → exit 0 + warning, allowing the agent to continue.
3497
-
3498
- ## 1.5.5 - 2026-05-30
3499
-
3500
- ### Added
3501
-
3502
- - **Handoff Quality Gate** — opt-in, tool-agnostic, file-based, 4-phase pipeline (Idea+Plan → Create Tasks → Implement+Test → Review+Test) for tasks routed through `docs/AI_HANDOFF/`. Daily ad-hoc prompts are NOT affected and continue with the existing lightweight workflow.
3503
- - New agent `templates/.claude/agents/code-reviewer.md`: independent reviewer with a model-isolation check. Refuses to review when `EXECUTOR_MODEL` equals reviewer's own model, when either is missing/unknown, or when re-run of Verification Commands fails. Emits a structured `## Reviewer Verdict` block.
3504
- - New config block `handoff.*` in `templates/ukit/storage/config.json` with Vietnamese `_help` entries: `handoff.plan.requireTestPlan`, `handoff.executor.testFirstRequired`, `handoff.reviewer.model` (default `unic-smart`), `handoff.reviewer.blockOnCritical`, etc. The `*.modelHint` fields are explicitly documented as *labels for humans, not enforced selectors* — model enforcement happens via executor self-report + reviewer refusal.
3505
- - New `## 4. Test Plan (REQUIRED — TDD-style)` section in `templates/docs/AI_HANDOFF/PLAN.md`.
3506
- - New `templates/docs/AI_HANDOFF/tasks/_TEMPLATE.md`: every task file MUST embed its own `## Test Cases` (table with happy + ≥1 edge case + regression for bug fixes) + `## Test Files` + `## Verification Commands` + `## Acceptance Criteria`. Tasks without these are `needs_breakdown`, not `ready`.
3507
- - `## Discussion` section pattern on task files: structured AI-to-AI comment thread (date · role · tool/model) so planner/executor/reviewer can talk back to each other through files — no out-of-band channels.
3508
- - New task status states in `INDEX.md`: `pending_review`, `changes_requested`, `critical_block`, `approved`, `approved_minor`, plus Owner/Reviewer columns.
3509
-
3510
- ### Changed
3511
-
3512
- - `templates/.claude/agents/feature-implementer.md`: now operates in two explicit modes. **Daily mode** (DEFAULT): unchanged lightweight flow — tests only when touched code has coverage, no reviewer trigger. **Handoff mode** (when task lives under `docs/AI_HANDOFF/tasks/`): test-first → green → reviewer; cannot claim `STATUS: DONE` without fresh PASS in turn. Report format now includes `EXECUTOR_TOOL`, `EXECUTOR_MODEL`, `EXECUTOR_SUBAGENT` self-report.
3513
- - `templates/.claude/agents/bug-debugger.md`: same two-mode split. Handoff mode requires regression-test-first (RED before fix, GREEN after); Daily mode unchanged.
3514
- - `templates/docs/AI_HANDOFF/RULES.md`: rewritten around the 4-phase model. Added `## Hard rule — All work stays in docs/AI_HANDOFF/` (no out-of-band AI communication). Added Phase 2 TDD-embedded requirement. Auto-compact 80-line rule scoped to state files (ACTIVE/INDEX/tasks); PLAN.md and RULES.md exempt.
3515
- - `templates/CLAUDE.md` + `templates/AGENTS.md`: added scoped `## Handoff Quality Gate` section with explicit OPT-IN scope language so adapter targets (Claude Code, Kilo Code, Codex, OpenCode, future tools) only apply Quality Gate to handoff work, not daily prompts.
3516
-
3517
- ### Fixed
3518
-
3519
- - Fixed output-history deduplication for `promptCache: false` — the second call with semantically equivalent (but noisy) output now returns the cached first summary instead of recomputing. Root cause: `normalizeOutputSummaryForDedupe` wasn't stripping `FAIL`/`PASS`/`Test Files`/`Tests`/`Duration`/`Start at` lines from the dedup key, so slight token-budget differences between two similar payloads produced different keys and broke cache hits. Added `findOutputHistoryEntry` lookup in `main()` to serve cached summaries without prompt-cache.
3520
-
3521
- ### Why
3522
-
3523
- User had two real concerns: (1) cheap-model executors (e.g. Kilo Code) miss small things — fixed by mandatory test-first + independent reviewer with different model; (2) UKit cannot dictate which model any external tool uses — fixed by making the contract self-report-based (executor writes `EXECUTOR_MODEL`, reviewer compares and refuses on match/unknown). The Quality Gate is opt-in via the `docs/AI_HANDOFF/` folder so daily ad-hoc work is unaffected.
3524
-
3525
- ## 1.5.4 - 2026-05-28
3526
-
3527
- ### Fixed
3528
-
3529
- - Fixed stale `docs/AI_HANDOFF.md` references in next-step skill, INSTALL.md, UKIT_USAGE_GUIDE.md, PROJECT.md (template + local).
3530
- - Fixed mirror `route-task.mjs` not showing `handoff=` in summary — wrong intent order (docsSpecific before handoff) + missing handoffFile field + missing display segment.
3531
- - Added `WORKLOG_ARCHIVE.md` to `.gitignore`.
3532
-
3533
- ### Changed
3534
-
3535
- - Compacted `docs/MEMORY.md` from 118KB/298 lines to 7.8KB/78 lines. Old entries archived to `docs/MEMORY_ARCHIVE.md`.
3536
- - Cleared handoff task queue after all cycle 002 tasks resolved.
3537
-
3538
- ## 1.5.3 - 2026-05-28
3539
-
3540
- ### Changed
3541
-
3542
- - Restructured `docs/AI_HANDOFF.md` into `docs/AI_HANDOFF/` folder: ACTIVE.md (snapshot), RULES.md (flow + token budget), PLAN.md (brainstorm), INDEX.md (task index), tasks/ (per-task files), archive/ (completed cycles, max 3).
3543
- - Each task is now an isolated file in `tasks/TASK-xxx.md` — AI reads only the task it implements, not the entire backlog.
3544
- - Added token budget rule: combined handoff reads must stay under 200 lines per request.
3545
- - Added auto-compact rule: if any handoff file exceeds 80 lines, trigger `clear handoff`.
3546
- - Updated template mirror `templates/docs/AI_HANDOFF/` to match new folder structure.
3547
- - Updated `taskRouting.js` handoffFile target from `docs/AI_HANDOFF.md` to `docs/AI_HANDOFF/ACTIVE.md`.
3548
- - Updated `install.js`, `doctor.js`, `uninstall.js` to check for `docs/AI_HANDOFF/ACTIVE.md`.
3549
-
3550
- ## 1.5.2 - 2026-05-28
3551
-
3552
- ### Added
3553
-
3554
- - Added first-class `ukit:handoff` prompt detection and routing for explicit handoff/brainstorm-to-task flows.
3555
- - Added `intentMode: handoff` to route summaries so hooks and helpers can prioritize handoff file automatically.
3556
- - Added a reusable generic handoff template for installed projects.
3557
-
3558
- ### Changed
3559
-
3560
- - Handoff prompts now route through `docs-quality` skill instead of generic `update-status`.
3561
- - Updated installed `next-step` skill guidance to read handoff file first for explicit handoff prompts.
3562
- - Updated `route-task` mirror and hook behavior in both source and installed artifact so `ukit install` users get consistent handoff routing.
3563
-
3564
- ### Fixed
3565
-
3566
- - Handoff authoring is now advisory (exit 0) in Safe Patch, so large handoff batches no longer block the handoff workflow.
3567
- - Hard runtime/shared-risk file broad rewrites still block by default unless `advisoryOnly=true` or `UKIT_SAFE_PATCH_ADVISORY=1` is set.
3568
-
3569
- ### Tests
3570
-
3571
- - Added explicit handoff routing coverage in `tests/index/taskRouting.test.js`.
3572
- - Verified Safe Patch protocol still passes 12 tests including the new handoff advisory case.
3573
-
3574
- ## 1.5.0 - 2026-05-24
3575
-
3576
- ### Fixed
3577
-
3578
- - Switched safe-patch release regressions to `spawnSync`-based helpers so advisory-mode assertions capture `stderr` correctly even when the hook exits `0`.
3579
- - Raised the packed artifact size budget slightly to preserve the shipped canvas font lane and recent runtime/router surfaces without failing release smoke on a 625-byte overage.
3580
-
3581
- ### Changed
3582
-
3583
- - Bumped package and shared runtime version metadata to `1.5.0`.
3584
-
3585
- ## 1.4.5 - 2026-05-24
3586
-
3587
- ### Fixed
3588
-
3589
- - Stopped safe-patch hooks (`stale-spec-check`, `post-edit-verify`) from hard-blocking tool calls when configured via the new `safePatch.advisoryOnly` flag or the `UKIT_SAFE_PATCH_ADVISORY=1` env. Removes the mid-task "stop and wait for continue" stalls that hit shared-risk files in `.claude/`, `templates/`, `scripts/`, etc., while preserving the diagnostic message so Claude/Codex can self-correct instead of stalling.
3590
- - Default behavior unchanged (`advisoryOnly: false`): pre-edit corruption guards (shebang-bom, non-text, whole-file Write to shared-risk) and the `protect-files` / `block-dangerous` hooks still hard-block.
3591
-
3592
- ### Tests
3593
-
3594
- - Added regression coverage for advisory-mode exit code and stderr in `tests/hooks/safePatchProtocol.test.js`.
3595
- - Added default + validation assertions for `safePatch.advisoryOnly` in `tests/core/runtimeConfig.test.js`.
3596
-
3597
- ## 1.4.4 - 2026-05-11
3598
-
3599
- ### Fixed
3600
-
3601
- - Removed shipped `.gitignore` negations that accidentally unignored installed `.claude/` and `.codex/` files in fresh repos, preventing large post-install `git status` noise.
3602
- - Kept the intended local-only ignores for `AGENTS.md`, `CLAUDE.md`, `docs/STATUS.md`, `docs/TASKS.md`, runtime cache, and adapter state intact.
3603
-
3604
- ### Tests
3605
-
3606
- - Added install-pipeline regression coverage that initializes a fresh git repo, runs `ukit install`, and asserts managed UKit files stay ignored.
3607
-
3608
- ## 1.4.3 - 2026-05-10
3609
-
3610
- ### Changed
3611
-
3612
- - Tightened execute-first orchestration guidance so one clear safe path runs directly, while real user-choice or risk-confirmation moments still ask.
3613
- - Added compact route-audit coverage and repeated write-lane rescue bias to reduce stop-and-explain loops.
3614
- - Published patch `1.4.3` after fresh full-suite, release-verify, and registry-smoke validation.
3615
-
3616
- ## 1.4.2 - 2026-05-10
3617
-
3618
- ### Added
3619
-
3620
- - Added a quality-first internal orchestration ladder with seven execution layers: `tiny-fix`, `local-fix`, `local-build`, `find-cause`, `shared-edit`, `map-impact`, and `review-release`.
3621
- - Added structured route continuity state so installed helpers and hooks can carry `completionState`, `continuationState`, and stuck-lane rescue signals across turns instead of forgetting unfinished execution debt.
3622
- - Added orchestration/runtime config defaults and Codex adapter metadata for the internal advisor/orchestrator contract while keeping the teammate workflow centered on `ukit install`.
3623
-
3624
- ### Fixed
3625
-
3626
- - Kept context routing and context-mode hints internal so UKit no longer surfaces `pull-indexed-context`, `resolve-context`, or `mode=LITE/FULL` in the main route prose for ordinary work.
3627
- - Preserved the structured route state (`nextActionType`, `helperHint`, `contextMode`) for internal orchestration, while removing the user/model-facing leakage that was nudging sessions into micro-step stop-and-wait behavior.
3628
- - Hardened implementation routing and installed agent guidance so explicit implement/apply/fix requests keep moving through bounded read → edit → verify flow instead of stopping after read-only inspection.
3629
- - Escalated repeated unfinished returns with `repeatCount`, `stuckRisk`, and `rescueMode` so UKit can rescue a stuck lane instead of quietly looping the same partial milestone.
3630
- - Fixed the installed `route-task` continuation handoff so previous route summaries are carried through correctly during rescue escalation.
3631
-
3632
- ### Tests
3633
-
3634
- - Added/updated route, hook, reinject, install-pipeline, and package-artifact coverage for internal helper hiding, continuation rescue escalation, and the expanded orchestration contract.
3635
-
3636
- ## 1.4.1 - 2026-05-09
3637
-
3638
- - Completed cleanup and 1.4.1 template alignment.
3639
-
3640
- ## 1.4.0 - 2026-05-09
3641
-
3642
- ### Added
3643
-
3644
- - Added Adaptive Autonomy runtime config (`autonomy`) with three levels: `conservative`, `balanced` (default), and `free-run`.
3645
- - `conservative`: asks before fallback verification and broad/risky escalation; suppresses non-essential delegation except explicit plan/batch execution and small-task maintainer.
3646
- - `balanced`: default behavior unchanged — targeted verification auto-runs, broad risky asks confirmation, delegation follows existing thresholds.
3647
- - `free-run`: auto-runs fallback verification, removes broad verification confirmation for escalation-only, lowers feature/debug delegation thresholds slightly.
3648
- - Added `autonomy.level`, `autonomy.affectVerification`, and `autonomy.affectDelegation` to runtime config defaults and validation.
3649
- - Added LITE/FULL context mode labels to stepBudgets (`trivial`/`simple` = LITE, `sharedSimple`/`nonTrivial` = FULL) for subagent model selection hints.
3650
- - Added `contextMode` (LITE/FULL) to route summary output and `mode=` segment in summary line.
3651
- - Added `autonomyLevel` to routing context and verification plan cache key for autonomy-aware plan reuse.
3652
-
3653
- ### Changed
3654
-
3655
- - `deriveTaskRoute`, `deriveVerificationPlan`, and `deriveExecutionPolicy` now accept `autonomyLevel` parameter.
3656
- - `deriveDelegationRecommendation` now respects `autonomyLevel`: conservative suppresses non-essential delegation; free-run relaxes bug-debugger and feature-implementer thresholds.
3657
- - Updated `CLAUDE.md`, `.codex/README.md`, and `ukit/README.md` templates with v1.4.0 version wording and Adaptive Autonomy policy.
3658
- - Added Vietnamese `_help` for autonomy config in `config.json` template.
3659
-
3660
- ### Tests
3661
-
3662
- - Added targeted tests for autonomy validation, conservative/free-run execution policy, and delegation behavior.
3663
-
3664
- ## 1.4.0 - 2026-05-06
3665
-
3666
- ### Fixed
3667
-
3668
- - Fixed `ukit install` failing with `ENOENT` when a published/global package is missing optional `templates/.gitignore`; install now uses a built-in fallback.
3669
-
3670
- ### Tests
3671
-
3672
- - Added a regression test for package artifacts without `templates/.gitignore`.
3673
-
3674
- ## 1.3.0 - 2026-05-06
3675
-
3676
- ### Added
3677
-
3678
- - Added UKit Safe Patch Protocol guardrails for risky AI edits: stale/ambiguous `old_string` detection, whole-file shared-risk `Write` blocking, anchor-search helper, safe patch helper, text-profile detection, and pre-edit rollback bytes for shared-risk files.
3679
- - Added post-edit delta verification for backed-up shared-risk edits so unexpected broad rewrites are flagged against the Safe Patch hunk/changed-line budget and rollback manifests record after hashes.
3680
- - Added Safe Patch backup retention and bounded delta-diff fallback so rollback data does not grow forever and very large edits avoid unbounded LCS memory use.
3681
- - Added byte-first UTF-8/BOM/newline profile handling so helper-mediated patches preserve UTF-8 BOM/no-BOM, LF/CRLF, Vietnamese/CJK/emoji content, and reject unsafe binary/invalid UTF-8 edit paths.
3682
- - Added `safePatch` runtime config defaults under `.ukit/storage/config.json` while keeping the end-user workflow unchanged: normal users still only need `ukit install`; helpers remain internal guardrails.
3683
-
3684
- ### Changed
3685
-
3686
- - Promoted shared-risk edit routing to surface an internal `editGuard=anchor-required` hint for installed runtime/template targets.
3687
- - Extended impact-risk classification to installed runtime paths such as `.claude/hooks/**`, `.claude/ukit/**`, and `.codex/**`.
3688
-
3689
- ### Tests
3690
-
3691
- - Added focused Safe Patch Protocol hook/helper coverage and install wiring coverage.
3692
-
3693
- ## 1.2.2 - 2026-05-05
3694
-
3695
- - Removed the `.claude/ukit/.env` / `.env.example` config surface so UKit runtime tuning lives in `.ukit/storage/config.json` only.
3696
- - Added full Vietnamese `_help` guidance inside `templates/ukit/storage/config.json`, including common edits for changing the internal model and Codex compact thresholds.
3697
- - Set Codex Desktop compact budget default to 100,000 tokens as a quality/safety balance, with compact handoff target 150 lines and hard max 170 lines.
3698
- - Preserved Claude PreCompact/reinject and OpenCode native auto/prune compaction while keeping `ukit-small-task-maintainer` as a non-blocking sidecar lane.
3699
-
3700
- ## 1.2.1 - 2026-05-05
3701
-
3702
- ### Local AI Task Queue
3703
-
3704
- - Added gitignored `docs/TASKS.md` as a local AI task queue for deferred work that one AI can write and another AI/agent can implement later.
3705
- - Installed `docs/TASKS.md` with skip merge semantics so end-user task notes are never overwritten or uninstall-owned.
3706
- - Added safe default cleanup rules: remove exact duplicates, prune `Done Recently` to 10 compact lines, move stale/vague work to deferred review, and never delete unfinished human-authored tasks unless explicitly asked and clearly obsolete/duplicated.
3707
- - Updated `next-step`, `update-status`, and `docs-quality` guidance plus route signals so queued-task selection goes to `next-step` while task cleanup/editing goes to `docs-quality`.
3708
- - Added `docs/STATUS.md` and `docs/TASKS.md` to generated gitignore handling so living local AI state does not pollute project commits.
3709
- - Added the internal `ukit-small-task-maintainer` subagent, powered by optional `subagents.smallTaskModel=unic-lite`, for safe UKit decisions such as task cleanup, compact decisions, doc summarization, classification, auto-triage, queue maintenance, and small reversible cleanup while keeping risky/security/release work on the main model.
3710
-
3711
- ## 1.1.8 - 2026-05-05
3712
-
3713
- ### Living Project Status
3283
+ - **`feature-implementer` and `code-reviewer` run unattended in handoff mode.** Ambiguity resolves through task file → PLAN.md → surrounding code → recommended choice, recorded in `## Discussion`;
3284
+ - **`handoff-model-guard.sh` gained a bash fast path** that skips the node spawn when the payload contains neither `AI_HANDOFF` nor `git push`.
3714
3285
 
3715
- - Added `docs/STATUS.md` as a compact living project-state baseline for active work, debug threads, blockers, verification, and next candidates.
3716
- - Added `next-step` and `update-status` skills so Claude/Codex/OpenCode can use project status automatically without adding any user-facing commands beyond `ukit install`.
3717
- - Made next-step routing freshness-aware: stale or missing status must be treated as orientation only and verified against source/index before recommendations.
3718
- - Added concrete-task precedence so prompts like “fix login bug but not sure next step” stay on the debug/implementation/review workflow instead of being hijacked by global roadmap suggestions.
3719
- - Registered status docs/skills in the manifest with skip semantics for the living doc, and kept source route catalogs aligned with installed helper mirrors.
3720
- - Updated install/routing/manifest regression coverage for open-ended status prompts, explicit handoff updates, concrete debug edge cases, and default skill installation.
3721
-
3722
- ## 1.1.7 - 2026-04-25
3723
-
3724
- ### Impact Confidence
3725
-
3726
- - Added impact-confidence indexing for changed shared/runtime files, including lightweight call extraction and `calls.json` artifacts.
3727
- - Added shared-impact classification so source index runtime, install/runtime core, shipped hooks/helpers, manifests, and templates are routed as higher-confidence verification work instead of ordinary simple edits.
3728
- - Added mirror-counterpart guidance between source modules and installed helper mirrors, helping agents catch source/template drift before release.
3729
- - Added shipped `impact-context.mjs` helper and manifest coverage so installed workspaces can resolve impact context after `ukit install`.
3730
- - Tightened verification planning and guard behavior so impact-test lanes run targeted checks first, while broad verification remains advisory unless explicitly enforced.
3731
- - Added package-artifact, hook, indexing, impact-context, and impact-catalog coverage for the new release surface.
3732
-
3733
- ## 1.1.6 - 2026-04-23
3734
-
3735
- ### Hidden Runtime Root
3736
-
3737
- - Moved the shared runtime install target from visible `ukit/` to hidden `.ukit/` so end-user projects no longer see a confusing extra root folder beside `.claude/ukit/`.
3738
- - Kept `.claude/ukit/` for installed helper/index/hook machinery and installer metadata, instead of mixing mutable runtime storage into that helper tree.
3739
- - Added safe reinstall migration so rerunning `ukit install` moves legacy runtime assets from `ukit/README.md` and `ukit/storage/` into `.ukit/` when the new target paths are free, without force-overwriting newer state.
3740
- - Preserved conservative legacy cleanup: unknown user files under old `ukit/` still survive, and the old root is removed only when it becomes empty after migration/cleanup.
3741
- - Updated manifest targets, gitignore/uninstall ownership handling, current docs, and release/package smoke expectations to align on the new hidden runtime root.
3742
- - Promoted the current runtime/version surfaces to `@ngockhoale/ukit@1.1.6` while keeping the same `ukit` binary and the same install-first teammate workflow.
3743
-
3744
- ## 1.1.5 - 2026-04-23
3745
-
3746
- ### Owned-Scope npm Distribution Alignment
3747
-
3748
- - Realigned the published npm package name from `@ukit/cli` to `@ngockhoale/ukit` so release distribution uses a maintainer-owned scope that can actually publish today.
3749
- - Kept the installed CLI binary name as `ukit`, so the human-facing workflow inside projects remains exactly the same: teammates still only need `ukit install`.
3750
- - Preserved the existing GitHub `v1.1.4` release history and cut the package-identity change as a clean follow-up patch release instead of rewriting an already-pushed tag.
3751
- - Updated current install/documentation surfaces to point maintainers at `npm install -g @ngockhoale/ukit` while keeping UKit’s install-first product contract unchanged.
3752
-
3753
- ## 1.1.4 - 2026-04-23
3754
-
3755
- ### Recovery-Safe Output Compaction
3756
-
3757
- - Added recovery-safe output compaction on top of the existing command-aware compression lane instead of introducing a second output/history subsystem.
3758
- - Preserved raw tool output in `ukit/storage/cache/tee/` for high-value recovery cases such as failed commands, large raw outputs, or unusually high token savings.
3759
- - Extended output-history entries with recovery metadata (`rawSaved`, `rawPath`, `rawBytes`, `recoveryReason`) so routed/runtime consumers can reuse the same shared artifact instead of rerunning noisy commands blindly.
3760
- - Appended a compact `Full output:` recovery hint only when it still preserves net token savings; when it would erase the savings, UKit still keeps the raw artifact and metadata without bloating the inline summary.
3761
- - Kept source runtime behavior and shipped Claude hook behavior aligned for recovery-safe compaction, including prompt-cache reuse of recovery metadata and history dedupe that ignores the recovery-hint line.
3762
- - Extended `ukit status` output-compression reporting to show recovery counts so maintainers can see when the runtime preserved raw evidence in addition to saving tokens.
3763
- - Updated shared runtime docs/version surfaces to reflect the new v1.1.4 recovery-safe compaction lane while keeping the teammate workflow centered on `ukit install`.
3764
-
3765
- ## 1.1.3 - 2026-04-22
3766
-
3767
- ### Vietnamese-friendly retrieval + routing hardening
3768
-
3769
- - Added shared Unicode-aware query normalization so Vietnamese prompts can match English-heavy code paths and symbols more reliably without forcing users to switch to English.
3770
- - Added compact Vietnamese alias expansion for routing/search intent (for example review/auth/permission/cache/route-style terms) in both source runtime and shipped installed helpers.
3771
- - Hardened shared route scoring so normalized prompt signals improve skill selection without leaking prompt aliases into unrelated file-signal matches.
3772
- - Kept installed Claude/Codex hook/helper behavior aligned with the source runtime, including safe fallback behavior for hook/template test environments and legacy route-task stubs.
3773
- - Added regression coverage for Vietnamese retrieval/routing across source query/index, source task routing, installed route-task/query helpers, and the Claude skill-router hook.
3774
- - Added a simple direct-target fast path in shared `resolveContext` so when direct test context already localizes a simple/trivial change, UKit keeps the context bundle compact and skips widening into shared abstractions/analogs unless broader evidence is still needed.
3775
- - Skipped previous-context memory injection for localized simple/trivial route lanes with an explicit file target in both the installed `route-task` helper and the Claude `skill-router` hook, reducing unnecessary memory scanning on already-localized tasks while keeping non-trivial routes unchanged.
3776
- - Skipped recent-output snapshot reads for localized simple/trivial direct-target testing lanes in the installed `route-task` helper, so test-focused routes stop reading `ukit/storage/cache/output-history.json` when that compressed terminal context would not change the chosen next step.
3777
- - Reused the installed `route-task` verification environment snapshot when `package.json` already declares `packageManager`, so UKit no longer re-reads `package.json` or stats every lockfile candidate just to derive the same verification commands.
3778
- - Aligned the source verification planner and shipped `verify-context` helper with that same declared-`packageManager` fast path, so direct verification lanes also skip redundant lockfile fingerprint probes while reusing the parsed `package.json` snapshot.
3779
- - Applied the same declared-`packageManager` fingerprint fast path to the Claude `skill-router` hook and reused the parsed package snapshot for verification recommendations, removing another avoidable lockfile-probe burst from pure Claude flows.
3780
-
3781
- ## 1.1.2 - 2026-04-22
3782
-
3783
- ### Live compact + compress runtime slice
3784
-
3785
- - Added real `src/core/token/`, `src/core/compact/`, and `src/core/output/` runtime modules so compact/compress are no longer config-only switches.
3786
- - Added a threshold-based compact pressure planner with soft/hard phases, hysteresis, cooldown reuse, and layered compact plans so long sessions can auto-compact near the configured context limit without flapping.
3787
- - Threshold compact memory-bridge output now dedupes bulky `Previous context` snapshots into compact anchors such as active task, key decision, rule, and next step instead of replaying the same context blob twice.
3788
- - `ukit memory recall` now uses live input compaction, prompt-cache reuse, and compaction-history metrics.
3789
- - Memory recall now tightens its own budget under compact pressure, preserving project anchors and key decisions while dropping lower-value extras when the runtime is already under hard pressure.
3790
- - Added a real Claude `PreCompact` runtime lane that re-injects compact routed context, previous shared memory context, and recent compressed command output from shared runtime cache.
3791
- - Added a Claude `PostToolUse` Bash output-compression hook that compresses noisy terminal output into reusable summaries under `ukit/storage/cache/output-history.json`.
3792
- - Added an automatic previous-context bridge in the installed `route-task` helper so Codex-routed flows can carry compact shared memory context in `.claude/ukit/skill-router-state.json` without relying on manual recall commands.
3793
- - Added a compact recent-output bridge in the installed `route-task` helper so Codex-routed flows can carry the latest compressed terminal summary into `.claude/ukit/skill-router-state.json` and invalidate reuse when that output snapshot changes.
3794
- - Added safe-zone terminal compression profiles for repeated search/file-list/tree/git output so UKit keeps anchor paths and test signals while dropping noisy repeated lines.
3795
- - Claude reinject now reuses that compact shared `previousContext` snapshot before rescanning `ukit/storage/memory/`, cutting duplicate memory retrieval work across Codex/Claude continuation flows while keeping the same safety fallback.
3796
- - Claude `skill-router` now persists compact shared `previousContext` snapshots earlier in `.claude/ukit/skill-router-state.json` and invalidates same-prompt reuse when that memory snapshot changes, so pure Claude flows also benefit from lower repeated memory drag before `PreCompact`.
3797
- - Updated shared adapter guidance so OpenCode (`AGENTS.md`) and Antigravity (`.antigravity/rules/rules.md`) reuse compact `previous-context` / `recent-output` snapshots from the shared route state before widening reads or replaying noisy logs.
3798
- - OpenCode and Antigravity guidance now also points both adapters at the canonical `node .claude/ukit/index/route-task.mjs ...` helper for complex/ambiguous routing so they can refresh the same shared route memory path Codex/Claude already use.
3799
- - OpenCode now ships native `opencode.json` command entrypoints for shared UKit route/context/index/query/verify/triage flows, pins `--adapter opencode`, and keeps those helpers internal so end users still only need `ukit install`.
3800
- - Shared `route-task` state now records the originating adapter (`claude`, `codex`, `antigravity`, `opencode`) so OpenCode/Claude continuations do not accidentally reuse the same cached route snapshot just because the task text matches.
3801
- - Antigravity can now call its native symlinked helper path (`node .antigravity/ukit/index/route-task.mjs ...`) and route/resolve/triage using `.antigravity/ukit/index/...` lanes instead of falling back to Claude-shaped helper paths.
3802
- - `verify-context` and maintainer `ukit index verify` output now compact repeated targeted test commands and verbose docs-only notes into shorter canonical display lines without changing verification policy.
3803
- - Memory recall / previous-context snippets now use compact canonical `project=...` / `session=...` display lines so agents spend fewer tokens on repeated prose while keeping decisions, rules, actions, and next steps visible.
3804
- - `ukit status` now surfaces prompt-cache and output-compression metrics so maintainers can see live savings instead of only static config toggles.
3805
- - Maintainer `release:verify` now defaults to a local `npm pack --dry-run --json` packaging check instead of hitting npmjs during the normal release-ready workflow.
3806
-
3807
- ## 1.1.0 - 2026-04-21
3808
-
3809
- ### Production-ready v1.1.0 runtime foundation
3810
-
3811
- - Promoted UKit to **v1.1.0** with a shared project-local runtime at `ukit/` for config, cache, and cross-agent memory.
3812
- - Added maintainer-facing runtime commands:
3813
- - `ukit status`
3814
- - `ukit memory list|search|recall|forget|export`
3815
- - Hardened lifecycle commands around the new runtime:
3816
- - `ukit doctor` now validates `ukit/storage/` health and runtime config integrity
3817
- - uninstall now removes tracked runtime config/cache files under `ukit/` safely
3818
- - Updated installed Claude/Codex/AGENTS guidance so adapters know to reuse `ukit/storage/config.json`, `ukit/storage/memory/`, and the shared runtime cache files.
3819
- - Added a safe recall lane for non-trivial work: `ukit memory recall "<task>"` now prints a compact `## Previous Context` block from shared local memory before widening docs/context.
3820
- - Hardened recall before release so it stays inside the current project boundary and fails closed when `ukit/storage/config.json` is corrupted.
3821
- - Fixed publish packaging so the OpenCode adapter preset is included in the npm artifact even though `opencode.json` is globally gitignored in the repo.
3822
-
3823
- ## 1.0.1 - 2026-04-21
3824
-
3825
- ### Patch release
3826
-
3827
- - Added **OpenCode** as a first-class optional coding adapter in the default `ukit install` surface.
3828
- - Kept the human workflow unchanged: teammates still only need to remember **`ukit install`**.
3829
- - Reused the canonical `AGENTS.md` + `.claude/skills/` workspace shape for OpenCode instead of generating a duplicate mirror tree, keeping the adapter leaner for production.
3830
- - Added a production-tuned managed `opencode.json` with:
3831
- - safe default build agent behavior
3832
- - compaction enabled
3833
- - noisy watcher paths ignored
3834
- - index/test/lint/build commands auto-allowed where safe
3835
- - destructive git/rm flows denied or forced through confirmation
3836
- - Extended adapter selection, gitignore management, uninstall ownership handling, docs, and integration coverage for the new OpenCode adapter.
3837
- - Re-verified the release lane after the patch with artifact smoke, full core suite, and `npm publish --dry-run`.
3838
-
3839
- ## 1.0.0 - 2026-04-16
3840
-
3841
- ### Product promise
3842
-
3843
- - Teammates should remember only **`ukit install`** for normal in-project workflow.
3844
- - The same command handles first-time workspace setup and refresh inside a project.
3845
- - The AI should absorb the complexity: routing, hidden skill activation, context pulling, verification scope, and selective delegation.
3846
-
3847
- ### Core capabilities
3848
-
3849
- - **Index-first code localization** so Claude Code, Codex, and Antigravity can find the right files/tests quickly without broad repo reads.
3850
- - **Automatic skill routing** from prompt + file/tool evidence, including hidden lanes such as Docker packaging and DuraOne.
3851
- - **Scoped verification** that prefers related tests and only widens when shared/risky scope justifies it.
3852
- - **Shared multi-adapter workspace** authored once and reused across Claude, Codex, and Antigravity.
3853
-
3854
- ### Release hardening
3855
-
3856
- - Made index freshness **source-aware**, not just age-based:
3857
- - stale detection now rebuilds when indexed source/style files changed immediately after the last build
3858
- - symlinked source directories are deduplicated to avoid duplicate/cyclic indexing
3859
- - shipped helpers/mirror follow the same freshness rule after **`ukit install`**
3860
- - Broadened hidden index test handling for co-located `.test.mjs`, `.spec.mjs`, `.test.cjs`, and `.spec.cjs`, and kept likely test files out of normal query top matches unless the prompt explicitly asks for tests/specs.
3861
- - Tightened the Claude auto-allow hook so interpreter entrypoints (`node`, `python`, `bash`, etc.) are not silently whitelisted as generic safe Bash rules.
3862
- - Removed empty `frontend-vue` placeholder components from the shipped hidden skill bundle by replacing them with real reference wrappers for mobile dropdown and form-view usage.
3863
- - Cut one extra stale-path freshness reread from shipped index helpers by returning `generatedAtMs` directly from index rebuild summaries and reusing it after rebuild.
3864
- - Added packed-artifact smoke coverage proving the published npm tarball can:
3865
- - run `ukit install`
3866
- - ship working index helpers
3867
- - build the shipped index
3868
- - route Docker packaging work
3869
- - support default adapters
3870
- - support nested DuraOne monorepo activation
3871
- - Fixed index graph resolution for extensionless React-style internal imports (`.jsx`, `.tsx`, and directory `index.jsx` / `index.tsx`) so rerunning **`ukit install`** rebuilds correct relations/analogs in JSX/TSX projects too.
3872
- - Fixed source discovery for supported **symlinked source files** in both the repo runtime and the shipped installed mirror, so alias file paths inside the project remain indexed/searchable even when the real file lives elsewhere.
3873
- - Stopped `ukit install` from claiming success before the required source-code index actually finishes; if index build fails, the command now tells maintainers to fix the repo state and rerun **`ukit install`**.
3874
- - Slimmed the bundled hidden `canvas-design` asset lane to a curated built-in font set, cutting the published tarball from roughly **3.3 MB** to **1.5 MB** while preserving immediate post-install usability and the one-command `ukit install` workflow.
3875
- - Deduped the heavy hidden **OOXML** support bundle used by PPTX/DOCX into a shared installed lane, preserving the same skill paths after `ukit install` via symlinks and safely migrating previously managed real directories on reinstall.
3876
- - Hardened uninstall against stale tracked metadata under managed symlink roots: if old install records still mention descendants like `.claude/skills/pptx/ooxml/...` after the root became a tracked link, uninstall now removes only the tracked link and refuses to follow that symlink into the shared target bundle.
3877
- - Hardened reinstall migration for shared OOXML symlink targets so UKit only auto-replaces an old real directory when every nested path is still clearly UKit-managed; untracked empty subdirectories now block replacement instead of being silently deleted.
3878
- - Hardened reinstall migration again so even an **empty real directory** at a managed symlink target is treated as ambiguous user content; UKit now warns and keeps the directory instead of silently replacing it during `ukit install`.
3879
- - Hardened legacy reinstall cleanup so `ukit install` no longer deletes the whole old `ukit/.ukit/` directory tree; it now removes only the legacy `install.json` file and keeps any user files that may still live under that folder.
3880
- - Hardened legacy flat-file cleanup so paths like `.claude/skills/delivery.md` are removed only when they are actual files/symlinks; if a user has a real directory with the same legacy name, UKit now preserves it instead of recursively deleting it.
3881
- - Hardened adapter deselection metadata cleanup so removing a managed link path also removes stale tracked descendants under that path, preventing old `.antigravity/skills/...` or `.codex/skills/...` entries from lingering in install metadata after `ukit install --tools=...` changes.
3882
- - Hardened maintainer preview flows so `ukit diff` / dry-run install planning no longer delete a previously managed real directory before showing the preview; only the real install path may perform safe managed-directory replacement.
3883
- - Fixed index import resolution for **single-segment `baseUrl` imports** (for example `import { loadUser } from 'userApi'` with `baseUrl: "./src/services"`), in both the source runtime and the shipped installed mirror, so source-code indexing keeps relations/query ranking correct for that TypeScript layout too.
3884
- - Hardened adapter deselection safety again so UKit only prunes deselected adapter files when install metadata proves UKit actually owns them; a first `ukit install` no longer deletes a teammate’s pre-existing `.codex/.antigravity` files just because the adapter is currently deselected.
3885
- - Tightened deselection ownership handling so when adapter cleanup is skipped (non-interactive mode, user says no, or the path is a real directory), UKit immediately drops those deselected paths from install metadata instead of carrying stale ownership forward to uninstall.
3886
- - Restored **index-first routing** for prompt-only hybrid lanes where a standalone specialist (for example Docker packaging) is selected together with a real code skill; source runtime, shipped `route-task`, and the Claude `skill-router` hook now keep `resolve-context` available instead of falling straight to `read-skill-instructions`.
3887
- - Hardened fresh `ukit install` ownership handling against stray/non-UKit `install.json` files: obsolete-path pruning and metadata carry-forward now trust previous tracked files only when metadata proves the prior install was actually written by UKit, so a first install no longer deletes or inherits ownership of user files from foreign/stale metadata.
3888
- - Stopped tracking **skip-strategy bootstrap files** (for example `docs/PROJECT.md`, `docs/MEMORY.md`, `docs/WORKLOG.md`, `CLAUDE.md`, `AGENTS.md`, `.claude/settings.local.json`, `.codex/settings.local.json`) as uninstall-owned outputs, so UKit preserves team memory/local settings even when those files were first created by `ukit install`.
3889
- - Kept **test-like direct targets** targeted even when filenames omit `.test` / `.spec` (for example `tests/pages/LoginFlow.js`): source verification planning and shipped `resolve-context` / `verify-context` helpers now treat `tests/` / `specs/` targets as related tests instead of downgrading to minimal verification.
3890
- - Hardened source `deriveVerificationPlan(...)` again so callers that pass a precomputed/raw `contextResult` still normalize direct `tests/` / `specs/` primary targets into targeted verification; direct test files no longer fall back to `mode=minimal` just because `relatedTests` was not pre-expanded upstream.
3891
- - Fixed source + shipped index discovery so root-level **`specs/` / `spec/` / `test/` / `__tests__/`** lanes are scanned and treated consistently as likely tests; spec-root tests now feed `tests-map` / relations correctly and stay deprioritized in normal file search unless the prompt explicitly asks for tests/specs.
3892
- - Completed the root test-lane hardening so **root `test/`, `spec/`, and `__tests__/`** paths are recognized consistently across index build, query ranking, and direct test-target routing/verification heuristics in both source and shipped helpers.
3893
- - Aligned shipped helper cache keys with route-task seeding for **target-only helper invocations** (`--target ...` with no prompt text), so direct `resolve-context` / `verify-context` calls can reuse the route-seeded cache instead of recomputing indexed context.
3894
- - Reused relations/analogs safely for alias-based projects when code + alias config stay unchanged, reducing wasted rebuild work on repeated refreshes.
3895
- - Fixed package file modes so published regular files are readable and shipped hook/bin entrypoints stay executable in the npm artifact.
3896
- - Installed full hidden-skill companion bundles (references/scripts/assets) for default skill packs that need them, while keeping the teammate workflow unchanged: remember only **`ukit install`**.
3897
- - Cleared stale routed state when a later prompt has no matching skill, preventing old verification policies from leaking into unrelated work.
3898
- - Expanded explicit “full suite” verification intent detection so Vietnamese prompts like `chạy full test suite` are honored too.
3899
- - Hardened packaging for release-critical templates and adapter presets so publish artifacts match repo behavior.
3900
- - Added maintainer-facing production release checklist and completed the missing npm/GitHub release metadata.
3901
-
3902
- ### Migration notes
3903
-
3904
- - The old legacy delegation stack is **not** part of the UKit 1.0.0 product surface.
3905
- - If you are upgrading an older workspace, rerun **`ukit install`** to refresh the installed files and hidden routing logic.
3286
+ Entries for 1.0.0 through 2.0.7 are archived in the repository at `docs/archive/CHANGELOG-1.0.0-2.0.7.md` (not shipped in the npm package).