| name | workflow-to-skill |
| description | Use when the user wants to turn scattered conversation, a repeated personal/work process, a successful ad hoc procedure, notes, or a workflow idea into a reusable Codex skill. Extract the recurring loop, grill missing decisions one question at a time, write an implementable workflow spec, then create or update the local skill. |
Workflow To Skill
Turn a fuzzy repeated process into a small, predictable Codex skill.
Core Idea
A loop is a recurring pattern in the user's work: a weekly review, a literature extraction pass, a PPT generation routine, a file cleanup ritual, or any task they keep re-explaining. A workflow is the implementable spec for one loop. A skill is the reusable agent instruction that makes the workflow run reliably later.
Use this skill to move from conversation sediment to reusable procedure.
The loop lens is intentionally lightweight: it is a way to notice repeatability, not a mandate to add schedules, automation, checkpoints, or AI where they are not needed.
Workflow
-
Find the loop.
Identify the repeated activity, its natural trigger, inputs, outputs, tools, and what success looks like. If the loop is unclear, propose 1-3 candidate loops and ask the user which one to capture.
-
Build shared notes.
Record the user's terms, tools, preferred paths, source folders, output folders, naming conventions, and disliked failure modes. Keep this concise. When creating files, put raw context in references/notes.md inside the target skill only if it will help future runs.
-
Grill the gaps.
Ask one question at a time. Attach a recommended answer and explain the tradeoff briefly. Push checkpoints late: ask the user only where their choice materially changes the workflow. Continue until an implementer agent could run the workflow without asking a new question.
-
Write the workflow spec.
Use references/workflow-spec.md when the loop is still process-level. The spec must name the trigger, inputs, outputs, steps, checkpoints, validation, and failure recovery.
-
Decide the skill shape.
Use references/skill-spec.md. Prefer one concise SKILL.md. Add references/ only for details used conditionally. Add scripts/ only when deterministic automation prevents repeated fragile work.
-
Create or update the skill.
Install local skills under C:\Users\gongjx\.codex\skills\<skill-name>. Use the existing repo/workspace style when updating. For a new skill, create at minimum SKILL.md; include agents/openai.yaml when useful for the Codex UI.
-
Validate.
Check that frontmatter has name and a trigger-rich description, that every referenced file exists, and that the skill can be understood without this conversation. Tell the user to restart Codex when a new skill should be auto-loaded.
Output Rules
- Do not preserve chat transcript order. Preserve the repeatable process.
- Do not overfit to one example run. Capture the invariant loop and note optional branches.
- Do not ask for preferences that can be safely inferred from prior context.
- Do not create a large skill when a short workflow plus one template is enough.
- If the user asks to make the skill now, implement it instead of only proposing it.
Completion
The work is done when the target skill exists or is updated, validates structurally, and contains enough context for a future Codex session to run the workflow without rereading the original conversation.