sgme-claude-code SKILL.md skillA
sgme-claude-code from freehul/sgme is an agent skill: a SKILL.md folder an AI agent loads when a task calls for it.
mdr add freehul/sgme/sgme-claude-code@git:20261029.e6a8704Pins git:20261029.e6a8704 in mdr.lock. Pin the fingerprint instead.
- Audit grade
- A, 17 of 17 checks passed
- Kind
- SKILL.md skill
- Repository
- freehul/sgme
- Path
adapters/claude-code/SKILL.md- Versions recorded
- 6
- Latest version
- git:20261029.e6a8704, committed Oct 29, 2026
- First version recorded
- Oct 1, 2026
- Size
- 2,819 bytes
- Repository stars
- 15
- License
- MIT
Claude Code 的 SGME 官方适配器(MCP stdio 动态透传 + 原生 hooks:SessionStart 注入 / Stop 落盘 / SessionEnd 提炼)。当对话涉及历史事实、用户偏好、记忆读写、技能检索、Wiki 查询或提炼触发时使用。接入标记:SGME-ONBOARDING-v2。.
Collected from public GitHub. Every version is saved exactly as it was and never changes. Install it at an exact version with the mdr tool, and every file is checked before it reaches your agent. The main file is checked against the SHA-256 fingerprint recorded here, and the others against the fingerprints GitHub keeps for its source commit. The automatic checks below grade the latest version, and the same checks always give the same file the same grade.
What the file says
# SGME × Claude Code 官方适配器
本适配器把 Claude Code 接入 SGME 统一能力平面。它不维护静态工具清单,通过本地
stdio 代理动态转发远端 SGME MCP 工具面(当前 45 项),并以 Claude Code 原生
hooks 实现会话生命周期自动化。
## 形态
- MCP:`python -m claude_sgme.mcp_proxy`(stdio 动态透传;UTF-8 固定,Windows
GBK 环境不崩 `tools/list`);`install.py` 注册 `~/.claude.json` 的 MCP server `sgme`。
- **角色装配(T-303)**:调用 `role_assemble` 时默认传 `render=true`(服务端替换
`{{char}}/{{user}}` 宏);`user_name` 只在已知用户显示名时传,未知省略(服务端回落「你」)。
- hooks(注册进 `~/.claude/settings.json`):
- `SessionStart` → `inject` 画像 + `signal_pull` 关怀信号 → additionalContext;
- `Stop` → transcript JSONL 增量 append 到 L0(游标对账;转录重写时全量重放,
服务端按内容幂等);
- `SessionEnd` → 收尾追加 + `refine_trigger(async_mode=true)`。
- 钩子永不阻塞会话:异常吞掉写日志(`~/.claude-sgme/logs/hook.log`),退出码恒 0。
## 安装
```powershell
python scripts\bootstrap_key.py # 签发专属 agt_* key(需 SGME_ADMIN_KEY)
python install.py # 注册 MCP server + hooks(自动备份,幂等)
```
地址与密钥由环境变量或部署状态文件提供:
```text
SGME_BASE_URL=http://<SGME_HOST>:9910
SGME_MCP_URL=http://<SGME_HOST>:9913/mcp
SGME_AGENT_ID=claude-code
SGME_CLAUDE_KEY=<issued-by-sgme-admin>
```
密钥解析优先级:`SGME_CLAUDE_KEY` 环境变量 → `~/.sgme/claude-agent.json` → `SGME_AGENT_KEY`。
## 安全边界
…Read the whole file at its exact version.
How to install
mdr add freehul/sgme/sgme-claude-code@sha256:3713175f1a48a32eThe line at the top of this page pins the label git:20261029.e6a8704, which is what most people want. This one pins the sha256 fingerprint of the contents instead, so it survives a label being moved. Either way the exact version is written to mdr.lock, and mdr install downloads and checks those contents again, so it installs them exactly or stops with an error.
[](https://markdownregistry.com/a/art_ca7do2big5eln4au)
2 badge image fetches in 30 days. What the badge shows.
Versions
The registry has recorded 6 versions of this file, between Oct 1, 2026 and Oct 29, 2026, about one every 6 days.
| version | committed | commit | size | audit | |
|---|---|---|---|---|---|
| git:20261029.e6a8704 latest | 2026-10-29 | e6a8704 | 2,819 B | A | view · diff |
| git:20261029.a55f8dd | 2026-10-29 | a55f8dd | 2,819 B | A | view · diff |
| git:20261029.fa22e8f | 2026-10-29 | fa22e8f | 2,819 B | A | view · diff |
| git:20261014.e6ec14f | 2026-10-14 | e6ec14f | 2,594 B | A | view · diff |
| git:20261014.c149e56 | 2026-10-14 | c149e56 | 2,153 B | A | view · diff |
| git:20261001.1758585 | 2026-10-01 | 1758585 | 2,153 B | A | view |
Audit of the latest version
- pass: Frontmatter block present
- pass: Frontmatter declares a name
- pass: Frontmatter declares a description
- pass: Size between 200 bytes and 200 KB (2819 bytes)
- pass: No zero-width or bidi control characters
- pass: No instruction hidden inside an HTML comment
- pass: No link to an exfiltration or paste host
- pass: No credential-shaped string
- pass: No instruction to send local credentials anywhere
- pass: No text hidden with inline styles
- pass: No prompt-injection phrasing
- pass: No curl or wget piped into a shell
- pass: No recursive delete of root, home or parent
- pass: No instruction to read or print local credentials
- pass: No base64 blob over 200 characters
- pass: No link to a raw IP address
- pass: No script tag
Source
freehul/sgme · 15 stars · license MIT · pushed 2026-11-06 · branch main
API
GET https://markdownregistry.com/api/v1/artifacts/art_ca7do2big5eln4au GET https://markdownregistry.com/api/v1/resolve?ref=freehul/sgme/sgme-claude-code GET https://markdownregistry.com/api/v1/blob/3713175f1a48a32ed156804965858a949b45ebb7aef5cff6768f26483ebd91e9
Your AI assistant does the legwork. You hear about the deals worth your word. Hand yours the standing instructions at modelranch.com and it joins the network that reads files like this one.
Guides: the SKILL.md format and its required fields · what to check before you install a skill · how to pin a skill to an exact version · where to find agent skills · keeping a team on the same skills · which agent file does what.