@adhdev/daemon-core 0.9.82-rc.354 → 0.9.82-rc.356
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/dist/index.js +637 -209
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +637 -209
- package/dist/index.mjs.map +1 -1
- package/dist/mesh/mesh-event-trace.d.ts +21 -0
- package/dist/mesh/mesh-runtime-store.d.ts +1 -1
- package/dist/mesh/mesh-work-queue.d.ts +1 -1
- package/dist/providers/cli-provider-instance.d.ts +2 -0
- package/dist/providers/spec/adapter.d.ts +22 -0
- package/dist/providers/spec/cli-adapter.d.ts +6 -0
- package/dist/providers/spec/evaluator.d.ts +1 -0
- package/dist/providers/spec/fsm-driver.d.ts +49 -7
- package/dist/providers/spec/fsm-evaluator.d.ts +4 -0
- package/dist/providers/spec/types.d.ts +47 -5
- package/package.json +2 -2
- package/src/commands/router.ts +19 -6
- package/src/mesh/mesh-event-trace.ts +67 -0
- package/src/mesh/mesh-events-coordinator.ts +117 -12
- package/src/mesh/mesh-events-pending.ts +33 -0
- package/src/mesh/mesh-events-stale.ts +3 -1
- package/src/mesh/mesh-reconcile-loop.ts +47 -0
- package/src/mesh/mesh-runtime-store.ts +18 -2
- package/src/mesh/mesh-work-queue.ts +8 -1
- package/src/providers/cli-provider-instance.ts +86 -4
- package/src/providers/spec/adapter.ts +67 -0
- package/src/providers/spec/cli-adapter.ts +63 -7
- package/src/providers/spec/evaluator.ts +38 -13
- package/src/providers/spec/fsm-driver.ts +158 -14
- package/src/providers/spec/fsm-evaluator.ts +19 -2
- package/src/providers/spec/types.ts +41 -5
|
@@ -34,6 +34,21 @@ export type ControlAction =
|
|
|
34
34
|
wait_for: WaitForCondition;
|
|
35
35
|
extract_choices: SectionPattern;
|
|
36
36
|
submit_key: string;
|
|
37
|
+
/**
|
|
38
|
+
* How a parsed choice is committed once the picker is open.
|
|
39
|
+
* 'index' (default) — type the on-screen number then `submit_key`
|
|
40
|
+
* (`{index}\r`). Correct for CLIs whose picker is number-selectable
|
|
41
|
+
* (codex-cli, hermes-cli).
|
|
42
|
+
* 'arrow_keys' — the picker is a cursor list that ignores number keys
|
|
43
|
+
* (claude-cli /model): move the cursor from its current row to the
|
|
44
|
+
* target row with up/down arrows, then confirm with the `submit_key`
|
|
45
|
+
* tail (the `\r` left after stripping `{index}`). Requires the
|
|
46
|
+
* extracted choices to flag the current cursor row.
|
|
47
|
+
*/
|
|
48
|
+
select_mode?: 'index' | 'arrow_keys';
|
|
49
|
+
/** Arrow byte sequences for `select_mode: 'arrow_keys'`. Defaults to
|
|
50
|
+
* ANSI cursor up/down (`[A` / `[B`) when omitted. */
|
|
51
|
+
cursor_keys?: { up: string; down: string };
|
|
37
52
|
}
|
|
38
53
|
| {
|
|
39
54
|
type: 'attach_image';
|
|
@@ -154,11 +169,15 @@ export interface SectionDef {
|
|
|
154
169
|
until?: string; // section id OR regex (starts with ^)
|
|
155
170
|
/**
|
|
156
171
|
* Anchor regex(es). A single string anchors on the first/last matching line
|
|
157
|
-
* (per `anchor_last`). An array is an OR-set
|
|
158
|
-
*
|
|
159
|
-
*
|
|
160
|
-
*
|
|
161
|
-
*
|
|
172
|
+
* (per `anchor_last`). An array is an OR-set of candidate shapes: each
|
|
173
|
+
* candidate resolves its OWN anchor line independently (anchor_last → that
|
|
174
|
+
* candidate's last matching line, else its first), then the TOPMOST resolved
|
|
175
|
+
* line across candidates wins — a section's anchor marks the top of its
|
|
176
|
+
* block, so the highest recognized landmark bounds the whole block. This
|
|
177
|
+
* lets one section capture two shapes — e.g. a box-divider modal AND a
|
|
178
|
+
* divider-less modal whose only stable landmark is the question line above
|
|
179
|
+
* its numbered choices — while preventing a stray LOWER landmark (e.g. an
|
|
180
|
+
* input-box `────` rule below the choices) from clipping the block.
|
|
162
181
|
*/
|
|
163
182
|
anchor?: string | string[];
|
|
164
183
|
anchor_flags?: string;
|
|
@@ -223,4 +242,21 @@ export interface ExtractButtons {
|
|
|
223
242
|
key_for_index: string;
|
|
224
243
|
min_count?: number;
|
|
225
244
|
continuation_lines?: boolean;
|
|
245
|
+
/**
|
|
246
|
+
* How a button is committed when its modal is resolved (auto-approve or an
|
|
247
|
+
* explicit dashboard click).
|
|
248
|
+
* 'index' (default) — send `key_for_index` with `{index}` filled in
|
|
249
|
+
* (`{index}\r` → `1\r`). Correct for modals whose buttons are
|
|
250
|
+
* number-selectable (codex, hermes, antigravity number rows).
|
|
251
|
+
* 'arrow_keys' — the modal is a cursor list that IGNORES number keys
|
|
252
|
+
* (claude-cli's new TUI approval modal): a typed `1` leaks into the
|
|
253
|
+
* composer as literal text and `\r` submits it. Instead move the cursor
|
|
254
|
+
* from its current row to the target row with up/down arrows, then
|
|
255
|
+
* confirm with the `key_for_index` tail (the `\r` left after stripping
|
|
256
|
+
* `{index}`). Mirrors the `open_picker` `select_mode` of the same name.
|
|
257
|
+
*/
|
|
258
|
+
select_mode?: 'index' | 'arrow_keys';
|
|
259
|
+
/** Arrow byte sequences for `select_mode: 'arrow_keys'`. Defaults to ANSI
|
|
260
|
+
* cursor up/down (`[A` / `[B`) when omitted. */
|
|
261
|
+
cursor_keys?: { up: string; down: string };
|
|
226
262
|
}
|