/evolve-lite:synthesize-skillfrom evolve-lite
Converts a saved trajectory into a reusable agent skill (SKILL.md + supporting scripts) that future agents can invoke to skip rediscovered work.
Ships in evolve-lite. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them; scripts run unread.
This skill reads a saved trajectory and produces a reusable agent skill — a SKILL.md plus any supporting scripts — that captures the successful workflow the session discovered. The output goes to .evolve/skills/<skill-name>/ (canonical, evolve-managed) and to .claude/skills/<skill-name>/ (so Claude Code's skills loader picks it up automatically). Future sessions on the same project can then invoke the skill directly instead of re-deriving the workflow.
This is the executable counterpart to the learn skill's free-text guidelines: learn writes Markdown the next agent has to read and decide what to do; synthesize-skill writes a skill the next agent can simply call.
Use this skill when a trajectory captured:
Skip this skill — and let learn cover the case with a guideline alone — when:
.evolve/skills/ (use learn's guideline path to refine the existing skill instead of creating a duplicate).This skill runs in a forked context. You cannot see the parent conversation directly — read the trajectory the parent passed in via args or via the Run /evolve-lite:synthesize-skill on <path> instruction.
The trajectory path is either:
args to the skill invocation, orThe saved trajectory path is: <path> — take everything after the colon, strip surrounding whitespace and quotes.If neither is present, scan .evolve/trajectories/ for the most recently modified claude-transcript_<session-id>.jsonl and use that. If .evolve/trajectories/ does not exist or is empty, output zero artifacts and exit — do not invent a trajectory.
Read the trajectory with the Read tool — do NOT shell out. The transcript is JSONL: one JSON object per line. Filter for "type": "assistant" and "type": "human" records and reconstruct the flow from message.content.
Walk the trajectory and locate the final, working tool sequence — the one that actually produced the answer. Distinguish it from the trial-and-error leading up to it.
Capture:
Triggers section so the future agent knows when to reach for this skill instead of the failing approaches.If no clearly successful workflow is in the trajectory (the session ended without reaching an answer, or the answer came from a single trivial call), output zero artifacts and exit.
The skill name must be:
extract-exif-metadata, parse-cloudwatch-logs, restart-stuck-deploy).evolve/skills/The skill description (one line, in the SKILL.md frontmatter) should describe the task the skill solves, not the trajectory it came from. Bad: "Solves the focal-length question from session abc123." Good: "Extract EXIF metadata (focal length, GPS, lens, timestamps) from JPEG/HEIC images using Pillow when system EXIF tools are unavailable."
The trigger (in the SKILL.md body, under ## When To Use) should describe the broad task context, not the narrow original request — same rule as the learn skill's guidelines.
Before continuing, list .evolve/skills/ (use the Glob tool, not find / ls) and confirm your chosen name does not collide with an existing skill.
Author a SKILL.md with this exact frontmatter shape — the validator in Step 5 will reject it otherwise:
---
name: <kebab-case-name>
description: <one-line task description>
---
# <Title Case Name>
## Overview
<1–2 sentences: what the skill does and when to use it>
## When To Use
- <trigger 1>
- <trigger 2>
## Workflow
<step-by-step instructions for the agent>
Notes:
context: fork is omitted for synthesized skills. They run in the parent context so they can write files into the workspace and report back.scripts/ file (Step 4) and reference it from the SKILL.md.If the successful workflow used a non-trivial script (more than a one-liner), write it as a sibling file under scripts/ of your draft skill directory. Use the already-validated code from the trajectory — do not invent variations. Strip incidental one-off inputs (literal file names, IDs, hard-coded outputs) and replace with arguments or stdin where appropriate.
Common shape:
.evolve/skills/<name>/
├── SKILL.md
└── scripts/
└── <action>.py # callable as `python3 scripts/<action>.py <args>`
If the workflow was a sequence of shell commands rather than a script, encode it as an executable shell script (scripts/<action>.sh) so future agents can invoke it as a single unit instead of replaying each command.
If no non-trivial script is needed (the workflow is a sequence of standard tool calls), skip this step — the SKILL.md alone is the skill.
Place your draft files (SKILL.md and any scripts) under a temporary directory inside the workspace, e.g. /tmp/synthesized-<name>/, then call:
python3 ${CLAUDE_PLUGIN_ROOT}/skills/evolve-lite/synthesize-skill/scripts/synthesize.py \
finalize \
--src /tmp/synthesized-<name>/ \
--name <kebab-case-name> \
--trajectory <saved_trajectory_path>
The script will:
name and description required; name must match --name)..evolve/skills/ (overwriting requires --force)..evolve/skills/<name>/ (canonical), then mirror it into .claude/skills/<name>/ so Claude Code's skill loader sees it.synthesize_skill event to .evolve/audit.log recording the new skill, the source trajectory, and the timestamp.If the validator rejects the draft, fix the SKILL.md and retry — do not edit files under .evolve/skills/ or .claude/skills/ directly.
After the script returns, list the destination directories with the Glob tool to confirm the files landed. Output a short summary:
--trajectory flag so the audit log records provenance; future maintainers can trace the skill back to the session that produced it.learn skill's guideline path instead.What SKILL.md sets; muted values are Claude Code's defaults
npx claudepluginhub agenttoolkit/altk-evolve --plugin evolve-lite12 skills in this plugin
/adapt-memoryMirror a just-saved native memory into the shared evolve store so it becomes shareable and auditable/doctorDiagnose evolve health on Claude — verify the CLAUDE.md @import is actually loading the thin EVOLVE.md into sessions/provenanceAnalyze saved trajectories and recall audit events offline to record whether recalled guidelines influenced completed sessions./publishPublish a private entity (guideline, feedback, project or reference) to a configured write-scope repo./retentionApply data-retention rules to the local evolve store — flag or delete stale and unused memories and expired sessions (dry-run by default)/saveCaptures the current session's successful workflow and saves it as a reusable skill with SKILL.md and helper scriptsOther plugins' skills for the same job