Skip to main content
Glama
santanusinha

neovim-use-mcp

by santanusinha

Insert lines

nvim_insert_lines

Insert text before a specified line in a file, or append by using a line beyond the end. Saves the buffer without triggering format-on-save autocmds by default.

Instructions

Insert text before the given line, 1-based. Use a line beyond the end to append. Saves without running format-on-save autocmds by default.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
lineYesInsert before this line, 1-based
pathYesFile path
saveNoWrite the buffer, default true
textYesText to insert; use \n for several lines
Behavior4/5

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

Beyond the annotations, the description discloses save behavior and that format-on-save autocmds are skipped by default. This adds meaningful context about side effects not inferable from readOnlyHint/idempotentHint/destructiveHint.

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 two concise sentences with no fluff. The primary operation is front-loaded, followed by a key usage edge case and an important behavioral detail. Every sentence earns its place.

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?

For a simple insertion tool with no output schema, the description covers the operation, line indexing, append behavior, and save/default formatting behavior. It is sufficiently complete, though it does not mention potential errors or the effect of save=false explicitly.

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 coverage is 100%, so the schema already documents all parameters. The description adds value by explaining that a line beyond the end appends, and by clarifying the default save behavior, which goes beyond the schema's bare descriptions.

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 operation: insert text before a given 1-based line. It is specific enough to identify the tool's main function, though it does not explicitly contrast it with sibling tools like nvim_edit_lines or nvim_edit_text.

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 clear usage context: lines are 1-based, and using a line beyond the end appends. It does not explicitly mention alternatives or when not to use this tool, but the append guidance gives actionable usage directions.

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/santanusinha/neovim-use-mcp'

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