Skip to content

Model outputs the same response twice #14805

Closed as not planned
Closed as not planned

Description

@thetinygoat

What version of Codex CLI is running?

codex-cli 0.114.0

What subscription do you have?

Pro

Which model were you using?

gpt-5.4-high

What platform is your computer?

Darwin 24.6.0 arm64 arm

What terminal emulator and version are you using (if applicable)?

Ghostty 1.2.3

What issue are you seeing?

Screenshot of the issue, note the model responds with exact same response twice.

Image

What steps can reproduce the bug?

Nothing special is required, this comes up in normal conversations. Im using the superpowers brainstorming skill not sure if that is relevant.

link to the skill repo: https://github.com/obra/superpowers

What is the expected behavior?

No response

Additional information

No response

Activity

  1. added
    bug
    on Mar 16, 2026
  2. added
    CLI
    model-behavior
    on Mar 16, 2026
  3. github-actions commented on Mar 16, 2026

    @github-actions
    Contributor
  4. etraut-openai commented on Mar 16, 2026

    @etraut-openai
    Contributor

    If you're able to repro this, please use /feedback to upload the session details, then post the thread ID here.

  5. hellectronic commented on Mar 18, 2026

    @hellectronic

    I have the same issue. Most of the time a duplicate response appears when Codex asks for confirmation for the next step. Something like, "Ok that is the proposed design...do this and do that. Does that sound good?...Ok that is the proposed design...do this and do that. Does that sound good?"

  6. thetinygoat commented on Mar 19, 2026

    @thetinygoat
    Author

    I'll try to repro this and share the thread id

  7. hellectronic commented on Mar 20, 2026

    @hellectronic

    I have the same issue. Most of the time a duplicate response appears when Codex asks for confirmation for the next step. Something like, "Ok that is the proposed design...do this and do that. Does that sound good?...Ok that is the proposed design...do this and do that. Does that sound good?"

    thread ID 019d0b82-cf62-74a1-b1ba-07df92b345a6

  8. sangoi-exe commented on Mar 20, 2026

    @sangoi-exe
    Contributor

    Did you increase the context window beyond the usual limit? I tested the 1M when it launched, and once it goes past around 400k tokens, the model becomes unusable. When I scaled it back to just a bit above the usual, around 350k, that problem stopped.

  9. thetinygoat commented on Mar 25, 2026

    @thetinygoat
    Author

    If you're able to repro this, please use /feedback to upload the session details, then post the thread ID here.

    019d2436-feb8-7b71-8b9a-435856700589

  10. thetinygoat commented on Mar 25, 2026

    @thetinygoat
    Author

    Did you increase the context window beyond the usual limit? I tested the 1M when it launched, and once it goes past around 400k tokens, the model becomes unusable. When I scaled it back to just a bit above the usual, around 350k, that problem stopped.

    No im using the default configuration.
    Here's my config.toml

    model = "gpt-5.4"
    model_reasoning_effort = "high"
    personality = "friendly"
    
    [features]
    rmcp_client = true
    steer = true
  11. added
    TUI
    and removed
    model-behavior
    CLI
    on Mar 29, 2026
  12. ziyunli commented on Apr 8, 2026

    @ziyunli

    Also ran into this issue, 019d6e2c-748e-72d1-921e-2efb936060b2

  13. sr198 commented on Apr 10, 2026

    @sr198

    Also ran into the same issue - asked the agent to do an RCA and identify actual fix and here's the response:

    RCA

    The duplication is caused by an instruction collision in my runtime config, not by your prompts.

    There are two competing behaviors in the current agent instructions:

    • commentary is required to be frequent and informative, including what I’m doing and what I’ve learned.
    • final is required to explain outcomes and changes clearly.

    That combination leaves too much overlap. The model treats “inform the user while working” and “explain what was done at
    the end” as partially redundant tasks, so it restates the same content twice.

    There’s also a second contributing factor:

    • the instructions strongly encourage status updates every ~30s
    • but there is no equally strong negative rule saying “do not repeat commentary content in final unless it changed”

    So the model satisfies both objectives independently instead of treating them as separate channels with separate semantics.

    Root Cause Summary

    The real bug is missing channel separation semantics:

    • commentary currently means both progress and mini-summary
    • final currently means both final state and recap

    That ambiguity causes repetition.

    Actual Fix

    Put the preference in the developer prompt, under the channel behavior / final-answer instructions. This is not a repo-
    specific AGENTS.md concern and should not live in product constitutions. It is an agent runtime behavior rule.

    Best place:

    • the developer instructions section that defines Intermediary updates
    • and reinforce it in Final answer instructions

    Patch To Apply

    Add this to the developer prompt under Intermediary updates:

    Channel separation rule:

    • commentary is for incremental progress only.
    • Do not restate completed results in commentary if they will appear in final.
    • Do not use commentary to summarize the whole task, recap prior progress, or preview the final answer.
    • Each commentary update should contain only net-new information: current action, newly discovered constraint, or
      immediate next step.

    Add this to Final answer instructions:

    No-repetition rule:

    • final must not recap process updates that were already communicated in commentary unless the information changed, was corrected, or is necessary to state the final outcome.
    • Prefer reporting only:
      1. the end state,
      2. the files or artifacts changed,
      3. any remaining risk, blocker, or next step.
    • Do not include a progress narrative in final.

    If you want this even stricter, add:

    For small tasks, final should usually be 1-3 sentences and should not repeat reasoning or progress already stated in
    commentary.

    Why This Fix Works

    It creates a hard semantic split:

    • commentary = transient delta
    • final = durable handoff

    That removes the overlap instead of just asking the model to “be less repetitive.”

    What Not To Do

    Don’t put this in:

    • AGENTS.md
    • product constitutions
    • repo architecture docs

    Those govern work in the repo. This issue is cross-task agent behavior, so the fix belongs in the agent’s developer-level
    instruction set.

    Recommended Final Form

    If you want one single rule to install globally, use this:

    commentary is delta-only. final is handoff-only. Never repeat commentary in final unless it changed or is required for
    the final state.

    If you want, I can turn this into a ready-to-paste diff against your current developer prompt text.

  14. alecramos-sudo commented on Apr 12, 2026

    @alecramos-sudo

    submitted feedback for this same thing 019d8330-af3d-7f21-86eb-49a61837a5da

  15. marked Duplicated output #18121 as a duplicate of this issue on Apr 16, 2026
  16. dicedpixels commented on Sep 30, 2026

    @dicedpixels

    Still happens. I'm using Codex CLI with a 3rd party provider. I'd assume it's not a model issue.

    Feedback ID: 01a0f22e-cd3c-73c2-b679-1220aacac8e7.

    Image

    (Do note, the responses are slightly different)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    TUIbug

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions