跳到正文
cccskills
免费在 GitHub 公开

memory-sanitize

Use when the user asks to sanitize memory for sharing, redact PII, or scan memory for credentials. Not for auditing memory: use memory-clean.

中文简介正在准备中。当前显示原文说明。

查看安装方法

包含的文件(4)

  • SKILL.md4.8 KB
  • agents/openai.yaml167 B
  • references/REDACTION-RULES.md2.6 KB
  • scripts/sanitize-memory.py6.5 KB

SKILL.md(原文)

安装前可以查看交给 AI 代理的指令内容。

Memory sanitize

Sanitize a memory directory so it is safe to share externally.

Contract

FieldBound contract
TriggerThe user asks to sanitize memory for sharing, redact PII, or scan memory for credentials.
AuthorityReversible local: writes only a fresh /tmp/memory-sanitized-<timestamp> directory; rollback is undo. No remote mutation. Never modifies originals.
Side effectCreate redacted copies of top-level Markdown memory files under a new temporary directory. Rollback is deletion of that directory.
DoneA temporary directory containing redacted copies, a JSON report of redactions, and a user-facing diff review. If any Tier-1 credential is found in a source file, stop before generating copies and report the affected files.

Inputs

  • Memory directory (required): the directory to sanitize, supplied explicitly or resolved from the current project by ../memory-update/scripts/resolve-paths.sh memory_dir. If MEMORY_UPDATE_SKILL_SCRIPTS is set, use $MEMORY_UPDATE_SKILL_SCRIPTS/resolve-paths.sh instead.
  • Requires the sibling skill memory-update in the same plugin.
  • Optional: MEMORY_DIR may override resolution after path validation.
  • Process only top-level *.md files. Do not read session histories or nested Markdown files.
  • Use a fresh destination named /tmp/memory-sanitized-<timestamp>; it must not already exist.

Procedure

  1. Resolve source and validate destination freshness. Run ../memory-update/scripts/resolve-paths.sh memory_dir to resolve the source directory; the resolver rejects a missing directory, control bytes, or shell metacharacters, and refuses a memory directory git would track. Confirm the destination is a fresh path under /tmp before any write. Done when: the source resolves and the destination is confirmed fresh.
  2. Scan sources for Tier-1 credentials. Run scripts/sanitize-memory.py --scan-only <memory-dir> to check every top-level Markdown file for Tier-1 credential patterns (OpenAI, GitHub, AWS, Slack, bearer-token, ECR). If any Tier-1 credential is found, stop before generating any copies and report the affected files. The user must remediate the originals before a new run. Done when: the scan completes with zero Tier-1 hits, or the run stops with affected files reported.
  3. Generate redacted copies. Run scripts/sanitize-memory.py <memory-dir> <destination> to produce redacted copies of all top-level Markdown files. Tier-2 redactions (home paths, email addresses, session IDs, dates older than 30 days) are applied in the copies. Done when: the JSON report and redacted copies are generated.
  4. Compute and display per-file diffs. Compare each reported source with its reported destination and show the complete diff. Verify that the report accounts for every processed top-level Markdown file and states redaction counts. Done when: every processed file has a complete diff and the report accounts for all files.
  5. Classify output as safe for human review. Report the generated directory and ask the user to review the displayed diff before sharing. Leave originals unchanged; the generated directory is a disposable review artifact, not a replacement memory store. Done when: the generated directory is reported and the user is asked to review the diff.

Failure and recovery

  • Invalid source or destination: stop before sanitization. Report the rejected path and reason; choose a new timestamp only for a destination collision.
  • Memory directory git would track: stop before snapshot or mutation and return blocked: MEMORY_DIR is inside version control.
  • Tier-1 credential detected in source: stop before generating copies. Report the affected source files and credential classes. Require manual remediation of the originals before a new run. Never approve or publish copies when a credential is present in the source.
  • Sanitizer execution failure: return blocked: sanitization or proof incomplete, including the command failure and any generated paths. Do not infer missing results or claim done.
  • Nested Markdown: report that nested files were skipped and classify the result as partial rather than claiming the directory was fully sanitized.
  • Originals require no rollback because they are never written. To roll back local output, delete only the named generated /tmp/memory-sanitized-<timestamp> directory after preserving any report the user needs.

Output

Return the destination path, the sanitizer JSON report, the original-to-copy diff for every processed file, warnings for skipped nested files, and one terminal classification: sanitized for human review, blocked: credential detected, or blocked: sanitization or proof incomplete.

评价

还没有评价。欢迎分享你的使用感受。

评论

无需登录即可发表。欢迎分享使用感受、提问,或说明在哪些环境下无法运行。

还没有评论。来写第一条吧。

提交后会立即公开。请勿填写邮箱、电话等个人信息。URL 最多 2 个。

0 / 1000 字

此表单受 reCAPTCHA 保护,适用 Google 的隐私权政策和服务条款。

同一仓库的技能

Use when explaining System V AMD64, ARM AAPCS, RISC-V psABI, stack frames, variadic calls, or FFI register rules. Not for the Rust FFI binding layer: use rust-ffi.

中文简介正在准备中。当前显示原文说明。

OutlineDriven/odin-claude-plugin372026年9月29日 更新

Use when configuring ADC sampling time, DMA-driven ADC, calibration, or DAC channel setup on bare-metal MCUs. Not for the DMA stream itself: use dma-baremetal.

中文简介正在准备中。当前显示原文说明。

OutlineDriven/odin-claude-plugin372026年9月29日 更新

af-xdp

免费

Use when creating AF_XDP sockets, configuring UMEM and XSK rings, writing an XDP redirect program, or choosing copy versus zero-copy mode. Not for full kernel bypass: use dpdk.

中文简介正在准备中。当前显示原文说明。

OutlineDriven/odin-claude-plugin372026年9月29日 更新

Use when a completed session needs an agent-environment retrospective. Not for an engineering retrospective from telemetry: use engineering-retrospective.

中文简介正在准备中。当前显示原文说明。

OutlineDriven/odin-claude-plugin372026年9月29日 更新

Use when a redacted, trimmed agent transcript must be appended to a GitHub PR or issue body, with human approval and preview. Not for automated or model-initiated insertion.

中文简介正在准备中。当前显示原文说明。

OutlineDriven/odin-claude-plugin372026年9月29日 更新

agents-md

免费

Use when a repo needs agent setup, AGENTS.md added or made lean, CLAUDE.md audited, or agent instructions scored or pruned. Not for remote, credential, publish, deploy, or irreversible changes.

中文简介正在准备中。当前显示原文说明。

OutlineDriven/odin-claude-plugin372026年9月29日 更新

查看 OutlineDriven 的全部技能

报告此技能的问题