Skip to main content
Glama
lundgrenalex

MCP FishBase Server

by lundgrenalex

search_species

Find marine species by entering common names or partial scientific names to retrieve detailed biological information from FishBase data.

Instructions

Search for species by common name or partial scientific name

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
queryYesSearch term (common name or partial scientific name)
limitNoMaximum number of results to return (default: 20)

Implementation Reference

  • MCP tool handler for 'search_species': calls fishbaseAPI.searchSpecies with query and limit parameters, stringifies the result as JSON text response.
    case "search_species":
      return {
        content: [
          {
            type: "text",
            text: JSON.stringify(
              await fishbaseAPI.searchSpecies(args.query as string, (args.limit as number) || 20),
              null,
              2
            ),
          },
        ],
      };
  • src/index.ts:49-67 (registration)
    Registration of the 'search_species' tool in ListToolsRequestHandler, including name, description, and input schema definition.
    {
      name: "search_species",
      description: "Search for species by common name or partial scientific name",
      inputSchema: {
        type: "object",
        properties: {
          query: {
            type: "string",
            description: "Search term (common name or partial scientific name)",
          },
          limit: {
            type: "number",
            description: "Maximum number of results to return (default: 20)",
            default: 20,
          },
        },
        required: ["query"],
      },
    },
  • Core implementation of species search: filters species data from 'species' table by matching query against scientific or common names, limits results.
    async searchSpecies(query: string, limit: number = 20): Promise<SpeciesData[]> {
      try {
        const speciesData = await this.queryTable('species');
        const lowerQuery = query.toLowerCase();
        
        const filtered = speciesData.filter((row: any) => {
          const scientificName = `${row.Genus || ''} ${row.Species || ''}`.toLowerCase();
          const commonName = (row.FBname || '').toLowerCase();
          return scientificName.includes(lowerQuery) || commonName.includes(lowerQuery);
        }).slice(0, limit);
    
        return filtered;
      } catch (error) {
        throw new Error(`Failed to search species: ${error}`);
      }
    }
Behavior2/5

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

No annotations are provided, so the description carries the full burden of behavioral disclosure. While it indicates this is a search operation, it lacks details on permissions, rate limits, pagination, error handling, or the format of results. For a search tool with zero annotation coverage, this leaves significant gaps in understanding how the tool behaves beyond its basic function.

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, efficient sentence that directly states the tool's purpose without any redundant or unnecessary words. It is front-loaded with the core action and resource, making it easy to parse quickly. Every part of the sentence earns its place by conveying essential information.

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 lack of annotations and output schema, the description is incomplete for a search tool. It doesn't explain what the results look like (e.g., list of species with fields), how to handle large result sets, or any behavioral constraints. While the purpose is clear, the overall context for effective use by an AI agent is insufficient.

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 schema description coverage is 100%, meaning the input schema fully documents both parameters ('query' and 'limit') with clear descriptions and defaults. The description adds no additional parameter semantics beyond what's in the schema, such as search syntax or result ordering. According to the rules, with high schema coverage (>80%), the baseline score is 3.

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 tool's purpose: searching for species using either common names or partial scientific names. It specifies the verb 'search' and the resource 'species', making the intent unambiguous. However, it doesn't explicitly differentiate this from sibling tools like 'get_species' or 'validate_species_name', which prevents a perfect score.

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 sibling tools like 'get_species' (which might retrieve specific species) or 'validate_species_name' (which might check name validity), nor does it specify any prerequisites, exclusions, or contextual cues for choosing this search function.

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/lundgrenalex/mcp-fishbase'

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