agent-director 0.17.1 → 0.17.3

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.
Files changed (2) hide show
  1. package/README.md +20 -14
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -223,7 +223,7 @@ alone (`"Escape"`, `"Enter"`, `"Up"`, `"Down"`, `"Tab"`, or one character),
223
223
  never followed by Enter. With `expect_pane_sha256` (the `pane_sha256` of
224
224
  the `readPane` you looked at, with its `n_lines`), nothing is sent if the
225
225
  pane changed since (`ErrPaneChanged`); on a relayed Spawn a match also
226
- passes the dialog hold (`ErrDialogMaybeOpen`, see "Answering a request at
226
+ passes the API's dialog hold (`ErrDialogMaybeOpen`, see "Answering a request at
227
227
  the pane" below). Pass it only for a pane a person or an LLM judged, never
228
228
  from an automatic flow.
229
229
 
@@ -246,15 +246,19 @@ success and make no exact transcript-confirmation claim. Manual
246
246
  operations (`no_enter`, `key`, empty text, pane hashes and permission answers)
247
247
  return an empty object on success; their input-ownership refusals are in
248
248
  [Manual input ownership](../../docs/caller-contract.md#manual-input-ownership).
249
- Supported launches, Codex fallback paste and input restrictions, omitted-ID
249
+ Supported launches, fallback readiness and input restrictions, omitted-ID
250
250
  behavior, structured outcomes and recovery are in
251
251
  [Ordinary text submission](../../docs/caller-contract.md#ordinary-text-submission).
252
252
  Allow sufficient `callTimeoutMs` for that delivery window; a timeout does not
253
- cancel submission.
253
+ cancel submission. Cursor sends with Enter can return `ErrSubmissionUnconfirmed`
254
+ with `outcome: "gateway_refused"`; see
255
+ [Cursor input outcomes](../../docs/caller-contract.md#cursor-input-outcomes).
254
256
 
255
257
  Pass `allow_pending: true` to also allow a `pending` row: a launch (spawn,
256
- reuse or resume) whose agent has not reported in yet, for example to dismiss a
257
- prompt the agent shows before it reports in. Keys are delivered only to a
258
+ reuse or resume) whose agent has not reported in yet, for example to answer a
259
+ startup choice with `key` (including `key: "Enter"`). See
260
+ [pending startup screens](../../docs/caller-contract.md#pending-rows-and-startup-screens)
261
+ for text answers and Enter-only sends. Keys are delivered only to a
258
262
  session started by the row's current launch. `ended` and `missing` rows are
259
263
  rejected, including retries of an existing delivery request. State, relay and
260
264
  dialog guards precede native capability selection and request reconciliation.
@@ -264,13 +268,15 @@ only a session an earlier launch left behind is found, gets
264
268
 
265
269
  `allow_pending` preserves native readiness and transcript requirements on
266
270
  supported launches; it does not make a startup dialog an ordinary composer.
267
- For fallback input to a pending Codex row, the bounded hook-state observation
268
- and its unconfirmed result are described in the caller contract.
271
+ Ordinary pending Claude fallback has a readiness wait, and pending Claude and
272
+ Codex fallback have a hook check; see
273
+ [Ordinary text submission](../../docs/caller-contract.md#ordinary-text-submission).
269
274
  `SubmissionUnconfirmedDetails` describes only a failed fallback hook observation:
270
275
  `keys_sent: true`, `submission_confirmed: false` and `row_state`. Native
271
- uncertainty and Codex fallback refusals or paste failures carry additional
272
- runtime fields, including `outcome`, `phase`, `bytes_attempted`,
273
- `enter_may_have_been_sent` and `reason`; native attempts can also carry
276
+ uncertainty, Claude fallback's `not_started` refusals, Codex fallback failures
277
+ and Cursor gateway refusals carry additional runtime fields, including
278
+ `outcome`, `phase`, `bytes_attempted`, `enter_may_have_been_sent` and `reason`;
279
+ native attempts can also carry
274
280
  `request_id` and `last_queue`.
275
281
  Read these through `AgentDirectorError.errDetails`, whose type is
276
282
  `Readonly<Record<string, unknown>> | null`, and check their values; see
@@ -279,7 +285,7 @@ for the fields and recovery.
279
285
 
280
286
  `liveness_note: "unreported"` means an alive agent has not reported since
281
287
  launch. Action on a pending row belongs to the
282
- [caller contract](../../docs/caller-contract.md#caller-contract).
288
+ [caller contract](../../docs/caller-contract.md#pending-rows-and-startup-screens).
283
289
 
284
290
  ### readPane
285
291
 
@@ -582,8 +588,8 @@ carry one, typed as exported interfaces: `ErrRelayFallenBack`
582
588
  (`DialogMaybeOpenDetails`), `ErrPauseTimeout` (`PauseTimeoutDetails`) and
583
589
  `ErrSubmissionUnconfirmed`
584
590
  (`SubmissionUnconfirmedDetails`, for failed fallback hook observation).
585
- Native and fallback paste facts remain available through the generic `errDetails`
586
- record. So does the `ErrInternal` of a
591
+ Native, Claude readiness, Codex paste and Cursor gateway facts remain available
592
+ through the generic `errDetails` record. So does the `ErrInternal` of a
587
593
  pane answer whose key was sent but not recorded (`PaneKeySentDetails`:
588
594
  `key_sent` `true` and `request_token`). Read facts from `errDetails`, never
589
595
  from `errDescription`.
@@ -668,7 +674,7 @@ These classes correspond to the shared CLI `err_name` contract. They surface bad
668
674
  |---|---|
669
675
  | `ErrSpawnNotFound` | No spawn row matches the supplied `instance_id`. |
670
676
  | `ErrSpawnNotInteractive` | New input requires a live interactive state (`waiting`/`working`/`ask_user`/`check_permission`); `pending`, `ended`, and `missing` are rejected. With `allow_pending: true`, `sendKeys` allows a `pending` row but delivers keys only to a session started by the row's current launch: a `pending` row with no launch start or launch token recorded, or where only a session an earlier launch left behind is found, is still refused and nothing is sent. `ended` and `missing` rows are refused even when observing an existing delivery request; see [Ordinary text submission](../../docs/caller-contract.md#ordinary-text-submission). |
671
- | `ErrSubmissionUnconfirmed` | `SubmissionUnconfirmedDetails` describes failed fallback hook observation; native and fallback paste outcome fields are available through the generic `errDetails` record. See [Ordinary text submission](../../docs/caller-contract.md#ordinary-text-submission) for automatic delivery and [Manual input ownership](../../docs/caller-contract.md#manual-input-ownership) for manual `sendKeys`. |
677
+ | `ErrSubmissionUnconfirmed` | `SubmissionUnconfirmedDetails` describes failed fallback hook observation; native, Claude readiness, Codex paste and Cursor gateway outcome fields are available through the generic `errDetails` record. See [Ordinary text submission](../../docs/caller-contract.md#ordinary-text-submission) for automatic delivery, [Cursor input outcomes](../../docs/caller-contract.md#cursor-input-outcomes) for `gateway_refused`, and [Manual input ownership](../../docs/caller-contract.md#manual-input-ownership) for manual `sendKeys`. |
672
678
  | `ErrSpawnNotPausable` | The target spawn is not in a pausable (`waiting`) state. |
673
679
  | `ErrPauseTimeout` | Exit keys were sent but `ended` was not observed; `errDetails` has the `PauseTimeoutDetails` shape. See [When pause cannot confirm exit](../../docs/caller-contract.md#when-pause-cannot-confirm-exit). |
674
680
  | `ErrSpawnNotResumable` | `resume` applies only to a finished (`ended`/`missing`) spawn. A live spawn is refused because its agent is running. A `pending` spawn is refused too: it is a launch (spawn, reuse or resume) in progress whose agent has not reported in, a resumed row included. Abandoned or failed launch handling is owned by [Caller contract](../../docs/caller-contract.md) and [Maintenance](../../docs/maintenance.md). Also returned when the row changed after `resume` examined it; nothing is written. |
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "agent-director",
3
- "version": "0.17.1",
3
+ "version": "0.17.3",
4
4
  "type": "module",
5
5
  "os": ["linux", "darwin"],
6
6
  "cpu": ["x64", "arm64"],