Skip to main content
Glama

delete_text

Remove targeted text from a Word paragraph, with support for precise anchoring and optional tracked changes for review.

Instructions

Delete text from a paragraph.

Finds the text within the paragraph (across run boundaries if needed). With tracked=True (default) the deleted text stays visible as red strikethrough in Word's Track Changes view — the human reviewer must accept the deletion to remove it permanently. With tracked=False the text is removed immediately.

Provide context_before/context_after to disambiguate when the same text appears multiple times, or when it contains smart quotes / special whitespace.

Args: para_id: paraId of the target paragraph. text: Text to delete (ASCII quotes/dashes/spaces match their Unicode equivalents). author: Author name shown in Word's review pane (tracked=True only). context_before: Text immediately before the target (for precise anchoring). context_after: Text immediately after the target (for precise anchoring). ignore_case: If True, match text and context case-insensitively. tracked: True (default) = red strikethrough the human accepts/rejects. False = text removed immediately, no markup. document_handle: Optional handle for concurrent session isolation.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
para_idYes
textYes
authorNoClaude
context_beforeNo
context_afterNo
ignore_caseNo
trackedNo
document_handleNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior4/5

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

Describes tracked behavior (red strikethrough), matching ASCII equivalents, and cross-run boundaries. No annotations provided, so description carries full burden; could mention error handling but overall sufficient.

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

Conciseness4/5

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

Well-structured with clear summary, tracked explanation, disambiguation guidance, and parameter list. Slightly lengthy but each sentence adds value.

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?

Covers core behavior, tracking, ambiguous text handling, and parameters. Output schema exists, so return values are covered. Could mention text-not-found behavior but complete enough for a deletion tool.

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

Parameters5/5

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

Schema coverage is 0%, but description adds extensive meaning via Args section, explaining each parameter (e.g., text matching, context disambiguation, tracked behavior), far beyond the schema titles.

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 'Delete text from a paragraph' with specific verb and resource, and distinguishes from siblings like delete_paragraph or delete_table by focusing on in-paragraph text deletion.

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?

Provides explicit guidance on tracked vs untracked modes and disambiguation with context_before/after, but does not explicitly state when not to use this tool versus alternatives like replace_text.

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/SecurityRonin/docx-mcp'

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