| name | hermes-curator |
| description | Background maintenance agent that prunes, consolidates, and refines agent-created skills to prevent bloat and reduce token waste. |
Hermes Curator: Background Maintenance Agent
This skill implements the Hermes Curator Pattern for autonomous maintenance of the agent's procedural memory (skills). It ensures that the skill library remains lean, accurate, and cost-effective by weeding out redundant or outdated instructions.
触发条件 (Triggers)
- เมื่อมีทักษะ (Skills) ในโฟลเดอร์
.agent/skills/ หรือ ~/.gemini/skills/ จำนวนมาก (แนะนำที่ 20+ ทักษะ)
- เมื่อผู้ใช้สั่ง "สะสางทักษะ", "จัดระเบียบสกิล", หรือ "hermes curator run"
- เมื่อพบทักษะที่ทำงานซ้ำซ้อนกันหรือล้าสมัย (Drift)
ขั้นตอนการทำงาน (Workflow)
1. สถานะและการตรวจสอบ (Discovery)
- ตรวจสอบโฟลเดอร์ทักษะที่เอเจนต์สร้างขึ้น (
agent_created)
- อ่าน Metadata (ถ้ามี) หรือประวัติการใช้งาน (Logs) เพื่อระบุความถี่และอายุของทักษะ
2. การจัดการวงจรชีวิต (Lifecycle Management)
- Active → Stale: หากทักษะไม่ได้ใช้งานเกิน 30 วัน ให้ย้ายไปตรวจสอบในขั้นตอน Consolidation
- Stale → Archived: หากไม่ได้ใช้งานเกิน 90 วัน ให้ย้ายไปที่โฟลเดอร์
.archive/ (ห้ามลบทิ้งถาวร)
3. การรวมทักษะ (Consolidation Pass)
- ใช้โมเดลเสริม (Auxiliary Model) วิเคราะห์ทักษะที่ใกล้เคียงกัน
- Action: รวม (Merge) ทักษะย่อย ๆ ให้กลายเป็น "Master Skill" ที่ครอบคลุมกว่าเดิม เพื่อประหยัด Token และลดความสับสนของ Agent
4. การแก้ไขความคลาดเคลื่อน (Patching Drift)
- ตรวจสอบว่าคำแนะนำใน
SKILL.md ยังสอดคล้องกับสภาพแวดล้อมปัจจุบัน (เช่น เวอร์ชั่นของไลบรารีที่เปลี่ยนไป)
- Action: แก้ไข (Patch) เนื้อหาใน
SKILL.md ให้ทันสมัย
5. ความปลอดภัยและธรรมาภิบาล (Safety & Governance)
- Snapshots: สร้างสำเนาสำรอง (tar.gz) ของโฟลเดอร์ทักษะก่อนเริ่มดำเนินการเสมอ
- Pinning: ห้ามแตะต้องทักษะที่ถูกระบุว่า "pinned" หรือทักษะที่เป็น "Bundled/Official"
- Dry Run: แสดงแผนการเปลี่ยนแปลงให้ผู้ใช้เห็นก่อนดำเนินการจริงเสมอ หากไม่ใช่การรันแบบอัตโนมัติ
คำสั่งการใช้งาน (Manual Commands)
hermes-curator status: สรุปจำนวนทักษะและสถานะความสดใหม่
hermes-curator run --dry-run: ตรวจสอบและเสนอแผนการสะสาง
hermes-curator pin <name>: ป้องกันไม่ให้ทักษะถูก Archive หรือแก้ไข
hermes-curator restore <name>: กู้คืนทักษะจาก Archive
มาตรฐานการจัดเก็บ (Storage Standards)
- Active:
.agent/skills/
- Archive:
.agent/skills/.archive/
- Logs:
.agent/skills/logs/curator_report.md