Commit graph

3 commits

Author SHA1 Message Date
wangzhuc
344f7509f1 feat: structured edit learning with typed patterns and confidence scoring
learn_edits.py: patterns now have type/key/description/rule fields,
confidence auto-computed from occurrences + recency with 30-day decay.
--summarize --json outputs aggregated patterns sorted by confidence.

learn-edits.md: playbook.md format changed from free text to structured
YAML rules with confidence levels. Rules with confidence ≥ 5 become
hard constraints in Step 4, < 5 are soft references, < 2 get pruned.

SKILL.md Step 4: playbook priority now confidence-gated.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-30 20:23:34 +08:00
wangzhuc
5cb1f99ecf 修复首次使用者模拟发现的 5 个卡点
#1: {skill_dir} 显式定义(24处引用,从未声明)
#2: 行为声明新增"Onboard 例外"(交互式不受全自动约束)
#4: WebSearch 不可用时告知用户 AI 检测通过率会降低
#5: Step 8a history.yaml 不存在则创建
#7: learn-edits.md 引导用户从微信编辑器粘贴 final 版本

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-29 01:14:19 +08:00
wangzhuc
78e8fd666e SKILL.md 结构重构:571行→273行,学习 gstack 模式
拆分:
- Onboard → references/onboard.md
- 学习飞轮 → references/learn-edits.md
- 效果复盘 → references/effect-review.md
SKILL.md 只保留主管道(写文章)+ 错误处理。

重编号:
- 去掉 0, 2.5, 3.5, 3.75, 7.5 等补丁式编号
- Step 1-8 连续编号,子步骤用 a/b/c

新增行为声明区(学习 gstack preamble 模式):
- 角色、模式、降级原则一次性声明
- 完成协议:DONE / DONE_WITH_CONCERNS / BLOCKED / NEEDS_CONTEXT
- 辅助功能用 读取: references/xxx.md 按需加载
- frontmatter 新增 allowed-tools

结构:11 个 section header(原 34 个),Agent 认知负荷大幅降低。

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-29 00:01:04 +08:00