Skip to main content
Glama
robobobby
by robobobby

dk_compare_weather

Compare current weather conditions between two Danish locations to inform travel decisions or analyze regional climate differences.

Instructions

Compare current weather between two Danish locations side by side. Useful for deciding between destinations or comparing conditions across the country.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
location1YesFirst location (city name, postal code, or coordinates)
location2YesSecond location

Implementation Reference

  • The handler function for dk_compare_weather which fetches and compares weather data for two locations.
    async ({ location1, location2 }) => {
      try {
        const [loc1, loc2] = await Promise.all([getLocation(location1), getLocation(location2)]);
        const [data1, data2] = await Promise.all([
          openMeteoFetch({
            latitude: loc1.lat, longitude: loc1.lon,
            current: "temperature_2m,apparent_temperature,precipitation,weather_code,wind_speed_10m,cloud_cover",
          }),
          openMeteoFetch({
            latitude: loc2.lat, longitude: loc2.lon,
            current: "temperature_2m,apparent_temperature,precipitation,weather_code,wind_speed_10m,cloud_cover",
          }),
        ]);
        const c1 = data1.current, c2 = data2.current;
        const wx1 = WMO_CODES[c1.weather_code] || "", wx2 = WMO_CODES[c2.weather_code] || "";
        const lines = [
          `## Weather Comparison\n`,
          `| | ${loc1.name} | ${loc2.name} |`,
          `|---|---|---|`,
          `| **Conditions** | ${wx1} | ${wx2} |`,
          `| **Temperature** | ${c1.temperature_2m}°C | ${c2.temperature_2m}°C |`,
          `| **Feels like** | ${c1.apparent_temperature}°C | ${c2.apparent_temperature}°C |`,
          `| **Wind** | ${c1.wind_speed_10m} km/h | ${c2.wind_speed_10m} km/h |`,
          `| **Cloud cover** | ${c1.cloud_cover}% | ${c2.cloud_cover}% |`,
          `| **Precipitation** | ${c1.precipitation} mm | ${c2.precipitation} mm |`,
          `\n*DMI HARMONIE 2km model*`,
        ];
        return { content: [{ type: "text", text: lines.join("\n") }] };
      } catch (err) {
        return { content: [{ type: "text", text: `Error: ${err.message}` }], isError: true };
      }
    }
  • Registration of the dk_compare_weather tool, including its name, description, and input schema.
    server.tool(
      "dk_compare_weather",
      "Compare current weather between two Danish locations side by side. Useful for deciding between destinations or comparing conditions across the country.",
      {
        location1: z.string().describe("First location (city name, postal code, or coordinates)"),
        location2: z.string().describe("Second location"),
      },
Behavior2/5

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

No annotations are provided, so the description carries full burden. It mentions 'current weather' and 'side by side' comparison, which implies read-only behavior and output format. However, it lacks critical behavioral details: whether it requires authentication, rate limits, error handling, data freshness, or what specific weather metrics are compared (temperature, precipitation, etc.). For a tool with no annotations, this is insufficient disclosure.

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 perfectly concise: two sentences with zero waste. The first sentence states the core functionality, and the second provides usage context. Every word earns its place, and it's front-loaded with the essential purpose.

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

Completeness3/5

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

Given no annotations and no output schema, the description is moderately complete. It covers the basic purpose and usage context but lacks behavioral details (e.g., output format, error cases) and doesn't fully compensate for the missing structured data. For a comparison tool with two simple parameters, it's adequate but has clear gaps in transparency.

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%, with both parameters clearly documented in the schema. The description adds no additional parameter information beyond implying two locations are needed for comparison. Since the schema already fully describes the parameters, the baseline score of 3 is appropriate—the description doesn't add value here but doesn't need to compensate.

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: 'Compare current weather between two Danish locations side by side.' It specifies the verb ('compare'), resource ('current weather'), and scope ('Danish locations'), distinguishing it from generic weather tools. However, it doesn't explicitly differentiate from sibling 'fi_compare_weather' (Finnish version) beyond the 'Danish' qualifier.

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?

The description provides clear usage context: 'Useful for deciding between destinations or comparing conditions across the country.' This gives practical scenarios when to use the tool. However, it doesn't specify when NOT to use it (e.g., vs. 'dk_current_weather' for single locations or 'dk_weather_forecast' for future conditions), nor does it explicitly name alternatives.

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/robobobby/mcp-nordic'

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