Skill for Sensitive File Masking: Locally Scan Documents and Generate Readable Redacted Copies

Preface

Contracts, customer lists, financial tables, and internal reports often need names, ID numbers, bank card numbers, and institution names removed before being shared externally. Manual search-and-replace often leads to missed items, while simply replacing everything with [REDACTED] makes tables and paragraphs difficult to read. If you want an Agent to scan according to rules, generate reports, and replace sensitive values with consistent fake data—while minimizing damage to the structure of DOCX, Markdown, or Excel files—you can set this capability up as a Skill attached to your current client. Below is an introduction to the “Sensitive File Anonymization Skill” on SkillHub, including installation and usage highlights.

What is this

The “Sensitive File Anonymization Skill” (ID @user_c0e4b78f/anonymize-sensitive-files, current version 1.0.2) is a community sourced ai-agent category Skill maintained by the publisher user_c0e4b78f; the SkillHub page lists the author as zongzack. The tag requires_api_key=false indicates that, according to SkillHub metadata, it does not rely on additional API keys.

It targets the “document anonymization” scenario: scanning and replacing names, phone numbers, emails, ID card numbers, Unified Social Credit Codes, bank card numbers, bank routing numbers, addresses, contract numbers, company/institution names, custom sensitive words, etc., within documents, while preserving the readable structure of the original text as much as possible. It is suitable for contracts, customer data, procurement documents, financial files, internal reports, resumes, and business documents that require de-sensitization before sharing. When you mention requirements in the conversation such as anonymization, de-sensitization, sensitive information, personal information, ID cards, phone numbers, emails, bank cards, contracts, customers, projects, or keys, the Agent can select this Skill accordingly.

Core Functions

The following capabilities are based on official SkillHub descriptions and can be understood as a workflow of “Scan → Verify → Anonymize”:

  1. Scan & Report: Scans for sensitive information and generates a JSON report.
  2. Safe Output: Generates anonymized copies without overwriting the original files.
  3. Replacement Strategy: Replaces original values with realistic fake data rather than simply writing [REDACTED]; within the same run, the same original value maps to the same fake value to facilitate structural comparison.
  4. Wordlist: Supports custom sensitive wordlists.
  5. Table & Excel Field Rules:
    • Markdown tables, DOCX tables, and Excel worksheets support adjacent field rules, e.g., A1=Legal Representative, B1=Some Name.
    • Excel also supports rules where the column header is above the value, e.g., A1=Name, A2=Some Name.
  6. Excel & Macros:
    • The processing scope includes workbook properties, worksheet names, string cells, and hyperlink text and targets; it strives to preserve the workbook, styles, hidden sheets, and macros.
    • Comments, images, charts, text boxes, pivot tables, embedded objects, and macro code require additional manual review.
    • .xlsm files retain the VBA project, but the macro code is neither scanned nor modified.
  7. Formulas & Cell Types:
    • Formula expressions are scanned during scan/verify; anonymize does not rewrite formulas. If sensitive values are detected within formulas, the process will refuse to generate an output file that might retain sensitive values.
    • Numeric, date, and boolean cells are not modified by default to avoid breaking types and formats; if an adjacent field rule detects a sensitive value in such a cell, anonymize will fail rather than write out a workbook containing residual sensitive values. To replace such values, convert the target column to text first or export to CSV/TSV for processing.

Installation & Activation

The Skill follows the standard SKILL.md format. Assuming the SkillHub CLI is available, install it to a skills directory recognizable by the current Agent (you must specify --dir during installation; otherwise, it defaults to ./skills/ and may not be loaded by the client).

  1. Check the CLI:
command -v skillhub && skillhub --version
  1. If not installed, follow the SkillHub installation documentation to perform a full installation or install only the CLI (network access is required in sandbox environments):
curl -fsSL https://skillhub-1388575217.cos.ap-guangzhou.myqcloud.com/install/install.sh | bash
curl -fsSL https://skillhub-1388575217.cos.ap-guangzhou.myqcloud.com/install/install.sh | bash -s -- --cli-only
  1. Install this Skill (replace <skills directory> with the path for your current environment):
skillhub install @user_c0e4b78f/anonymize-sensitive-files --dir <skills directory>

Common client skills directories (excerpted from SkillHub installation instructions):

  • Cursor: ~/.cursor/skills/
  • Claude Code: ~/.claude/skills/
  • Codex: ~/.codex/skills/ or .agents/skills/ under the project directory

After installation, refresh or restart according to the specific client’s requirements to load the Skill. The SkillHub page also provides natural language installation prompts: ask the Agent to install @user_c0e4b78f/anonymize-sensitive-files based on the SkillHub Installation Documentation.

Typical Usage

Once the Skill is enabled, a common practice is to instruct the Agent to perform the three types of operations described officially on specified files:

  1. scan: Detect sensitive items and output a JSON report to confirm if the scope and rules are appropriate.
  2. verify: Review complex content (such as formulas) to check for remaining sensitive values (e.g., literals within formula expressions).
  3. anonymize: Generate an anonymized copy after passing the verification policy; if sensitive values still exist in formulas or protected cell types, the process will abort rather than write out an unsafe file.

In the conversation, you can explicitly state the file path, whether a custom sensitive wordlist is needed, and whether to only scan or to directly anonymize. For Excel scenarios, describe the layout of headers and values (adjacent cells or “column header above”) to enable adjacent field rules.

Use Cases & Cautions

Suitable for: Teams that need to perform structured anonymization on business documents such as Markdown, DOCX, and Excel before sharing, reviewing, or preparing training materials; and wish to preserve the layout while using consistent fake names/numbers to maintain readability.

Cautions:

  • Limitations regarding non-string cells and formulas in Excel are detailed above; complex objects (charts, embedded objects, etc.) should be manually spot-checked after anonymization.
  • .xlsm macro code is not within the scope of scanning or rewriting; do not assume that macros or hidden layers have been anonymized.
  • SkillHub Statistics (based on scraped data): Category ai-agent, Rating 100000, Downloads 2165; installation count may be 0 in the metadata, please refer to real-time page data.

Conclusion

The “Sensitive File Anonymization Skill” incorporates scanning reports, consistent fake data replacement, and structural preservation for Excel/DOCX/Markdown into the Agent workflow, making it suitable for reviewable local anonymization before sending documents externally. Official Skill page and API entry:

  • https://www.skillhub.cn/skills/user_c0e4b78f/anonymize-sensitive-files
  • https://api.skillhub.cn/user_c0e4b78f/anonymize-sensitive-files
羽毛球分组比赛记分
小程序二维码

欢迎使用《羽毛球分组比赛记分》微信小程序

Xiaoye