create-mod
Fungsinya
Skill ini menyiapkan mod Claude Code baru dari templat standar, dengan aturan penamaan dan status yang sudah diterapkan. Skill ini cocok untuk developer yang ingin memperluas cara Claude Code berperilaku dengan cara yang aman dan konsisten.
Kapan dipakai
- βSaat Anda ingin mod baru yang menambahkan panel, perintah, atau hook ke Claude Code.
- βSaat Anda ingin menambahkan hook fungsi ke perilaku Claude Code.
- βSaat Anda ingin mod yang mengikuti aturan yang sama dengan templat Ruflo yang sudah ditinjau.
Link skill
https://github.com/ruvnet/ruflo/blob/main/plugins/ruflo-plugin-creator/skills/create-mod/SKILL.mdSalin lalu tempelkan ke AI Anda (Claude, ChatGPT, atau Cursor) dan minta AI mengikuti instruksinya.
Cara pakai
Cara paling mudah: salin pesan ini dan tempelkan ke AI Anda. AI akan membaca skill dan mengikuti instruksinya.
Pesan siap tempel
Untuk Claude Code, Codex, atau Cursor: jalankan di folder proyek, lalu skill langsung terpasang.
Unduh SKILL.md lalu taruh di folder skill agen Anda.
Contoh permintaan ke AI
βBuat mod baru bernama focus-timer dari templat dan periksa bahwa itu valid.β
5 skill baru setiap minggu. 1 menit baca.
Cara kerjanya
Skill memilih nama dengan format kebab-case, menyalin folder templat ke lokasi target, dan mengganti nama placeholder dengan nama Anda. Skill kemudian menjaga file status tetap dalam format yang diharapkan dan menjalankan pemeriksaan.
Konten teknis (SKILL.md asli)
Teks asli dari pembuat, dalam bahasa Inggris, langsung dari GitHub.
Create Mod
Scaffold a mod the governed way, instead of an ad-hoc one: the template already follows the rules ruflo's own mod (ADR-404) was reviewed against.
Steps
- Name it. kebab-case
<name>. Commands it registers are namespaced<name>-<verb>; never register a built-in's name (/diff,/help) or another plugin's (/ruos*,ruflo-*). - Scaffold from the template with
node plugins/ruflo-plugin-creator/scripts/scaffold-mod.mjs <name> <target-dir>. It copiestemplates/mod/, turns the manifest templateplugin.json.tmplinto.claude-plugin/plugin.json(the template keeps it under a non-manifest name so plugin validators do not mistaketemplates/modfor a second plugin), and replacesmy-modeverywhere (plugin.jsonname, the command,MY_MOD_ACTIVEβ<NAME>_ACTIVEin bothhooks/register.tsandhooks/classic.cjs, the status folder). Doing it by hand: copy the folder, moveplugin.json.tmplto.claude-plugin/plugin.json, and make the same replacements. - Keep the status contract.
hooks/status.tswrites.claude-flow/<name>-mod/status.json, the file the console's Mods section reads. The folder must be<name>-mod(lowercase, digits, hyphens, at most 41 characters): the scaffold script already setsSTATUS_PATHto<name>-mod. Fields:version: 1(required, anything else is ignored),summary(one line),modVersion,guard(boolean),calls(a number, not a per-tool object),blocked(number),lastDenied(a short reason, only once the mod has refused something), plusupdatedMs/startedMs. Other fields are not shown.tests/status.test.tsasserts the shape. - Write the behaviour in pure functions taking the
Host(seehooks/host.ts). Inregister.ts, build the host from literal$.noun.method(...)calls only β the engine reads a module's$uses off its source, andclaude plugin validaterefuses$passed around, computed ($[noun]), or deeper than$.noun.method(input). - Keep the rules:
- Observe with
const r = await next(e); β¦; return r; rewrite withnext({ ...e, β¦ }); answer ({ deny }) only when you mean to stop the chain. - On
tool.check, only ever tighten (the stricter ofawait next(e)and yours); never answerallowof your own. - Wrap every
$call so a refusal degrades instead of failing the turn (admins can withhold any$affordance). - No
$.process.run/$.http.fetchbuilt from event input. Nothing slow on the hot path (about 10 s per dispatch). - Anything that must survive a hot reload goes in
$.store/$.state, not module variables. - Options come from
userConfigin plugin.json, not environment variables.
- Observe with
- Keep the fallback honest.
hooks.jsonis hybrid: the classic command hook runs everywhere, the module only where function hooks are on (Claude Code >= 2.1.287; 2.1.277+ withCLAUDE_CODE_ENABLE_FUNCTION_HOOKS=1). The module sets<NAME>_ACTIVEatsession.start; the classic script exits early when it sees it, so nothing fires twice. - Validate and test:
claude plugin validate <dir> # lists hooked events, $ calls, env reads/writes claude plugin test <dir> # tests/*.test.ts on the engine kit claude -p --plugin-dir <dir> "/<name>-status" # writes .claude-plugin/types/ and proves a live load npx tsc -p <dir> # against those generated types - Ship it in a plugin marketplace (
marketplace.jsonentry), installed with/plugin install <name>@<marketplace>and picked up with/reload-plugins. If ruflo-mods is installed withmodTrust: refuse-risky, a mod usingprocess.run/process.spawn,http.fetch,mcp.call/mcp.connect,session.send,config.set,env.set,fs.write,agent.spawn/agent.register,prompt.submit,session.append,tool.callorcommand.run, or hooking any event in itsRISKY_EVENTS(tool.check,tool.call,prompt.*,agent.spawn,tool.describe,session.append,session.receive,turn.step,skill.prompt,session.compact,prompt.edit,fs.read/fs.stat/fs.exists/fs.list,settings.read,env.get, a hook on any of the calls above (it can rewrite another mod's call),plugin.register,classic.*,*; a glob or a!negation is judged by what it selects), is refused unless its plugin id (<name>@<marketplace>) is inmodTrustAllowβ the template setsenv.set(the fallback handshake), so allow-list it by id.
Pertanyaan umum
Nama apa yang harus saya hindari?
Jangan memakai ulang nama perintah bawaan seperti diff atau help, atau nama yang dipakai plugin lain.
Di mana file status ditulis?
Skill menetapkannya ke folder yang dinamai sesuai mod Anda, yang dibaca oleh konsol.
Apakah templat menjalankan kode yang belum ditinjau?
Skill menyatakan templat mengikuti aturan yang sudah ditinjau, tetapi Anda tetap perlu menguji mod sebelum memakainya.
Detail
Deskripsi asli dari pembuat
Scaffold a Claude Code mod (a plugin with a function-hooks module) from ruflo's governed template, then validate and test it. Use when the user asks for a mod, a function hook, or wants Claude Code to modify itself.
repo: ruvnet/ruflo
Popularitas
- Bintang GitHub
- 81k
- Peringkat
- #1678
- Lisensi
- MIT
- Diperbarui
- 2/11/2026
Komentar
- β¦
Skill lain dari repositori ini
agent-adaptive-coordinator
81kMembantu agent Anda membagi dan menyeimbangkan kembali sekelompok agent AI saat beban kerja berubah, dengan memilih tata letak yang sesuai tugas.
agent-agent
81kMengajari agent Anda mengubah tujuan besar menjadi rencana tindakan yang berurutan, dan menyusun ulang rencana saat kondisi berubah.
agent-agentic-payments
81kMembantu agent Anda mengelola mandat belanja untuk belanja AI, dengan batas pengeluaran, jendela waktu, aturan merchant, dan persetujuan yang ditandatangani.
agent-analyze-code-quality
81kMembantu agent Anda meninjau kualitas kode, menemukan bau kode, utang teknis, dan ide refaktor tanpa mengubah berkas.
Skill serupa
diffs
394kMemungkinkan agent Anda menghasilkan diff perubahan yang nyata dan dapat dibagikan sebagai tautan viewer atau file gambar, bukan ringkasan yang ditulis manual.
coding-agent
394kMembantu agent Anda menyerahkan pekerjaan pemrograman besar ke Codex, Claude Code, atau OpenCode di latar belakang, lalu memeriksa kemajuannya.
gh-issues
394kMembantu agent Anda menemukan issue GitHub, memilih yang dikerjakan, dan membuka pull request perbaikan, termasuk tindak lanjut komentar tinjauan.