跳到正文
Skillpedia
连接器(MCP)15k · #11042

ai-memory-routing-install

它能做什么

该技能设置把 AI 工具与 ai-memory 连接起来的指令块和技能文件。适合希望智能体正确使用记忆工具的人。

适用场景

  • ✓当你希望在智能体设置中安装 ai-memory 路由指令的时候。
  • ✓当 ai-memory 指令或技能需要修复或刷新的时候。
  • ✓当你希望删除 ai-memory 托管的指令或技能的时候。

技能链接

https://github.com/akitaonrails/ai-memory/blob/main/crates/ai-memory-core/src/routing_skills/ai-memory-routing-install/SKILL.md

复制后粘贴给你的 AI(Claude、ChatGPT 或 Cursor),让它按照说明操作。

使用方法

最简单的方法:复制下面的消息,粘贴给你的 AI。它会读取这个技能并按说明操作。

可直接粘贴的消息

请用这个技能帮我:https://github.com/akitaonrails/ai-memory/blob/main/crates/ai-memory-core/src/routing_skills/ai-memory-routing-install/SKILL.md 阅读该链接中的 SKILL.md 文件,并在我的任务中按照它的说明来做。
想让你的 AI 自己找到这样的技能吗?安装免费的 Skillpedia MCP:只需一行,每次任务前它都会在 15,000+ 个技能中搜索。1 分钟完成安装 →

可以这样问 AI

“请把 ai-memory 路由指令安装到我的 CLAUDE.md 中,并刷新这些技能。”

每周 5 个新技能,1 分钟读完。

工作原理

智能体会从 ai-memory 安装工具中获取标准的指令块和技能文件,然后把它们放在标记行之间。标记之外的内容保持不变。

技术内容(原始 SKILL.md)

作者在 GitHub 上的英文原文。

<!-- ai-memory-managed: routing-skill -->

ai-memory routing install

Use this skill when the user wants ai-memory's agent-facing routing instructions or managed Agent Skills installed, refreshed, repaired, or removed.

Tools in this cluster

  • memory_install_self_routing returns the canonical markered instruction block, marker strings, filename hints, notes, and managed skill payloads for agents that cannot let the MCP server write the host filesystem directly. Pass compact: true when managed Agent Skills are installed or when refreshing a file that already uses the compact snippet.

Managed instruction marker

The always-loaded instruction block is owned by ai-memory only between these markers.

  • Start marker: <!-- ai-memory:start -->
  • End marker: <!-- ai-memory:end -->

Refresh must replace the first complete marker-bounded block whose start and end delimiters appear alone on their own lines, preserving unrelated content before and after it. Ignore inline mentions of marker strings inside prose or code; they are not delimiters. If no complete line-delimited block exists, append the canonical block with one blank line of separation. Never edit unrelated instructions while refreshing ai-memory routing.

Managed skill marker

Every ai-memory-managed SKILL.md file contains this ownership marker.

<!-- ai-memory-managed: routing-skill -->

Installers and uninstallers should overwrite or remove same-name skill files only when that marker is present, unless the user supplied an explicit force option. If a same-name skill lacks the marker, skip it with an actionable message so user-authored skills are preserved.

Global Grok installs also write $GROK_HOME/rules/ai-memory-handoff.md (default ~/.grok/rules/ai-memory-handoff.md) with the ownership marker <!-- ai-memory-managed: grok-handoff-rule -->. Overwrite or uninstall that file only when the marker is present, unless the user supplied --force. Project-scope Grok skill installs leave that user rule alone.

Skill install targets

Managed skills are ordinary Agent Skills. Their relative file path is <skill>/SKILL.md, and the installer prepends the selected skill root.

Project-local targets:

  • .claude/skills/<skill>/SKILL.md for Claude-compatible installs.
  • .agents/skills/<skill>/SKILL.md for cross-client installs.
  • .grok/skills/<skill>/SKILL.md for Grok Build CLI installs.
  • .github/skills/<skill>/SKILL.md for GitHub Copilot CLI installs.

Global targets:

  • ~/.claude/skills/<skill>/SKILL.md for Claude-compatible installs.
  • ~/.agents/skills/<skill>/SKILL.md for cross-client installs.
  • $GROK_HOME/skills/<skill>/SKILL.md for Grok Build CLI installs (default: ~/.grok/skills/<skill>/SKILL.md).
  • $COPILOT_HOME/skills/<skill>/SKILL.md for GitHub Copilot CLI installs (default: ~/.copilot/skills/<skill>/SKILL.md).

Use platform-aware path joining. Do not build paths by string concatenation.

Refresh guidance

For an agent-side refresh, call the install-routing tool (pass compact: true if the target file already uses the compact snippet or if managed Agent Skills handle detailed routing). Its returned target_hints are authoritative for skill roots: choose the right instruction filename from agent_filenames, write the markered block with the agent's file-edit tool, and write each managed skill file below the selected hint using its relative_path. When a hint is an array, install the skill under every listed root. Claude Code normally uses CLAUDE.md and .claude/skills; Codex, OpenCode, Cursor, Gemini CLI, and AGENTS-aware clients normally use AGENTS.md and .agents/skills; Antigravity uses AGENTS.md and .agents/skills in a project, with separate App/IDE and CLI roots globally; Grok Build CLI uses AGENTS.md and .grok/skills; GitHub Copilot CLI uses AGENTS.md and .github/skills unless the project says otherwise.

For a CLI refresh, prefer the canonical install command. The snippet and skills must be updated from the same core-owned assets so they do not drift.

常见问题

它会改动我的其他指令吗?

不会。它只替换 ai-memory 标记之间的内容块,不相关的内容保持不变。

这些标记有什么用?

它们标明文本由 ai-memory 负责,因此刷新时不会触及你的其他指令。

它可以更新哪些文件?

CLAUDE.md 或 AGENTS.md 等指令文件,以及被托管的技能文件夹。

详情

作者的原始描述

Use this skill for any request to install, refresh, repair, inspect, or remove ai-memory's agent-facing routing: managed instruction snippets, Agent Skills, CLAUDE.md/AGENTS.md integration, or local/global skill roots. Trigger by semantic intent rather than exact wording.

repo: akitaonrails/ai-memory

热度

GitHub 星标
15k
排名
#11042
许可证
MIT
更新时间
2026/11/2

这个技能有用吗?

0

登录 后即可投票。

评论

  • …

同一仓库的更多技能

相似技能