[Feature] Per-model V1/V2 subagent mode selection (including V2 Plaintext)

Open
#8,953 3 comments 1 reaction 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
42/100
Issue type
Feature
Clarity
Clearly specified
Activity status
Active
Tech stack
typescript

Research direction

Start by reading the multi-agent mode configuration and routed task delivery paths, especially the V2 Plaintext compiler for the canonical ChatGPT route. Check whether provider identity is available when selecting a parent model and constructing subagent tasks. Done means compatible third-party parents can use readable V2 tasks, or per-model mode overrides select V1/V2/V2 Plaintext for new conversations without changing existing ones; the issue does not name specific files or tests.

Written by the indexing model from the issue text.

Description

enhancement proxy
Area

Proxy and routing

What are you trying to accomplish?

I want to choose the multi-agent collaboration mode per model, instead of applying one global V1/V2 mode to every model in Codex Desktop.

My preferred setup is:

  • Native ChatGPT GPT models: v2-plaintext, so they can delegate readable tasks to routed subagents.
  • opencode-go/deepseek-v4.1-flash: v2, since I tested it as a V2 parent and it can spawn working V2 subagents.
  • ZQ/gpt-6.2-sol: v1 as a compatibility fallback, because V2 delegation currently fails for me.

Ideally, the mode would be selected automatically when I choose a parent model for a new conversation. I would also like to know whether individual subagent models can be configured separately (for example, one model uses V1 and another uses V2), rather than being forced to use the same collaboration mode globally.

I want to retain V2 where it actually works, without repeatedly changing the global mode to accommodate an incompatible provider.

What prevents this today?

I'm using OpenCodex 2.100.5 with Codex Desktop. I have enabled multiAgentMode: "v2-plaintext".

I tested three scenarios:

  1. Native GPT parent → DeepSeek V2 child: Works. Both spawn_agent and followup_task successfully deliver readable tasks to opencode-go/deepseek-v4.1-flash.
  2. DeepSeek parent → V2 subagents: Also works. I tested opencode-go/deepseek-v4.1-flash as the parent and it was able to spawn and use V2 subagents successfully.
  3. Third-party GPT parent → DeepSeek V2 child: With ZQ/gpt-6.2-sol (using the openai-responses adapter) as the parent, V2 child creation fails in practice. The child reports: Routed V2 worker task is encrypted for the native ChatGPT backend and cannot be read by the selected provider. The parent reports unreadable_encrypted_agent_task; sometimes the child conversation fails to load at all. This still happens with V2 Plaintext enabled, as shown in the attached screenshot.

I understand the documented plaintext compiler only applies to the canonical ChatGPT forward route, not arbitrary third-party Responses providers. I have not verified where the encrypted payload originates.

Questions:

  • Is it expected that v2-plaintext does not rewrite tasks for a third-party GPT parent using openai-responses?
  • Is there a way to fix this specific routed-GPT-parent failure while keeping working third-party V2 parents such as DeepSeek on V2?
  • If not, can OpenCodex let users assign V1/V2 modes per model, instead of forcing a global choice?
What should OpenCodex do?

Ideally, please investigate whether compatible third-party GPT providers can participate in readable V2 delegation, while preserving the current canonical-ChatGPT plaintext path.

Regardless of whether that is possible, I would like a configurable per-model collaboration mode:

  • Allow an explicit v1, v2, or v2-plaintext choice for eligible models, with a global default for models without an override.
  • When starting a new conversation, use the selected parent model's configured mode automatically.
  • Keep DeepSeek on V2 when it works; use V1 only for specific incompatible models such as my routed ZQ/gpt-6.2-sol.
  • Do not silently change existing conversations or forward encrypted tasks to providers unable to read them.

Additional question about subagent configuration: Could the mode also be configured per subagent model in the subagent roster (e.g. model A uses V1, model B uses V2)? If mixing V1 and V2 subagents within one parent session is not supported by Codex's collaboration protocol, could you clarify that limitation and support per-parent-model modes for new sessions as a first step?

The exact implementation/configuration interface is flexible.

Example usage or interface

An illustrative configuration could look like this:

{
  "multiAgentMode": "v2",
  "multiAgentModeByModel": {
    "gpt-6.2-sol": "v2-plaintext",
    "ZQ/gpt-6.2-sol": "v1",
    "opencode-go/deepseek-v4.1-flash": "v2"
  }
}

This is proposed syntax, not an existing OpenCodex configuration option.

Expected behavior when starting new parent sessions:

  1. Select native gpt-6.2-sol → use V2 Plaintext; routed DeepSeek child tasks remain readable.
  2. Select opencode-go/deepseek-v4.1-flash → use V2; it can spawn V2 subagents.
  3. Select ZQ/gpt-6.2-sol → automatically use V1, avoiding the failing V2 task-delivery path.
  4. No manual global-mode toggling or restart just to switch models.

If supported, I would also appreciate individual subagent-model V1/V2 settings in the subagent configuration UI. If not, per-parent-model selection alone would already solve my main workflow issue.

Alternatives or workarounds
  • Global V1: Avoids some V2 incompatibilities, but unnecessarily gives up working V2 flows for native GPT and DeepSeek.
  • Global V2 Plaintext: Native GPT → DeepSeek works, and DeepSeek can also act as a V2 parent, but ZQ/gpt-6.2-sol still fails as a V2 parent.
  • Manually change the global mode: Possible, but inconvenient when switching between models.
  • Separate OpenCodex configurations/instances: More complicated than a per-model setting.

I am aware of the experimental agentTaskRecovery mechanism, but it does not appear to be a general fix for arbitrary third-party parent models.

Additional context

Environment

  • OpenCodex: 2.100.5
  • Client: Codex Desktop
  • Tested global mode: v2-plaintext
  • Native parent: gpt-6.2-sol (ChatGPT OAuth)
  • Third-party GPT parent that fails: ZQ/gpt-6.2-sol (openai-responses)
  • Third-party V2 parent that works: opencode-go/deepseek-v4.1-flash
  • Confirmed working third-party V2 child: opencode-go/deepseek-v4.1-flash

Related issues and implementation

I'm happy to provide sanitized request logs and further reproduction details if needed.

image image
Checks
  • I searched existing issues and documentation.
  • This request describes a concrete OpenCodex workflow rather than merely naming a desired technology.
  • I removed secrets and personal data.
Dominant language
TypeScript
Stars
16.9k
Forks
1.3k
Avg merge
1d 4h
Merged PRs (30d)
814

Getting set up

This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from lidge-jun/opencodex

All issues in lidge-jun/opencodex

Similar issues

More TypeScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.