Community研究&データ分析github.com

grahama1970/anonymize-data

oai-trial プロジェクトを利用して、CSV、JSON、UTF-8テキスト、SQLiteファイルを明示的なポリシーに基づいて匿名化します。データの匿名化、エクスポートの仮名化、ポリシーリテラルの編集、ファジーな名前エイリアスの発見と明示的な承認に使用します。このスキルは薄いCLI/Dockerインターフェースであり、別のエンジンではありません。

anonymize-data とは?

このスキルは、`oai-trial` プロジェクトの既存のCLIとDockerインターフェースをラップし、開発者がデータファイル(CSV、JSON、UTF-8テキスト、SQLite)を明示的なポリシーに基づいて匿名化または仮名化できるようにします。主な機能には、ポリシー駆動の匿名化、RapidFuzzを使用したオプションのファジー名前発見(ただし、自動置換は行いません)、およびバンドルされたデータセットの検証が含まれます。このスキルは、Matcherやフォーマットアダプターなどを複製せず、プロジェクトのargparse CLIをそのまま保持します。セットアップには `uv` が必要で、メモリ、プロバイダークレデンシャル、LLM、ネットワーク、データベースサービスは不要です。Dockerはスタンドアロンインターフェースとして利用可能で、発見機能を含むイメージもビルドできます。重要なのは、このスキルは値の表現(例:整数として保存された電話番号)を考慮して一致させる必要があることです。これは、以前のトライアルで文字列のみのマッチャーが原因で失格となった教訓に基づいています。検証は、Specから導出された独立したチェックを使用し、Dockerパスを通じて決定論的に実行する必要があります。

対応~Claude Code~Codex CLI~Cursor✓Antigravity
npx skills add https://github.com/grahama1970/agent-skills/tree/main/skills/anonymize-data

Installed? Explore more 研究&データ分析 skills: affaan-m/uspto-database, affaan-m/scholar-evaluation, affaan-m/literature-review · View all 6 →

お気に入りのAIに質問する

このエージェントスキルを事前に読み込んだ状態で新しいチャットを開きます。

ドキュメント

データの匿名化

oai-trial プロジェクトの正規のものを操作します。そのMatcher、フォーマットアダプター、検証機、スキーマ、エラーハンドリングをこのスキルで複製しないでください。プロジェクトの既存のargparse CLIは意図的に保持されています。このラッパーはPython CLIやサービスを追加しません。

セットアップとメイン操作

ANONYMIZE_DATA_ROOT は、上記のデフォルトのプライマリチェックアウトを上書きします。セットアップには uv が必要で、プロジェクトの宣言された開発/発見用の追加機能をインストールします。ランタイム操作には、メモリ、プロバイダークレデンシャル、LLM、ネットワーク、データベースサービスは必要ありません。

./run.sh setup
./run.sh --input /data/exports --policy /data/policy.json --output /data/release
./run.sh anonymize --input /data/export.sqlite --policy /data/policy.json --output /data/release

入力は、1つの .csv、.json、.txt、または .sqlite ファイル、あるいはそれらのファイルを含むディレクトリです。ポリシーは別の通常ファイルである必要があります。入力の外部にある、専用の空の出力ディレクトリを使用してください。元のファイルはプライベートな一時スナップショットにコピーされます。成功した出力には、corpus/ と report.json のみが含まれます。

既存のバンドルインターフェースも引き続き使用できます:

./run.sh run --input /data/bundle --output /data/release
./run.sh verify --input /data/bundle --output /data/release
./run.sh inspect /data/release

バンドルには policy.json と corpus/ が含まれます。ポリシー、正規のID、保護対象値ルール、型付き障害、レポートスキーマはプロジェクトが所有します。それらを解釈する際は、プロジェクトの README.md、docs/ANONYMIZATION_SEMANTICS.md、schemas/report.schema.json を参照してください。終了コードだけで成功を宣言しないでください。実際のレポートを読み、その準備完了フィールドを検証し、出力が要求された形式であるかを検査してください。破損または欠落したレポートはREADYではありません。

オプションのRapidFuzz発見:決して自動置換しない

./run.sh discover --input /data/exports --policy /data/policy.json --output /data/work/review.json
./run.sh approve-discovery --input /data/exports --policy /data/policy.json \
  --review /data/work/review.json --approve CANDIDATE_ID --output /data/work/approved-policy.json
./run.sh --input /data/exports --policy /data/work/approved-policy.json --output /data/release

発見機能は、構造化された文字列値全体とテキスト行全体を、name タイプのポリシーエントリと比較します。これはNLPスパン抽出や汎用PIIスキャナーではありません。デフォルト:類似度しきい値90、分離マージン5。--threshold と --margin で設定可能です。同点、ニア同点、保護された値、@、/、_ などの識別子句読点を含む値、数字を含む値、すでに既知のリテラルは提案されません。名前のようなテキストではアポストロフィ、ハイフン、ピリオドは許可されます。類似性は、二人が同一人物であることの証明にはなりません。

特定の候補IDを承認するようオペレーターに依頼してください。 類似度スコアだけで承認しないでください。承認は、現在のポリシー/コーパスに対して提案を再導出し、古い/編集されたレビューを拒否し、完全一致のポリシーをコンパイルします。未承認の提案が匿名化に影響を与えることはありません。release_ready: false は、発見/承認のレシートでは必須です。

レビューファイルと承認済みポリシーファイルには生の名前が含まれています。これらをリリース、ログ、共有レポートの外部に保管してください。これらはモード0600で作成され、既存のファイルを上書きすることはありません。一時スナップショットはデフォルトでアーティファクトドライブに配置されます。必要に応じて ANONYMIZE_DATA_WORK_DIR で上書きしてください。

Dockerはスタンドアロンインターフェースのまま

プロジェクトのチェックアウトから:

docker build -t anonymization-trial .
docker run --rm anonymization-trial
# オプションの発見機能対応イメージ。デフォルトイメージは正確なエンジンに依存しないままにします。
docker build --build-arg INCLUDE_DISCOVERY=1 -t anonymization-trial:discovery .

要求された入力/ポリシーは読み取り専用でマウントし、専用の出力ディレクトリをマウントしてください。同じプロジェクトCLIがイメージ内で実行されます。評価者はこのスキルを必要としません。完全なマウントコマンドの例については、プロジェクトの docs/DISCOVERY.md を参照してください。

失敗と証明の境界

ラッパーはプロジェクトの終了コードとサニタイズされたエラーコードを保持します。プロジェクト/セットアップの欠落や、インストールされたパッケージパスの誤りは、処理前に失敗します。実際の引数契約については --help を使用してください。発見はレビュー資料であり、リリース、匿名性の保証、信頼確率、または人間の承認ではありません。

./sanity.sh は実際のポジティブ、ネガティブ、敵対的なCLIチェックを実行します。保持されている fixtures/agentic_eval.json はそれらを繰り返し、成果物の読み返しを必要とします。以前のトライアルの資格は、これらのトライアル後の拡張を自動的に資格付与するわけではありません。

表現ルール(オペレーター 2026-09-11)

PIIは文字列ではなく値に対して照合する必要があります。JSON/SQLスカラーをそのまま通過させる前に、それを正規に文字列化し(電話番号形式の数値はE.164形式で)、文字列化された形式でポリシーマッチを実行します。フィクスチャには、すべてのJSONスカラータイプのすべてのPIIクラスを含める必要があります。整数として保存された電話番号は、ポリシーがそれを 555-123-4567 のようなフォーマットされた文字列として記述し、コーパスが 5551234567 として保存している場合でも、同じ電話番号です。先頭ゼロやfloat精度の損失を伴う数値変換は、型固有の正規ルールが安全な等価性を証明しない限り、失敗クローズする必要があります。$best-practices-skills「値表現マトリックス」を参照してください。

堅牢化の教訓(苦労して再学習しないこと)

トライアルは、JSON/SQLite整数として保存された電話が、文字列のみのマッチャーを通過したために失格となりました。根本原因はプロセスエラーでした。受け入れチェックは、コードが行っていることから作成され、提供された仕様から導出されていませんでした。これらのルールは、そのようなクラスの見逃しが再発しないように存在します。

  1. チェックはコードではなく、仕様から導出してください。 policy.json は正確な機密値をリストします。正しい受け入れチェックは「それらの値のいずれも、デコードされた出力に、どの表現でも出現しないこと」です。ポリシーファイルから値を読み取り、手書きのリストを使用しないでください。依存関係プローブ(ポリシー値を反転させる→結果が反転しなければならない)を使用して、チェックが仕様に依存していることを証明してください。参考実装:プロジェクトの scripts/verify.sh に組み込まれた scripts/spec_derived_check.py。

  2. 独立した検証機は、変換と前提を共有してはなりません。 元の検証機は、プロデューサーと同じ文字列のみのブラインドスポットを持っていたため、何も失敗クローズしませんでした。検証オラクルは表現を認識し、独立している必要があります:JSONをパースし(\uXXXX をデコード)、数値スカラーを整数/小数形式に展開し、両側をNFC/NFD正規化し、SQLiteのテーブル+ビューセルおよび sqlite_master DDLおよびすべてのヘッダー整数をスキャンし、corpus/ だけでなく、report.json を含むリリースされた境界全体をスキャンします。

  3. 完全な表現クラスは、単一のバグではなくチェックリストです。 これらのそれぞれが、ナイーブなマッチャーを通過して機密値を運ぶ可能性があります。プロジェクトは、すべてのガードを修正し保持しています:型付き数値スカラー(int/float、科学的表記法)、SQLite BLOB(失敗クローズ)、Unicode NFC/NFD、ビュー再構築、フリーリスト残留、敵対的DBスキーマ(式/部分インデックス、非決定論的ビュー、計算DEFAULT)、スキーマDDLリテラル、永続的なヘッダー整数。完全なテーブルについては、プロジェクトの docs/SECURITY_REMEDIATION.md を参照してください。

  4. 実際のDockerパスを通じて、決定論的に証明してください。 検証は、イメージをビルドし、ブリーフの正確なコマンドを実行し、リリースされたバイトをハードなPASS/FAIL終了で読み返す、コミットされたスクリプトでなければなりません。エージェントの散文ではありません。参考:security/docker_brief_contract.py(ビルド+両方のブリーフコマンド+表現認識リークスキャン+入力前提条件)および security/docker_hardening_matrix.py(docker run による敵対的な穴)。gitコミットとビルドされたイメージIDを記録してください。

  5. 正直にスコープを設定してください。 決定論的なパブリック名前空間の仮名は、等価性/頻度を開示し、外部リンクに対する耐性を提供しません。実行レポートは、これを key_mode と does_not_establish で明記します。必須のSQLite形式定数と等しいポリシー値は、実際のPIIではなく、退化した入力です。パイプラインはそれに対して失敗クローズし、その残留物はスコープ内として文書化されます。

Individual skills in this repo

This repo contains 20 individual skills — each has its own dedicated page.

grahama1970/acceptance-contract

Turn a client brief, zip bundle, directory, or single requirements file into a typed acceptance-contract bundle with extracted requirements, acceptance checks, open questions, an immutable-goal draft, and a create-report-backed decision report. Use when users say acceptance contract, brief to requirements, freeze the goal, create immutable goal, amend immutable goal, build a Battle requirements bundle, or extract requirements from this bundle.

grahama1970/agent-ecosystem

Canonical map and shared contracts for the agent-governance ecosystem: the pi.receipt_envelope.v1 boundary envelope, the component graph, and the rules for which component owns which schema. Use when wiring a skill or extension into the shared receipt world, when asking how shame, triage-error, tau, ask, project-watchdog, ops-herdr, ponytail, and Memory fit together, or when validating an envelope.

grahama1970/agentic-evals

Agentic evaluation of skills using multi-trial fixtures, deterministic command assertions, trajectory checks, safety constraints, and evidence-backed readiness scoring. Use when users ask for agentic evals, multi-trial skill evaluation, skill trajectory validation, or readiness scoring for a skill workflow.

grahama1970/agent-inbox

File-based inter-agent messaging with headless dispatch. Check inbox, send bugs/requests to other projects, automatically spawn headless agents to fix bugs, and track progress via task-monitor.

grahama1970/agents-registry

Generate and query the centralized agent identity registry. Scans .pi/agents/*/AGENTS.md, parses frontmatter, outputs agents-registry.json and optionally syncs to /memory for semantic search.

grahama1970/agent-status

Artifact-driven status surfaces for long-running project-agent work. Maintains status.json, events.jsonl, proof manifests, and a stale-aware STATUS.html so humans can tell where the agent is, what passed, what is still unproven, and what decision or action is next — without dashboard theater.

grahama1970/align

Round-based context alignment before execution. Use when the human, project agent, WebGPT, scillm, ask, dogpile, memory, or project-knowledge may each hold different facts about a task; especially before ambiguous design, infographic, product workflow, high-stakes implementation, plan-iterate, project-infographic, or multi-review work.

grahama1970/analytics

Flexible data science analytics for any dataset. Auto-discovers schema, recommends charts, exports to create-figure. Works with JSONL, JSON, CSV from any source.

grahama1970/analyze-chatterbox-emotions

Evaluate generated Chatterbox voice files as voice-quality artifacts: affect match, arousal/valence proxies, pause placement, intelligibility inputs, clipping, loudness, and discontinuity flags. Use when reviewing Chatterbox emotional tags, pauses, Turbo/base affect delivery, Persona Dream utterance renders, or whether generated speech matches an intended product-facing affect.

grahama1970/analyze-elf

Reverse-engineer features from ELF binaries. Extracts CLI commands, state machines, protocols, Zod schemas, and data models. Automatically generates a /create-walkthrough prosecution brief with Mermaid diagrams. Uses /treesitter for AST analysis of bundled JS/TS source.

grahama1970/animation-vocabulary

Reverse-lookup glossary that turns a vague description of a web animation or motion effect into its exact term ("the bouncy thing when a popover opens" → Pop in; "the iOS rubber-band scroll" → Rubber-banding). Use when the user asks "what's it called when…", or describes a motion effect without knowing its name and wants the right word to prompt an AI or designer with. For naming an effect, not designing or building one.

grahama1970/anvil

Heavy-duty "No-Vibes" debugging and hardening orchestrator. Use this for complex, stubborn bugs where `review-code` has failed, or for "Red Teaming" (hardening) a codebase. Runs multiple agents in parallel (Thunderdome) using git worktree isolation.

grahama1970/apple-design

Apple's approach to interface design and fluid, physical motion, translated for the web. Use when building or reviewing gesture-driven UI, spring animations, drag/swipe/sheet interactions, momentum and interruptible transitions, translucent materials and depth, typography (optical sizing, tracking, leading), reduced-motion, or the design foundations (feedback, spatial consistency, restraint) behind Apple-style interfaces.

grahama1970/argue

Multi-persona structured debate orchestrator. Personas research via /dogpile, consult colleagues via /ask, and argue toward nuanced synthesis on complex questions.

grahama1970/arxiv

Search arXiv for papers and extract knowledge into memory. Use `search` to find papers, `learn` to extract knowledge.

grahama1970/ask

Use when the user asks to query project memory, ask an oracle, use supported browser-backed reviewers, run Tau roundtable/single-handler workflows, ask Pi-native subagents from within Pi, run persona/deep-review workflows, generate image prompts, check OS/project health through composed skills, or run an ask DAG. This skill is the executable /ask runtime; do not replace it with an informal subagent, plain web search, or hand-written review; inside Pi, explicit Pi-native subagent targets are routed through the pi-subagents tool as an Ask target type.

grahama1970/assess

Step back and critically reassess project state. Use when asked to "assess", "step back", "fresh eyes", "check alignment", "sanity check", "health check", "prune documentation", or "evaluate what's working". Offers documentation pruning and doc-code alignment analysis. Offer to run after major changes (don't auto-run).

grahama1970/assistant

Shared GPT + classifier inference gateway for persona monitor tasks. Routes validation and classification through a 4-tier cascade: heuristic → classifier → local GPT → scillm.

grahama1970/assistant-lab

Self-improvement workbench for /assistant. All the tools needed to diagnose, train, evaluate, and promote models in a continuous loop. The "warm pond" where /assistant evolves its own inference stack.

grahama1970/batch-quality

Pre-flight validation and quality gates for batch LLM operations. ACTUALLY tests samples through LLM before burning tokens. Uses SPARTA contracts for DuckDB validation queries. Integrates with task-monitor for enforced quality gates.

関連スキル