Skip to main content
Glama

get_protein_orthologs

Identify orthologous proteins for evolutionary studies by comparing a UniProt protein across organisms. Use this tool to find protein counterparts in different species.

Instructions

Identify orthologous proteins for evolutionary studies

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
accessionYesUniProt accession number
organismNoTarget organism to find orthologs in
sizeNoNumber of results to return (1-100, default: 25)

Implementation Reference

  • The handler function that executes the tool logic: validates input, fetches the source protein details, constructs a UniProt search query using the gene name in the target organism, retrieves matching proteins, and returns the results as JSON.
    private async handleGetProteinOrthologs(args: any) {
      if (!isValidHomologArgs(args)) {
        throw new McpError(ErrorCode.InvalidParams, 'Invalid ortholog search arguments');
      }
    
      try {
        // Get the protein info first
        const proteinResponse = await this.apiClient.get(`/uniprotkb/${args.accession}`, {
          params: { format: 'json' },
        });
        const protein = proteinResponse.data;
    
        // Build ortholog search (similar function, different organism)
        let query = `reviewed:true`;
        if (protein.genes?.[0]?.geneName?.value) {
          query += ` AND gene:"${protein.genes[0].geneName.value}"`;
        }
        if (args.organism) {
          query += ` AND organism_name:"${args.organism}"`;
        }
        query += ` NOT accession:"${args.accession}"`;
    
        const response = await this.apiClient.get('/uniprotkb/search', {
          params: {
            query: query,
            format: 'json',
            size: args.size || 25,
          },
        });
    
        return {
          content: [
            {
              type: 'text',
              text: JSON.stringify(response.data, null, 2),
            },
          ],
        };
      } catch (error) {
        return {
          content: [
            {
              type: 'text',
              text: `Error finding orthologs: ${error instanceof Error ? error.message : 'Unknown error'}`,
            },
          ],
          isError: true,
        };
      }
    }
  • src/index.ts:489-500 (registration)
    Tool registration in the list of available tools, including name, description, and input schema definition.
      name: 'get_protein_orthologs',
      description: 'Identify orthologous proteins for evolutionary studies',
      inputSchema: {
        type: 'object',
        properties: {
          accession: { type: 'string', description: 'UniProt accession number' },
          organism: { type: 'string', description: 'Target organism to find orthologs in' },
          size: { type: 'number', description: 'Number of results to return (1-100, default: 25)', minimum: 1, maximum: 100 },
        },
        required: ['accession'],
      },
    },
  • src/index.ts:743-744 (registration)
    Dispatch registration in the CallToolRequestSchema switch statement, mapping the tool name to its handler.
    case 'get_protein_orthologs':
      return this.handleGetProteinOrthologs(args);
  • Input schema definition for the get_protein_orthologs tool, specifying parameters and validation rules.
    inputSchema: {
      type: 'object',
      properties: {
        accession: { type: 'string', description: 'UniProt accession number' },
        organism: { type: 'string', description: 'Target organism to find orthologs in' },
        size: { type: 'number', description: 'Number of results to return (1-100, default: 25)', minimum: 1, maximum: 100 },
      },
      required: ['accession'],
    },
  • Validation helper function used by the orthologs handler to check input arguments.
    const isValidHomologArgs = (
      args: any
    ): args is { accession: string; organism?: string; size?: number } => {
      return (
        typeof args === 'object' &&
        args !== null &&
        typeof args.accession === 'string' &&
        args.accession.length > 0 &&
        (args.organism === undefined || typeof args.organism === 'string') &&
        (args.size === undefined || (typeof args.size === 'number' && args.size > 0 && args.size <= 100))
      );
    };
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. It states the tool 'identifies' orthologous proteins but doesn't explain how (e.g., algorithm, data sources), what the output looks like, or any limitations (e.g., rate limits, accuracy). This is a significant gap for a tool with no annotation coverage.

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: 'Identify orthologous proteins for evolutionary studies.' It's front-loaded with the core purpose and contains no redundant information, making it highly concise and well-structured.

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 (identifying orthologs involves biological inference) and lack of annotations and output schema, the description is incomplete. It doesn't address behavioral traits, output format, or limitations, which are crucial for an agent to use it effectively in evolutionary studies.

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?

Schema description coverage is 100%, so the schema already documents all parameters (accession, organism, size) with descriptions. The description adds no additional parameter semantics beyond what's in the schema, such as explaining relationships between parameters or usage examples. Baseline 3 is appropriate when the schema does the heavy lifting.

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: 'Identify orthologous proteins for evolutionary studies.' It specifies the action (identify), resource (orthologous proteins), and context (evolutionary studies). However, it doesn't explicitly differentiate from sibling tools like 'get_protein_homologs' or 'get_phylogenetic_info,' 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 prerequisites, exclusions, or compare it to similar tools like 'get_protein_homologs' or 'compare_proteins,' leaving the agent to infer usage from the name alone.

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/Augmented-Nature/UniProt-MCP-Server'

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