Skip to main content
Glama

Search Structures

search_structures
Read-onlyIdempotent

Search the Crystallography Open Database (COD), an open repository of crystal structures (inorganic, organic, metal-organic, and mineral). Search by compound name (free text), chemical formula, or mineral name; returns matching crystal structures with unit-cell parameters, space group, year, and a link to the CIF structure file. Keyless. Provide at least one of query, formula, or mineral. Formulas are normalized to COD's stored Hill notation for you, so "NaCl", "SiO2" and "CaCO3" all work; the response reports formula_searched with the exact string that was matched.

Example tool call

This call uses example arguments supplied in the tool’s input schema.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "query": "quartz"
    },
    "name": "search_structures"
  }
}

Input Schema

NameRequiredDescriptionDefault
limitNoMax structures to return (default 20, max 100).
queryNoFree-text search (compound/common name, title words, author, etc.). e.g. "quartz", "aspirin".
formulaNoChemical formula in any common spelling, "NaCl", "SiO2", "CaCO3", "C6H6", or COD's own "O2 Si". It is converted to COD's stored Hill form (C first, then H, then the rest alphabetically; counts of 1 omitted) before searching. Matches the whole stoichiometry exactly, so "SiO2" will not match "CaMgSi2O6".
mineralNoMineral name, e.g. "Quartz", "Calcite", "Halite". Matched against each structure's mineral field (case-insensitive substring), so "Quartz" also returns "Quartz low" / "Quartz high".

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / formula / description
      Previous value: -"Chemical formula in any common spelling — \"NaCl\", \"SiO2\", \"CaCO3\", \"C6H6\", or COD's own \"O2 Si\". It is converted to COD's stored Hill form (C first, then H, then the rest alphabetically; counts of 1 omitted) before searching. Matches the whole stoichiometry exactly, so \"SiO2\" will not match \"CaMgSi2O6\"."New value: +"Chemical formula in any common spelling, \"NaCl\", \"SiO2\", \"CaCO3\", \"C6H6\", or COD's own \"O2 Si\". It is converted to COD's stored Hill form (C first, then H, then the rest alphabetically; counts of 1 omitted) before searching. Matches the whole stoichiometry exactly, so \"SiO2\" will not match \"CaMgSi2O6\"."
  2. Changed4 schema fields changed
    • changedInput schema / examples
      Previous value: -[
      -  {
      -    "query": "quartz"
      -  },
      -  {
      -    "formula": "Si O2",
      -    "limit": 10
      -  },
      -  {
      -    "mineral": "Calcite"
      -  }
      -]New value: +[
      +  {
      +    "query": "quartz"
      +  },
      +  {
      +    "formula": "SiO2",
      +    "limit": 10
      +  },
      +  {
      +    "mineral": "Calcite"
      +  }
      +]
    • changedInput schema / properties / formula / description
      Previous value: -"Chemical formula, e.g. \"As Ga O4\" (elements space-separated)."New value: +"Chemical formula in any common spelling — \"NaCl\", \"SiO2\", \"CaCO3\", \"C6H6\", or COD's own \"O2 Si\". It is converted to COD's stored Hill form (C first, then H, then the rest alphabetically; counts of 1 omitted) before searching. Matches the whole stoichiometry exactly, so \"SiO2\" will not match \"CaMgSi2O6\"."
    • changedInput schema / properties / mineral / description
      Previous value: -"Mineral name, e.g. \"Calcite\". Note: the COD mineral field is sparsely populated, so this often returns no results."New value: +"Mineral name, e.g. \"Quartz\", \"Calcite\", \"Halite\". Matched against each structure's mineral field (case-insensitive substring), so \"Quartz\" also returns \"Quartz low\" / \"Quartz high\"."
    • changedInput schema / properties / query / description
      Previous value: -"Free-text search (compound/common name, title words, author, etc.). e.g. \"quartz\"."New value: +"Free-text search (compound/common name, title words, author, etc.). e.g. \"quartz\", \"aspirin\"."
  3. Changed1 schema field changed
    • addedInput schema / examples
      Added value: +[
      +  {
      +    "query": "quartz"
      +  },
      +  {
      +    "formula": "Si O2",
      +    "limit": 10
      +  },
      +  {
      +    "mineral": "Calcite"
      +  }
      +]
  4. First observed

TDQS

A4.4/5.0
Behavior4/5

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

Annotations already cover read-only, idempotent, non-destructive, open-world behavior, so the safety profile needs no restating. The description adds genuinely non-obvious traits: keyless access, automatic normalization of formulas into COD's Hill notation, exact whole-stoichiometry matching (SiO2 will not match CaMgSi2O6), and the formula_searched echo field. Missing only notes on pagination or empty-result behavior.

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?

Front-loaded with what the database is and what the agent gets back, then the operational constraint, then the formula caveat — a sensible order. There is mild redundancy, since the Hill-notation explanation appears in both the description and the formula parameter's schema text.

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

Completeness5/5

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

With no output schema, the description carries the return-value burden and does it: unit-cell parameters, space group, year, CIF link, and the formula_searched field. Combined with the coverage of auth (keyless), matching semantics, and result limits in the schema, nothing an agent needs to call this correctly is absent.

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 baseline is 3; the description nevertheless adds a cross-parameter constraint absent from the schema (at least one of query/formula/mineral must be supplied) and explains the practical consequence of formula matching semantics with a concrete non-match example. Much of the normalization text duplicates the schema's own formula description, which keeps it out of 5 territory.

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?

States a specific verb and resource ('Search the Crystallography Open Database') and enumerates the searchable dimensions (compound name, formula, mineral), plus what a hit contains. An agent can distinguish this discovery tool from the fetch-style siblings get_structure and get_cif without opening any 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?

Explicitly states the entry condition 'Provide at least one of query, formula, or mineral', which is real when-to-use guidance, and the mineral substring note tells the agent what breadth to expect. It stops short of naming get_structure/get_cif as the follow-up path, so the search-vs-fetch routing is only implied by the CIF link mention.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.