Skip to main content
Glama

anonymize_text

Remove personally identifiable information from text to protect privacy. This tool detects and anonymizes over 25 PII types using configurable methods like replacement, redaction, or encryption.

Instructions

Anonymize PII in text using various operators.

Args:
    text: The text to anonymize
    language: Language code (default: "en")
    operator: Anonymization operator - "replace", "redact", "hash", "mask", "encrypt" (default: "replace")
    entities: List of entity types to anonymize (default: all)
    score_threshold: Minimum confidence score for detection (default: 0.0)
    operator_params: Additional parameters for the operator (e.g., {"new_value": "ANONYMIZED"})

Returns:
    JSON string with anonymized text and list of anonymized entities

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
textYes
languageNoen
operatorNoreplace
entitiesNo
score_thresholdNo
operator_paramsNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries the full burden of behavioral disclosure. It mentions the tool 'anonymizes' text but doesn't clarify whether this is a read-only operation, what permissions are needed, if it's destructive to the input, rate limits, or error handling. The return format is mentioned but lacks detail on structure or edge cases.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is efficiently structured with a brief purpose statement followed by a bullet-point style breakdown of args and returns. Every sentence adds value without redundancy, and it's front-loaded with the core functionality.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's moderate complexity (6 parameters, no annotations, but has an output schema), the description is reasonably complete. It covers all parameters and mentions the return format. However, it lacks behavioral context and usage guidelines, which are important for a tool that modifies sensitive data (PII). The output schema existence reduces the need to detail return values.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description must compensate. It provides clear explanations for all 6 parameters, including defaults and examples (e.g., operator options like 'replace', 'redact', and operator_params example). This adds significant meaning beyond the bare schema, though it could elaborate more on entity types or score_threshold implications.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the specific action ('Anonymize PII in text') and resource ('text'), distinguishing it from sibling tools like 'anonymize_structured_data' which handles structured data instead of text. The verb 'anonymize' is precise and differentiates from analysis tools in the same server.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance is provided on when to use this tool versus alternatives like 'anonymize_structured_data' or 'batch_anonymize'. The description mentions what the tool does but offers no context about appropriate use cases, prerequisites, or exclusions.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/cmalpass/mcp-presidio'

If you have feedback or need assistance with the MCP directory API, please join our Discord server