Commit Graph

9 Commits

Author SHA1 Message Date
Patrick Fu
1cf9a45ca2 Handle encrypted collaboration message schemas
- Generalize spawn_agent tool path discovery into codexToolPathsByNames
  driven by a name set, and add codexCollaborationMessageTools covering
  spawn_agent, send_message, and followup_task.
- Strip parameters.properties.message.encrypted from all collaboration
  message tools (top-level tools and input[].additional_tools, including
  nested namespace tools) via removeCodexCollaborationMessageEncryption,
  invoked unconditionally before the spawn-agent optimization decision.
- Extend optimize_multi_agent_v2_test.go with coverage for the new tool
  path discovery, encrypted-field removal semantics, preservation of
  unrelated encrypted fields, and end-to-end OptimizeCodexMultiAgentV2Request
  behavior across namespace and additional_tools payloads.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-08-03 04:40:13 +08:00
Luis Pater
3d5ec8628e feat(models): add minimal reasoning level to Codex client models
- Introduced a new reasoning level, `minimal`, to the `codexClientAllowedReasoningLevels` map.
- Updated response-building logic to include descriptive messaging for the `minimal` level.

Closes: #4542
2026-07-28 01:54:16 +08:00
Luis Pater
f8dffa0522 feat(logging): log Codex media forwarding start with detailed fields
- Implemented logging for Codex remote media forwarding start events, including detailed connection and credential metadata.
- Added `formatLogFieldValue` for quoting specific log fields and ensured newline safety in log output.
- Enhanced unit tests to validate log content, escaping, and field inclusion.
2026-07-25 07:51:43 +08:00
Luis Pater
49be36aef6 feat(live): add TCP proxy for Codex Live WebRTC relay
- Implemented a TCP proxy for WebRTC candidate tunneling in Codex Live, supporting passive TCP candidates on port 443.
- Restricted tunneling to globally routable public IPs and added safeguards for rejecting unsafe/private targets.
- Added robust validation of STUN BindingRequest frames before forwarding to upstream candidates.
- Includes extensive unit tests for proxying behavior, candidate validation, and tunnel edge cases.
2026-07-25 07:12:28 +08:00
Luis Pater
ebc7446929 feat(diff): enhance config diff and relay updates for Codex Live Media
- Added comprehensive diffing for Codex live media relay settings, including support for public IP, UDP port ranges, and ICE server changes.
- Introduced `displayOptionalValue` utility to handle optional values in diff outputs.
- Improved test coverage for config change detection, ensuring no sensitive information leakage.
- Replaced `allow-private-remote-ips` with the new `disable-private-remote-ips` property, adding YAML backward compatibility.
- Updated Codex live handler to differentiate media relay configuration changes and runtime updates.
2026-07-25 06:09:50 +08:00
Luis Pater
bda79b21bb feat(live): relay realtime WebRTC media 2026-07-25 05:11:28 +08:00
Luis Pater
46172dd452 feat(live): add Codex Live session handler and sideband support
- Implemented `live` package to handle Codex WebRTC session bootstrap requests.
- Introduced session forwarding, OAuth-based selection, and multipart payload handling.
- Added sideband WebSocket relay functionality with authorization pinning.
- Comprehensive tests for session handling, response validation, and header management included.

Closes: #4541
2026-07-25 03:44:41 +08:00
Luis Pater
71d591296b feat(models): add Codex client model catalog and response builder
- Introduced a new `models` package for organizing Codex client model templates and building responses.
- Migrated Codex response handling to `codexmodels.BuildResponse`.
- Added comprehensive tests for model metadata, reasoning levels, and input modalities handling.
2026-07-25 01:24:22 +08:00
Luis Pater
84bf9376e5 feat(executor): replace sdktranslator.TranslateRequest with helps.TranslateRequestWithCodexMultiAgentV2
- Updated Kimi and Gemini executors to use `TranslateRequestWithCodexMultiAgentV2` for improved multi-agent v2 optimization.
- Enhanced configuration and API server to support `CodexOptimizeMultiAgentV2`.
- Added codex multi-agent V2 optimizations in `config`, `executor`, and `watcher` modules.
2026-07-25 00:32:37 +08:00