claude-code-custom-skill-development
在Claude Code中开发自定义skill的完整指南。包括项目结构、配置方法、定时任务集成、MCP工具调用等。 适用于需要创建自动化工作流、定期任务、工具集成等场景。
Codex または Claude でインストール この Prompt をコピーして Codex、Claude、または他のアシスタントに貼り付けると、Skill ページを確認してインストールできます。
メニュー
在Claude Code中开发自定义skill的完整指南。包括项目结构、配置方法、定时任务集成、MCP工具调用等。 适用于需要创建自动化工作流、定期任务、工具集成等场景。
Codex または Claude でインストール この Prompt をコピーして Codex、Claude、または他のアシスタントに貼り付けると、Skill ページを確認してインストールできます。
SOC 職業分類に基づく
Capture a multi-step workflow into a timestamped pipeline memory after trial-and-error sessions. The core output is: (1) the final working commands saved as executable scripts (not bare shell commands), and (2) a structured markdown document separating the clean reproducible pipeline from the detours and pitfalls. Timestamped snapshots live in pipeline_memory/; mature pipelines can be promoted to PIPELINE.md and auto-loaded. Fully environment-agnostic — works for any project, any toolset, any domain. Use when the user finishes a multi-step task, says "保存工作流记忆", "save pipeline memory", "记录一下当前进展", or "/save-pipeline-memory". Takes an optional folder path.
Run Claude Code commands (including /insights, /doctor, custom prompts) via system crontab in non-interactive mode. Use when: (1) setting up daily/weekly automated Claude Code tasks, (2) scheduling reports or analysis via cron, (3) running Claude Code with third-party API backends (DeepSeek, Qwen, etc.) in headless environments, (4) "set up a daily report", "automate this in cron", "schedule insights". Covers: cron PATH setup, third-party API env vars for non-interactive mode, nvm/node auto-discovery, and wechat-reminder integration for notification delivery.
Use when the user wants to *learn* or *understand* a technical concept (an algorithm, a math derivation, an ML architecture, a systems internal) rather than just get a one-shot answer — triggers include "explain X", "teach me X", "help me understand X", or being stuck on a concept while reading a paper or code. Probe the user's level with a few questions FIRST, then teach interactively through a runnable Jupyter notebook with LaTeX derivations and small experiments.
Claudeception is a continuous learning system that extracts reusable knowledge from work sessions. Triggers: (1) /claudeception command to review session learnings, (2) "save this as a skill" or "extract a skill from this", (3) "what did we learn?", (4) After any task involving non-obvious debugging, workarounds, or trial-and-error discovery. Creates new Claude Code skills when valuable, reusable knowledge is identified.
Record a debugging session's findings into a timestamped markdown file under debug_experience/. Captures problem, root cause, solution, and key learnings in a structured, reusable format. Use when: you've just resolved a non-obvious bug, found an undocumented edge case, encountered an issue that took multiple attempts to fix, or when you say things like "保存调试经验", "save debug experience", "记录这次调试", "/save-debug-experience". Takes an optional folder path as argument.
MCP Notion工具使用指南,包含常见问题解决方案和最佳实践。使用当: (1) 访问Notion数据库view URL出现"URL type view not currently supported"错误, (2) 需要获取数据库schema和表结构信息, (3) 查询数据库中的条目内容, (4) 创建页面时MULTI_SELECT字段值不存在导致失败, (5) 需要更新数据库schema添加新选项, (6) 开发需要集成Notion数据的自动化工作流, (7) query_data_sources/query-database-view返回Business Plan要求错误, (8) 需要在无Business Plan的情况下枚举数据库所有条目。
| name | claude-code-custom-skill-development |
| description | 在Claude Code中开发自定义skill的完整指南。包括项目结构、配置方法、定时任务集成、MCP工具调用等。 适用于需要创建自动化工作流、定期任务、工具集成等场景。 |
| author | Claude Code |
| version | 1.0.0 |
| date | "2026-04-22T00:00:00.000Z" |
Claude Code的技能系统非常强大,但缺乏系统的开发指南,开发者在创建自定义技能时经常遇到:
/[skill-name]这种命令格式想知道如何创建每个技能放在独立的目录中,结构如下:
skill-name/
├── SKILL.md # 技能定义文件(必填)
├── run.sh # 主执行脚本(可选,也可以是Python等其他语言)
├── scripts/ # 辅助脚本目录(可选)
└── assets/ # 资源文件目录(可选)
---
name: skill-name-in-kebab-case
description: |
详细描述技能的用途、触发条件、解决的问题。要足够具体,方便语义匹配。
例如:"每日从Notion数据库随机选择研究者,总结后发送到飞书webhook"
author: 作者名
version: 1.0.0
date: YYYY-MM-DD
---
# 技能名称
## Problem
解决的问题描述
## Context / Trigger Conditions
使用场景和触发条件
## Solution
使用方法和实现逻辑
## Verification
验证方式
## Example
示例
## Notes
注意事项
.claude/skills/下,只在当前项目可用~/.claude/skills/下,所有项目都可以使用使用Claude Code内置的Cron工具设置定期执行:
# 添加定时任务,每天上午9点执行
/cron add "0 9 * * *" "/skill-command"
# 查看所有定时任务
/cron list
# 删除定时任务
/cron delete <job-id>
在技能中可以直接使用已配置的MCP工具,例如Notion:
# 在Python中调用MCP Notion工具
import subprocess
import json
def fetch_notion_page(page_id):
result = subprocess.run([
"mcp", "notion", "fetch",
"--id", page_id
], capture_output=True, text=True)
return json.loads(result.stdout)
直接使用curl或HTTP客户端调用外部API,例如飞书webhook:
# 发送飞书消息
curl -X POST \
-H "Content-Type: application/json" \
-d "$MESSAGE_BODY" \
"$FEISHU_WEBHOOK_URL"
/[skill-name]可以触发执行/cron list中看到.claude/skills/daily-cs-spotlight//cron add "0 9 * * *" "/daily-cs-spotlight"durable: true参数make notify、make setup-cron等