@dtlabs/ai-toolkit 0.16.5 → 0.16.6

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
@@ -1,4 +1,12 @@
1
1
  ## 0.1.4 (2026-07-21)
2
+ ## [0.16.6](https://github.com/dtlab-tech/ai-toolkit/compare/v0.16.5...v0.16.6) (2026-10-06)
3
+
4
+
5
+ ### Bug Fixes
6
+
7
+ * **task-executor:** drop --permission-prompts, it doesn't exist ([903dea5](https://github.com/dtlab-tech/ai-toolkit/commit/903dea58fba475e3bf5caa83a41723977f6d742e))
8
+ * **task-executor:** drop --permission-prompts, it doesn't exist ([9c49c78](https://github.com/dtlab-tech/ai-toolkit/commit/9c49c789f385e88763d606d70bdfd9653e37a948))
9
+
2
10
  ## [0.16.5](https://github.com/dtlab-tech/ai-toolkit/compare/v0.16.4...v0.16.5) (2026-10-05)
3
11
 
4
12
 
@@ -58,16 +58,21 @@ on any platform other than `win32` (see "Platform qualification" below), before
58
58
  other validation.
59
59
 
60
60
  **Permission bypass.** Every real implementation/review worker this loop dispatches is spawned
61
- with `--permission-mode auto --permission-prompts none` appended to its CLI args
62
- (`EXECUTOR_PERMISSION_BYPASS_ARGS` in `lib/task-executor/index.js`). A non-interactive `--print`
63
- invocation has no TTY to answer a permission prompt, so without this every Write/Edit/mkdir tool
64
- call is denied by default, regardless of task content — confirmed against a real run where every
65
- BE/FE task failed verification because its expected files/directories were never created. This
66
- restores exactly the invocation Tech-Spec OQ-01's pre-Gate-1 spike validated ("Percorso C") and
67
- Gate 1 was approved against; it had gone missing from the actual `dispatchTaskAttempt`/`runReview`
68
- implementation. The mode is deliberately unscoped within the task's own `--project` directory —
69
- the executor's job is letting a developer agent write anywhere under that project, so (unlike
70
- pm-phase1/2's read-only-text workers) a narrower allowlist is not an option here.
61
+ with `--permission-mode auto` appended to its CLI args (`EXECUTOR_PERMISSION_BYPASS_ARGS` in
62
+ `lib/task-executor/index.js`). A non-interactive `--print` invocation has no TTY to answer a
63
+ permission prompt, so without this every Write/Edit/mkdir tool call is denied by default,
64
+ regardless of task content — confirmed against a real run where every BE/FE task failed
65
+ verification because its expected files/directories were never created. `auto` alone was then
66
+ independently confirmed sufficient (a live dispatch created all of its task's expected
67
+ directories and files). An earlier version of this fix also appended `--permission-prompts
68
+ none`, citing Tech-Spec OQ-01's pre-Gate-1 spike note as having validated that exact pair —
69
+ reproduced directly against the real, installed CLI (v2.1.220): `--permission-prompts` is not a
70
+ recognized flag at all (`claude --help` lists no such option; passing it exits 1 with `error:
71
+ unknown option '--permission-prompts'` before any model/API call), so that spike note is stale or
72
+ was never run against the real executable as claimed. The mode is deliberately unscoped within
73
+ the task's own `--project` directory — the executor's job is letting a developer agent write
74
+ anywhere under that project, so (unlike pm-phase1/2's read-only-text workers) a narrower
75
+ allowlist is not an option here.
71
76
 
72
77
  ### `status`
73
78
 
@@ -74,28 +74,40 @@ function _buildProcessTag(runId, taskId, attemptNumber) {
74
74
  // the tagged "worker" under test, per this task's own testing constraint.
75
75
  const DEFAULT_TAGGED_PROCESS_EXE_BASENAME = 'claude.exe';
76
76
 
77
- // Permission-bypass flags required for every real (non-test-fixture) worker
78
- // spawn — implementation AND review alike. Without them, a non-interactive
77
+ // Permission-bypass flag required for every real (non-test-fixture) worker
78
+ // spawn — implementation AND review alike. Without it, a non-interactive
79
79
  // `--print` invocation has no TTY to answer a permission prompt, so every
80
- // Write/Edit/mkdir tool call is denied by default: this was validated
81
- // (Tech-Spec OQ-01, "Percorso C", resolved 2026-09-18, pre-Gate-1 spike) as
82
- // `--permission-mode auto --permission-prompts none` — "Exit 0 confirmed
83
- // with structured JSON output and full usage data" — and is NOT a new or
84
- // speculative flag choice, it restores exactly what Gate 1 was approved
85
- // against (see internal_docs/features/FTR-018-deterministic-task-execution-
86
- // checkpoints-and-resume/history/pre-consolidation-2026-09-20-*.md). It was
87
- // missing from dispatchTaskAttempt's/runReview's actual baseSpawnArgs/
88
- // spawnArgs literals — every real implementation/review dispatch was
89
- // therefore guaranteed to have every write denied, regardless of task
90
- // content (confirmed against a real blocked run: INFRA-TASK-INFRA-01's own
91
- // post-dispatch verification found none of its expected directories had
92
- // been created). `--permission-mode auto` is deliberately broad (unscoped
93
- // within the spawned cwd) — the executor's whole job is letting a developer
94
- // agent write anywhere under the task's project, so a narrower scoped
95
- // allowlist is not an option here the way it was for pm-phase1/2's
96
- // read-only-text workers (see lib/workflow-control.js's own doc comment on
97
- // why THAT subsystem sidesteps Write entirely instead).
98
- const EXECUTOR_PERMISSION_BYPASS_ARGS = ['--permission-mode', 'auto', '--permission-prompts', 'none'];
80
+ // Write/Edit/mkdir tool call is denied by default: confirmed against a real
81
+ // blocked run (INFRA-TASK-INFRA-01's own post-dispatch verification found
82
+ // none of its expected directories had been created) before this constant
83
+ // existed at all. `--permission-mode auto` is a real, documented choice on
84
+ // the installed CLI (`claude --help`: "(choices: \"acceptEdits\", \"auto\",
85
+ // \"bypassPermissions\", \"manual\", \"dontAsk\", \"plan\")") and is
86
+ // deliberately broad (unscoped within the spawned cwd) — the executor's
87
+ // whole job is letting a developer agent write anywhere under the task's
88
+ // project, so a narrower scoped allowlist is not an option here the way it
89
+ // was for pm-phase1/2's read-only-text workers (see
90
+ // lib/workflow-control.js's own doc comment on why THAT subsystem sidesteps
91
+ // Write entirely instead).
92
+ //
93
+ // CORRECTION: an earlier version of this constant also appended
94
+ // `--permission-prompts none`, citing Tech-Spec OQ-01's pre-Gate-1 spike
95
+ // note ("Percorso C", resolved 2026-09-18) as having validated that exact
96
+ // pair. Reproduced directly against the real, currently-installed CLI
97
+ // (v2.1.220): `--permission-prompts` is NOT a recognized flag at all —
98
+ // `claude --print --permission-mode auto --permission-prompts none` fails
99
+ // immediately with `error: unknown option '--permission-prompts'` (exit 1,
100
+ // commander.js argv validation, before any model/API call). Every dispatch
101
+ // would have failed closed again, just with a different symptom (an argv
102
+ // crash instead of a denied Write) — so the historical spike note is either
103
+ // stale against a since-changed CLI surface or was never run against the
104
+ // real executable as literally claimed (this Tech-Spec history already
105
+ // contains one prior instance of an overclaimed, later-audited-away result —
106
+ // see FTR-018-Gate1-Review-Actions.md's own "Correction (2026-09-22)"). Only
107
+ // `--permission-mode auto` is carried forward; it alone was independently
108
+ // confirmed sufficient (a live dispatch created all of its task's expected
109
+ // directories and files).
110
+ const EXECUTOR_PERMISSION_BYPASS_ARGS = ['--permission-mode', 'auto'];
99
111
 
100
112
  // Real, positive-evidence-only liveness query for a tagged process, using
101
113
  // the exact E-02-qualified Win32_Process/CIM technique proven in the Gate-1
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dtlabs/ai-toolkit",
3
- "version": "0.16.5",
3
+ "version": "0.16.6",
4
4
  "description": "AI Toolkit — reusable agents and procedures for developers to build AI-powered applications.",
5
5
  "files": [
6
6
  "docs/",