skill-optimizer
Skill này làm gì
Công cụ này phân tích cách các “skill” (hướng dẫn cho AI) của bạn hoạt động dựa trên các cuộc trò chuyện trước đó. Nó kiểm tra xem skill có được kích hoạt đúng không và có giúp AI làm đúng điều bạn muốn không.
Khi nào nên dùng
- ✓Khi một skill có vẻ không hoạt động như mong đợi.
- ✓Khi bạn muốn nâng cao chất lượng các skill của mình.
- ✓Khi bạn muốn biết skill nào ít được dùng hoặc đang lãng phí tài nguyên AI không cần thiết.
Liên kết skill
https://github.com/sickn33/agentic-awesome-skills/blob/main/skills/skill-optimizer/SKILL.mdSao chép rồi dán vào AI của bạn (Claude, ChatGPT hoặc Cursor) và nhờ nó làm theo hướng dẫn.
Cách dùng
Cách dễ nhất: sao chép tin nhắn và dán vào AI của bạn. AI sẽ đọc skill và làm theo hướng dẫn.
Tin nhắn có sẵn để dán
Dành cho Claude Code, Codex hoặc Cursor: chạy lệnh trong thư mục dự án của bạn và skill sẽ được cài đặt.
Tải tệp SKILL.md về và thả vào thư mục skill của agent.
Ví dụ cách nhờ AI
“Phân tích các skill của tôi và cho biết cái nào cần cải thiện.”
5 skill mới mỗi tuần. Đọc chỉ 1 phút.
Cách hoạt động
Công cụ đọc các file skill của bạn và dữ liệu từ các cuộc trò chuyện trước. Nó so sánh điều lẽ ra phải xảy ra với điều thực sự đã xảy ra để tìm vấn đề và đề xuất cải thiện.
Nội dung kỹ thuật (SKILL.md gốc)
Lấy nguyên văn từ GitHub, do tác giả viết bằng tiếng Anh.
When to Use This Skill
- Use when skills are not triggering as expected or seem broken
- Use when you want to audit and improve your skill library's quality
- Use when you want to understand which skills are underperforming or wasting context tokens
Rules
- Read-only: never modify skill files. Only output report.
- All 8 dimensions: do not skip any. If data is insufficient, report "N/A — insufficient session data" rather than omitting.
- Quantify: "you had 12 research tasks last week but the skill never triggered" beats "you often do research".
- Suggest, don't prescribe: give specific wording suggestions for description improvements, but frame as suggestions.
- Show evidence: for undertrigger claims, quote the actual user message that should have triggered the skill.
- Evidence-based suggestions: when suggesting description rewrites, cite the specific research finding that motivates the change (e.g., "front-load trigger keywords — MCP study shows 3.6x selection rate improvement").
Overview
Analyze skills using historical session data + static quality checks, output a diagnostic report with P0/P1/P2 prioritized fixes. Scores each skill on a 5-point composite scale across 8 dimensions.
CSO (Claude/Agent Search Optimization) = writing skill descriptions so agents select the right skill at the right time. This skill checks for CSO violations.
Usage
/optimize-skill→ scan all skills/optimize-skill my-skill→ single skill/optimize-skill skill-a skill-b→ multiple specified skills
Data Sources
Auto-detect the current agent platform and scan the corresponding paths:
| Source | Claude Code | Codex | Shared |
|---|---|---|---|
| Session transcripts | ~/.claude/projects/**/*.jsonl |
~/.codex/sessions/**/*.jsonl |
— |
| Skill files | ~/.claude/skills/*/SKILL.md |
~/.codex/skills/*/SKILL.md |
~/.agents/skills/*/SKILL.md |
Platform detection: Check which directories exist. Scan all available sources — a user may have both Claude Code and Codex installed.
Workflow
Identify target skills
↓
Collect session data (python3 scripts scan JSONL transcripts)
↓
Run 8 analysis dimensions
↓
Compute composite scores
↓
Output report with P0/P1/P2
Step 1: Identify Target Skills
Scan skill directories in order: ~/.claude/skills/, ~/.codex/skills/, ~/.agents/skills/. Deduplicate by skill name (same name in multiple locations = same skill). For each, read SKILL.md and extract:
- name, description (from YAML frontmatter)
- trigger keywords (from description field)
- defined workflow steps (Step 1/2/3... or ### sections under Workflow)
- word count
If user specified skill names, filter to only those.
Step 2: Collect Session Data
Use python3 scripts via Bash to scan session JSONL files. Extract:
Claude Code sessions (~/.claude/projects/**/*.jsonl):
Skilltool_use calls (which skills were invoked)- User messages (full text)
- Assistant messages after skill invocation (for workflow tracking)
- User messages after skill invocation (for reaction analysis)
Codex sessions (~/.codex/sessions/**/*.jsonl):
session_metaevents → extractbase_instructionsfor skill loading evidenceresponse_itemevents → assistant outputs (workflow tracking)event_msgevents → tool execution and skill-related events- User messages from
turn_contextevents (for reaction analysis)
Note: Codex injects skills via context rather than explicit Skill tool calls. Skill loading (present in base_instructions) does NOT equal active invocation. To detect actual use, search for skill-specific workflow markers (step headers, output formats) in response_item content within that session. A skill is "invoked" only if the agent produced output following the skill's defined workflow.
Aggregated:
- Per-skill: invocation count, trigger keyword match count
- Per-skill: user reaction sentiment after invocation
- Per-skill: workflow step completion markers
Step 3: Run 8 Analysis Dimensions
You MUST run ALL 8 dimensions. The baseline behavior without this skill is to skip dimensions 4.2, 4.3, 4.5b, and 4.8. These are the most valuable dimensions — do not skip them.
4.1 Trigger Rate
Count how many times each skill was actually invoked vs how many times its trigger keywords appeared in user messages.
Claude Code: count Skill tool_use calls in transcripts.
…
Câu hỏi thường gặp
Công cụ có thay đổi các skill của tôi không?
Không, nó chỉ phân tích và đề xuất cải thiện. Nó không sửa đổi các file skill của bạn.
“Dimensions” là gì?
Đây là các khía cạnh khác nhau mà công cụ phân tích để đánh giá chất lượng một skill, chẳng hạn tần suất sử dụng và việc người dùng có hài lòng với kết quả hay không.
“CSO” nghĩa là gì?
CSO là viết tắt của Claude/Agent Search Optimization. Đây là việc viết mô tả skill sao cho AI chọn đúng skill vào đúng thời điểm.
Chi tiết
Mô tả gốc của tác giả
Diagnose and optimize Agent Skills (SKILL.md) with real session data and research-backed static analysis. Works with Claude Code, Codex, and any Agent Skills-compatible agent.
Độ phổ biến
- Sao GitHub
- 48k
- Vị trí xếp hạng
- #6298
- Giấy phép
- MIT
- Cập nhật
- 15/10/2026
Bình luận
- …
Thêm skill từ kho mã này
00-andruia-consultant
48kGiúp agent của bạn bắt đầu hoặc cải thiện các dự án AI. Phân tích mã, gợi ý công cụ và lập kế hoạch hành động bằng tiếng Tây Ban Nha.
007
48kCho phép agent của bạn thực hiện kiểm toán bảo mật và mô hình hóa mối đe dọa. Hữu ích để bảo vệ dự án khỏi các cuộc tấn công và lỗ hổng.
10-andruia-skill-smith
48kGiúp agent của bạn tạo hoặc cải thiện các công cụ AI. Xác định cách công cụ hoạt động, viết tài liệu và kiểm tra cấu trúc.
20-andruia-niche-intelligence
48kGiúp agent của bạn tạo bản tóm tắt về một ngành cụ thể. Hữu ích để hiểu bối cảnh, quy tắc, cách người dùng tương tác và rủi ro của dự án.
Skill tương tự
test-driven-development
311kDạy agent của bạn viết kiểm thử thất bại trước, xem nó thất bại, rồi viết đoạn mã ngắn nhất để vượt qua trước khi làm bất kỳ tính năng hay bản sửa nào.
verification-before-completion
311kDạy agent của bạn chạy kiểm tra thực tế và đọc kết quả đầu ra trước khi khẳng định một việc, bản sửa hoặc bản build đã hoàn thành hay vượt qua.
migrate-to-shoehorn
310kThay các ép kiểu rủi ro trong tệp kiểm thử bằng thư viện shoehorn, để các bài kiểm thử dùng dữ liệu một phần vẫn qua được kiểm tra kiểu.