CLI: duplicate numbered-list Markdown rule in system instructions (token waste)

Resolved 💬 3 comments Opened Mar 21, 2026 by kiankyars Closed Mar 21, 2026

<!-- Structured like .github/ISSUE_TEMPLATE/3-cli.yml -->

What version of Codex CLI is running?

codex-cli 0.116.0

What subscription do you have?

Not specified

Which model were you using?

gpt-5.4

What platform is your computer?

Darwin 25.3.0 arm64 arm

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

Cursor integrated terminal / zsh (not critical to this report)

What issue are you seeing?

The system / base instructions repeat the same Markdown list rule verbatim multiple times: numbered lists must use ` 1. 2. 3. -style markers (period after the number), never 1) `.

This shows up twice in the resolved base_instructions.text recorded in rollout session metadata (same substring appears in two different bullet contexts). It wastes context tokens and adds noise without adding constraint.

What steps can reproduce the bug?

  1. Start a Codex CLI session with a model that uses the bundled instructions (e.g. gpt-5.4).
  2. Inspect rollout session_meta / cached model metadata, or search the composed base_instructions string for:

For numbered lists, only use the … ` 1. 2. 3. never 1) `.

  1. Observe two occurrences in the same composed blob.

Source locations (same bullet in two templates):

The model instructions template includes {{ personality }}, so orchestrator-style personality content and the “Final answer formatting rules” section can both carry the identical paragraph.

Shipped metadata: codex-rs/core/models.json — for slug: "gpt-5.4", the same sentence appears twice inside base_instructions and twice inside model_messages.instructions_template (duplicate blocks within each string, not only cross-file duplication).

What is the expected behavior?

The rule should appear once in the composed system prompt (single source of truth), e.g. keep it only under final-answer formatting or only under personality/tone—not both—and dedupe the gpt-5.4 blobs in models.json.

Additional information

Happy to open a PR that removes the duplicate from one template and dedupes the gpt-5.4 strings in models.json if the team wants an external contribution—say the word and I’ll base it on main.

View original on GitHub ↗

This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗