Skip to main content
Glama

upsert_functional_groups_batch

Batch insert or update functional groups for a specific molecule, matching existing groups by lowercased name to avoid duplicate entries.

Instructions

Batch insert or update functional groups for a specific molecule matching on lower(name).

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "molecule_id": "<molecule_id>",
      "functional_groups": "<functional_groups>"
    },
    "name": "upsert_functional_groups_batch"
  }
}

Input Schema

NameRequiredDescriptionDefault
molecule_idYesParent Molecule ID
functional_groupsYesArray of functional groups to upsert

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

A3.6/5.0
Behavior3/5

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

With no annotations, the description carries the full behavioral burden. It usefully discloses the upsert conflict rule ('matching on lower(name)') and batch semantics, but omits transaction/atomicity behavior, partial-failure handling, required permissions, and what is returned or overwritten.

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 definition is a single front-loaded sentence with no redundant wording. Every phrase contributes operation, resource, scope, or matching behavior.

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

Completeness3/5

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

For a two-parameter tool with full schema description coverage, the definition is sufficient to make a correct call. However, as a mutation tool with no annotations or output schema, it should say more about transactional behavior, failure modes, and when to prefer the single-record alternatives.

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 parameter basics are already documented. The description adds meaningful semantics not present in the schema by explaining that names are matched case-insensitively via 'lower(name)', which is central to how the upsert decides to insert versus update.

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 states a specific verb ('Batch insert or update'), a specific resource ('functional groups'), the parent scope ('for a specific molecule'), and the conflict key ('matching on lower(name)'). This clearly distinguishes it from single-record create/update tools, though it does not explicitly differentiate it from sibling bulk/populate tools.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The phrase 'Batch insert or update' implies this tool is for bulk upserts, but the description never states when to use it instead of create_functional_group, update_functional_group, populate_functional_groups_bulk, or populate_molecule_functional_groups. Usage is only implied by the operation name and scope.

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