An accessibility-forward native macOS Codex client that uses your local codex app-server over stdio.
Codax is still early alpha, but the protocol-facing layers are now real enough that the repo should be read as an actively evolving native client, not just a shell around placeholder architecture.
Codax currently has working foundations for:
- local Codex process launch and stdio transport
- JSON-RPC request/response routing with retry handling for retryable overloads
- a typed client layer for the currently implemented app-server methods
- a runtime coordinator that owns process, connection, client, notification forwarding, and server-request observation
- an app-facing orchestrator that projects typed runtime events into SwiftUI state
- an early
NavigationSplitViewshell backed by shared orchestrator state
The app is still incomplete:
- the ChatGPT login flow is still a placeholder
- the UI shell is transitional and needs broader state handling, polish, and accessibility work
- request coverage and notification coverage are both still curated subsets of the broader app-server surface
The current ownership chain is:
Transport -> Connection -> Runtime -> Orchestration -> Views
CodexTransportdefines rawDatasend/receive/close behavior.StdioCodexTransportis the current actor-based stdio implementation and lives inCodexTransport.swift.CodexProcesslaunches and terminates the localcodex app-serverprocess.CodexCLIProbeperforms startup compatibility checks before connect flows proceed.
CodexConnectionowns JSON-RPC framing, request correlation, retry behavior, inbound response/error handling, notification decoding, and server-request routing.CodexConnectionremains protocol-focused. It does not own UI state or runtime policy.
CodexRuntimeCoordinatorowns the live runtime boundary.- It creates
CodexProcess,CodexConnection, andCodexClient. - It exposes two separate app-facing streams:
notifications() -> AsyncStream<ServerNotificationEnvelope>serverRequests() -> AsyncStream<ServerRequestEnvelope>
- It installs the default
CodexServerRequestResponderused byCodexConnection.
CodexClientprovides typed wrappers over the generic connection layer.- Shared JSON and decoding helpers live in
CodexClient+CodingSupport.swift. - The client model layer is now split into focused files for account/auth, collaboration, sandbox, error/tool support, items, threads, turns, server notifications, and server requests.
CodexValueis the canonical arbitrary-JSON escape hatch used where upstream payloads remain intentionally open-ended.
CodaxOrchestratoris the app-facing session and state projection layer.- It owns connect, thread loading, thread start, and turn start flows.
- It consumes both runtime streams, although server-request observation is currently wired as a no-op reducer while the default responder still returns
.unhandled. AuthCoordinatorremains the side-effect boundary for auth-specific external actions.
- SwiftUI views consume shared state from
CodaxOrchestrator. ContentViewModelremains pane-local UI state, not the source of shared app state.
Codax/Controllers/Transport- transport protocol, stdio transport, process lifecycle, and CLI compatibility probing
Codax/Controllers/Connection- JSON-RPC message and connection-layer types plus routing behavior
Codax/Controllers/Runtime- runtime ownership via
CodexRuntimeCoordinator
- runtime ownership via
Codax/Controllers/Client- typed client methods, shared JSON/coding helpers, inbound notification/request envelopes, and protocol DTOs
Codax/Controllers/Orchestration- app-facing state, session orchestration, and auth coordination types
Codax/Views- the current SwiftUI shell
CodaxTests- layer-organized tests for transport, connection, client, runtime, and orchestration
Docs- contributor-facing schema, coverage, and architecture reports
CodexClient currently wraps these client-initiated methods:
initializeinitializedthread/startthread/resumethread/readturn/startturn/interruptaccount/readaccount/login/startaccount/login/cancel
The runtime currently surfaces this typed notification subset:
errorserverRequest/resolvedaccount/updatedaccount/login/completedthread/startedthread/status/changedthread/tokenUsage/updatedturn/startedturn/completedturn/diff/updatedturn/plan/updateditem/starteditem/completeditem/agentMessage/deltaitem/commandExecution/outputDeltaitem/fileChange/outputDeltaitem/reasoning/textDeltaitem/reasoning/summaryTextDeltaitem/reasoning/summaryPartAdded
The typed server-request envelope covers the full current request-method union, but the default responder still returns .unhandled after surfacing each request onto the runtime stream.
Codax currently assumes:
- macOS
- Xcode
- a locally installed
codexCLI capable of runningcodex app-server --listen stdio://
The current compatibility gate supports Codex CLI 0.111.x and 0.112.x.
- Open the project in Xcode.
- Build the
Codaxtarget. - Run the app from Xcode.
Current expectations:
- the app launches into an early
NavigationSplitViewshell - compatibility is checked before the runtime starts
- some thread and turn flows are real
- broader login, approval handling, and UI refinement are still in progress
Start with:
- ROADMAP.md
- TRANSPORT_SCHEMA_REPORT.md
- CONNECTION_SCHEMA_REPORT.md
- CLIENT_SCHEMA_REPORT.md
- CLIENT_THREAD_TURN_ITEM_AUDIT.md
- ORCHESTRATION_SCHEMA_REPORT.md
- APP_SERVER_COVERAGE_REPORT.md
- SCHEMA_DIFF_REPORT_v0.111.0_to_v0.112.0.md
Contribution guidance lives in CONTRIBUTING.md.
The highest-value work right now is likely to be:
- broader client request coverage
- broader notification coverage
- real server-request response behavior for approvals, elicitation, and auth refresh
- orchestration refinement
- accessibility-first UI work
- continued architecture and report alignment as the runtime grows
- Codax is still an early alpha project.
- The protocol-facing layers are ahead of the UX.
CodexRuntimeCoordinatoris now the runtime boundary;CodaxOrchestratoris no longer responsible for raw runtime assembly.CodexValueis the single arbitrary-JSON model used across the client and connection layers.- The current docs are contributor-first because architecture maturity still exceeds end-user polish.