openai / openai/codex

Allow harness-generated timing to be omitted from model-visible tool results

Open
#42,092 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

CLI config enhancement model-behavior tool-calls
Dominant language
Rust
Stars
125k
Forks
19.4k
PR merge metrics
PR metrics pending

Description

Environment and scope
  • Observed Codex version: 0.150.1
  • Interfaces: direct CLI and clients using codex app-server
  • This appears to be shared core behavior rather than platform-specific behavior
Problem

Codex adds its own elapsed-time metadata to model-facing tool results, for example:

Wall time: 835 seconds

This value is generated by Codex. It is not command stdout, stderr, or MCP tool-returned content. I need a supported way to prevent it from entering model context.

This is an information-boundary requirement, not merely a model-behavior complaint. Even if every model ignored the value, I would still want Codex not to disclose it.

This request concerns explicit timing generated by Codex. It does not attempt to prevent indirect inference of latency or remove timing emitted by the underlying command or tool.

Long blocking calls are normal in my workflow and must be repeated. Models sometimes treat the reported duration as a reason to abandon that workflow. This illustrates the impact, but it is not required to reproduce the underlying issue.

Implementation confirmation

The timing is added while constructing model-facing results, not only while rendering the UI.

In the current 0.152.0 source:

Requested behavior

Provide a supported configuration or model-input policy that omits Codex-generated elapsed-time metadata from model-accessible tool results.

When enabled:

  • Codex-generated timing must be absent from model input and persisted or replayed conversation history.
  • The policy must cover direct exec, MCP, model-accessible code-mode results, and elapsed timing in abort results.
  • Command stdout, stderr, exit status, errors, tool status, and tool-returned content must remain unchanged.
  • Timing emitted by the underlying command or MCP tool must not be filtered.
  • Operator-facing timing must remain available through client events, the UI, logs, tracing, and telemetry.
  • The policy must be honored by direct CLI sessions and threads created through codex app-server.

Hiding timing only in the UI is insufficient. Omission must occur before model-input and conversation-history construction.

The existing behavior may remain available for compatibility. The exact configuration name is not important; a global setting inherited by app-server threads would satisfy the request.

Contributor guide

Open the contributing guide

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.

Research direction

Start in codex-rs/core/src/tools/context.rs, especially response_header(), response_payload(), and the code-mode result handling linked in the issue. Trace how these results enter model input and persisted or replayed history, including abort results and app-server threads. Done means an opt-in policy omits Codex-generated timing across all listed result paths while preserving command and tool output plus operator-facing timing.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
api, tooling
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Active
Clarity
Clearly specified
Newbie friendliness
52/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.