Skip to content

Add durable Companion mode conversation initialization - #60

Open
alex-w-99 wants to merge 4 commits into
mainfrom
feat/skip-webhook-reconcile
Open

alex-w-99 wants to merge 4 commits into
mainfrom
feat/skip-webhook-reconcile

Conversation

@alex-w-99

@alex-w-99 alex-w-99 commented Sep 20, 2026

Copy link
Copy Markdown
Contributor

Executive Summary

Add durable Companion mode conversation initialization to Codex bridge 0.2.14.

  • Initialize group email, MMS and iMessage conversations with one complete history input.
  • Persist ordered work, fixed reply targets, and explicit status/recovery commands.
  • Build SDK 0.7.3 from an immutable public source revision in PR CI.

Description

The Companion inbox feeds the native session queue, records logical input and acknowledged thread/turn identifiers, and retains each turn's group reply target. inkbox-codex companion-status exposes checkpoints; companion-resolve supports reviewed recovery. History never enters local command or approval parsing. Current main's activity callbacks, context-only queue messages, group reply behavior, A2A progress and audio support are preserved.

All PR unit and contract jobs fetch and verify public SDK commit 449966c885208d41f995d09c54072e012df9eb1a, build the Python wheel from sdk/python, and install it alongside the bridge. Runtime requirements and installed-version checks remain >=0.7.3,<1.0.0; no checks are disabled.

Reason

Group conversations need complete available context and a durable boundary between initialization, subsequent messages and uncertain host execution. Exact-source SDK builds enable honest prerelease validation without depending on registry publication.

Decisions

  • Host input: Use one complete initialization input in the native queue, bounded by a configurable 262144-byte default.
  • Recovery: Require a reviewed outcome for ambiguous submissions rather than automatically repeat the turn.
  • Dependencies: Keep the package's SDK floor unchanged and make PR CI explicitly build the pinned public SDK source.
  • Configuration: Upgrades preserve identity settings; an administrator selects and enables the sponsor.

Testing

  • Exact public SDK checkout and wheel build succeeded. Three native app-server Companion lifecycle cases passed using the rebuilt wheel and deterministic local model responses.
  • Each channel submitted one initializer, held live work behind completion, and resumed the same thread after restart without another initializer.
  • Post-merge focused checks: 158 source cases and 7 installed-wheel/native/SDK-threshold cases passed.
  • Exercise companion-status, companion-resolve, group replies and uncertain restart recovery: expect fixed group targeting and no blind replay.
  • PR CI run 35497300760 passed on 86ca19e: Python 3.11/3.12/3.13 unit jobs and native host contracts. CodeQL also passed. Published-registry installation and live channel/model acceptance remain unverified.

Readiness-triggered CI snapshot (2026-09-20 08:48 UTC)

Readiness-triggered Full stack e2e 35500001349 failed during dependency setup. The reusable canary and live installers still request registry inkbox==0.7.3, which is unavailable. These paths need the same exact-source dependency handling as unit CI before tests can run; no live acceptance is established.

Companion PR stack

These peer PRs each target their own main; the coordinated set is now ready for review.

Review and release status

Ready for review. SDK/CLI 0.7.3 remains unreleased; SDK PR 190 and public source commit 449966c885208d41f995d09c54072e012df9eb1a are the dependency reference. Current-head unit/contract CI passed; any readiness-triggered live checks require their own completed results. Package publication and full live channel/model acceptance are not claimed.

Comment thread inkbox_codex/gateway.py
response = web.json_response({"ok": True, "ignored": event_type})
except CompanionClosedError as exc:
self._dedup_rollback(request_id)
return web.Response(status=503, text=str(exc))
Comment thread inkbox_codex/gateway.py
return web.Response(status=503, text=str(exc))
except CompanionError as exc:
self._dedup_rollback(request_id)
return web.Response(status=422, text=str(exc))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants