Skip to main content
Glama

model_modelFieldRemove

Remove a field from an Anki flashcard model to simplify note structure and eliminate unnecessary data fields.

Instructions

Removes a field from an existing model.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
modelNameYesName of the model to modify.
fieldNameYesName of the field to remove.

Implementation Reference

  • The core handler function for the tool 'model_modelFieldRemove'. It invokes AnkiConnect's modelFieldRemove action to remove a field from a model.
    @model_mcp.tool(
        name="modelFieldRemove", description="Removes a field from an existing model."
    )
    async def remove_model_field_tool(                                                        
        modelName: Annotated[str, Field(description="Name of the model to modify.")],
        fieldName: Annotated[str, Field(description="Name of the field to remove.")],
    ) -> None:
        return await anki_call("modelFieldRemove", modelName=modelName, fieldName=fieldName)
  • Registers the model service tools under the 'model_' prefix, making 'modelFieldRemove' available as 'model_modelFieldRemove'.
    await anki_mcp.import_server("model", model_mcp)
  • Utility function used by the handler to communicate with the AnkiConnect API.
    async def anki_call(action: str, **params: Any) -> Any:
        async with httpx.AsyncClient() as client:
            payload = {"action": action, "version": 6, "params": params}
            result = await client.post(ANKICONNECT_URL, json=payload)
            result.raise_for_status()                                      
            result_json = result.json()
            error = result_json.get("error")
            if error:
                raise Exception(f"AnkiConnect error for action '{action}': {error}")
            response = result_json.get("result")
                                                                 
                                                                                                         
                                                                                            
            if "result" in result_json:
                return response
            return result_json                                                                        
  • Creates the sub-MCP instance for model tools where the tool is decorated and registered locally.
    model_mcp = FastMCP(name="AnkiModelService")
Behavior2/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It states this is a removal operation, implying mutation, but doesn't cover critical aspects like whether this action is reversible, what permissions are required, how it affects existing data, or error conditions (e.g., if the field doesn't exist). For a mutation tool with zero annotation coverage, this is a significant gap in 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?

The description is a single, direct sentence with zero wasted words—it front-loads the core action and target efficiently. Every word earns its place, making it easy to parse and understand quickly without unnecessary elaboration.

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

Completeness2/5

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

Given the tool's complexity (a mutation operation with no annotations and no output schema), the description is incomplete. It lacks information on behavioral traits (e.g., side effects, error handling), usage context, and output expectations, leaving the agent under-informed for safe and effective invocation in a real-world scenario.

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?

The input schema has 100% description coverage, with clear documentation for both 'modelName' and 'fieldName'. The description adds no additional parameter semantics beyond what's in the schema (e.g., no format examples or constraints), so it meets the baseline of 3 where the schema does the heavy lifting without compensating value.

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 action ('Removes') and the target ('a field from an existing model'), making the purpose immediately understandable. However, it doesn't distinguish this tool from its sibling 'model_modelFieldAdd' (which adds fields) or other model-modification tools like 'model_updateModelStyling', leaving room for improvement in sibling differentiation.

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?

The description provides no guidance on when to use this tool versus alternatives. It doesn't mention prerequisites (e.g., the model must exist), when not to use it (e.g., if the field is critical), or refer to sibling tools like 'model_modelFieldAdd' for adding fields or 'model_updateModelStyling' for other modifications, leaving the agent without contextual usage cues.

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/ujisati/anki-mcp'

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