LearnNewsExamplesServices
Frontmatter
id13395
titleRestore Codex direct wake route to osascript
stateClosed
labels
bugaitestingregressionarchitecturemodel-experience
assigneesneo-gpt
createdAtJun 16, 2026, 1:26 AM
updatedAtJun 16, 2026, 2:35 AM
githubUrlhttps://github.com/neomjs/neo/issues/13395
authorneo-gpt
commentsCount0
parentIssue13287
subIssues[]
subIssuesCompleted0
subIssuesTotal0
blockedBy[]
blocking[]
closedAtJun 16, 2026, 2:35 AM

Restore Codex direct wake route to osascript

Closed v13.1.0/archive-v13-1-0-chunk-3 bugaitestingregressionarchitecturemodel-experience
neo-gpt
neo-gpt commented on Jun 16, 2026, 1:26 AM

Context

During #13287 recovery on 2026-06-15, the active @neo-gpt wake route was found to be using adapter: 'codex-app-server' even though the operator-observed working path was the guarded Codex UI osascript flow with focusSeedKey: 'r'. The broader parent #13287 still owns live Codex prompt-submit/start-turn matrix proof; this ticket is the narrower template and route repair so future bootstraps do not reintroduce the experimental app-server debug client as the default direct-wake path.

Live latest-open sweep: checked latest 20 open issues immediately before creation on 2026-06-15 23:31 UTC; found parent #13287 and no equivalent narrow route-template ticket. A2A in-flight sweep: checked latest 30 messages across all read states immediately before creation; only the current wake-suppressed #13287 lane claim overlapped this scope. Semantic ticket sweep: ask_knowledge_base for Codex wake route osascript subscriptionTemplate codex-app-server direct wake route ticket duplicate found historical app-server direction/implementation (#10517, #13067) but no corrective default-route restoration ticket.

Release classification: v13.1 Agent Harness reliability, boardless. This sub is a small corrective close target; parent #13287 owns the full live reactivation/matrix proof.

The Problem

The current Codex app-server route is implemented through codex debug app-server send-message-v2, which is a debug/test-client path and cannot be treated as durable proof that a direct A2A wake submitted a Codex turn. Leaving the @neo-gpt subscription template on codex-app-server means a re-bootstrap can drift back to a route whose process success only proves app-server acceptance/injection, not the #13287 final submit/start-turn requirement.

The Architectural Reality

  • ai/graph/identityRoots.mjs is the bootstrap source for first-party AgentIdentity.subscriptionTemplate metadata.
  • ai/services/memory-core/WakeSubscriptionService.mjs hydrates stale identity cache rows from the durable AgentIdentity row during bootstrap, so the template must carry the correct default metadata.
  • ai/daemons/wake/daemon.mjs still supports explicit codex-app-server routes, but its own comments state send-message-v2 command success is not proof of the Codex prompt-submission / turn-start boundary.
  • ai/docs/wake-prompt-landing-matrix.md remains the authority for live prompt landing/submission evidence; this sub-ticket does not lift that evidence requirement.

The Fix

Restore the direct-wake default for @neo-gpt to the guarded Codex UI route:

  • adapter: 'osascript'
  • appName: 'Codex'
  • tabShortcut: null
  • focusSeedKey: 'r'

Keep the explicit codex-app-server adapter available and fail-visible for controlled probes, but stop documenting or testing it as the default direct wake route for @neo-gpt.

Contract Ledger

Target Surface Source of Authority Proposed Behavior Fallback / Edge Case Docs Evidence
@neo-gpt.properties.subscriptionTemplate.harnessTargetMetadata ai/graph/identityRoots.mjs Default direct wake route is osascript with focusSeedKey: 'r'. Explicit app-server routes remain possible only when a subscription opts into adapter: 'codex-app-server'. Identity-root unit test. Unit coverage for template shape.
WakeSubscriptionService.bootstrap() durable-template recovery ai/services/memory-core/WakeSubscriptionService.mjs Cache-stale bootstrap hydrates the osascript Codex route, not the debug app-server route. If the durable row changes, bootstrap reflects that row and tests must be updated with the new contract. WakeSubscriptionService unit test. Unit coverage for created subscription and hydrated identity metadata.
Wake operator guide wording learn/agentos/wake-substrate/PersistentProcessManagement.md Describe Codex direct wakes as the current osascript route; app-server remains explicitly configured/live-host-gated. The broader #13287 matrix still blocks wake substrate reactivation until live proof exists. Operator guide update. Static diff + unit tests for code surfaces.

Decision Record impact: none. This is aligned with the existing wake prompt landing matrix and does not change ADR-level topology.

Acceptance Criteria

  • @neo-gpt static wake subscription template uses the Codex osascript direct-wake route with focusSeedKey: 'r'.
  • WakeSubscriptionService.bootstrap() preserves that route when hydrating from durable AgentIdentity state.
  • Existing explicit codex-app-server wake daemon behavior remains fail-visible and does not silently fall back to osascript.
  • Operator-facing wake process docs stop listing codex debug app-server send-message-v2 as the normal Codex direct-wake path.
  • Focused unit coverage passes for identity roots, wake subscription bootstrap, and wake daemon Codex route behavior.

Out of Scope

  • Full #13287 live Codex prompt-submit/start-turn validation.
  • Re-enabling the wake safety gate or restarting the wake/orchestrator substrate.
  • Replacing send-message-v2 with a documented JSON-RPC turn/start app-server client.
  • Stale-read retry suppression from #13281 / #13285.

Related

Parent: #13287 Related: #13067 Related: #10517

Origin Session ID: 09850a49-643e-42cc-81dc-b2b38bf6f3a1

Retrieval Hint: "Codex wake direct route osascript focusSeedKey r subscriptionTemplate app-server send-message-v2 #13287"

tobiu referenced in commit c6fb14a - "fix(wake): restore Codex direct wake route (#13395) (#13396) on Jun 16, 2026, 2:35 AM
tobiu closed this issue on Jun 16, 2026, 2:35 AM