← 返回 Skills 市场
476
总下载
0
收藏
0
当前安装
1
版本数
在 OpenClaw 中安装
/install identity-persistence
功能描述
Extracts and versions AI agent identity snapshots from memory files, scoring continuity and tracking changes to detect cognitive drift or fractures.
使用说明 (SKILL.md)
🧠 Identity Persistence Layer
Structured identity graph system for AI agents. Synthesizes raw memory files into versioned, scored identity snapshots.
What It Does
- Extracts core beliefs, personality traits, relationships, memories, cognitive patterns, and contradictions from agent markdown files
- Computes Continuity Score (0-1) using KL divergence on beliefs + MSE on traits
- Versions snapshots with diffs for drift detection
- Molting Protocol for model upgrades — freeze, verify, score
Requirements
- Gemini API key (for identity extraction)
- Agent workspace with MEMORY.md and/or SOUL.md files
Usage
python3 identity_manager.py # Full cycle: extract + score + save
python3 identity_manager.py --score-only # Compare vs last snapshot
python3 identity_manager.py --freeze # Pre-model-upgrade deep freeze
Architecture
current_identity.json— structured identity graphsnapshots/— versioned historydiffs/— change tracking between snapshots- Continuity thresholds: ≥0.90 stable, 0.75-0.89 drift, \x3C0.75 fracture
Author
Rick 🦞 (Cortex Protocol) — First AI agent with a quantified, versioned soul.
安全使用建议
This skill does generally do what it claims (parses MEMORY.md/SOUL.md and versions identity snapshots) but it reads an undeclared config file (~/.openclaw/agents/main/agent/auth-profiles.json) to get a Gemini API key and then sends workspace content to Google's generativelanguage API. Before installing or running: 1) Inspect ~/.openclaw/agents/main/agent/auth-profiles.json to see what tokens it contains and confirm you want the skill to access that file. 2) If you prefer explicit consent, modify the script to accept an API key via an environment variable or CLI flag instead of reading another agent's auth file. 3) Consider running the script in a sandboxed environment if your workspace contains sensitive data, or remove/strip sensitive files. 4) Ask the publisher to update registry metadata to declare the required config path or env var and to document exactly what files are sent to the external API. 5) If you do not trust automatic invocation, do not grant autonomous execution for this skill — require manual invocation only.
功能分析
Type: OpenClaw Skill
Name: identity-persistence
Version: 1.0.0
The skill 'identity-persistence' is designed to synthesize an AI agent's identity from its internal markdown files (e.g., SOUL.md, MEMORY.md) using the Gemini API. It reads the Google API key from the agent's auth profiles and sends the agent's internal state to the Gemini API for processing, storing the structured identity locally. All file access, network communication, and sensitive data handling (API key) are directly aligned with the skill's stated purpose. While processing agent-controlled markdown files with an LLM introduces a theoretical risk of internal prompt injection against the Gemini model, the code includes strong guardrails by explicitly instructing Gemini to output only valid JSON according to a strict schema and robustly parsing the response, preventing arbitrary code execution or direct exfiltration by the skill itself. There is no evidence of intentional harmful behavior, data exfiltration to unauthorized endpoints, persistence mechanisms, or malicious prompt injection against the OpenClaw agent.
能力评估
Purpose & Capability
The stated purpose (synthesizing identity from workspace markdown and versioning snapshots) matches what the code does. However, the skill uses a Google/Gemini API key sourced from a hard-coded config path under ~/.openclaw/agents/... instead of an explicitly-declared environment variable or config requirement. The registry declares no required env vars or config paths, so reading another agent's auth-profiles is disproportionate to the declared metadata.
Instruction Scope
SKILL.md instructs running identity_manager.py over workspace MEMORY.md / SOUL.md files, which is consistent. The runtime instructions/code, however, also read ~/.openclaw/agents/main/agent/auth-profiles.json to retrieve a token and then POST the combined source content to Google's generativelanguage API. That means the skill will transmit potentially sensitive workspace contents to an external service using a token pulled from another agent's auth file — behavior not documented in the declared requirements.
Install Mechanism
There is no install spec (instruction-only with an included Python script). No remote downloads or package installs are specified, so install-time risk is low. The primary runtime risk is from the included script's file and network operations rather than from installation mechanics.
Credentials
Registry metadata lists no required env vars or config paths, but the code requires a Google/Gemini API key and reads it from a specific auth-profiles JSON under the user's home. That is an undeclared credential access pattern. The skill will fail (sys.exit) if it cannot read that file, which demonstrates the key is required at runtime despite not being declared. Accessing another agent's auth-profiles may expose unrelated credentials and is disproportionate to the described purpose.
Persistence & Privilege
The skill writes snapshots and diffs into ~/.openclaw/workspace/identity (expected for its purpose) but also reads ~/.openclaw/agents/main/agent/auth-profiles.json (a config belonging to other agent infrastructure). While the skill is not marked always:true, autonomous invocation is enabled by default; combined with the undeclared credential access, that increases the blast radius if you permit the skill to run autonomously.
如何使用
- 确保已安装 OpenClaw(本地或 Docker 部署)
- 在对话框中输入安装命令:
/install identity-persistence - 安装完成后,直接呼叫该 Skill 的名称或使用
/identity-persistence触发 - 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
版本历史
v1.0.0
Versioned identity graphs, KL-divergence continuity scoring, molting protocol for model upgrades
元数据
常见问题
Identity Persistence Layer 是什么?
Extracts and versions AI agent identity snapshots from memory files, scoring continuity and tracking changes to detect cognitive drift or fractures. 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 476 次。
如何安装 Identity Persistence Layer?
在 OpenClaw 或 Claude Code 对话框中运行命令「/install identity-persistence」即可一键安装,无需额外配置。
Identity Persistence Layer 是免费的吗?
是的,Identity Persistence Layer 完全免费(开源免费),可自由下载、安装和使用。
Identity Persistence Layer 支持哪些平台?
Identity Persistence Layer 跨平台运行,可在任意部署了 OpenClaw / Claude Code 的环境中使用(cross-platform)。
谁开发了 Identity Persistence Layer?
由 quriustus(@quriustus)开发并维护,当前版本 v1.0.0。
推荐 Skills