openai / openai/codex

Skills across ~/.codex/skills and ~/.agents/skills appear duplicated due to path-based deduplication

Open
#44,172 0 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

app app-server bug skills windows-os
Dominant language
Rust
Stars
125k
Forks
19.4k
PR merge metrics
PR metrics pending

Description

What version of the Codex App / CLI are you using?
  • Codex CLI: 0.153.4
  • Codex Desktop App: 26.901.6511.0 (Windows x64)
What platform is your computer?

Microsoft Windows 11 Pro 10.0.26200 x64

What issue are you seeing?

When skills exist in both ~/.codex/skills/ (the traditional Codex skills root) and ~/.agents/skills/ (the open agent skills standard root supported by Codex 0.150+), the skills appear duplicated in:

  1. The Desktop app's $ skill autocomplete / mention picker.
  2. The Desktop app's Skills catalog / dialog.
  3. The prompt instructions under ### Available skills generated by the app-server (codex debug prompt-input).

By inspecting the Desktop App frontend bundle (app.asar), the skills deduplication helper (Exi function) deduplicates entries by path:

function Exi(e) {
  return uniqBy(e?.flatMap(e => e.skills) ?? [], e => e.path);
}

Because ~/.codex/skills/<name>/SKILL.md and ~/.agents/skills/<name>/SKILL.md have different filesystem paths, uniqBy(..., e => e.path) does not deduplicate them, causing duplicate items with identical names in the UI.

Similarly, in the app-server skill loader (ext/skills/src/loader/host_merge.rs), both roots (r0 for ~/.codex/skills and r1 for ~/.agents/skills) register their discovered skills into the catalog without merging or precedence resolution by skill name.

What steps can reproduce the bug?
  1. Create or install a skill in ~/.codex/skills/example-skill/SKILL.md.
  2. Also place or install the same skill in ~/.agents/skills/example-skill/SKILL.md.
  3. Open Codex Desktop or start a new thread.
  4. Type $example-skill in the composer, or query the app-server via skills/list.
  5. Observe that example-skill appears twice with identical names and descriptions.
What is the expected behavior?
  1. Skills across multi-root discovery (~/.agents/skills and ~/.codex/skills) should have a clear precedence rule (e.g. ~/.agents/skills taking precedence over legacy ~/.codex/skills, or vice-versa) so that skills with the same name are merged/deduplicated by name/identifier rather than treated as independent skills.
  2. The Desktop UI deduplication logic should deduplicate skills by name (or canonical skill ID/key) instead of raw path (uniqBy(skills, s => s.name)).

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 with ext/skills/src/loader/host_merge.rs and reproduce the duplicate entries through skills/list using matching skills in both roots. Trace how the catalog is passed to the Desktop picker, Skills catalog, and generated prompt instructions. Done means the roots have a defined precedence or merge behavior and same-name skills no longer appear duplicated in those surfaces.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, rust
Domain
desktop, developer-experience, tooling
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.