Task · AIO-0005.03

Codex developer: spike, image, runner and telemetry

Description

Adds OpenAI Codex CLI as a developer agent. doc-0002 “Codex” has the facts: amazon-bedrock provider on bedrock-mantle, hooks-based plugin with one generation per turn, managed hooks in /etc/codex/config.toml to avoid the interactive trust step the Grafana guide mentions, native OTel that needs logs:write, and several UNVERIFIED items. Start with a spike on a throwaway box (not the demo host) and record the answers in this task before building. The spike decides the Bedrock region and whether MCP works on the Bedrock provider; if MCP does not, record which prompts are excluded for Codex.

Acceptance Criteria

Definition of Done

Implementation Plan

Verify pinned Codex 0.162.1 against live Bedrock before image integration. Signed /openai/v1/models returns 404; /v1/models succeeds and lists openai.gpt-5.6-luna in us-east-1, but POST /v1/responses rejects that model as unsupported. Discriminate inference routing before choosing any provider workaround; do not promote catalog availability to executable proof.

Implementation Notes

2026-10-15 live signed streaming inference succeeded: us-east-1 /openai/v1/responses, openai.gpt-5.6-luna, reasoning low, returned touchline-spike-ok and response.completed. Model discovery is /v1/models; its path differs intentionally from OpenAI inference. Initial nonstream timeout does not establish endpoint incompatibility. Keep pinned Codex default provider route.

Live throwaway ARM64 container proved scoped Mantle initial/resume, same thread, real apply_patch and mcp__time__get_current_time, two ingested generations with correct user/team/model/tokens. Plugin reports provider codex and omits cost; runner estimates cumulative cost separately. Native metrics initially absent: pinned core/src/otel_init.rs gates custom metrics on analytics.enabled. Corrected to true only with explicit Grafana exporters; live rerun now exposes codex_turn_token_usage_{bucket,count,sum}, codex_tool_call_total, codex_hooks_run_total, and latency families. No browser proof claimed.

Additional live transport proof: Codex called a streamable-HTTP MCP fixture and returned its exact marker; stdio MCP was already proven. Managed hooks work in initial and resumed sessions without trust bypass. Actual hook/output vocabulary includes apply_patch and Bash. Native metric namespace touchline confirmed.

All spike facts now recorded: working region/model, real stdio and HTTP MCP, initial/resume managed hooks and Stop-derived generations, actual thread_id, apply_patch/Bash vocabulary, provider/cost limitation and actual native metric names. Runtime image checksum/Sigstore verified and hooks parity checked. Visual Coding agents criterion remains unverified by maintainer decision.

Implementation and required runtime/API evidence complete; resume for the explicitly deferred Coding agents visual verification and final host rollout after AIO-0007 (unpatched braces advisory disposition). No browser proof claimed.

References

View the source file on GitHub