| name | template-extract |
| description | Use when: extracting domain-specific page scenarios from existing project pages into wl-scenario JSON templates (with Page Blueprint low-token retrieval as the discovery front-end). Triggers on: 提取模板, 抽取模板, 沉淀模板, 模板贡献, 提取场景, extract template, extract scenario. |
Skill: 模板提取(template-extract)
从现有项目的成熟页面提取领域场景,沉淀为 wl-scenario JSON 场景模板
(.wl-skills/templates/scenarios/<域>/),让后续同类页面直接
wl-skills scenario render 确定性生成,AI 零自由度。
两阶段流水线:
① 检索发现(低 token):wl-skills snapshot 项目摘要 + wl-skills template search
蓝图相似检索(Page Blueprint,不含业务代码的结构事实),用于判断"是否已有可复用场景";
② 沉淀落盘(确定性):wl-skills scenario extract 产出 wl-scenario JSON。
Blueprint 负责"找得像",Scenario 负责"还原得出来"——蓝图检索命中后,仍以 scenario JSON 为准落盘。
触发词
提取模板 / 抽取模板 / 沉淀模板 / 模板贡献 / 提取场景 / extract template
Pre-flight 声明
🚀 已触发技能 template-extract/SKILL.md → 从现有页面提取场景模板
✅ 已读取 template-extract/SKILL.md → 提取流程主规则
✅ 已读取 templates/patterns.json → 模式注册表(避免重复登记 pattern)
✅ 已读取 templates/scenarios/README.md → 场景库结构与往返保证
✅ 已读取 standards/02-code-structure.md → 提取产物必须遵循的代码结构
✅ 已读取 standards/13-platform-components.md → 平台组件合规
执行流程
步骤 1:开发者指定目标
"提取模板,目标页:src/views/produce/sjgl/mmwr-rolling-management/"
步骤 2:低 token 检索(Blueprint 前置)
wl-skills snapshot
wl-skills template search --query "工位 实绩"