From skills-lab
Transplant a skill, command, or capability from one agentic-system repo into another via a 5-phase gated protocol (inventory → import → localize → wire → verify). Use when grafting a feature from an upstream repo that has its own dependencies, platform assumptions, or upstream-specific file references that need adapting before the feature will work in the destination repo. Not for copying a self-contained file — use only when the feature has a dependency footprint and the destination repo has its own conventions the import must respect.
How this skill is triggered — by the user, by Claude, or both
Slash command
/skills-lab:skill-transplantThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
Transplant a feature — a skill, command, sub-system, or capability — from a source agentic-system repo into a destination repo. The protocol treats the import like an organ transplant: identify the organ (in-scope files) and its vessels (dependencies), check compatibility with the host (destination repo conventions and platform), localize to prevent rejection (dead references, platform paths, l...
Transplant a feature — a skill, command, sub-system, or capability — from a source agentic-system repo into a destination repo. The protocol treats the import like an organ transplant: identify the organ (in-scope files) and its vessels (dependencies), check compatibility with the host (destination repo conventions and platform), localize to prevent rejection (dead references, platform paths, language, optional branches), and verify the transplant is working before closing up.
Execute in 5 strict phases. Do not skip, merge, or reorder.
═══════════════════════════════════════════════════════════════ PHASE 1 — INVENTORY (read-only, no file writes yet) ═══════════════════════════════════════════════════════════════
For the source repo:
__dirname,
import.meta.url, __file__, or similar to resolve adjacent
assets (fonts, templates, configs). These CANNOT be relocated
without code patches./tmp/, /usr/,
~/.config/), shell commands (file, which), or OS-specific
APIs that may not exist on the destination platform.For the destination repo: 10. List what already exists that the feature will depend on: invocation pattern (one-skill-per-slash? sub-commands?), available tools/MCP servers, shell utilities, platform (OS, shell, Node/Python version), existing data sources that could replace upstream input sources.
Deliverable: a structured report with: - In-scope files (grouped by role) - Out-of-scope (with one-line reason each) - Runtime deps (minimal set) - Entry-point signature - Data contract (input source + output shape) - Position-locked assets - Platform gotchas - Optional branches (each with cost/reliability verdict) - Localization surface - Destination-repo compatibility check - Recommended default path (if multiple) - License considerations
STOP and wait for approval before any writes.
═══════════════════════════════════════════════════════════════ PHASE 2 — IMPORT (raw copy, no edits) ═══════════════════════════════════════════════════════════════
npx playwright install chromium).═══════════════════════════════════════════════════════════════ PHASE 2.5 — LOCALIZE (adapt to destination) ═══════════════════════════════════════════════════════════════
cv.md, config/profile.yml, upstream dashboards).
Replace each with the destination equivalent OR with an
instruction to prompt the user inline./tmp/ → output/ or
os.tmpdir()). Verify the substitution works on the
destination's actual platform.cv.md), rewrite the data-ingestion step to use it.═══════════════════════════════════════════════════════════════ PHASE 3 — WIRE (additive only, no refactors) ═══════════════════════════════════════════════════════════════
═══════════════════════════════════════════════════════════════ PHASE 4 — VERIFY & REPORT ═══════════════════════════════════════════════════════════════
git pull of upstream harder)═══════════════════════════════════════════════════════════════ CONSTRAINTS (apply to all phases) ═══════════════════════════════════════════════════════════════
═══════════════════════════════════════════════════════════════ WORKED EXAMPLE — PDF generation transplant ═══════════════════════════════════════════════════════════════
Scenario: transplant PDF generation (Playwright + headless Chromium,
markdown-to-PDF) from github.com/santifer/career-ops into a
personal job-search-os repo, wired to the resume-tailor skill.
Phase 1 findings (condensed):
scripts/render-pdf.js, templates/resume.html,
styles/print.css.cv.md (upstream-only input source — replaced in
2.5), entire Canva integration branch (no Canva API configured
in destination), upstream dashboard configs.playwright only. Post-install: npx playwright install chromium.node render-pdf.js <input.md> <output.pdf>.templates/ and styles/ must sit adjacent
to render-pdf.js (resolved via __dirname)./tmp/resume.pdf — needs
remap for Windows destination.Phase 2 actions: copied 3 files into
skills/generate-pdf/{render-pdf.js, templates/, styles/}.
Added playwright to package.json. Ran chromium post-install.
Smoke test: node render-pdf.js sample.md sample.pdf → passed.
Phase 2.5 actions:
cv.md read with a parameter: skill accepts markdown
string directly from resume-tailor output (no file read)./tmp/resume.pdf → output/resume.pdf
(portable on Windows/Mac/Linux).career-ops:pdf to /generate-pdf.Phase 3 actions: added a final step to /resume-tailor that pipes
its markdown output into /generate-pdf. No refactor of existing
resume-tailor logic.
Phase 4 report:
skills/generate-pdf/.skills/resume-tailor/SKILL.md, added final
PDF step — 8 lines).git pull of upstream
won't merge cleanly because of cv.md replacement and Canva
removal. Document this in PROVENANCE.md.Provides behavioral guidelines to reduce common LLM coding mistakes, focusing on simplicity, surgical changes, assumption surfacing, and verifiable success criteria.
Searches, retrieves, and installs Agent Skills from prompts.chat registry using MCP tools like search_skills and get_skill. Activates for finding skills, browsing catalogs, or extending Claude.
Creates, edits, and optimizes skills for Claude Code, including drafting, evaluating with test prompts, iterating on performance, and improving skill descriptions for better triggering accuracy.
npx claudepluginhub sujinhwang27/agent-os-lab --plugin skills-lab