From bb411f49f44e1db4da4f7f8a3ac29eeb7266bc49 Mon Sep 17 00:00:00 2001 From: Victor Date: Sun, 14 Dec 2025 12:42:19 -0800 Subject: [PATCH 1/2] docs: document enabling experimental skills Skills are behind the experimental `skills` feature flag (disabled by default), but the skills guide didn't explain how to turn them on. - Add an explicit enable section to docs/skills.md (config + --enable) - Add the skills flag to docs/config.md and docs/example-config.md - Document the /skills slash command --- docs/config.md | 1 + docs/example-config.md | 1 + docs/skills.md | 18 ++++++++++++++++++ docs/slash_commands.md | 1 + 4 files changed, 21 insertions(+) diff --git a/docs/config.md b/docs/config.md index ca4ba015e939..4659c2604c1e 100644 --- a/docs/config.md +++ b/docs/config.md @@ -49,6 +49,7 @@ Supported features: | `ghost_commit` | false | Experimental | Create a ghost commit each turn | | `enable_experimental_windows_sandbox` | false | Experimental | Use the Windows restricted-token sandbox | | `tui2` | false | Experimental | Use the experimental TUI v2 (viewport) implementation | +| `skills` | false | Experimental | Enable discovery and injection of skills | Notes: diff --git a/docs/example-config.md b/docs/example-config.md index f1d36cd4536f..0d09a6186925 100644 --- a/docs/example-config.md +++ b/docs/example-config.md @@ -220,6 +220,7 @@ view_image_tool = true web_search_request = false ghost_commit = false enable_experimental_windows_sandbox = false +skills = false ################################################################################ # Experimental toggles (legacy; prefer [features]) diff --git a/docs/skills.md b/docs/skills.md index 81bc278797af..5a9f17f0b07a 100644 --- a/docs/skills.md +++ b/docs/skills.md @@ -4,6 +4,19 @@ Codex can automatically discover reusable "skills" you keep on disk. A skill is a small bundle with a name, a short description (what it does and when to use it), and an optional body of instructions you can open when needed. Codex injects only the name, description, and file path into the runtime context; the body stays on disk. +## Enable skills + +Skills are behind the experimental `skills` feature flag and are disabled by default. + +- Enable in config (preferred): add the following to `$CODEX_HOME/config.toml` (usually `~/.codex/config.toml`) and restart Codex: + + ```toml + [features] + skills = true + ``` + +- Enable for a single run: launch Codex with `codex --enable skills` + ## Where skills live - Location (v1): `~/.codex/skills/**/SKILL.md` (recursive). Hidden entries and symlinks are skipped. Only files named exactly `SKILL.md` count. @@ -23,6 +36,11 @@ Codex can automatically discover reusable "skills" you keep on disk. A skill is - If valid skills exist, Codex appends a runtime-only `## Skills` section after `AGENTS.md`, one bullet per skill: `- : (file: /absolute/path/to/SKILL.md)`. - If no valid skills exist, the section is omitted. On-disk files are never modified. +## Using skills + +- Mention a skill by name in a message using `$`. +- In the TUI, you can also use `/skills` to browse and insert skills. + ## Validation and errors - Invalid skills (missing/invalid YAML, empty/over-length fields) trigger a blocking, dismissible startup modal in the TUI that lists each path and error. Errors are also logged. You can dismiss to continue (invalid skills are ignored) or exit. Fix SKILL.md files and restart to clear the modal. diff --git a/docs/slash_commands.md b/docs/slash_commands.md index 6961461d4263..b0fd596e4c62 100644 --- a/docs/slash_commands.md +++ b/docs/slash_commands.md @@ -24,6 +24,7 @@ Control Codex’s behavior during an interactive session with slash commands. | `/mention` | mention a file | | `/status` | show current session configuration and token usage | | `/mcp` | list configured MCP tools | +| `/skills` | browse and insert skills (experimental; see [docs/skills.md](./skills.md)) | | `/logout` | log out of Codex | | `/quit` | exit Codex | | `/exit` | exit Codex | From e687db8c1595b6ee859aaad76cb3af46326eebd8 Mon Sep 17 00:00:00 2001 From: Victor Date: Sun, 14 Dec 2025 13:15:13 -0800 Subject: [PATCH 2/2] docs: format slash commands table Run Prettier so `pnpm run format` passes after adding the /skills entry. --- docs/slash_commands.md | 36 ++++++++++++++++++------------------ 1 file changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/slash_commands.md b/docs/slash_commands.md index b0fd596e4c62..ed5b4dc85a98 100644 --- a/docs/slash_commands.md +++ b/docs/slash_commands.md @@ -10,24 +10,24 @@ Slash commands are special commands you can type that start with `/`. Control Codex’s behavior during an interactive session with slash commands. -| Command | Purpose | -| ------------ | ----------------------------------------------------------- | -| `/model` | choose what model and reasoning effort to use | -| `/approvals` | choose what Codex can do without approval | -| `/review` | review my current changes and find issues | -| `/new` | start a new chat during a conversation | -| `/resume` | resume an old chat | -| `/init` | create an AGENTS.md file with instructions for Codex | -| `/compact` | summarize conversation to prevent hitting the context limit | -| `/undo` | ask Codex to undo a turn | -| `/diff` | show git diff (including untracked files) | -| `/mention` | mention a file | -| `/status` | show current session configuration and token usage | -| `/mcp` | list configured MCP tools | +| Command | Purpose | +| ------------ | -------------------------------------------------------------------------- | +| `/model` | choose what model and reasoning effort to use | +| `/approvals` | choose what Codex can do without approval | +| `/review` | review my current changes and find issues | +| `/new` | start a new chat during a conversation | +| `/resume` | resume an old chat | +| `/init` | create an AGENTS.md file with instructions for Codex | +| `/compact` | summarize conversation to prevent hitting the context limit | +| `/undo` | ask Codex to undo a turn | +| `/diff` | show git diff (including untracked files) | +| `/mention` | mention a file | +| `/status` | show current session configuration and token usage | +| `/mcp` | list configured MCP tools | | `/skills` | browse and insert skills (experimental; see [docs/skills.md](./skills.md)) | -| `/logout` | log out of Codex | -| `/quit` | exit Codex | -| `/exit` | exit Codex | -| `/feedback` | send logs to maintainers | +| `/logout` | log out of Codex | +| `/quit` | exit Codex | +| `/exit` | exit Codex | +| `/feedback` | send logs to maintainers | ---