Skip to main content
Glama
rakeshgangwar

Formula One MCP Server

get_driver_info

Retrieve detailed information about a specific Formula One driver, including their performance statistics for a given year, event, and session, using the Formula One MCP Server.

Instructions

Get information about a specific Formula One driver

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
driver_identifierYesDriver identifier (number, code, or name; e.g., "44", "HAM", "Hamilton")
event_identifierYesEvent name or round number (e.g., "Monaco" or "7")
session_nameYesSession name (e.g., "Race", "Qualifying", "Sprint", "FP1", "FP2", "FP3")
yearYesSeason year (e.g., 2023)

Implementation Reference

  • Core handler function that executes the tool logic: loads F1 session data and retrieves specific driver information using the fastf1 library.
    def get_driver_info(year, event_identifier, session_name, driver_identifier):
        """Get information about a specific driver"""
        try:
            year = int(year)
            session = fastf1.get_session(year, event_identifier, session_name)
            session.load(telemetry=False)  # Load session without telemetry for faster results
            
            driver_info = session.get_driver(driver_identifier)
            
            # Convert to JSON serializable format
            driver_dict = driver_info.to_dict()
            clean_dict = {k: json_serial(v) for k, v in driver_dict.items()}
            
            return {"status": "success", "data": clean_dict}
        except Exception as e:
            return {"status": "error", "message": str(e), "traceback": traceback.format_exc()}
  • Tool schema definition including name, description, and input validation schema for the get_driver_info tool.
    {
      name: 'get_driver_info',
      description: 'Get information about a specific Formula One driver',
      inputSchema: {
        type: 'object',
        properties: {
          year: {
            type: 'number',
            description: 'Season year (e.g., 2023)',
          },
          event_identifier: {
            type: 'string',
            description: 'Event name or round number (e.g., "Monaco" or "7")',
          },
          session_name: {
            type: 'string',
            description: 'Session name (e.g., "Race", "Qualifying", "Sprint", "FP1", "FP2", "FP3")',
          },
          driver_identifier: {
            type: 'string',
            description: 'Driver identifier (number, code, or name; e.g., "44", "HAM", "Hamilton")',
          },
        },
        required: ['year', 'event_identifier', 'session_name', 'driver_identifier'],
      },
    },
  • src/index.ts:317-326 (registration)
    MCP tool registration and dispatching logic in the CallToolRequest handler switch statement.
    case 'get_driver_info': {
      const typedArgs = args as DriverInfoArgs;
      result = await executePythonFunction('get_driver_info', [
        typedArgs.year.toString(),
        typedArgs.event_identifier.toString(),
        typedArgs.session_name.toString(),
        typedArgs.driver_identifier.toString(),
      ]);
      break;
    }
  • Internal registration of the get_driver_info function in the Python dispatch dictionary.
    "get_driver_info": get_driver_info,
Behavior2/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure but only states it 'gets information' without specifying what type of information (e.g., biographical, performance stats), format, or any constraints like rate limits, authentication needs, or data freshness. This is inadequate for a tool with four required parameters and no output schema.

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, direct sentence with zero wasted words, front-loading the core purpose efficiently. It's appropriately sized for a straightforward retrieval tool, making it easy for an agent to parse quickly.

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 complexity (four required parameters, no output schema, and no annotations), the description is incomplete. It doesn't explain what information is returned, how results are structured, or any behavioral traits like error handling. This leaves significant gaps for an agent to invoke the tool correctly without additional context.

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%, so the input schema fully documents all four parameters with clear descriptions and examples. The description adds no additional parameter semantics beyond implying it retrieves driver-specific data, which is already evident from the tool name and schema. This meets the baseline for high schema coverage.

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 verb ('Get') and resource ('information about a specific Formula One driver'), making the purpose evident. However, it doesn't explicitly differentiate from sibling tools like 'analyze_driver_performance' or 'get_session_results', which might also provide driver-related information in different contexts.

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, context (e.g., historical vs. real-time data), or how it differs from siblings like 'analyze_driver_performance' or 'get_session_results', leaving the agent to infer usage from parameters 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

Related 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/rakeshgangwar/f1-mcp-server'

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