jg-agent-hq 13.5.7 → 13.5.8

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,5 +1,9 @@
1
1
  # Changelog
2
2
 
3
+ ## 13.5.8
4
+
5
+ - Keep informational Codex messages in the transcript and out of question observers when their async delivery carries no questions. Preserve validation for question bundles.
6
+
3
7
  ## 13.5.7 — documentation navigation
4
8
 
5
9
  - Keep the package overview concise and route setup, runtime ownership and delivery details to their canonical guides. Runtime behavior and public APIs are unchanged.
package/api/README.md CHANGED
@@ -260,7 +260,7 @@ File timestamps and records do not prove that a native process is idle or a turn
260
260
 
261
261
  ## Async questions
262
262
 
263
- An explicit Codex `agentMessage` with `delivery: 'async'` carries optional `asyncInput` on its normalized history item. The same metadata is available in live items, item details and every evidence fragment. Ordinary messages have no `asyncInput`; text or a `questions` field alone never establishes async semantics.
263
+ An explicit Codex `agentMessage` with `delivery: 'async'` carries `asyncInput` when it includes a non-null `questions` field. The same metadata is available in live items, item details and every evidence fragment. Async messages with a missing or null `questions` field are informational notices. Their text remains visible in the transcript, and question observers receive no item for them. Text or a `questions` field alone never establishes async semantics.
264
264
 
265
265
  Available metadata is `{ delivery: 'async', state: 'available', questions }`. Each ordered question has a nonempty `title` and optional ordered string `options`. Native `options: null` is normalized to an omitted `options` field for free-text questions. Question and choice strings retain their exact content, up to 8192 UTF-16 code units each, with at most 32 questions and 32 choices per question. The entire normalized `asyncInput` must fit `MAX_ASYNC_INPUT_BYTES` (32768 serialized UTF-8 bytes, including JSON escaping). Additive native fields are tolerated. Malformed contracts retain ordinary preview text and `{ delivery: 'async', state: 'unavailable', reason: 'invalid' }`; valid shapes over the byte budget use `reason: 'too-large'`. Choices are never shortened to fit a response. Evidence fitting accounts for metadata before selecting its text chunk; live memory accounting includes the complete serialized item, and saved/live reconciliation requires matching async metadata.
266
266
 
@@ -493,6 +493,8 @@ The operation matrix describes the implemented native interfaces and their expli
493
493
 
494
494
  On 2026-11-10, Linux with Node.js 24.15.0 and Codex 0.167.0 qualified the built public async-input API in an owned disposable workspace. Actual `request_user_input_async` emission retained the exact question choices and managed/native/turn/item identities, matched saved native history, and left the ordinary `ASYNC_QUALIFICATION_FINAL` result intact. Terminating only that runtime's owned Codex proxy produced output-gap/reconnect signals; bounded native history recovered the same question without inference or input replay. The owned session was deleted and the runtime closed. Fixture tests additionally cover invalid/oversized metadata, evidence fitting, observer isolation and shutdown; macOS and other CLI/model configurations require separate native evidence.
495
495
 
496
+ The informational-notice fix in 13.5.8 was checked through the built public API on Linux with Node.js 24.15.0 and Codex 0.170.0. A native informational notice retained its transcript text and produced no question observation. A genuine asynchronous question reached the observer with its native item identity, appeared in saved history, and the ordinary final response was retained. The disposable native session was deleted and its controller closed.
497
+
496
498
  On 2026-11-07, Codex 0.167.0 consumed image and labeled text input through `turn/steer` in the running turn. Claude Code 2.1.319 with claude-opus-5-5 and normal `auto` permissions consumed text/PDF document blocks at turn start, and image plus labeled text blocks in the original running turn. A native PDF steer was dropped, so it is excluded from Claude's steer media list. The repaired runtime journey verified exact browser/action/source identity, original first-text hash, separate persisted prompt blocks, unchanged saved image bytes, live/history reconciliation, and provenance after restart without resending. The queued prompt's graph UUID differs from its input's source UUID. Its projection rebuild was also checked against the retained real transcript and an older cached index. These checks establish the observed native shapes and provider versions, without using an origin override or changing turn-start encoding.
497
499
 
498
500
  | Area | Executed evidence | Boundary |
@@ -74,9 +74,9 @@ const MessageSchema = z.object({ text: z.string() });
74
74
  const NativeAsyncQuestionSchema = AsyncQuestionSchema.extend({
75
75
  options: AsyncQuestionSchema.shape.options.nullable(),
76
76
  }).transform(({ options, ...question }) => (options == null ? question : { ...question, options }));
77
- /** Preserves explicit async delivery even when its structured presentation cannot be trusted. */
77
+ /** Normalizes async question bundles and leaves informational notices as transcript messages. */
78
78
  const toAsyncInput = (item) => {
79
- if (item.type !== 'agentMessage' || item.delivery !== 'async')
79
+ if (item.type !== 'agentMessage' || item.delivery !== 'async' || item.questions == null)
80
80
  return undefined;
81
81
  const questions = z.array(NativeAsyncQuestionSchema).min(1).max(32).safeParse(item.questions);
82
82
  if (!questions.success)
@@ -210,6 +210,7 @@ export const toHistoryItem = ({ turnId, item, startedAtMs, completedAtMs }, full
210
210
  const last = text.charCodeAt(end - 1);
211
211
  if (end < text.length && last >= 0xd800 && last <= 0xdbff)
212
212
  end -= 1;
213
+ const asyncInput = toAsyncInput(item);
213
214
  return parseNative(HistoryItemSchema, {
214
215
  nativeId: item.id,
215
216
  turnId,
@@ -218,9 +219,7 @@ export const toHistoryItem = ({ turnId, item, startedAtMs, completedAtMs }, full
218
219
  provenance: nativeProvenance(kind, kind === 'user-message' && typeof item.clientId === 'string' ? item.clientId : null, inputText),
219
220
  text: text.slice(0, end),
220
221
  isTruncated: end < text.length,
221
- ...(item.type === 'agentMessage' && item.delivery === 'async'
222
- ? { asyncInput: toAsyncInput(item) }
223
- : {}),
222
+ ...(asyncInput ? { asyncInput } : {}),
224
223
  // a Codex item holds its call and its result together
225
224
  callId: null,
226
225
  outcome,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "jg-agent-hq",
3
- "version": "13.5.7",
3
+ "version": "13.5.8",
4
4
  "description": "Native Claude Code and Codex session control, history, usage and recoverable local storage for Node.js apps.",
5
5
  "type": "module",
6
6
  "license": "MIT",