Skip to content

[Feature]: Pass configured reasoning_effort through openai-codex Responses path #4198

Description

@Oldrich333

Issue Origin

Observed or reproduced in a real environment

Problem Statement

For vlm.provider = openai-codex, OpenViking cannot honour a configured reasoning effort today.

Two gaps:

  1. VLMConfig (openviking_cli/utils/config/vlm_config.py) has no reasoning_effort field (extra = forbid), and _build_vlm_config_dict() does not pass one into the VLM instance config.
  2. Even when OpenAIVLM puts reasoning_effort on the Chat Completions kwargs, CodexCompletionsAdapter._create_response (openviking/models/vlm/backends/codex_responses_adapter.py) builds a Responses API request with only model / instructions / input / store / tools and drops reasoning_effort.

Net effect for subscription Codex summarization: the Responses call always uses the model default effort. Operators cannot set high / xhigh / max from ov.conf.

Related but distinct from #4066 (LiteLLM per-call thinking translation). This issue is specifically the openai-codex Responses adapter + config surface for reasoning.effort.

Proposed Solution

  1. Add optional reasoning_effort: str | None to VLMConfig and pass it through _build_vlm_config_dict() / credential builders.
  2. In CodexCompletionsAdapter._create_response, when kwargs contain a truthy reasoning_effort, set:
    response_kwargs["reasoning"] = {"effort": reasoning_effort}
    When unset/None, omit the field so the model default remains.
  3. Document vlm.reasoning_effort in ov.conf examples for openai-codex.

Alternatives Considered

  • Leave effort at model default (works for many summarization workloads; this is what we run today).
  • Out-of-tree bind-mount overlays (works, but forks behaviour from upstream and must be rebased on every image bump).
  • Static extra_request_body — does not reach the openai-codex Responses adapter today either.

Feature Area

Model Integration

Use Case

Production knowledge stores that summarize resources via openai-codex (ChatGPT/Codex subscription) need the same effort control agent runtimes already expose (lowxhigh). Without a first-class config + Responses mapping, operators cannot raise effort for hard corpora or lower it for cheap bulk summarization.

Example API (Optional)

{
  "vlm": {
    "provider": "openai-codex",
    "model": "gpt-5.6-luna",
    "reasoning_effort": "xhigh"
  }
}

When reasoning_effort is omitted, behaviour stays as today (model default).

Additional Context

Happy to send a small PR if maintainers want this as a code change rather than design-only. Platform / Model Integration seems closest; please re-route if needed.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    Status
    Backlog

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions