Skip to main content
Glama

lib_delete_component

Deletes one named component from a .SchLib schematic library and marks the library dirty for deferred save; errors with COMPONENT_NOT_FOUND if the name is missing.

Instructions

Delete one symbol from a schematic library (.SchLib).

Removes the component whose LibReference is component_name and marks the library dirty for deferred save (flushed by app_save_all). Deletes a single named part; if the name is not found the call errors (COMPONENT_NOT_FOUND) rather than silently doing nothing. There is no wildcard mass-delete.

Args: component_name: the component's LibReference (its library name). library_path: optional absolute .SchLib path to target; defaults to the currently focused library document. component_index: alternative to component_name; the integer index from lib_get_components. Use it to delete a part whose name carries unreproducible bytes (embedded quote or control char). Provide exactly one of the two.

Returns: {"success": true, "library_path": "...", "deleted": "..."}.

Input Schema

NameRequiredDescriptionDefault
library_pathNo
component_nameNo
component_indexNo

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.6.1

TDQS

A4.4/5.0
Behavior4/5

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

With no annotations, the description carries the full load and does so well: it discloses that the library is marked dirty for deferred save flushed by app_save_all, that a missing name raises COMPONENT_NOT_FOUND rather than silently succeeding, and that there is no wildcard mass-delete. It omits whether deletion is undoable or requires the library to be writable, which matters for a destructive mutation.

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?

Behavioral caveats are front-loaded before the Args block, and the structured layout scans well. The explicit Returns section partly duplicates the existing output schema, slightly diminishing the value of every line.

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 three-parameter destructive library operation with no annotations, the description covers targeting, error semantics, and persistence, and the output schema handles return values. Missing only authorization/undo context, which is a modest gap rather than a blocking one.

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%, so the description must compensate fully — and it does, documenting all three parameters, their meaning (LibReference, absolute .SchLib path, integer index from lib_get_components), the defaults, and the mutual-exclusivity constraint that the schema cannot express.

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 a specific verb and resource ('Delete one symbol from a schematic library (.SchLib)') and immediately bounds scope ('a single named part', 'no wildcard mass-delete'), which separates it from footprint deletion and generic object deletion siblings. An agent can identify the operation without opening the schema.

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?

It explains default behavior (targets the currently focused library document) and gives explicit parameter-selection guidance ('Provide exactly one of the two'), including the niche case for using component_index when a name has unreproducible bytes. It does not name alternative sibling tools (e.g., lib_delete_footprint, obj_delete), so it stops short of full when-not guidance.

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

Deploy Server

Other Tools