Skip to main content
Glama

Edit a text file

overleaf_edit_file

Replace an exact string in Overleaf LaTeX project files to edit content precisely and directly.

Instructions

Replace an exact string inside a project file.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
filePathYes
newStringYes
oldStringYes
projectIdNo
replaceAllNo
Behavior2/5

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

With no annotations, the description must fully disclose behavior. It only states 'replace an exact string' and omits details about replaceAll behavior, error handling when oldString is not found, project selection requirements, or file existence assumptions. This leaves significant ambiguity.

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 a single concise sentence with no redundancy. It is front-loaded and every word contributes to the core purpose.

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

Completeness1/5

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

For a 5-parameter mutation tool with no annotations and no output schema, this description is severely incomplete. It fails to explain crucial behaviors like replacement scope, project context, and failure modes, making it inadequate for correct agent usage.

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

Parameters1/5

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

The description adds no meaning to the parameters. With 0% schema description coverage, it should at least explain the roles of oldString, newString, filePath, projectId, and replaceAll, but it does not mention any of them.

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

Purpose4/5

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

The description clearly states the tool replaces an exact string in a project file, using a specific verb and resource. It distinguishes from sibling tools like overleaf_write_file by emphasizing 'exact string', though it does not explicitly name alternatives.

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 such as overleaf_write_file or overleaf_grep. There is no mention of appropriate scenarios, prerequisites, or exclusions, leaving the agent without decision support.

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/MarvelCollin/overleaf-claude-mcp'

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