Feature Request: map root disable-model-invocation to the codexcli agents/openai.yaml invocation policy
Problem
The root-level disable-model-invocation skill flag is a shared default for most targets, but not for codexcli. From docs/reference/file-formats.md (v17.0.0):
shared default for tools that support the flag — claudecode, copilot, copilotcli, crush, cursor, zed, pi, qwencode, grokcli, factorydroid, dsh, and commandcode.
For Codex the equivalent control lives only in the agents/openai.yaml sidecar, and the sidecar is emitted only from an explicit codexcli section — same file:
When
codexcli.interface,codexcli.policy, orcodexcli.dependenciesis present, Rulesync emits.agents/skills/<name>/agents/openai.yamland reads it back on import.
In the source, buildOpenaiYamlObject in src/features/skills/codexcli-skill.ts receives only the codexcli section and returns early without it:
const hasSidecarFields = Boolean(codexcli.interface || codexcli.policy || codexcli.dependencies);
if (!hasSidecarFields) {
return undefined;
}
So a skill written once as user-only:
---
name: release-notes
description: Draft release notes from the merged pull requests
targets: ["*"]
disable-model-invocation: true
---
is user-only in Claude Code, Copilot, Cursor and the other listed targets, and implicitly invocable in Codex: no sidecar is written, and Codex's SKILL.md frontmatter carries only name and description, so nothing else can express the policy. The author has to know about the gap and repeat the intent in a Codex-specific form on every such skill:
codexcli:
policy:
allow_implicit_invocation: false
In a repository where some pipeline steps run in Claude Code and others in Codex, the same skill then behaves differently depending on which harness picks it up.
Proposed solution
Treat root disable-model-invocation as a shared default for codexcli as well, mapped onto policy.allow_implicit_invocation in the sidecar.
The root flag already maps onto a target whose native form differs from a boolean key — devin "also reads this root value (true maps onto a user-only triggers list)" — so a mapping onto a sidecar field fits the existing design. #1770 introduced the sidecar and #1928 introduced the root flag with per-target overrides; this request connects the two for codexcli.
Desired behaviour
- Root
disable-model-invocation: truewith nocodexcli.policy.allow_implicit_invocation→ the sidecar is emitted withpolicy.allow_implicit_invocation: false, even if the skill has no othercodexclifield. - An explicit
codexcli.policy.allow_implicit_invocationwins over the root flag, as the other targets' own sections do today. - Root
disable-model-invocation: falseor absent, with nocodexclisidecar fields → no sidecar, exactly as today. - On import, a sidecar whose only content is
policy.allow_implicit_invocation: falseround-trips to rootdisable-model-invocation: truerather than to acodexcli.policyblock, or the choice between the two is documented.
Reference
Read at tag v17.0.0: docs/reference/file-formats.md (the root disable-model-invocation flag, the codexcli section and the Codex sidecar note) and src/features/skills/codexcli-skill.ts (buildOpenaiYamlObject). Related: #1741, #1770, #1928.