Skip to main content
Glama
microbiomedata

nmdc-mcp

Official

get_samples_by_annotation

Find biosamples with specific functional annotations (PFAM, KEGG, COG, GO) and retrieve complete records including data objects like GFF files with IDs and URLs.

Instructions

Use this tool to find biosamples with specific functional annotations. Returns COMPLETE biosample records including all data objects (GFF files, protein files, etc.) with their IDs and URLs. ALWAYS set max_records to match the user's request (e.g., if they ask for '1 sample' or 'a sample', set max_records=1). Use max_records, NOT limit, to control how many samples to return. Required formats: PFAM domains use 'PFAM:PF04183', KEGG use 'KEGG.ORTHOLOGY:K00001', COG use 'COG:COG0001', GO use 'GO:GO0000001'. When users want genomic locations of domains, use this first to find samples, then use fetch_and_filter_gff_by_pfam_domains with a GFF data_object_id from the results.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
gene_function_idsYes
max_recordsNo
limitNo
offsetNo
Behavior4/5

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

With no annotations, the description compensates well by stating it returns 'COMPLETE biosample records including all data objects (GFF files, protein files, etc.) with their IDs and URLs.' It also explains required ID formats. However, it lacks details on default behavior when max_records is null and does not mention offset handling.

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?

The description is well-front-loaded with the primary purpose, and each subsequent sentence adds value (usage guidelines, parameter behavior, chaining with other tools). It could be slightly shorter by combining some sentences, but overall efficient.

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?

Given no output schema, the description explains the return structure (complete records with data objects). It covers the main use case and mentions chaining with a sibling tool. Missing details on pagination (offset and limit behavior) are minor, but the description is largely complete for an agent.

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 0%, so the description adds meaning for 'gene_function_ids' (required formats) and 'max_records' (use instead of limit). It also clarifies not to use 'limit'. However, it does not explain 'offset' and 'limit' defaults, leaving some gaps.

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 clearly states the tool finds biosamples with specific functional annotations, specifying the resource ('biosamples') and verb ('find'). It distinguishes from siblings like 'get_samples_by_ecosystem' and 'get_biosamples_for_study' by focusing on functional annotations.

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

Usage Guidelines5/5

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

The description provides explicit usage guidance: 'ALWAYS set max_records to match the user's request', advises against using 'limit', gives required formats for identifiers, and directs when to follow up with 'fetch_and_filter_gff_by_pfam_domains' for genomic locations.

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/microbiomedata/nmdc-mcp'

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