agentleFS
VoTruongDanhVoTruongDanh/Skills-Agent/.claude/skills/integrate/SKILL.md

integrate

Skill4 starsChanged 33 days agoMITView on GitHub

Integrate provided sample code/snippets into the existing system with minimal changes and minimal risk. Use when the user gives a code mẫu and wants to merge it into current project. Triggers: integrate, merge snippet, gộp code mẫu, ghép code, áp code mẫu vào hệ thống.

We split this skill into the rules it gives an agent

13 rules. 0 are common, 9 are distinctive, and 4 are very specific to this project.

  • 0

    Common

    Most of the 10 edited versions we read keep these.

  • 9

    Distinctive

    This author's own choices. Worth a look.

  • 4

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    START: Read .ai-memory.md from project root.

    line 10
  2. Very specific:

    END: Update .ai-memory.md using Memory Compaction Rules with: integration points, files touched, behavior changes (if any), and …

    line 11
  3. Distinctive:

    Before editing, verify these inputs exist.

    line 17
  4. Distinctive:

    Do not reformat or restructure unrelated code.

    line 27
  5. Distinctive:

    Prefer adapters/wrappers over rewriting existing modules.

    line 28
  6. Distinctive:

    If the integration requires changing shared interfaces, introduce compatibility shims (or feature flag) instead of breaking changes.

    line 29
  7. Distinctive:

    If uncertain about side effects, stop and ask rather than guessing.

    line 30
  8. Distinctive:

    Prefer adding a thin adapter layer rather than changing existing call sites.

    line 37
  9. Distinctive:

    Prefer dependency injection/config wiring over global edits.

    line 38
  10. Very specific:

    Add new file(s) when that reduces risk (e.g., adapter/, integrations/).

    line 40
  11. Distinctive:

    Run/adjust existing tests if present.

    line 43
  12. Distinctive:

    Ensure no unrelated behavior changes.

    line 44
  13. Very specific:

    All code snippets and example files referenced or produced by this skill must be UTF-8 encoded.

    line 56

“Common” is measured: kept by at least 6 in 10 of the 10 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Memory Protocol

START: Read .ai-memory.md from project root. Focus on: entry points, key directories, conventions, and any integration decisions already logged. END: Update .ai-memory.md using Memory Compaction Rules with: integration points, files touched, behavior changes (if any), and verification notes.

Goal

Merge the requested sample code into the current codebase without broad refactors, keeping behavior stable and avoiding changes to unrelated files.

Socratic Gate (ask if missing)

Before editing, verify these inputs exist. If any is missing or ambiguous, ASK:

  1. The sample code to integrate (full snippet + expected behavior).
  2. The target location in this project (file/module/feature area).
  3. Constraints: must keep API stable? must keep UI stable? backward compatible?
  • Clean code chuẩn (Standard clean code applied)
  • Cập nhật đầy đủ tất cả các file liên quan (All related files fully updated)

Rules (Blast-radius control)

  • Touch the smallest possible set of files.
  • Do not reformat or restructure unrelated code.
  • Prefer adapters/wrappers over rewriting existing modules.
  • If the integration requires changing shared interfaces, introduce compatibility shims (or feature flag) instead of breaking changes.
  • If uncertain about side effects, stop and ask rather than guessing.

Workflow

  1. Read Memory — Load .ai-memory.md for architecture + conventions.
  2. Locate Integration Point — Identify the narrowest place to hook in (entry, router, service, component, util).
  3. Diff the Concepts — Map sample code concepts → existing abstractions (types, services, routes, state).
  4. Design Minimal Bridge:
    • Prefer adding a thin adapter layer rather than changing existing call sites.
    • Prefer dependency injection/config wiring over global edits.
  5. Implement in Small Steps:
    • Add new file(s) when that reduces risk (e.g., adapter/, integrations/).
    • Modify existing files only where the integration connects.
  6. Verification:
    • Run/adjust existing tests if present; otherwise add a minimal smoke test when feasible.
    • Ensure no unrelated behavior changes.
  7. Quality Gate — Read .kiro/skills/_scripts/checklist.md.
  8. Update Memory — Log only high-signal bullets (integration point, key decision, files touched, outcome).

Output Format

  • Integration target (what feature/module)
  • Files touched (added/modified)
  • Minimal change strategy (1–3 bullets)
  • Verification performed (commands/tests)
  • Risks / follow-ups (if any)

Encoding

All code snippets and example files referenced or produced by this skill must be UTF-8 encoded. When applicable, include encoding: "UTF-8" in SKILL.md front-matter and ensure saved files use UTF-8 (no BOM).

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.