Skip to main content
Glama

redact_text

Permanently remove sensitive text from Word documents, scanning body, headers, footnotes, and metadata. Verifies successful redaction and reports unexamined content, leaving the file unchanged on any error.

Instructions

Permanently REMOVE matched text (true redaction: the characters are replaced in the XML, not highlighted). targets: [{find, regex?}]. Runmap-safe: secrets fragmented across Word's split runs are removed as one match. Scrubs body incl. tables, headers/footers, footnotes/endnotes (per scope: body | headers | footnotes | all), and ALWAYS: comment text, document properties, hyperlink text/tooltips/URL targets, field instructions, cached field results, tracked-change deleted text. Reports per-class counts, what was NOT examined (images, charts, OLE; text drawn in an image is not redacted), and verified_clean from a full post-redaction re-scan. Zero-width regexes and empty finds are refused up front; any error leaves the file unchanged. Irreversible in the saved file: the prev backup slot is the undo. Auto-backup: prev/anchor slots in .ks4w-backups (backup=False skips rotation only); atomic validated save. Refuses documents open in Word.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
scopeNoall
backupNo
targetsYes
file_pathYes
replacementNo[REDACTED]

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Behavior5/5

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

With no annotations, the description carries the full burden and does so thoroughly. It discloses destructive permanence, backup/undo behavior, scope handling, always-scrubbed areas, non-examined content like images and charts, verified_clean re-scanning, atomic error handling, and refusal of open documents. This is exemplary behavioral transparency.

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?

Despite the length, every sentence carries a distinct operational fact relevant to safe invocation: what is redacted, what is skipped, how backups work, failure guarantees, and irreversibility. The main action is front-loaded, and there is no filler or repetition.

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

Completeness5/5

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

For a destructive tool with no annotations, the description is remarkably complete: it covers scope, limitations, backup behavior, failure atomicity, verification, and open-document refusal. An output schema exists, so the description does not need to explain return shapes, and the mention of per-class counts and verified_clean fills the key reporting context.

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

Parameters3/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 does explain targets loosely ('[{find, regex?}]'), scope options, and backup behavior, but it does not document file_path or replacement semantics in the description, and the targets structure remains ambiguous about whether `regex?` is a boolean or a regex string. Partial compensation only.

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 opens with 'Permanently REMOVE matched text' and explicitly contrasts true redaction with highlighting ('not highlighted'), making the operation and its intent unmistakable. It also distinguishes this tool from search/replace-style siblings by emphasizing permanent removal and post-redaction verification.

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

Usage Guidelines4/5

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

The description clearly conveys when to use this tool: when permanent redaction is required, not reversible highlighting or replacement. It also warns that the operation is irreversible and refuses documents open in Word. It does not explicitly name alternative sibling tools, but the context is sufficiently clear for an agent to select it appropriately.

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/nometalalchemist/KitchenSink4Word'

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